Code Monkey home page Code Monkey logo

tinker_python's People

Contributors

angelomelonas avatar icypalm avatar jordyheemskerk avatar lexym avatar nickvandegroes avatar ogkevin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

tinker_python's Issues

Is this repository still maintained?

I cannot run any of the code examples, seems like the sdk was updated, but tinker was not.

❯  python create_production_configuration.py
Traceback (most recent call last):
  File "/home/murr/Sandboxes/bunq-tinker/tinker/create_production_configuration.py", line 5, in <module>
    from bunq.sdk.context import ApiContext
ImportError: cannot import name 'ApiContext' from 'bunq.sdk.context' (/home/murr/.local/share/virtualenvs/bunq-tinker-B0ODIK44/lib64/python3.11/site-packages/bunq/sdk/context/__init__.py)

~/.../bunq-tinker/tinker ( master U:2 ⊘ )
❯  python user_overview.py
Traceback (most recent call last):
  File "/home/murr/Sandboxes/bunq-tinker/tinker/user_overview.py", line 2, in <module>
    from libs.bunq_lib import BunqLib
  File "/home/murr/Sandboxes/bunq-tinker/tinker/libs/bunq_lib.py", line 8, in <module>
    from bunq.sdk.client import Pagination
ModuleNotFoundError: No module named 'bunq.sdk.client'

Not able to run!

Im not able to run user_overview.py I get this error message

File "tinker/user_overview.py“, line 2, in <module>
    from libs.bunq_lib import BunqLib
  File "/bunqtink/tinker/libs/bunq_lib.py", line 8, in <module>
    from bunq.sdk.client import Pagination
  File "/bunqtink/.venv/lib/python3.6/site-packages/bunq/__init__.py", line 6, in <module>
    from bunq.sdk.json import converter
  File "/bunqtink/.venv/lib/python3.6/site-packages/bunq/sdk/json/converter.py", line 1
    from __future__ import annotations
    ^
SyntaxError: future feature annotations is not defined

`pipenv` can already be installed without being in the user's path

Running bash <(curl -s https://tinker.bunq.com/python/setup.sh) returned

Could not find "pipenv", try installing it by running "pip install pipenv".

even thoughpip list does show pipenv and pip install pipenv says it is already installed.

The problem is that which pipenv (which setup.py runs to verify it being present) indeed returned nothing. I was able to fix this by installing it again through brew install pipenv which does install itself in the user's path:

$ which pipenv
/usr/local/bin/pipenv

Can't find the Python binary

For off: I'm running Python 3.7 while the scripts clearly depend on 3.6. I know this is not supported.

But I'm running into issues. I've installed with the setup.sh script. This seemed successful. But pipenvInstall did not run due to my system having Python 3.7.
After updating the Pipfile to use Python 3.7 and running the pipenvInstall snippet I'm still not able to run the user_overview.py script:

$ ./tinker/user_overview.py 
/usr/bin/env: ‘.venv/bin/python -W ignore’: No such file or directory
/usr/bin/env: use -[v]S to pass options in shebang lines

When trying to invoke the script directly:

env .venv/bin/python tinker/user_overview.py 
Traceback (most recent call last):
  File "tinker/user_overview.py", line 2, in <module>
    from libs.bunq_lib import BunqLib
  File "/tmp/tinker/tinker/libs/bunq_lib.py", line 6, in <module>
    from bunq.sdk.client import Pagination
ModuleNotFoundError: No module named 'bunq.sdk.client'

get() missing 1 required positional argument: 'user_id'

First, installed requirements using pip3. Then ran python3 ./tinker/create_production_configuration.py --api-key (API_KEY) to create a production context.

Then tried running python3 ./tinker/user_overview.py but it fails with following error. It seems the API now requires a user_id to be given up front in the constructor, instead of retrieving it from the created context.

Traceback (most recent call last):
  File "./tinker/user_overview.py", line 46, in <module>
    main()
  File "./tinker/user_overview.py", line 13, in main
    bunq = BunqLib(environment_type)
  File "/Users/l.dwaalmalefijt/Downloads/tinker_python-develop/tinker/libs/bunq_lib.py", line 54, in __init__
    self.setup_current_user()
  File "/Users/l.dwaalmalefijt/Downloads/tinker_python-develop/tinker/libs/bunq_lib.py", line 94, in setup_current_user
    user = endpoint.User.get().value.get_referenced_object()
TypeError: get() missing 1 required positional argument: 'user_id'

Deprecate sandbox-user

The sandbox-user user endpoint is being deprecated and will be replaced by sandbox-user-person and sandbox-user-company.

Error on Ubuntu on WSL

Installed PyEnv to have python 3.6.4

Ran the script from bunq.com/dev

entered the virtualenv with pipenv shell

Tried to run: tinker/user_overview.py
Got the error:

/usr/bin/env: ‘.venv/bin/python -W ignore’: No such file or directory

In the bunq Telegram group another user had the same issue, we have no idea what is wrong

can't run user_overview.py

$ tinker/user_overview.py --production

bash: tinker/user_overview.py: .venv/bin/python: bad interpreter: No such file or directory

why i can't run tinker/user_overview.py --production ? why is missing the .venv directory?

i have executed './go-pro' beforehand

Missing license

Without any indication of a license in the code, we can't really use it, can we?

Tinker scripts give ModuleNotFoundError: No module named 'bunq.sdk.client'

Trying to get the tinker scripts to work in Python 3.8. In setup.sh I changed it to include the interpreter: PIPENV_VENV_IN_PROJECT=1 pipenv --python /usr/bin/python3 install

The installation seems to succeed. However running the tinker scripts fail:

./tinker/update_account.py 
Traceback (most recent call last):
  File "./tinker/update_account.py", line 2, in <module>
    from libs.bunq_lib import BunqLib
  File "/home/dave2/b2/tinker/libs/bunq_lib.py", line 8, in <module>
    from bunq.sdk.client import Pagination
ModuleNotFoundError: No module named 'bunq.sdk.client'

Running go-pro does not create a production config

Environment: Ubuntu 18.04, dependencies up-to-date.

  1. Run setup with bash/curl pipe provided at bunq.com/api
  2. Run ./go-pro
  3. Scan the QR code and confirm in the app
  4. go-pro returns with the title GO PRO title and the message "You're ready to use the PRODUCTION environment." and the help options with the --production flags.
  5. No bunq-production.conf is created, so none of the commands work.

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.