Git Product home page Git Product logo

cryptodex's People

Contributors

leoncvlt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

cryptodex's Issues

KeyError

I cannot seem to get past this error. Any input or recommendations?

[09:21:01] DEBUG    Starting new HTTPS connection (1): api.coingecko.com:443                                                                                                 connectionpool.py:971
โ ™ Connecting to exchange...           DEBUG    https://api.coingecko.com:443 "GET /api/v3/coins/markets?vs_currency=usd HTTP/1.1" 200 None                                                              connectionpool.py:452
           DEBUG    Starting new HTTPS connection (1): api.kraken.com:443                                                                                                    connectionpool.py:971
โ ธ Connecting to exchange...           DEBUG    https://api.kraken.com:443 "POST /0/private/Balance HTTP/1.1" 200 None                                                                                   connectionpool.py:452
โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ Traceback (most recent call last) โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ /usr/lib/python3.8/runpy.py:194 in _run_module_as_main                                           โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   191 โ”‚   main_globals = sys.modules["__main__"].__dict__                                        โ”‚
โ”‚   192 โ”‚   if alter_argv:                                                                         โ”‚
โ”‚   193 โ”‚   โ”‚   sys.argv[0] = mod_spec.origin                                                      โ”‚
โ”‚ โฑ 194 โ”‚   return _run_code(code, main_globals, None,                                             โ”‚
โ”‚   195 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚    "__main__", mod_spec)                                                 โ”‚
โ”‚   196                                                                                            โ”‚
โ”‚   197 def run_module(mod_name, init_globals=None,                                                โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /usr/lib/python3.8/runpy.py:87 in _run_code                                                      โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    84 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚      __loader__ = loader,                                                โ”‚
โ”‚    85 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚      __package__ = pkg_name,                                             โ”‚
โ”‚    86 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚      __spec__ = mod_spec)                                                โ”‚
โ”‚ โฑ  87 โ”‚   exec(code, run_globals)                                                                โ”‚
โ”‚    88 โ”‚   return run_globals                                                                     โ”‚
โ”‚    89                                                                                            โ”‚
โ”‚    90 def _run_module_code(code, init_globals=None,                                              โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/cryptodex/cryptodex/__main__.py:221 in <module>                                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   218                                                                                            โ”‚
โ”‚   219 if __name__ == "__main__":                                                                 โ”‚
โ”‚   220 โ”‚   try:                                                                                   โ”‚
โ”‚ โฑ 221 โ”‚   โ”‚   app()                                                                              โ”‚
โ”‚   222 โ”‚   except KeyboardInterrupt:                                                              โ”‚
โ”‚   223 โ”‚   โ”‚   log.critical("Interrupted by user")                                                โ”‚
โ”‚   224 โ”‚   โ”‚   try:                                                                               โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click/core.py:829 in __call__                    โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    826 โ”‚                                                                                         โ”‚
โ”‚    827 โ”‚   def __call__(self, *args, **kwargs):                                                  โ”‚
โ”‚    828 โ”‚   โ”‚   """Alias for :meth:`main`."""                                                     โ”‚
โ”‚ โฑ  829 โ”‚   โ”‚   return self.main(*args, **kwargs)                                                 โ”‚
โ”‚    830                                                                                           โ”‚
โ”‚    831                                                                                           โ”‚
โ”‚    832 class Command(BaseCommand):                                                               โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click/core.py:782 in main                        โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    779 โ”‚   โ”‚   try:                                                                              โ”‚
โ”‚    780 โ”‚   โ”‚   โ”‚   try:                                                                          โ”‚
โ”‚    781 โ”‚   โ”‚   โ”‚   โ”‚   with self.make_context(prog_name, args, **extra) as ctx:                  โ”‚
โ”‚ โฑ  782 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   rv = self.invoke(ctx)                                                 โ”‚
โ”‚    783 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   if not standalone_mode:                                               โ”‚
โ”‚    784 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   return rv                                                         โ”‚
โ”‚    785 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   # it's not safe to `ctx.exit(rv)` here!                               โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click_shell/core.py:164 in invoke                โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   161 โ”‚   def invoke(self, ctx):                                                                 โ”‚
โ”‚   162 โ”‚   โ”‚   # Call super() first.  This ensures that we call the method body of our instance   โ”‚
โ”‚   163 โ”‚   โ”‚   # in case it's something other than `pass`                                         โ”‚
โ”‚ โฑ 164 โ”‚   โ”‚   ret = super(Shell, self).invoke(ctx)                                               โ”‚
โ”‚   165 โ”‚   โ”‚                                                                                      โ”‚
โ”‚   166 โ”‚   โ”‚   if not ctx.protected_args and not ctx.invoked_subcommand:                          โ”‚
โ”‚   167 โ”‚   โ”‚   โ”‚   # Set this to None so that it doesn't get printed out in usage messages        โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click/core.py:1236 in invoke                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   1233 โ”‚   โ”‚   โ”‚   # list (which means that no subcommand actually was executed).                โ”‚
โ”‚   1234 โ”‚   โ”‚   โ”‚   if self.invoke_without_command:                                               โ”‚
โ”‚   1235 โ”‚   โ”‚   โ”‚   โ”‚   if not self.chain:                                                        โ”‚
โ”‚ โฑ 1236 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   return Command.invoke(self, ctx)                                      โ”‚
โ”‚   1237 โ”‚   โ”‚   โ”‚   โ”‚   with ctx:                                                                 โ”‚
โ”‚   1238 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   Command.invoke(self, ctx)                                             โ”‚
โ”‚   1239 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   return _process_result([])                                            โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click/core.py:1066 in invoke                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   1063 โ”‚   โ”‚   """                                                                               โ”‚
โ”‚   1064 โ”‚   โ”‚   _maybe_show_deprecated_notice(self)                                               โ”‚
โ”‚   1065 โ”‚   โ”‚   if self.callback is not None:                                                     โ”‚
โ”‚ โฑ 1066 โ”‚   โ”‚   โ”‚   return ctx.invoke(self.callback, **ctx.params)                                โ”‚
โ”‚   1067                                                                                           โ”‚
โ”‚   1068                                                                                           โ”‚
โ”‚   1069 class MultiCommand(Command):                                                              โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click/core.py:610 in invoke                      โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    607 โ”‚   โ”‚   args = args[2:]                                                                   โ”‚
โ”‚    608 โ”‚   โ”‚   with augment_usage_errors(self):                                                  โ”‚
โ”‚    609 โ”‚   โ”‚   โ”‚   with ctx:                                                                     โ”‚
โ”‚ โฑ  610 โ”‚   โ”‚   โ”‚   โ”‚   return callback(*args, **kwargs)                                          โ”‚
โ”‚    611 โ”‚                                                                                         โ”‚
โ”‚    612 โ”‚   def forward(*args, **kwargs):  # noqa: B902                                           โ”‚
โ”‚    613 โ”‚   โ”‚   """Similar to :meth:`invoke` but fills in default keyword                         โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/.local/lib/python3.8/site-packages/click/decorators.py:21 in new_func               โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    18 โ”‚   """                                                                                    โ”‚
โ”‚    19 โ”‚                                                                                          โ”‚
โ”‚    20 โ”‚   def new_func(*args, **kwargs):                                                         โ”‚
โ”‚ โฑ  21 โ”‚   โ”‚   return f(get_current_context(), *args, **kwargs)                                   โ”‚
โ”‚    22 โ”‚                                                                                          โ”‚
โ”‚    23 โ”‚   return update_wrapper(new_func, f)                                                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/cryptodex/cryptodex/__main__.py:89 in app                                           โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    86 โ”‚   โ”‚   data["exchange"]["key"], data["exchange"]["secret"]                                โ”‚
โ”‚    87 โ”‚   )                                                                                      โ”‚
โ”‚    88 โ”‚   with console.status("[bold green]Connecting to exchange..."):                          โ”‚
โ”‚ โฑ  89 โ”‚   โ”‚   portfolio.connect(exchange)                                                        โ”‚
โ”‚    90 โ”‚   ctx.obj = State(portfolio, exchange, currency)                                         โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/cryptodex/cryptodex/portfolio.py:57 in connect                                      โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    54 โ”‚   โ”‚   self.holdings = []                                                                 โ”‚
โ”‚    55 โ”‚   โ”‚   cg = CoinGeckoAPI()                                                                โ”‚
โ”‚    56 โ”‚   โ”‚   market_data = cg.get_coins_markets(self.currency)                                  โ”‚
โ”‚ โฑ  57 โ”‚   โ”‚   owned_assets = exchange.get_owned_assets()                                         โ”‚
โ”‚    58 โ”‚   โ”‚   available_assets = exchange.get_available_assets(self.currency)                    โ”‚
โ”‚    59 โ”‚   โ”‚   excluded_assets = [asset.lower() for asset in self.model["exclude"]]               โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/ubuntu/cryptodex/cryptodex/exchanges/kraken.py:45 in get_owned_assets                      โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   42 โ”‚   def get_owned_assets(self):                                                             โ”‚
โ”‚   43 โ”‚   โ”‚   return {                                                                            โ”‚
โ”‚   44 โ”‚   โ”‚   โ”‚   key.lower(): value                                                              โ”‚
โ”‚ โฑ 45 โ”‚   โ”‚   โ”‚   for key, value in self.api.query_private("Balance")["result"].items()           โ”‚
โ”‚   46 โ”‚   โ”‚   โ”‚   #if float(value) > 0                                                            โ”‚
โ”‚   47 โ”‚   โ”‚   }                                                                                   โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
KeyError: 'result'

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.