Giter VIP home page Giter VIP logo

Comments (8)

bayne avatar bayne commented on May 30, 2024

👍 Ran into this issue

from bowerphp.

ardi-n avatar ardi-n commented on May 30, 2024

Me too.

from bowerphp.

TomHAnderson avatar TomHAnderson commented on May 30, 2024

+1

from bowerphp.

TomHAnderson avatar TomHAnderson commented on May 30, 2024

@sstok you intoned Composer uses github-api. It does not. Both products do what you say and I think composer does it better and github-api does it easier. Besides wrapping the whole app in a try-catch block to catch ApiLimitExceedException, what's the best way to do this?

We would need this to be automated for post deploy runs and hitting the API limit wouldn't be acceptable. Have you got some insight into this?

from bowerphp.

sstok avatar sstok commented on May 30, 2024

From what I know is that Composer uses the API to get the dist-file location.
https://github.com/composer/composer/blob/cec1627acf7ea66799ec43116b460fb52cf0ce75/src/Composer/Repository/Vcs/GitHubDriver.php

And then GitHub remembers (for a short period of time) that the remote IP has been authorized and you can just get dist without worrying about the rate-limit.

Wrapping the complete application in try-catch block is not a good idea indeed, and actually breaks multiple good practices as the rate-limit is only related to the GitHub driver.
https://github.com/composer/composer/blob/cec1627acf7ea66799ec43116b460fb52cf0ce75/src/Composer/Repository/Vcs/GitHubDriver.php#L291

from bowerphp.

mrDlef avatar mrDlef commented on May 30, 2024

+1

from bowerphp.

garak avatar garak commented on May 30, 2024

Great news! I just pushed a big refactoring, inspired by @TomHAnderson
Now every command uses github API instead of Guzzle, and I even managed to use Bowerphp with a token of mine.
Now we only need to find a way a user can inject his/her personal token inside
See https://github.com/Bee-Lab/bowerphp/blob/master/src/Bowerphp/Command/Command.php#L53
Meanwhile, everyone can test it by hand, uncommenting line 54 an putting own token in place of 'TODO' string.

from bowerphp.

TomHAnderson avatar TomHAnderson commented on May 30, 2024

@garak I wonder how Engine Yard does composer. They look for a composer.lock and run composer when you deploy....so, where's that api key coming from? Is the Engine Yard api key used? If it is can you setup a global bowerphp config like ~/.bowerphp/auth.json?

I poked around and couldn't find the Engine Yard answer so maybe you can ask because I would love to have bowerphp run on deploy.

from bowerphp.

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.