jobserver.py: fix very rare python3 failure reported by a user.
Traceback (most recent call last):
File "/nix/store/i0835myyhrfr13lh4y26r58406kk90xj-redo-apenwarr-0.42a/bin/../lib/redo/cmd_ifchange.py", line 54, in main
jobserver.force_return_tokens()
File "/nix/store/i0835myyhrfr13lh4y26r58406kk90xj-redo-apenwarr-0.42a/bin/../lib/redo/jobserver.py", line 482, in force_return_tokens
os.write(_cheatfds[1], 't' * _cheats)
TypeError: a bytes-like object is required, not 'str'
Unfortunately I wasn't able to replicate it, but this is obviously the right fix.
This commit is contained in:
parent
c1054a5902
commit
aa920f12ed
1 changed files with 1 additions and 1 deletions
|
|
@ -479,7 +479,7 @@ def force_return_tokens():
|
||||||
_debug('%d,%d -> force_return_tokens: recovering final token\n'
|
_debug('%d,%d -> force_return_tokens: recovering final token\n'
|
||||||
% (_mytokens, _cheats))
|
% (_mytokens, _cheats))
|
||||||
_destroy_tokens(_cheats)
|
_destroy_tokens(_cheats)
|
||||||
os.write(_cheatfds[1], 't' * _cheats)
|
os.write(_cheatfds[1], b't' * _cheats)
|
||||||
assert state.is_flushed()
|
assert state.is_flushed()
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue