Closed
Bug 1962245
Opened 24 days ago
Closed 23 days ago
Jujutsu: Internal error: Failed to access working copy state
Categories
(Firefox Build System :: Mach Core, defect, P3)
Firefox Build System
Mach Core
Tracking
(firefox139 fixed)
RESOLVED
FIXED
139 Branch
Tracking | Status | |
---|---|---|
firefox139 | --- | fixed |
People
(Reporter: ahochheiden, Assigned: ahochheiden)
References
Details
Attachments
(1 file)
I regularly CTRL+C
to cancel a running ./mach
process. When using jj
and doing that, the following regularly happens:
KeyboardInterrupt
mach interrupted by signal or user action. Stopping.
ahochheiden@Alex-Mozilla-P620 /d/mozilla-source/mozilla-unified
$ ^C
ahochheiden@Alex-Mozilla-P620 /d/mozilla-source/mozilla-unified
$ jj log
Internal error: Failed to access working copy state
Caused by:
1: Failed to lock working copy
2: Timed out while trying to create lock file: D:\mozilla-source\mozilla-unified\.jj\working_copy\working_copy.lock
3: The file exists. (os error 80)
And I have to manually delete the working_copy.lock
before I can use jj
again.
My naive solution would be to add something like the following to the JujutsuRepository
class:
def _run(self, *args, **kwargs):
try:
return super()._run(*args, **kwargs)
except KeyboardInterrupt as error:
working_copy_lock = self.jj_ws_root / ".jj" / "working_copy" / "working_copy.lock"
working_copy_lock.unlink()
print(f"\nRemoved: {working_copy_lock}")
raise error
except Exception as error:
raise error
But I'm not sure if that's wise.
:beth mentioned that adding --ignore-working-copy
to the jj
commands that don't modify the repo state would prevent the lock, but I'm not sure I fully understand the implications, since the description for that flag doesn't quite line up with what I think we need.
:sfink what do you think?
Flags: needinfo?(sphink)
Assignee | ||
Comment 1•24 days ago
|
||
Updated•24 days ago
|
Assignee: nobody → ahochheiden
Attachment #9480680 -
Attachment description: WIP: Bug 1962245: Add `--ignore-working-copy` to various `jj` commands in `JujutsuRepository` r?sfink → Bug 1962245: Add `--ignore-working-copy` to various `jj` commands in `JujutsuRepository` r?sfink
Status: NEW → ASSIGNED
Updated•24 days ago
|
Attachment #9480680 -
Attachment description: Bug 1962245: Add `--ignore-working-copy` to various `jj` commands in `JujutsuRepository` r?sfink → Bug 1962245: Add a `_run_read_only` function in `JujutsuRepository` r?sfink
Updated•24 days ago
|
Attachment #9480680 -
Attachment description: Bug 1962245: Add a `_run_read_only` function in `JujutsuRepository` r?sfink → Bug 1962245: Add a `_run_read_only` function to `JujutsuRepository` r?sfink
Pushed by ahochheiden@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c85afcf62f3b
Add a `_run_read_only` function to `JujutsuRepository` r=sfink
Comment 4•23 days ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 23 days ago
status-firefox139:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 139 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•