geex-arts / django-jet

Modern responsive template for the Django admin interface with improved functionality. We are proud to announce completely new Jet. Please check out Live Demo
https://github.com/jet-admin/jet-bridge
GNU Affero General Public License v3.0
3.57k stars 776 forks source link

django-jet is not Django3 compatible #430

Open Barukimang opened 4 years ago

Barukimang commented 4 years ago

This version of django-jet works with Django3.0: https://github.com/Barukimang/django-jet/

To install use: pip install django-3-jet

See also here: https://pypi.org/project/django-3-jet/

Includes fixes for errors such as:

ImportError: cannot import name 'python_2_unicode_compatible' from 'django.utils.encoding' (/usr/local/lib/python3.7/site-packages/django/utils/encoding.py)

TemplateSyntaxError at /admin/ 'admin_static' is not a registered tag library. Must be one of: ...

After install, you will probably notice that the Lookup Field Popup of django-jet is not rendering in Django3, with this error:

Refused to display 'http://localhost:8000/.../?_to_field=id&_popup=1' in a frame because it set 'X-Frame-Options' to 'deny'

Here is the fix for that: https://github.com/geex-arts/django-jet/issues/429

RamsesMartinez commented 4 years ago

Hi, I created a Fork from this project, which only removes python 2 support to work on python 3, greetings!

MauroNavaLuevanos commented 4 years ago

I got this error: No module named 'six' image image

Barukimang commented 4 years ago

@MauroNavaLuevanos: pip install six https://pypi.org/project/six/

Also fixed this with this commit: https://github.com/geex-arts/django-jet/pull/427/commits/c9e0024f055c0856de3513753db4a5fdca26e98b

So removing package and reinstalling should also work

ruslankrivoshein commented 4 years ago

@RamsesMartinez, /jet/dashboard/templates/admin/index.html 2 line, please, remove admin_static and release again. I face _'adminstatic' is not a registered tag library.

Barukimang commented 4 years ago

@ruslankrivoshein had addressed that in this commit https://github.com/geex-arts/django-jet/pull/427/commits/ef5896ecdab054905c2dfe72025e52ac76b02e1e

Also see the file https://github.com/Barukimang/django-jet/blob/dev/jet/dashboard/templates/admin/index.html

RamsesMartinez commented 4 years ago

@RamsesMartinez, /jet/dashboard/templates/admin/index.html 2 line, please, remove admin_static and release again. I face _'adminstatic' is not a registered tag library.

@ruslankrivoshein I made the change that mentions @Barukimang in this version

ruslankrivoshein commented 4 years ago

Thanks! But there are now two static tags) Does it work still correctly?

RamsesMartinez commented 4 years ago

Thanks! But there are now two static tags) Does it work still correctly?

I didn't realize that, in the next correction that requires it I remove it, it shouldn't affect it, it's just overwriting one tag with the other.