Git Product home page Git Product logo

Comments (4)

jcrugzz avatar jcrugzz commented on July 4, 2024

Thought I would document my investigation as I go here. I have figured out that the account number is somehow missing from the URL when calling getInstances only when it is in a state of 'offline'. I have found where the account number is set on authorization using the test data. And the data being loaded can be seen in the test itself. When it goes to make a request in the base client, the url is set which calls this function.

After following all of this I am having a hard time understanding how this change of state could cause the test to error. I know it will end up just being some odd little bug hidden somewhere but from what I understand now it all checks out. It will probably turn up as I familiarize myself with the code base.

from pkgcloud.

cronopio avatar cronopio commented on July 4, 2024

Hi

Thank you for all your work on pkgcloud. I'm following you with this problem, please continue putting here any information you think is relevant with the problem. In a quick view, I think with no connection so there is no authentication and there is no account number, because if I recall well, the account number is taken from the token.

I'll try to reserve some time to review all your work.

Keep contributing!

from pkgcloud.

jcrugzz avatar jcrugzz commented on July 4, 2024

Thanks for the input @cronopio. I figured out that there weren't enough auth nocks for all of the tests to hit. This became even more obvious when more tests were added in my PR and a rackspace/databases/databases test began to fail. I suppose the tests were able to hit rackspace's servers when online and still succeed, which I find quite interesting.

My solution was adding more .posts and .replys similar to below in the users-test.js in order for all the tests to succeed. The distribution of the auth nocks can still be tweaked in order to accurately depict how many auth requests are made per rackspace test. (e.g database-test.js, instance-test.js, users-test.js, etc.) I'll dig in a little more and see when all the auth requests are taking place.

nock('https://' + client.authUrl)
    .post('/v1.1/auth', { "credentials": credentials })
      .reply(200, helpers.loadFixture('rackspace/token.json'))

from pkgcloud.

cronopio avatar cronopio commented on July 4, 2024

The commit mentioned land as v0.6.8, should be fixed.

from pkgcloud.

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.