Coder Social home page Coder Social logo

Comments (11)

ramsey avatar ramsey commented on May 27, 2024 1

A recent change might have fixed this or at least made it less likely to occur: 370d521

Please keep trying it out and let me know if you see these errors again.

My hypothesis right now is that, since the cache keys were the same across operating systems, if (for example) the job for Windows tried to run with PHP 7.4 and lowest dependencies at the same time as the job for Linux with PHP 7.4 and lowest dependencies, then maybe there was some kind of read-access blocking to the device, since I assume it's sharing the same mounted filesystem for the caches.

Anyway, I have no confirmation this has fixed it, but I haven't seen the issue since I made this change.

from composer-install.

ramsey avatar ramsey commented on May 27, 2024 1

This is fixed in v2, please upgrade using ramsey/composer-install@v2 or ramsey/[email protected]. Details are available on the release announcement and the README.

Thanks!

from composer-install.

ctrl-f5 avatar ctrl-f5 commented on May 27, 2024

Can confirm, also experiencing this issue randomly in the PR pact-foundation/pact-php#194

from composer-install.

ramsey avatar ramsey commented on May 27, 2024

I just got a failure on Windows in another repo: https://github.com/ramsey/php-library-starter-kit/runs/2070621484

Error: file_get_contents(C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org/provider-phpunit~phpunit.json): Failed to open stream: Resource temporarily unavailable

from composer-install.

ramsey avatar ramsey commented on May 27, 2024

Another error in a different repo. Different error, but I think it's the same root cause. https://github.com/ramsey/devtools-lib/runs/2078491516?check_suite_focus=true

Error: rename(C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org/provider-slevomat~coding-standard.json.6048eddc87a296.29835153.tmp,C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org/provider-slevomat~coding-standard.json): Access is denied (code: 5)

from composer-install.

ramsey avatar ramsey commented on May 27, 2024

Yet another in a different repo. This is the "access is denied" error: https://github.com/ramsey/conventional-commits/runs/2108197091?check_suite_focus=true

from composer-install.

LastDragon-ru avatar LastDragon-ru commented on May 27, 2024

I haven't seen the issue since I made this change.

https://github.com/LastDragon-ru/lara-asp-formatter/runs/2108870196?check_suite_focus=true

but seems it occurs less than before

from composer-install.

LastDragon-ru avatar LastDragon-ru commented on May 27, 2024

Also another error:

image

Run ramsey/composer-install@v1
  with:
    dependency-versions: highest
Composer cache directory found at C:/Users/runneradmin/AppData/Local/Composer
Composer working directory set to project root.
Using highest versions of dependencies
PHP version is 8.0.3
Operating system is win32
Cache primary key is win32-php-8.0.3-highest-fd4cda7bf11267d674976d6c8660bb91b36447fe6a1624d907b9b88fdb8fc218-
Cache restore keys are: win32-php-8.0.3-highest-fd4cda7bf11267d674976d6c8660bb91b36447fe6a1624d907b9b88fdb8fc218-, win32-php-8.0.3-highest-
C:\Windows\system32\cmd.exe /D /S /C "c:\tools\php\composer.bat update --no-interaction --no-progress --ansi"
Loading composer repositories with package information
Received 19109288 of 19109288 (100.0%), 67.2 MBs/sec
Cache Size: ~18 MB (19109288 B)
C:\Windows\System32\tar.exe -z -xf D:/a/_temp/edd2f068-d936-4fe2-b234-ec2344fed194/cache.tgz -P -C D:/a/lara-asp-core/lara-asp-core
Cache restored successfully
Cache restored from key: win32-php-8.0.3-highest-fd4cda7bf11267d674976d6c8660bb91b36447fe6a1624d907b9b88fdb8fc218-
Error: rename(C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org/provider-dragonmantank~cron-expression.json.60613c1c3c6c05.64268794.tmp,C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org/provider-dragonmantank~cron-expression.json): Access is denied (code: 5)


  [ErrorException]                                                                                                     
  rename(C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org/provider-dragonmantank~cron-expr  
  ession.json.60613c1c3c6c05.64268794.tmp,C:/Users/runneradmin/AppData/Local/Composer/repo/https---repo.packagist.org  
  /provider-dragonmantank~cron-expression.json): Access is denied (code: 5)                                            


update [--with WITH] [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--lock] [--no-install] [--no-autoloader] [--no-scripts] [--no-suggest] [--no-progress] [-w|--with-dependencies] [-W|--with-all-dependencies] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [-i|--interactive] [--root-reqs] [--] [<packages>]...

Error: The process 'c:\tools\php\composer.bat' failed with exit code 1

from composer-install.

jaapio avatar jaapio commented on May 27, 2024

I can confirm this issue is still there. we do have the same issue in https://github.com/phpDocumentor/phpDocumentor

from composer-install.

jaapio avatar jaapio commented on May 27, 2024
 Operating system is win32
Cache primary key is win32-php-7.2.34-locked-0b124dbf7c8e0b4aecdd9c1cc21fb55002ef6c6e082968ff7ac63b2722b2fc37---optimize-autoloader
Cache restore keys are: win32-php-7.2.34-locked-0b124dbf7c8e0b4aecdd9c1cc21fb55002ef6c6e082968ff7ac63b2722b2fc37-, win32-php-7.2.34-locked-
C:\Windows\system32\cmd.exe /D /S /C "c:\tools\php\composer.bat install --no-interaction --no-progress --ansi --optimize-autoloader"
Received 14696183 of 14696183 (100.0%), 62.8 MBs/sec
Cache Size: ~14 MB (14696183 B)
Installing dependencies from lock file (including require-dev)
Verifying lock file contents can be installed on current platform.
C:\Windows\System32\tar.exe -z -xf D:/a/_temp/f161ff02-06b2-40a1-9215-646e7cb536af/cache.tgz -P -C D:/a/phpDocumentor/phpDocumentor
Package operations: 65 installs, 0 updates, 0 removals
  - Downloading symfony/flex (v1.13.3)
  - Downloading doctrine/event-manager (1.1.1)
  - Downloading doctrine/lexer (1.2.1)
  - Downloading fzaninotto/faker (v1.9.2)
  - Downloading jawira/plantuml (v1.59.0)
  - Downloading jean85/pretty-package-versions (2.0.4)
  - Downloading league/commonmark (1.6.6)
  - Downloading league/mime-type-detection (1.7.0)
  - Downloading league/pipeline (1.0.0)
  - Downloading symfony/polyfill-ctype (v1.23.0)
  - Downloading psr/event-dispatcher (1.0.0)
  - Downloading psr/container (1.1.1)
  - Downloading psr/cache (1.0.1)
  - Downloading symfony/contracts (v2.4.0)
  - Downloading psr/log (1.1.4)
  - Downloading league/tactician (v1.1.0)
  - Downloading league/tactician-logger (v0.10.0)
  - Downloading league/tactician-container (2.0.0)
  - Downloading league/tactician-bundle (v1.2.0)
  - Downloading league/uri-interfaces (2.2.0)
  - Downloading league/uri (6.3.0)
  - Downloading mikey179/vfsstream (v1.6.9)
  - Downloading hamcrest/hamcrest-php (v2.0.1)
  - Downloading mockery/mockery (1.3.4)
  - Downloading league/flysystem (1.1.4)
  - Downloading phpdocumentor/flyfinder (1.1.0)
  - Downloading phpdocumentor/graphviz (2.0.0)
  - Downloading nikic/php-parser (v4.12.0)
Cache restored successfully
Cache restored from key: win32-php-7.2.34-locked-0b124dbf7c8e0b4aecdd9c1cc21fb55002ef6c6e082968ff7ac63b2722b2fc37---optimize-autoloader
Error: copy(C:/Users/runneradmin/AppData/Local/Composer/files/phpdocumentor/reflection/d02003861304bd11c7a7c8649c2f9b9603d88cb7.zip): failed to open stream: Resource temporarily unavailable

If you look at the order of the restore messages this seems to be odd...

Linux does this:

 Operating system is linux
Cache primary key is linux-php-8.0.9-locked-f6b45f088bb279953b0c03505a981d2bb4f232fd97a0cc6b7dd29dfddc41e81b---optimize-autoloader
Cache restore keys are: linux-php-8.0.9-locked-f6b45f088bb279953b0c03505a981d2bb4f232fd97a0cc6b7dd29dfddc41e81b-, linux-php-8.0.9-locked-
/usr/local/bin/composer install --no-interaction --no-progress --ansi --optimize-autoloader
Installing dependencies from lock file (including require-dev)
Verifying lock file contents can be installed on current platform.
Received 14639000 of 14639000 (100.0%), 69.5 MBs/sec
Cache Size: ~14 MB (14639000 B)
/usr/bin/tar --use-compress-program zstd -d -xf /home/runner/work/_temp/c3d4442d-5a9f-4f74-8aa5-8a3ee769e186/cache.tzst -P -C /home/runner/work/phpDocumentor/phpDocumentor
Cache restored successfully
Cache restored from key: linux-php-8.0.9-locked-f6b45f088bb279953b0c03505a981d2bb4f232fd97a0cc6b7dd29dfddc41e81b---optimize-autoloader
Package operations: 65 installs, 0 updates, 0 removals
  - Installing symfony/flex (v1.13.3): Extracting archive
  - Installing doctrine/event-manager (1.1.1): Extracting archive
  - Installing doctrine/lexer (1.2.1): Extracting archive

it looks like the cache restore is taking to long on windows, and it continues before it was fully restored?

from composer-install.

mvriel avatar mvriel commented on May 27, 2024

The issue still occurs (https://github.com/phpDocumentor/phpDocumentor/runs/3630487891?check_suite_focus=true); maybe something as simple as a retry option would be useful? This could also help in cases of flaky networks when downloading/installing composer packages

from composer-install.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.