Code Monkey home page Code Monkey logo

Comments (5)

DaniinXorchenabo avatar DaniinXorchenabo commented on August 20, 2024 1

so, my requirements.txt is empty, but I receive this problem again...

I deleted my deta app and created again. this solved my problem.

Can I close this lssue?

from deta-python.

aavshr avatar aavshr commented on August 20, 2024

hi sorry this is due an bug with orjson and our internal library. You can remove orjson in the requirements.txt, deploy again and it should resolve the issue.

If you must use orjson unfortunately, we would have to push a fix before you can use it.

from deta-python.

DaniinXorchenabo avatar DaniinXorchenabo commented on August 20, 2024

Hi, I updated my requirements.txt (Yes, I delete all useless libs):

fastapi[all]

But I get this error again:

[2021-09-30T16:11:57+03:00] [ERROR] AttributeError: module 'orjson' has no attribute 'JSONEncoder'
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/_entry.py", line 1, in <module>
    from detalib.handler import handle
  File "/opt/python/detalib/handler.py", line 3, in <module>
    from . import handlers
  File "/opt/python/detalib/handlers.py", line 1, in <module>
    from .event import parse_event
  File "/opt/python/detalib/event.py", line 1, in <module>
    from .helpers import json
  File "/opt/python/detalib/helpers.py", line 16, in <module>
    class CustomJSONEncoder(json.JSONEncoder):

from deta-python.

aavshr avatar aavshr commented on August 20, 2024

hi fastapi[all] also installs orjson (https://github.com/tiangolo/fastapi/blob/master/pyproject.toml#L84-#L98) hence the issue.

from deta-python.

aavshr avatar aavshr commented on August 20, 2024

hi @DaniinXorchenabo , thanks for the report. I'm will close this issue here as it is an issue with our internal lib for micros and not the sdk.

from deta-python.

Related Issues (20)

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.