Bug 42984 - webkit-patch post-commits is broken: AttributeError: Values instance has no attribute 'no_squash'
Summary: webkit-patch post-commits is broken: AttributeError: Values instance has no a...
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
Depends on:
Reported: 2010-07-26 11:24 PDT by David Kilzer (:ddkilzer)
Modified: 2010-07-27 13:24 PDT (History)
3 users (show)

See Also:

Patch (4.53 KB, patch)
2010-07-27 13:00 PDT, Ojan Vafai
eric: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Kilzer (:ddkilzer) 2010-07-26 11:24:37 PDT
$ ./WebKitTools/Scripts/webkit-patch post-commits -m "Patch v1" HEAD
Traceback (most recent call last):
  File "./WebKitTools/Scripts/webkit-patch", line 64, in <module>
  File "./WebKitTools/Scripts/webkit-patch", line 59, in main
  File "/Volumes/Data/WebKit.git/WebKitTools/Scripts/webkitpy/tool/multicommandtool.py", line 308, in main
    result = command.check_arguments_and_execute(options, args, self)
  File "/Volumes/Data/WebKit.git/WebKitTools/Scripts/webkitpy/tool/multicommandtool.py", line 117, in check_arguments_and_execute
    return self.execute(options, args, tool) or 0
  File "/Volumes/Data/WebKit.git/WebKitTools/Scripts/webkitpy/tool/commands/upload.py", line 288, in execute
    steps.ObsoletePatches(tool, options).run(state)
  File "/Volumes/Data/WebKit.git/WebKitTools/Scripts/webkitpy/tool/steps/abstractstep.py", line 38, in __init__
    if options.no_squash:
AttributeError: Values instance has no attribute 'no_squash'

Note that "upload" keeps opening an editor for a patch that already has a ChangeLog, which is not what I want either:

./WebKitTools/Scripts/webkit-patch upload -m "Patch v1" -g HEAD
Comment 1 Eric Seidel (no email) 2010-07-26 12:29:00 PDT
Looks like this needs a test case. :)  Ojan is our master of --no-squash...
Comment 2 Ojan Vafai 2010-07-27 13:00:13 PDT
Created attachment 62731 [details]
Comment 3 Eric Seidel (no email) 2010-07-27 13:13:41 PDT
Comment on attachment 62731 [details]

How does this change PostCommits?
Comment 4 Ojan Vafai 2010-07-27 13:20:50 PDT
This issue was that post-commits used an object that inherited from AbstractStep, which would check the values of these options without using the options in the AbstractStep itself. I think there's an architectural issue in the code here, but I'm not sure it's worth fixing now.
Comment 5 Ojan Vafai 2010-07-27 13:24:00 PDT
Committed r64153: <http://trac.webkit.org/changeset/64153>