Author Topic: python bitshare i have some error sell command  (Read 104 times)

0 Members and 1 Guest are viewing this topic.

Offline oddhome

python bitshare i have some error sell command
« on: March 30, 2018, 05:02:08 am »
i can run on my desktop work successful and upload to server run fail please help


Traceback (most recent call last):
  File "/var/web/tools/bot_trade_cryptobridge.py", line 65, in <module>
    print(market.sell(bid, amount))
  File "/usr/local/lib/python3.5/dist-packages/bitshares/market.py", line 513, in sell
    tx = self.bitshares.finalizeOp(order, account["name"], "active")
  File "/usr/local/lib/python3.5/dist-packages/bitshares/bitshares.py", line 292, in finalizeOp
    self.txbuffer.sign()
  File "/usr/local/lib/python3.5/dist-packages/bitshares/transactionbuilder.py", line 347, in sign
    signedtx.sign(self.wifs, chain=self.bitshares.rpc.chain_params)
  File "/usr/local/lib/python3.5/dist-packages/bitsharesbase/signedtransactions.py", line 21, in sign
    return super(Signed_Transaction, self).sign(wifkeys, chain)
  File "/usr/local/lib/python3.5/dist-packages/graphenebase/signedtransactions.py", line 186, in sign
    signature = sign_message(self.message, wif)
  File "/usr/local/lib/python3.5/dist-packages/graphenebase/ecdsa.py", line 180, in sign_message
    private_key = ec.derive_private_key(int(repr(priv_key), 16), ec.SECP256K1(), default_backend())
AttributeError: module 'cryptography.hazmat.primitives.asymmetric.ec' has no attribute 'derive_private_key'

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12523
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BitShares: xeroc
  • GitHub: xeroc
Re: python bitshare i have some error sell command
« Reply #1 on: March 30, 2018, 06:06:02 am »
Interesting.

This could be fixed by running

  pip3 install secp256k1

as root.

Also, can you please create an issue on github for this? Thanks
Give BitShares a try! Use the http://testnet.bitshares.eu provided by http://bitshares.eu powered by ChainSquad GmbH

Offline oddhome

Re: python bitshare i have some error sell command
« Reply #2 on: March 30, 2018, 07:11:29 am »
Thank you very much. it work.