Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HgPoller._stopOnFailure() missing 1 required positional argument: 'f' #7488

Closed
Zash opened this issue Mar 28, 2024 · 0 comments · Fixed by #7553
Closed

HgPoller._stopOnFailure() missing 1 required positional argument: 'f' #7488

Zash opened this issue Mar 28, 2024 · 0 comments · Fixed by #7553
Labels

Comments

@Zash
Copy link
Contributor

Zash commented Mar 28, 2024

Looking at updating a BuildBot instance from 2.10.1 (on Debian 11) to
3.7.0 and encountered this error in the logs:

2024-03-28 16:12:32+0000 [-] <buildbot.changes.hgpoller.HgPoller object at 0x7f7e3c580750>: while polling for changes
	Traceback (most recent call last):
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 700, in errback
	    self._startRunCallbacks(fail)
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 763, in _startRunCallbacks
	    self._runCallbacks()
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 857, in _runCallbacks
	    current.result = callback(  # type: ignore[misc]
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 1750, in gotResult
	    current_context.run(_inlineCallbacks, r, gen, status)
	--- <exception caught here> ---
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 1656, in _inlineCallbacks
	    result = current_context.run(
	  File "/usr/lib/python3/dist-packages/twisted/python/failure.py", line 517, in throwExceptionIntoGenerator
	    return g.throw(self.type, self.value, self.tb)
	  File "/usr/lib/python3/dist-packages/buildbot/changes/hgpoller.py", line 145, in poll
	    yield self._getChanges()
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 1656, in _inlineCallbacks
	    result = current_context.run(
	  File "/usr/lib/python3/dist-packages/twisted/python/failure.py", line 517, in throwExceptionIntoGenerator
	    return g.throw(self.type, self.value, self.tb)
	  File "/usr/lib/python3/dist-packages/buildbot/changes/hgpoller.py", line 219, in _getChanges
	    yield self._initRepository()
	  File "/usr/lib/python3/dist-packages/twisted/internet/defer.py", line 1660, in _inlineCallbacks
	    result = current_context.run(gen.send, result)
	  File "/usr/lib/python3/dist-packages/buildbot/changes/hgpoller.py", line 210, in _initRepository
	    self._stopOnFailure()
	builtins.TypeError: HgPoller._stopOnFailure() missing 1 required positional argument: 'f'

Which seems to point here:

if rc != 0:
self._stopOnFailure()
raise EnvironmentError(f'{self}: repository init failed with exit code {rc}')

And it looks like this has not changed in main.

Configuration snippet:

c["change_source"].append(
    changes.HgPoller(
        "https://hg.prosody.im/trunk/",
        workdir="hgpoller-prosody-trunk",
        revlink=lambda branch, revision: "https://hg.prosody.im/trunk/rev/{}".format(revision[:12]),
        pollAtLaunch=True,
        pollInterval=257,
        pollRandomDelayMax=31,
        pollRandomDelayMin=0,
    )
)
  • Buildbot 3.7.0 in Debian 12
  • Python 3.11.2
@p12tic p12tic added the bug label Apr 29, 2024
tdesveaux added a commit to tdesveaux/buildbot that referenced this issue May 2, 2024
No longer used sinced _stopOnFailure is no longer called by deferred.addErrback since buildbot#6046

Fixes buildbot#7488
p12tic pushed a commit to p12tic/buildbot that referenced this issue May 4, 2024
No longer used sinced _stopOnFailure is no longer called by deferred.addErrback since buildbot#6046

Fixes buildbot#7488
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants