Page MenuHomePhabricator

Update Django to 5.0
Closed, ResolvedPublic

Description

Lingua Libre currently runs on Django 4.2.

Django 5.0 has been released in early December 2023 (see release notes).

The main changes we should have a look into are:

  • the introduction of db_default for fields
  • the GeneratedField class
  • the field choices improvements
IMPORTANT: Wait for Django REST Framework to be officially compatible with Django 5 before proceeding.

Related Objects

Event Timeline

Yug changed the task status from Open to Stalled.Sep 28 2024, 10:00 PM
Yug triaged this task as Low priority.
Yug updated the task description. (Show Details)

Hi, @Yug I am Aditya (GitHub), a final-year Computer Science student from India.
I have some experience in Python, Django, and DjangoRestFramework. Can I work on this task?

IMPORTANT: Wait for Django REST Framework to be officially compatible with Django 5 before proceeding.

I have checked this Django REST Framework now supports Django 5

Aklapper changed the task status from Stalled to Open.Jan 1 2025, 5:08 PM

Resetting status per last comment

Can I work on this task?

See https://www.mediawiki.org/wiki/New_Developers#Communication_tips :)

See https://www.mediawiki.org/wiki/New_Developers#Communication_tips :)

Thank you @Aklapper I have started working on this task, and I will raise a pull request soon :)

@Aditya just saw your PR thank you ! We will review it.

Also, how do you trust your PR and that the database is still working as expected, did you ran and test its ? Which guideline, documentation did you follow or which IA assistant did you use ? We need to understand how your worked.

Also, how do you trust your PR and that the database is still working as expected, did you ran and test its ? Which guideline, documentation did you follow or which IA assistant did you use ? We need to understand how your worked.

Yes, the database is working I ran a few ORM queries using Django shell (python manage.py shell).
Yes, I ran the tests using the python manage.py test all the test cases are getting passed.
I followed Django 5.0 Release notes to cover this, I went through each point of backward-incompatible-changes to make sure nothing breaks.
Do you mean AI assistant? I use ChatGPT generally, but Django's documentation was more helpful for this particular task.
Other than that, I used the lingua libre using the local frontend and tried to make a few recordings to make sure everything was working fine end to end.

Screen Shot 2025-01-16 at 10.53.55 AM.png (623×1 px, 151 KB)

Screen Shot 2025-01-16 at 10.54.33 AM.png (238×823 px, 42 KB)

Screen Shot 2025-01-16 at 11.01.54 AM.png (737×1 px, 87 KB)

@Yug can you suggest some other task on which I can work on next

Hello @Aditya ,
Thank you for this fix. Pushkar our current main dev have been actively working on some other features recently, but we are getting to this task.
You are already contributing well thank you.

Before to give you other tasks I would like to DM with you. Are you on Lingua Libre discord server ? Should we exchange via email ?

Aditya changed the task status from Open to In Progress.Jan 28 2025, 10:20 AM

Thank you for reviewing and merging my MR @Yug
I have tested the changes on my local they are working fine, we can resolve this task.

Before to give you other tasks I would like to DM with you. Are you on Lingua Libre discord server ? Should we exchange via email ?

We connected on the Discord server :)

Yug closed this task as Resolved.EditedJan 29 2025, 11:46 PM

Hello @Aditya , you gave enough guarantees, I mark this issue as resolved.

Note: in professional context another dev should run and validate.

Thanks for marking it as resolved @Yug :)