django-pwa icon indicating copy to clipboard operation
django-pwa copied to clipboard

Compatibility Issue with Django 4.0

Open mmhy2003 opened this issue 3 years ago • 6 comments

Hello,

I upgraded an old project of mine from Django 3 to 4. And I found a compatibility issue while integrating your module with the project.

BR,

mmhy2003 avatar Jan 09 '22 08:01 mmhy2003

At least one compatibility issue is with the use of django.conf.urls.url(), removed in Django 4. See: https://stackoverflow.com/a/70319607/3674106

phme avatar Mar 24 '22 16:03 phme

Assalam, I have the same error, I think the "url" should be changed to "re_path" in "import url" since "url" is deprecated in Django 4. Thank you.

elhachimi-ch avatar May 01 '22 17:05 elhachimi-ch

This issue is fixed once #88 has been accepted.

eeriksp avatar Jun 07 '22 13:06 eeriksp

Downloaded the latest version. Still getting an error with this.

/lib/python3.8/site-packages/pwa/urls.py", line 1, in from django.conf.urls import url ImportError: cannot import name 'url' from 'django.conf.urls' (/Users/abhinav/Library/Caches/pypoetry/virtualenvs/10pc-main4-st3C-Inu-py3.8/lib/python3.8/site-packages/django/conf/urls/init.py)

abhinav-j07 avatar Jun 13 '22 23:06 abhinav-j07

The fixed version is not published yet, you can surely circumvent this by installing the package directly from GitHub as it's in the master branch:

poetry add git+https://github.com/silviolleite/django-pwa

In case you aren't using poetry yet:

pip install git+https://github.com/silviolleite/django-pwa

Fazendaaa avatar Jul 22 '22 15:07 Fazendaaa

Thanks Lucas. Much appreciated.

On Fri, 22 Jul, 2022, 9:07 pm Lucas de Almeida Carotta, < @.***> wrote:

The fixed version is not published yet, you can surely circumvent this by installing the package directly from GitHub as it's in the master branch:

poetry add git+https://github.com/silviolleite/django-pwa

In case you already aren't using poetry https://python-poetry.org/ yet:

pip install git+https://github.com/silviolleite/django-pwa

— Reply to this email directly, view it on GitHub https://github.com/silviolleite/django-pwa/issues/83#issuecomment-1192700490, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALOCZQFKQUSVQD4G35YUYFDVVK54VANCNFSM5LRTPH3Q . You are receiving this because you commented.Message ID: @.***>

abhinav-j07 avatar Jul 22 '22 15:07 abhinav-j07

I had the same issue as at today. In case you also encounter same, navigate to the pwa/urls.py change, "from django.conf.urls import urls" to from django.urls import re_path . Hope it helps someone

DekuMawuli avatar Oct 11 '22 13:10 DekuMawuli

Hello. I just released 1.1.0 with the contents of master branch and the fix introduced by #68 .

hartungstenio avatar Dec 20 '22 13:12 hartungstenio