Closed Bug 1630668 Opened 5 years ago Closed 5 years ago

TypeError when running `./mach try syntax`

Categories

(Developer Infrastructure :: Try, defect)

defect

Tracking

(firefox77 fixed)

RESOLVED FIXED
mozilla77
Tracking Status
firefox77 --- fixed

People

(Reporter: willdurand, Assigned: rstewart)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: regression)

Attachments

(1 file)

Hi, I wanted to push to Try and I reused a command I used yesterday (or the day before yesterday) but I received an error:

$ ./mach try syntax --no-artifact -b do -p win32,linux64,macosx64 -u mochitests,test-verify,xpcshell -t none
Error running mach:

    ['try', 'syntax', '--no-artifact', '-b', 'do', '-p', 'win32,linux64,macosx64', '-u', 'mochitests,test-verify,xpcshell', '-t', 'none']

The error occurred in code that was called by the mach command. This is either
a bug in the called code itself or in the way that mach is calling it.
You can invoke |./mach busted| to check if this issue is already on file. If it
isn't, please use |./mach busted file| to report it. If |./mach busted| is
misbehaving, you can also inspect the dependencies of bug 1543241.

If filing a bug, please include the full output of mach, including this error
message.

The details of the failure are as follows:

TypeError: add_remove_files() takes exactly 2 arguments (1 given)

  File "/Users/williamdurand/projects/mozilla/gecko/tools/tryselect/mach_commands.py", line 416, in try_syntax
    return self.run(**kwargs)
  File "/Users/williamdurand/projects/mozilla/gecko/tools/tryselect/mach_commands.py", line 177, in run
    return mod.run(**kwargs)
  File "/Users/williamdurand/projects/mozilla/gecko/tools/tryselect/selectors/syntax.py", line 613, in run
    return at.run(**kwargs)
  File "/Users/williamdurand/projects/mozilla/gecko/tools/tryselect/selectors/syntax.py", line 608, in run
    closed_tree=kwargs["closed_tree"])
  File "/Users/williamdurand/projects/mozilla/gecko/tools/tryselect/push.py", line 178, in push_to_try
    vcs.add_remove_files(*changed_files)

Do I have to update some dependencies manually or something? (sorry if that's a silly question).

Otherwise, this could maybe be related to https://bugzilla.mozilla.org/show_bug.cgi?id=1630047.

Flags: needinfo?(mozilla)

Yeah, that patch is messed up. The method signatures of add_remove_files and forget_add_remove_files differ in incompatible ways across the parent class and the subclasses. I can get a fix in in a moment.

Assignee: nobody → rstewart
Priority: -- → P3
Regressed by: 1630047
Has Regression Range: --- → yes
Keywords: regression

:rstewart thanks! I confirm applying the attached patch fixes the problem for me.

Flags: needinfo?(mozilla)

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: General → Try

The component has been changed since the backlog priority was decided, so we're resetting it.
For more information, please visit auto_nag documentation.

Priority: P3 → --
Pushed by rstewart@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b411dd8c786a Fix incompatible type signatures in subclasses of Repository r=dmajor

FWIW with this and the bug 1630047 patch applied, I get this message when I do a ./mach try:

Nothing specified, nothing added.
Maybe you wanted to say 'git add .'?

The try push itself works fine though.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla77
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: