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

An abundance of JSONDecodeError #49

Open
yyolk opened this issue Sep 20, 2021 · 0 comments
Open

An abundance of JSONDecodeError #49

yyolk opened this issue Sep 20, 2021 · 0 comments

Comments

@yyolk
Copy link
Owner

yyolk commented Sep 20, 2021

While using the JsonRPCClient; the oracle will see an abundance of JSONDecodeErrors that are coming as a result of the server saying it's too busy.
image
image

I was aware of this happening, and was swallowing, notifying and then raising FailedExecutionWillRetry

Got a JSONDecodeError of 'Expecting value: line 1 column 1 (char 0)'. Retrying the transaction by failing this execution.


JSONDecodeError: Expecting value: line 1 column 1 (char 0)
Traceback (most recent call last):
  File "/var/lang/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/var/task/contract.py", line 45, in <module>
    base_fee = get_fee(xrpl_client)
  File "/var/task/xrpl/ledger/main.py", line 54, in get_fee
    return asyncio.run(main.get_fee(client))
  File "/var/lang/lib/python3.9/asyncio/runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "/var/lang/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
    return future.result()
  File "/var/task/xrpl/asyncio/ledger/main.py", line 64, in get_fee
    response = await client.request_impl(Fee())
  File "/var/task/xrpl/asyncio/clients/json_rpc_base.py", line 46, in request_impl
    return json_to_response(response.json())
  File "/var/task/httpx/_models.py", line 1415, in json
    return jsonlib.loads(self.text, **kwargs)
  File "/var/lang/lib/python3.9/json/__init__.py", line 346, in loads
    return _default_decoder.decode(s)
  File "/var/lang/lib/python3.9/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/var/lang/lib/python3.9/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant