Skip to content

Handle race condition when creating cache directory #330

Handle race condition when creating cache directory

Handle race condition when creating cache directory #330

Triggered via pull request January 12, 2025 05:29
@vjikvjik
synchronize #89
mkdir-fix
Status Success
Total duration 1m 6s
Artifacts

mutation.yml

on: pull_request
Matrix: mutation / roave-infection
Fit to window
Zoom out
Zoom in

Annotations

3 warnings
mutation / PHP 8.3-ubuntu-latest
ubuntu-latest pipelines will use ubuntu-24.04 soon. For more details, see https://github.com/actions/runner-images/issues/10636
mutation / PHP 8.3-ubuntu-latest: src/FileCache.php#L198
Escaped Mutant for Mutator "TrueValue": --- Original +++ New @@ @@ foreach ($values as $key => $value) { $this->set((string) $key, $value, $ttl); } - return true; + return false; } public function deleteMultiple(iterable $keys) : bool {
mutation / PHP 8.3-ubuntu-latest: src/FileCache.php#L332
Escaped Mutant for Mutator "Throw_": --- Original +++ New @@ @@ return; } if (is_file($path)) { - throw new CacheException("Failed to create cache directory, file with the same name exists: \"{$path}\"."); + new CacheException("Failed to create cache directory, file with the same name exists: \"{$path}\"."); } set_error_handler(static function (int $errorNumber, string $errorString) use($path) : bool { if (is_dir($path)) {