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

refactor: update Django to 4.2 LTS #1545

Closed
wants to merge 26 commits into from
Closed

Conversation

NtskwK
Copy link
Contributor

@NtskwK NtskwK commented Aug 25, 2024

What's new

Django 4.2:

Django 4.2 supports PostgreSQL 12 and highe

django.conf.urls.url() is removed.

django.utils.encoding.force_text() and are removed.smart_text()

PostgreSQL JSONField is deprecated

Activate the postgis_raster extension with Django.

Docker-compose:

remove Version top-level element (obsolete)

Docker

set ENV with = (e.g. ENV VAR=xxx)

Others

PostGIS Support Matrix: https://trac.osgeo.org/postgis/wiki/UsersWikiPostgreSQLPostGIS

unfix:

djangorestframework-simplejwt (Critical)

there are also many different from django-rest-framework-jwt to djangorestframework-simplejwt. So it can not pass the test in webodm.sh. Login function is broken now. The browser will create window.prompt automatic which is required account and password to instead of the login function. It's necessary to overwrite auth functions.

django-webpack-loader

There is a bug(?) in static template at v1.0.0 or higher version.

Error during template rendering In template /mnt/d/Program/gitwork/WebODM/app/templates/app/base.html

rio-tiler

RioTilerBaseModel:warn 'key' access will has been deprecated and will be removed in rio-tiler 7.0."

webpack

  • (node:5096) [DEP_WEBPACK_DEPRECATION_ARRAY_TO_SET] DeprecationWarning: Compilation.chunks was changed from Array to Set (using Array method
    'map' is deprecated)

  • (node:5096) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead.
    (Use node --trace-deprecation ... to show where the warning was created)

  • WARNING in webpack performance recommendations: webapp | You can limit the size of your bundles by using import() or require.ensure to lazy load some parts of your application.

Docker-compose

Maintainer tag is deprecated

@NtskwK
Copy link
Contributor Author

NtskwK commented Aug 25, 2024

@pierotofy
#1471 #1543

Dockerfile Outdated
@@ -1,33 +1,55 @@
FROM ubuntu:21.04
FROM ubuntu:20.04
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Curious about the move from 21 to 20 here. Due to the upcoming EOL of 20.04 would it make sense to work on bumping this to 22.04 or higher?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Version of ubuntu in Docker webodm_db and webodm_webapp should be same to ensure apt will install some package in the same version. Maybe I should to update both?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. The base image is Ubuntu 22.04 now, because PDAL can not be found by apt in Ubuntu 24.04.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah 24 is still fairly new but 22 has plenty of life left in it.

@NtskwK NtskwK marked this pull request as ready for review August 31, 2024 17:33
@pierotofy
Copy link
Member

I appreciate the efforts to upgrade Django, Postgres and base system, but there's a lot that needs to be addressed.

My comments from #1543 (comment) still haven't been addressed and I don't understand why this was marked as "ready for review".

This is not an easy task and there's a reason it hasn't been done yet; it's a lot of work and needs a solid amount of funding (or a lot of careful work by a dedicated contributor) to be done.

@pierotofy pierotofy closed this Sep 8, 2024
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

Successfully merging this pull request may close these issues.

3 participants