Windows: graphify update can hang in tempfile.mkstemp while saving manifest
Maintainers usually reply within 1 day
Nobody has claimed this yet.
- #3663 by @nikhilsaxena04 — closed without merging
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 25/100
Research direction
Start in graphify/paths.py at _atomic_replace() and write_json_atomic(), then trace their callers in graphify/detect.py and graphify/watch.py. Review linked PR #3663 and reproduce graphify update . on Windows; done means the command completes or reports a visible, actionable error naming the manifest target.
Written by the indexing model from the issue text.
Description
Summary
On Windows, graphify update . can stop after AST extraction and never return. A faulthandler dump shows that Graphify is blocked in tempfile.mkstemp() while saving manifest.json.
Environment
- graphifyy 0.9.63
- Python 3.11.15, 64-bit
- Windows 11 Pro, version 10.0.26200, build 26200
- Target manifest path length: 55 characters (local project path redacted)
Reproduction
-
Use a project with an existing
graphify-out/directory and roughly 1,090 code files. -
Run:
graphify update . -
The command reports progress through AST extraction, for example:
AST extraction: 1000/1088 uncached files (91%) -
It then remains active without printing a completion message or returning.
A 20-second faulthandler timeout captured this stack:
File "...\Lib\tempfile.py", line 257 in _mkstemp_inner
File "...\Lib\tempfile.py", line 358 in mkstemp
File "...\graphify\paths.py", line 120 in _atomic_replace
File "...\graphify\paths.py", line 165 in write_json_atomic
File "...\graphify\detect.py", line 2418 in save_manifest
File "...\graphify\watch.py", line 1988 in _rebuild_code
Expected behavior
graphify update . completes or fails with a visible error and an actionable target path.
Actual behavior
The process blocks indefinitely in temporary-file creation. There is no final success or failure output.
Additional observations
- The graph artifacts had already been written and the resulting graph was valid (11,158 nodes, 40,276 edges; no missing or dangling endpoints).
- The manifest target is deliberately short, so this does not appear to be the Windows path-length issue described in #3351.
- In the current code,
_atomic_replace()callstempfile.mkstemp(dir=str(real.parent), prefix=".gfy-", suffix=".tmp")directly. The existing fallback around the lateros.replace()step cannot handle a block before that point.
A bounded retry/timeout around temporary-file creation, plus explicit diagnostic output naming the target file, would make this failure mode recoverable.
- Dominant language
- Python
- Stars
- 124k
- Forks
- 11.9k
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Graphify-Labs/graphify
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
Graphify-Labs/graphify#3763 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Graphify-Labs/graphify#3611 · 1 comment ·
Maintainers usually reply within 1 day
-
Nix supportOpen
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Graphify-Labs/graphify#3193 · 2 reactions ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 92/100
Graphify-Labs/graphify#2871 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Graphify-Labs/graphify#2865 ·
Maintainers usually reply within 1 day
All issues in Graphify-Labs/graphify
Similar issues
-
Difficulty 1/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
tharje/spooler-v2#20 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
-
Bump version of azure-servicebusPossibly taken @joostlek claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
home-assistant/core#186275 ·
Maintainers usually reply within 1 day
-
documentation
Difficulty 1/5 Under an hour Newbie friendliness 72/100