Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal server error when running without --wallet-type indy #518

Closed
nrempel opened this issue May 21, 2020 · 1 comment
Closed

Internal server error when running without --wallet-type indy #518

nrempel opened this issue May 21, 2020 · 1 comment
Labels
bug Something isn't working

Comments

@nrempel
Copy link
Contributor

nrempel commented May 21, 2020

For example, I run the software like this:

PORTS="5000:5000" ./scripts/run_docker start -it http 0.0.0.0 8000 -ot http --admin 0.0.0.0 5000 --admin-insecure-mode --seed 255h235iu2yg354uiyg234i5iu2yg54i --endpoint http://localhost:8000 --genesis-url http://test.bcovrin.vonx.io/genesis

Then I call POST /schemas

The server response is:

500 Internal Server Error

Server got itself in trouble

The following error is produced in the logs:

2020-05-21 17:34:18,369 aries_cloudagent.core.dispatcher ERROR Handler error: schemas_send_schema
Traceback (most recent call last):
  File "/home/indy/aries_cloudagent/messaging/schemas/routes.py", line 105, in schemas_send_schema
    ledger: BaseLedger = await context.inject(BaseLedger)
  File "/home/indy/aries_cloudagent/config/injection_context.py", line 126, in inject
    return await self.injector.inject(base_cls, settings, required=required)
  File "/home/indy/aries_cloudagent/config/injector.py", line 83, in inject
    "No instance provided for class: {}".format(base_cls.__name__)
aries_cloudagent.config.base.InjectorError: No instance provided for class: BaseLedger
2020-05-21 17:34:18,370 aiohttp.server ERROR Error handling request
Traceback (most recent call last):
  File "/home/indy/.pyenv/versions/3.6.9/lib/python3.6/site-packages/aiohttp/web_protocol.py", line 418, in start
    resp = await task
  File "/home/indy/.pyenv/versions/3.6.9/lib/python3.6/site-packages/aiohttp/web_app.py", line 458, in _handle
    resp = await handler(request)
  File "/home/indy/.pyenv/versions/3.6.9/lib/python3.6/site-packages/aiohttp/web_middlewares.py", line 119, in impl
    return await handler(request)
  File "/home/indy/.pyenv/versions/3.6.9/lib/python3.6/site-packages/aiohttp_apispec/middlewares.py", line 45, in validation_middleware
    return await handler(request)
  File "/home/indy/aries_cloudagent/admin/server.py", line 192, in apply_limiter
    return await task
  File "/home/indy/aries_cloudagent/messaging/schemas/routes.py", line 105, in schemas_send_schema
    ledger: BaseLedger = await context.inject(BaseLedger)
  File "/home/indy/aries_cloudagent/config/injection_context.py", line 126, in inject
    return await self.injector.inject(base_cls, settings, required=required)
  File "/home/indy/aries_cloudagent/config/injector.py", line 83, in inject
    "No instance provided for class: {}".format(base_cls.__name__)
aries_cloudagent.config.base.InjectorError: No instance provided for class: BaseLedger

We should catch the error a return a more useful message to the user.

The problem is that the following command line flag was missing: --wallet-type indy

@sklump
Copy link
Contributor

sklump commented May 28, 2020

#533
addresses

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants