Skip to content

Conversation

@renovate
Copy link
Contributor

@renovate renovate bot commented Nov 11, 2024

This PR contains the following updates:

Package Type Update Change
tempfile (source) dev-dependencies minor 3.13.0 -> 3.20.0

Release Notes

Stebalien/tempfile (tempfile)

v3.20.0

Compare Source

This release mostly unifies the behavior/capabilities around "keeping" temporary files:

  • Rename Builder::keep(bool) (via deprecation) to Builder::disable_cleanup(bool) to make it clear that behaves differently from NamedTempFile::keep(). The former disables automatic cleanup while the latter consumes the NamedTempFile object entirely and unsets the "temporary file" attribute (on Windows).
  • Rename TempDir::into_path (via deprecation) to TempDir::keep to mirror NamedTempFile::keep.
  • Add TempDir::disable_cleanup, NamedTempFile::disable_cleanup, and TempPath::disable_cleanup making it possible to disable automatic cleanup in-place after creating a temporary file/directory (equivalent to calling Builder::disable_cleanup before creating the file/directory).

Additionally, it adds a few spooled temporary file features:

  • Add SpooledTempFile::into_file for turning a SpooledTempFile into a regular unnamed temporary file, writing it to the backing storage ("rolling" it) if it was still stored in-memory.
  • Add spooled_tempfile_in and SpooledTempFile::new_in methods for creating spooled temporary files in a specific directory. This makes it possible to choose the backing device for your spooled temporary file which is rather important on Linux where the default temporary directory is likely backed by memory (defeating the entire point of having a spooled temporary file).

Finally, this release improves documentation, especially the top-level documentation explaining which temporary file type to use.

BREAKING for those with deny(warnings):

  • Builder::keep deprecated in favor of Builder::disable_cleanup.
  • TempDir::into_path is deprecated in favor of TempDir::keep.

BREAKING:

v3.19.1

Compare Source

  • Don't unlink temporary files immediately on Windows (fixes #​339). Unfortunately, this seemed to corrupt the file object (possibly a Windows kernel bug) in rare cases and isn't strictly speaking necessary.

v3.19.0

Compare Source

  • Remove direct dependency on cfg-if. It's still in the tree, but we didn't really need to use it in this crate.
  • Add an unstable feature (unstable-windows-keep-open-tempfile) to test a potential fix to #​339.

v3.18.0

Compare Source

  • Update rustix to 1.0.0.
  • Make NamedTempFile::persist_noclobber atomic on Apple operating systems. It's now atomic on MacOS, Windows, and Linux (depending on the OS version and filesystem used).

v3.17.1

Compare Source

  • Fix build with windows-sys 0.52. Unfortunately, we have no CI for older windows-sys versions at the moment...

v3.17.0

Compare Source

  • Make sure to use absolute paths in when creating unnamed temporary files (avoids a small race in the "immediate unlink" logic) and in Builder::make_in (when creating temporary files of arbitrary types).
  • Prevent a theoretical crash that could (maybe) happen when a temporary file is created from a drop function run in a TLS destructor. Nobody has actually reported a case of this happening in practice and I have been unable to create this scenario in a test.
  • When reseeding with getrandom, use platform (e.g., CPU) specific randomness sources where possible.
  • Clarify some documentation.
  • Unlink unnamed temporary files on windows immediately when possible instead of waiting for the handle to be closed. We open files with "Unix" semantics, so this is generally possible.

v3.16.0

Compare Source

  • Update getrandom to 0.3.0 (thanks to @​paolobarbolini).
  • Allow windows-sys versions 0.59.x in addition to 0.59.0 (thanks @​ErichDonGubler).
  • Improved security documentation (thanks to @​n0toose for collaborating with me on this).

v3.15.0

Compare Source

Re-seed the per-thread RNG from system randomness when we repeatedly fail to create temporary files (#​314). This resolves a potential DoS vector (#​178) while avoiding getrandom in the common case where it's necessary. The feature is optional but enabled by default via the getrandom feature.

For libc-free builds, you'll either need to disable this feature or opt-in to a different getrandom backend.

v3.14.0

Compare Source

  • Make the wasip2 target work (requires tempfile's "nightly" feature to be enabled). #​305.
  • Allow older windows-sys versions #​304.

Configuration

📅 Schedule: Branch creation - "every 2nd week starting on the 2 week of the year before 4am on Monday" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@bitwarden-bot bitwarden-bot changed the title [deps]: Update Rust crate tempfile to v3.14.0 [PM-14692] [deps]: Update Rust crate tempfile to v3.14.0 Nov 11, 2024
@bitwarden-bot
Copy link

Internal tracking:

@codecov
Copy link

codecov bot commented Nov 11, 2024

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 7.32%. Comparing base (f1b32df) to head (72422ba).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@          Coverage Diff          @@
##            main   #1172   +/-   ##
=====================================
  Coverage   7.32%   7.32%           
=====================================
  Files         20      20           
  Lines       1378    1378           
=====================================
  Hits         101     101           
  Misses      1277    1277           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@renovate renovate bot changed the title [PM-14692] [deps]: Update Rust crate tempfile to v3.14.0 [deps]: Update Rust crate tempfile to v3.14.0 Nov 11, 2024
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.14.0 [deps]: Update Rust crate tempfile to v3.15.0 Jan 2, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 038ecca to 1ad2f7a Compare January 2, 2025 23:30
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.15.0 [deps]: Update Rust crate tempfile to v3.16.0 Jan 28, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch 2 times, most recently from f019c2a to 49a4b53 Compare February 4, 2025 03:21
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.16.0 [deps]: Update Rust crate tempfile to v3.15.0 Feb 4, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 49a4b53 to 297900e Compare February 4, 2025 22:50
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.15.0 [deps]: Update Rust crate tempfile to v3.16.0 Feb 4, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 297900e to 3cd5bd5 Compare February 24, 2025 00:41
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.16.0 [deps]: Update Rust crate tempfile to v3.17.0 Feb 24, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 3cd5bd5 to 42d130c Compare February 24, 2025 17:55
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.17.0 [deps]: Update Rust crate tempfile to v3.17.1 Feb 24, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 42d130c to 46e4d23 Compare March 13, 2025 20:14
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.17.1 [deps]: Update Rust crate tempfile to v3.18.0 Mar 13, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 46e4d23 to bcede53 Compare March 21, 2025 05:02
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.18.0 [deps]: Update Rust crate tempfile to v3.19.0 Mar 21, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from bcede53 to e5738bc Compare March 26, 2025 17:53
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.19.0 [deps]: Update Rust crate tempfile to v3.19.1 Mar 26, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from e5738bc to 80207f7 Compare May 18, 2025 21:01
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.19.1 [deps]: Update Rust crate tempfile to v3.20.0 May 18, 2025
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 80207f7 to 482955d Compare June 25, 2025 19:08
@renovate renovate bot requested a review from a team as a code owner June 25, 2025 19:08
@renovate renovate bot force-pushed the renovate/tempfile-3.x-lockfile branch from 482955d to 72422ba Compare July 30, 2025 12:01
@renovate renovate bot changed the title [deps]: Update Rust crate tempfile to v3.20.0 [deps]: Update Rust crate tempfile to v3.20.0 - autoclosed Jul 31, 2025
@renovate renovate bot closed this Jul 31, 2025
@renovate renovate bot deleted the renovate/tempfile-3.x-lockfile branch July 31, 2025 18:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants