Giter Club home page Giter Club logo

Comments (7)

np5 avatar np5 commented on July 17, 2024

Could you post here the django logs, please ?

from zentral.

AndersTao avatar AndersTao commented on July 17, 2024
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]: 2018-07-09 06:40:26,871 PID3786 exception ERROR Internal Server Error: /munki/enroll/
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]: Traceback (most recent call last):
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/venv/lib/python3.5/site-packages/django/core/handlers/exception.py", line 42, in inner
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     response = get_response(request)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/venv/lib/python3.5/site-packages/django/core/handlers/base.py", line 187, in _get_response
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     response = self.process_exception_by_middleware(e, request)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/venv/lib/python3.5/site-packages/django/core/handlers/base.py", line 185, in _get_response
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     response = wrapped_callback(request, *callback_args, **callback_kwargs)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/usr/lib/python3.5/contextlib.py", line 30, in inner
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     return func(*args, **kwds)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/venv/lib/python3.5/site-packages/django/views/decorators/csrf.py", line 58, in wrapped_view
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     return view_func(*args, **kwargs)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/venv/lib/python3.5/site-packages/django/views/generic/base.py", line 68, in view
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     return self.dispatch(request, *args, **kwargs)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/venv/lib/python3.5/site-packages/django/views/generic/base.py", line 88, in dispatch
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     return handler(request, *args, **kwargs)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/home/zentral/app/releases/2018.07.05-15.56.05-master-3b683f/zentral/contrib/munki/views.py", line 91, in post
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     request_json = json.load(request)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/usr/lib/python3.5/json/__init__.py", line 268, in load
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     parse_constant=parse_constant, object_pairs_hook=object_pairs_hook, **kw)
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:   File "/usr/lib/python3.5/json/__init__.py", line 312, in loads
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]:     s.__class__.__name__))
Jul 09 08:40:26 zentral.domain.com gunicorn[1379]: TypeError: the JSON object must be str, not 'bytes'

from zentral.

np5 avatar np5 commented on July 17, 2024

Yes, that's what I thought. Same issue as the santa enrollment one. Fixed in a000fb3. We don't get these errors in our environments.

from zentral.

AndersTao avatar AndersTao commented on July 17, 2024

Yep, it is fixet now 👏🏼 Thanks again @np5

from zentral.

np5 avatar np5 commented on July 17, 2024

I have found the issue. We run python 3.6 on our prod servers and in the docker setup. With python 3.6, you can pass a file opened in binary mode to json.load, not with python 3.5, which is the standard on ubuntu 16.04, used for the Zentral all-in-one images.

from zentral.

AndersTao avatar AndersTao commented on July 17, 2024

headmin did mention the use of python3.6 earlier, but I did not follow up after your first fix..
Any requmentet way to upgrade?, without breaking everything :)

from zentral.

np5 avatar np5 commented on July 17, 2024

python 3.6 is not in the standard ubuntu 16.04 and debian stable distributions. As much as I would love to be able to use only the latest version, this requirement is not really reasonable.

from zentral.

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.