Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | tempfile: Use random.choises() instead of choise() (GH-23068) | Inada Naoki | 2020-11-01 | 1 | -2/+2 |
| | |||||
* | Revert "bpo-42160: tempfile: Reduce overhead of pid check. (GH-22997)" | Inada Naoki | 2020-10-31 | 1 | -2/+2 |
| | | | | | `_RandomNameSequence` is not true singleton so using `os.register_at_fork` doesn't make sense unlike `random._inst`. This reverts commit 8e409cebad42032bb7d0f2cadd8b1e36081d98af. | ||||
* | bpo-42160: tempfile: Reduce overhead of pid check. (GH-22997) | Eric W | 2020-10-30 | 1 | -2/+2 |
| | | | | The _RandomSequence class in tempfile used to check the current pid every time its rng property was used. This commit replaces this code with `os.register_at_fork` to reduce the overhead. | ||||
* | bpo-40275: Use new test.support helper submodules in tests (GH-21169) | Hai Shi | 2020-06-30 | 1 | -8/+12 |
| | |||||
* | bpo-40443: Remove unused imports in tests (GH-19805) | Victor Stinner | 2020-04-29 | 1 | -1/+0 |
| | |||||
* | bpo-40287: Fix SpooledTemporaryFile.seek() return value (GH-19540) | Inada Naoki | 2020-04-17 | 1 | -2/+4 |
| | | | It has not returned the file position after the seek. | ||||
* | bpo-39481: Implementation for PEP 585 (#18239) | Guido van Rossum | 2020-04-07 | 1 | -2/+3 |
| | | | | | | | | | | | | This implements things like `list[int]`, which returns an object of type `types.GenericAlias`. This object mostly acts as a proxy for `list`, but has attributes `__origin__` and `__args__` that allow recovering the parts (with values `list` and `(int,)`. There is also an approximate notion of type variables; e.g. `list[T]` has a `__parameters__` attribute equal to `(T,)`. Type variables are objects of type `typing.TypeVar`. | ||||
* | bpo-40094: Add test.support.wait_process() (GH-19254) | Victor Stinner | 2020-03-31 | 1 | -9/+1 |
| | | | | | | | | | Moreover, the following tests now check the child process exit code: * test_os.PtyTests * test_mailbox.test_lock_conflict() * test_tempfile.test_process_awareness() * test_uuid.testIssue8621() * multiprocessing resource tracker tests | ||||
* | bpo-39019: Implement missing __class_getitem__ for SpooledTemporaryFile ↵ | Batuhan Taşkaya | 2019-12-30 | 1 | -0/+3 |
| | | | | | | (GH-17560) | ||||
* | bpo-26730: Fix SpooledTemporaryFile data corruption (GH-17400) | Inada Naoki | 2019-11-27 | 1 | -11/+14 |
| | | | | | | | SpooledTemporaryFile.rollback() might cause data corruption when it is in text mode. Co-Authored-By: Serhiy Storchaka <storchaka@gmail.com> | ||||
* | bpo-35803: Document and test dir=PathLike for tempfile (GH-11644) | Anthony Sottile | 2019-09-09 | 1 | -2/+14 |
| | | | Co-Authored-By: Ammar Askar <ammar_askar@hotmail.com> | ||||
* | bpo-26660, bpo-35144: Fix permission errors in TemporaryDirectory cleanup. ↵ | Serhiy Storchaka | 2019-05-31 | 1 | -9/+42 |
| | | | | | | | (GH-10320) TemporaryDirectory.cleanup() failed when non-writeable or non-searchable files or directories were created inside a temporary directory. | ||||
* | bpo-22831: Use "with" to avoid possible fd leaks in tests (part 2). (GH-10929) | Serhiy Storchaka | 2019-03-05 | 1 | -6/+4 |
| | |||||
* | Clean up code which checked presence of os.{stat,lstat,chmod} (#11643) | Anthony Sottile | 2019-02-25 | 1 | -10/+2 |
| | |||||
* | bpo-27300: Add the errors parameter to tempfile classes. (GH-6696) | sth | 2018-05-23 | 1 | -1/+10 |
| | |||||
* | bpo-31160: test_tempfile: Fix reap_children() warning (#3056) | Victor Stinner | 2017-08-10 | 1 | -1/+7 |
| | | | | TestRandomNameSequence.test_process_awareness() now calls os.waitpid() to avoid leaking a zombie process. | ||||
* | bpo-30197: Enhance functions swap_attr() and swap_item() in test.support. ↵ | Serhiy Storchaka | 2017-04-28 | 1 | -3/+2 |
| | | | | | | | | | | | | | (#1341) * bpo-30197: Enhance functions swap_attr() and swap_item() in test.support. They now work when delete replaced attribute or item inside the with statement. The old value of the attribute or item (or None if it doesn't exist) now will be assigned to the target of the "as" clause, if there is one. * Update docstrings. | ||||
* | bpo-30030: Revert f50354ad (tempfile) (#1187) | Victor Stinner | 2017-04-19 | 1 | -3/+2 |
| | | | | Revert f50354adaaafebe95ad09d09b825804a686ea843: it introduced a regression in test_threadedtempfile. | ||||
* | Reimplement tempfile._RandomNameSequence using a generator function. (#1075) | Serhiy Storchaka | 2017-04-11 | 1 | -2/+3 |
| | |||||
* | Issue #26385: Cleanup NamedTemporaryFile if open() fails, by SilentGhost | Martin Panter | 2016-02-28 | 1 | -1/+9 |
| | |||||
* | Issue 24230: The tempfile module now accepts bytes for prefix, suffix and dir | Gregory P. Smith | 2015-05-22 | 1 | -21/+148 |
| | | | | parameters and returns bytes in such situations (matching the os module APIs). | ||||
* | Issue #22107: tempfile.gettempdir() and tempfile.mkdtemp() now try again | Serhiy Storchaka | 2015-05-19 | 1 | -6/+41 |
|\ | | | | | | | | | | | when a directory with the chosen name already exists on Windows as well as on Unix. tempfile.mkstemp() now fails early if parent directory is not valid (not exists or is a file) on Windows. | ||||
| * | Issue #22107: tempfile.gettempdir() and tempfile.mkdtemp() now try again | Serhiy Storchaka | 2015-05-19 | 1 | -6/+41 |
| | | | | | | | | | | | | when a directory with the chosen name already exists on Windows as well as on Unix. tempfile.mkstemp() now fails early if parent directory is not valid (not exists or is a file) on Windows. | ||||
* | | Issue #9517: Move script_helper to the support package. | Berker Peksag | 2015-05-06 | 1 | -1/+2 |
| | | | | | | | | Patch by Christie Wilson. | ||||
* | | Issue #21741: Update 147 test modules to use test discovery. | Zachary Ware | 2015-04-13 | 1 | -4/+1 |
|/ | | | | | | | I have compared output between pre- and post-patch runs of these tests to make sure there's nothing missing and nothing broken, on both Windows and Linux. The only differences I found were actually tests that were previously *not* run. | ||||
* | Issue #23700: Iterator of NamedTemporaryFile now keeps a reference to | Serhiy Storchaka | 2015-03-19 | 1 | -0/+13 |
| | | | | NamedTemporaryFile instance. Patch by Bohuslav Kabrda. | ||||
* | Issue #22427: TemporaryDirectory no longer attempts to clean up twice when | Serhiy Storchaka | 2014-09-24 | 1 | -0/+24 |
| | | | | used in the with statement in generator. | ||||
* | Issue #18174: Fix leak of file descriptor in test_tempfile | Victor Stinner | 2014-07-28 | 1 | -0/+4 |
| | |||||
* | Issue #21058: fix typo in a comment. Patch written by Vajrasky Kok. | Victor Stinner | 2014-03-25 | 1 | -1/+1 |
| | |||||
* | Issue #21058: Fix a leak of file descriptor in tempfile.NamedTemporaryFile(), | Victor Stinner | 2014-03-25 | 1 | -0/+24 |
| | | | | close the file descriptor if io.open() fails | ||||
* | Issue #19077: tempfile.TemporaryDirectory cleanup no longer fails when | Serhiy Storchaka | 2014-01-27 | 1 | -47/+39 |
|\ | | | | | | | | | called during shutdown. Emitting resource warning in __del__ no longer fails. Original patch by Antoine Pitrou. | ||||
| * | Issue #19077: tempfile.TemporaryDirectory cleanup is now most likely | Serhiy Storchaka | 2014-01-27 | 1 | -47/+37 |
| | | | | | | | | | | | | successful when called during nulling out of modules during shutdown. Misleading exception no longer raised when resource warning is emitted during shutdown. | ||||
* | | Issue #18879: When a method is looked up on a temporary file, avoid closing ↵ | Antoine Pitrou | 2013-12-21 | 1 | -0/+17 |
|\ \ | |/ | | | | | the file before the method is possibly called. | ||||
| * | Issue #18879: When a method is looked up on a temporary file, avoid closing ↵ | Antoine Pitrou | 2013-12-21 | 1 | -0/+17 |
| | | | | | | | | the file before the method is possibly called. | ||||
* | | Issue 19572: More silently skipped tests explicitly skipped. | Zachary Ware | 2013-12-08 | 1 | -8/+4 |
|\ \ | |/ | |||||
| * | Issue 19572: More silently skipped tests explicitly skipped. | Zachary Ware | 2013-12-08 | 1 | -8/+4 |
| | | |||||
* | | Issue14255 Don't flatten case of tempdir | Tim Golden | 2013-10-25 | 1 | -0/+14 |
| | | |||||
* | | Issue #18945: Add tests for tempfile name collision handling. | Eli Bendersky | 2013-09-13 | 1 | -22/+65 |
|\ \ | |/ | | | | | Patch by Vlad Shcherbina | ||||
| * | Issue #18945: Add tests for tempfile name collision handling. | Eli Bendersky | 2013-09-13 | 1 | -22/+65 |
| | | | | | | | | Patch by Vlad Shcherbina | ||||
* | | Issue #18849: Fixed a Windows-specific tempfile bug where collision with an | Eli Bendersky | 2013-09-06 | 1 | -0/+26 |
|\ \ | |/ | | | | | | | existing directory caused mkstemp and related APIs to fail instead of retrying. Report and fix by Vlad Shcherbina. | ||||
| * | Issue #18849: Fixed a Windows-specific tempfile bug where collision with an | Eli Bendersky | 2013-09-06 | 1 | -0/+26 |
| | | | | | | | | | | existing directory caused mkstemp and related APIs to fail instead of retrying. Report and fix by Vlad Shcherbina. | ||||
* | | Issue #18571: Implementation of the PEP 446: file descriptors and file handles | Victor Stinner | 2013-08-27 | 1 | -0/+1 |
| | | | | | | | | | | are now created non-inheritable; add functions os.get/set_inheritable(), os.get/set_handle_inheritable() and socket.socket.get/set_inheritable(). | ||||
* | | Close #12015: The tempfile module now uses a suffix of 8 random characters | Victor Stinner | 2013-08-13 | 1 | -2/+2 |
| | | | | | | | | | | | | instead of 6, to reduce the risk of filename collision. The entropy was reduced when uppercase letters were removed from the charset used to generate random characters. | ||||
* | | Issue #16800: tempfile.gettempdir() no longer left temporary files when | Serhiy Storchaka | 2013-02-12 | 1 | -1/+39 |
|\ \ | |/ | | | | | the disk is full. Original patch by Amir Szekely. | ||||
| * | Issue #16800: tempfile.gettempdir() no longer left temporary files when | Serhiy Storchaka | 2013-02-12 | 1 | -1/+39 |
| |\ | | | | | | | | | | the disk is full. Original patch by Amir Szekely. | ||||
| | * | Issue #16800: tempfile.gettempdir() no longer left temporary files when | Serhiy Storchaka | 2013-02-12 | 1 | -2/+44 |
| | | | | | | | | | | | | the disk is full. Original patch by Amir Szekely. | ||||
* | | | Fix a test for SpooledTemporaryFile (added in issue #10355). | Serhiy Storchaka | 2013-02-10 | 1 | -1/+1 |
|\ \ \ | |/ / | |||||
| * | | Fix a test for SpooledTemporaryFile (added in issue #10355). | Serhiy Storchaka | 2013-02-10 | 1 | -1/+1 |
| |\ \ | | |/ | |||||
| | * | Fix a test for SpooledTemporaryFile (added in issue #10355). | Serhiy Storchaka | 2013-02-10 | 1 | -1/+1 |
| | | | |||||
* | | | Issue #17169: Restore errno in tempfile exceptions. | Serhiy Storchaka | 2013-02-09 | 1 | -1/+3 |
|\ \ \ | |/ / |