unwitting / bitstampy

Bitstamp API wrapper for Python
MIT License
54 stars 21 forks source link

Getting "APIError: Invalid nonce" #5

Closed dsmurrell closed 10 years ago

dsmurrell commented 10 years ago

Hi Jack

Thanks for the API!

I'm trying to do a buy limit order and I'm getting an error. Is this a problem with Bitstampy or just something that I'm doing wrong... sorry to post this here but I could not find your email address.

bitstamp.buy_limit_order(c, k, s, 0.01, ask * 1.10)

Traceback (most recent call last): File "/Users/daniel/bitcoin/coinduit/bank/bank.py", line 17, in bitstamp.buy_limit_order(c, k, s, 0.01, ask * 1.10) File "/Library/Python/2.7/site-packages/bitstampy/api.py", line 62, in buy_limit_order .call(amount=amount, price=price) File "/Library/Python/2.7/site-packages/bitstampy/calls.py", line 86, in call return super(APIPrivateCall, self).call(**params) File "/Library/Python/2.7/site-packages/bitstampy/calls.py", line 57, in call raise APIError(response['error']) APIError: Invalid nonce

Is there something I need to do to set the nonce?

dsmurrell commented 10 years ago

Sorry, this was just me being stupid and making two API calls in the same second.

unwitting commented 10 years ago

Hi!

I was going to say, are you doing that :) You should also find that @gravengaard actually fixed this anyway in commit 7f5cbc6!

dsmurrell commented 10 years ago

Hi Jack, thanks for getting back. I'm a bit confused. This fix say it happened 2 months ago. I thought I grabbed the latest version of your software... how come I didn't get this included?

On Sun, Mar 16, 2014 at 5:19 PM, Jack Preston notifications@github.comwrote:

Hi!

I was going to say, are you doing that :) You should also find that @gravengaard https://github.com/gravengaard actually fixed this anyway in commit 7f5cbc6 https://github.com/unwitting/bitstampy/commit/7f5cbc6!

Reply to this email directly or view it on GitHubhttps://github.com/unwitting/bitstampy/issues/5#issuecomment-37763390 .

unwitting commented 10 years ago

Ah, that'll be because I didn't re-publish the new version to pip (where you presumably grabbed from). What a noob, I'll do it now.

unwitting commented 10 years ago

There we go :).

dsmurrell commented 10 years ago

Thanks alot!

On Tue, Mar 18, 2014 at 11:36 AM, Jack Preston notifications@github.comwrote:

There we go https://pypi.python.org/pypi/bitstampy/0.0.8 :).

Reply to this email directly or view it on GitHubhttps://github.com/unwitting/bitstampy/issues/5#issuecomment-37923064 .