Skip to content

Update docs and usage of TEMPFILE/TempFileMunge - #4597

Merged
bdbaddog merged 2 commits into
SCons:masterfrom
mwichmann:issue/TEMPFILE-fiddle
Sep 16, 2024
Merged

bdbaddog merged 2 commits into
SCons:masterfrom
mwichmann:issue/TEMPFILE-fiddle

Conversation

@mwichmann

Copy link
Copy Markdown
Collaborator

tempfiles are now cleaned up via registering a cleanup with atexit(), instead of trying to squeeze removing the file into the command line. On Windows that caused the file to get deleted too early (did not work well with interactive mode), and on Linux it didn't remove the file at all.

The Platform test expected to be able to read the tempfile name as the last argument of the "command", but this is no longer provided as the rm filename (or on Windows del filename) is no longer added, so now it has to chop off the prefix from the command-file argument to get the filename.

Unrelatedly, two syntax warnings that turn up in the test output where some TeX syntax was listed in a docstring in a test are fixed by making that a raw string - got tired of seeing these.

Fixes #4595

Contributor Checklist:

  • I have created a new test or updated the unit tests to cover the new/changed functionality.
  • I have updated CHANGES.txt (and read the README.rst)
  • I have updated the appropriate documentation

mwichmann and others added 2 commits September 14, 2024 13:17
tempfiles are now cleaned up via registering a cleanups with atexit(),
instead of trying to squeeze removing the file into the command line.
On Windows that caused the file to get deleted too early (did not work
well with interactive mode), and on Linux it didn't remove the file
at all.

The Platform test expected to be able to read the tempfilename as
the last argument of the "command", but this is no longer provided
as the "rm filename" is no longer added, so now it has to chop off
the prefix from the command-file argument to get the filename.

Unrelatedly, two syntax warnings that turn up in the test output where
some TeX syntax was listed in a docstring in a test are fixed by making
that a raw string - got tired of seeing these.

Fixes SCons#4595

Signed-off-by: Mats Wichmann <[email protected]>
@bdbaddog
bdbaddog merged commit 4e005ff into SCons:master Sep 16, 2024
@mwichmann mwichmann added the TEMPFILE Long-command-line handling with TEMPFILE label Sep 16, 2024
@mwichmann mwichmann added this to the NextRelease milestone Sep 16, 2024
@mwichmann
mwichmann deleted the issue/TEMPFILE-fiddle branch September 16, 2024 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

TEMPFILE Long-command-line handling with TEMPFILE

Projects

No open projects
Status: Complete

Development

Successfully merging this pull request may close these issues.

Interactive mode and TEMPFILE don't get along

2 participants