You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the platform code, a tempfile used for linking (or other usage, for that matter) is deleted immediately upon use - it's built in to the command generated to use the tempfile:
(the exact contents of rm is determined a bit earlier).
The problem is in interactive mode, you want to be able to repeat commands, and that command is cached in a node, so it's just reissued, except the tempfile no longer exists, having been removed on first use. This simple reproducer was provided in the original thread:
I've confirmed this with some investigation. The node caching does take place; Interactive knows it has to do some work to prepare for a future build, as seen in:
# Clean up so that we can perform the next build correctly.
...
SCons.Script.Main.progress_display("scons: Clearing cached node information ...")
When we re-execute, it appears this command line is still there's in the node.attibutes.tempfile_cmdlist, where it was put for a reasonbly good reason:
# Store the temporary file command list into the target Node.attributes# to avoid creating two temporary files one for print and one for execute.
See PR #3801 (and referenced earlier ones) which also touch on this area - originally proposed not caching, but then evolved to a different solution.
The text was updated successfully, but these errors were encountered:
Opened from discord thread starting at https://discord.com/channels/571796279483564041/571796280146133047/1280915150005604394
In the platform code, a tempfile used for linking (or other usage, for that matter) is deleted immediately upon use - it's built in to the command generated to use the tempfile:
scons/SCons/Platform/__init__.py
Line 312 in b2a103b
(the exact contents of
rm
is determined a bit earlier).The problem is in interactive mode, you want to be able to repeat commands, and that command is cached in a node, so it's just reissued, except the tempfile no longer exists, having been removed on first use. This simple reproducer was provided in the original thread:
https://github.com/imuzzolini-vigrade/scons-interactive
I've confirmed this with some investigation. The node caching does take place; Interactive knows it has to do some work to prepare for a future build, as seen in:
When we re-execute, it appears this command line is still there's in the
node.attibutes.tempfile_cmdlist
, where it was put for a reasonbly good reason:See PR #3801 (and referenced earlier ones) which also touch on this area - originally proposed not caching, but then evolved to a different solution.
The text was updated successfully, but these errors were encountered: