Author Topic: Python Lib graphenelib not working  (Read 2360 times)

0 Members and 1 Guest are viewing this topic.

Offline abit

  • Committee member
  • Hero Member
  • *
  • Posts: 4664
    • View Profile
    • Abit's Hive Blog
  • BitShares: abit
  • GitHub: abitmore
ok i might decide to use https://github.com/bitshares/python-bitshares insted
at least the sample code is working

quick question about the connection to my witness node
Here in the BitShares() objet there is rpcuser/rpcwassord
Code: [Select]
:param str node: Node to connect to *(optional)*
:param str rpcuser: RPC user *(optional)*
:param str rpcpassword: RPC password *(optional)*

is that the same as username/passwords in api-access.json ??
I guess they are.
BitShares committee member: abit
BitShares witness: in.abit

Offline TreantBG

ok i might decide to use https://github.com/bitshares/python-bitshares insted
at least the sample code is working

quick question about the connection to my witness node
Here in the BitShares() objet there is rpcuser/rpcwassord
Code: [Select]
:param str node: Node to connect to *(optional)*
:param str rpcuser: RPC user *(optional)*
:param str rpcpassword: RPC password *(optional)*

is that the same as username/passwords in api-access.json ??

Offline TreantBG

yeah i even created docker file to test

Code: [Select]
FROM python:3

RUN apt update && apt install -y \
    libffi-dev \
    libssl-dev \
    python-dev \
    python3-dev \
    git

RUN pip3 install bitshares
RUN pip3 install bitshares --user --upgrade

RUN git clone https://github.com/xeroc/python-graphenelib/
WORKDIR ./python-graphenelib
RUN make install
#RUN pip3 install graphenelib
#RUN pip3 install graphenelib --user --upgrade

RUN mkdir /opt/workspace
WORKDIR /opt/workspace
ADD Bitshares.py .

CMD [ "python", "./Bitshares.py" ]


#docker build -t python-bitshares .


no luck with that too

Offline sschiessl

  • Administrator
  • Hero Member
  • *****
  • Posts: 662
    • View Profile
  • BitShares: sschiessl
Are you running the latest version?

You could try to purge everything, install fresh (or --upgrade) and make sure you have no double installation (system, user, venv)

Offline TreantBG

Hello,
it seems i cannot understand how to make graphenelib to work.
i have installed it trough pip and also manually
But i get this error
from grapheneapi import GrapheneAPI
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: cannot import name 'GrapheneAPI'


i use Python 3.6.4 :: Anaconda, Inc.


I also tried to contain it in clean docker environment with the same success..
What am i missing?