From Fedora Project Wiki
 
(28 intermediate revisions by 2 users not shown)
Line 3: Line 3:
  
 
<!-- The actual name of your proposed change page should look something like: Changes/Your_Change_Proposal_Name.  This keeps all change proposals in the same namespace -->
 
<!-- The actual name of your proposed change page should look something like: Changes/Your_Change_Proposal_Name.  This keeps all change proposals in the same namespace -->
= Change Proposal Name Django-2.0 =
+
= Django 2.0 =
  
 
== Summary ==
 
== Summary ==
 
<!-- A sentence or two summarizing what this change is and what it will do. This information is used for the overall changeset summary page for each release. -->
 
<!-- A sentence or two summarizing what this change is and what it will do. This information is used for the overall changeset summary page for each release. -->
This change is about upgrading python-django to version 2.0. The latest Django release drops support for Python 2, but still a few Django apps do
+
This change is about upgrading {{package|python-django}} to version 2.0. The latest Django release [https://docs.djangoproject.com/en/2.0/releases/2.0/#python-compatibility drops support for Python 2], but a few Django apps packaged in Fedora do not yet support Python 3. A compatibility package will be provided for those.
not support Python 3.
 
  
 
== Owner ==
 
== Owner ==
Line 16: Line 15:
 
-->
 
-->
 
* Name: [[User:mrunge| Matthias Runge]]
 
* Name: [[User:mrunge| Matthias Runge]]
 +
* Name: [[User:churchyard| Miro Hrončok]]
 +
* Name: [[User:pviktori| Petr Viktorin]]
 
<!-- Include you email address that you can be reached should people want to contact you about helping with your change, status is requested, or technical issues need to be resolved. If the change proposal is owned by a SIG, please also add a primary contact person. -->
 
<!-- Include you email address that you can be reached should people want to contact you about helping with your change, status is requested, or technical issues need to be resolved. If the change proposal is owned by a SIG, please also add a primary contact person. -->
* Email: <mrunge@matthias-runge.de>
+
* Email: <python-devel@lists.fedoraproject.org>
* Release notes owner: <!--- To be assigned by docs team [[User:FASAccountName| Release notes owner name]] <email address> -->
+
* Release notes ticket: [https://pagure.io/fedora-docs/release-notes/issue/77 #77]
 
<!--- UNCOMMENT only for Changes with assigned Shepherd (by FESCo)
 
<!--- UNCOMMENT only for Changes with assigned Shepherd (by FESCo)
 
* FESCo shepherd: [[User:FASAccountName| Shehperd name]] <email address>
 
* FESCo shepherd: [[User:FASAccountName| Shehperd name]] <email address>
Line 38: Line 39:
 
CLOSED as NEXTRELEASE -> change is completed and verified and will be delivered in next release under development
 
CLOSED as NEXTRELEASE -> change is completed and verified and will be delivered in next release under development
 
-->
 
-->
* Tracker bug: <will be assigned by the Wrangler>
+
* Tracker bug: [https://bugzilla.redhat.com/show_bug.cgi?id=1534542 #1534542]
  
 
== Detailed Description ==
 
== Detailed Description ==
  
 
<!-- Expand on the summary, if appropriate.  A couple sentences suffices to explain the goal, but the more details you can provide the better. -->
 
<!-- Expand on the summary, if appropriate.  A couple sentences suffices to explain the goal, but the more details you can provide the better. -->
The latest Django release 2.0 finally drops support for Python 2.7. Not all dependent applications can keep up with Djangos pace. This change describes a way how to enable both, keeping 2.7 compatibility and also leveraging the latest version.
+
The latest Django release 2.0 finally drops support for Python 2.7. Not all dependent applications in Fedora can keep up with Djangos pace. This change describes a way how to enable both, keeping 2.7 compatibility and also leveraging the latest version.
 +
 
 +
The {{package|python-django}} package will be updated to 2.0, Python 2 subpackage(s) will be removed. A new compatibility {{package|python2-django1.11}} package will be created with Python 2 version of Django 1.11. The Django 1.11.x series is the last to support Python 2.7, it also has Long Term Support (supported until April 2020 by upstream). See the [https://docs.djangoproject.com/en/2.0/releases/2.0/#python-compatibility Django 2.0 release notes] for details about Django compatibility with various Python versions.
 +
 
 +
The new {{package|python2-django1.11}} package will obsolete <code>python2-django < 2</code> and <code>python-django < 2</code>, but it will deliberately not provide either of those. This will render packages depending on <code>python(2)-django</code> FTBFS (or broken runtime dependencies if they don't require Django at buildtime). This is intentional. If we don't do that, all Django packages in Fedora will just keep dragging the Legacy Python dependency chain forever. Package owners of Django applications requiring Python 2 will need to manually adjust their dependencies to use {{package|python2-django1.11}} or move to Python 3 only (this is preferred but not always possible). Package owners of Django libraries will need to coordinate this with package owners of the applications. The rule of thumb is: If the library is not required by an application (packaged in Fedora) that uses Legacy Python, remove the Python 2 subpackage (or retire the package, if it cannot support Python 3).
 +
 
 +
There will be packages that fail to build or have broken dependencies. Package owners shall fix those by the steps described above. Proposal owners will send dist-git Pull Requests or Bugzilla patches to help. Proven packager powers will be used to merge those after 14 days of no activity. The removal of leftover packages from Fedora will be coordinated with FESCo (for approval) and releng (for execution).
 +
 
 +
[http://fedora.portingdb.xyz/grp/django/ Most of the Django packages in Fedora are already Python 3 compatible.]
 +
 
 +
''Note that we are aware that naming the compatibility package {{package|python2-django}} would make this entire change much easier. But we'd very much like to retire the entire Python 2 based Django ecosystem at this point already. Creating {{package|python2-django1.11}} and not providing  <code>python2-django</code> is a compromise. Also, we plan to provide it as a contingency plan if necessary, see bellow.''
  
 
== Benefit to Fedora ==
 
== Benefit to Fedora ==
Fedora will be able to provide both: latest and current release and also a fallback for applications, which do not support Python3 yet.
+
Fedora will be able to provide both: latest and current release of Django and also a fallback for applications, which do not support Python 3 yet.
 +
 
 +
This will also remove some legacy packages nobody is actively taking care of.
 
   
 
   
 
    
 
    
Line 52: Line 65:
  
 
== Scope ==
 
== Scope ==
* Proposal owners: drop Python2 subpackage from python-django, upgrade python-django to Django-2.0 and package Django-1.11.x for Python2 only.  
+
* '''Proposal owners:''' drop Python 2 subpackage(s) from {{package|python-django}} (done), upgrade {{package|python-django}} to 2.0 (done) and package {{package|python2-django1.11}} for Python 2 only (done).
 
<!-- What work do the feature owners have to accomplish to complete the feature in time for release?  Is it a large change affecting many parts of the distribution or is it a very isolated change? What are those changes?-->
 
<!-- What work do the feature owners have to accomplish to complete the feature in time for release?  Is it a large change affecting many parts of the distribution or is it a very isolated change? What are those changes?-->
  
* Other developers: Other developers, whose applications do work with Python3 and Django 2.0 will need to change the requirement to python3-django.
+
* '''Django apps owners:''' Either update to Python 3 or use {{package|python2-django1.11}} as a dependency.
  
* Release engineering: [https://pagure.io/releng/issues #Releng issue number] (a check of an impact with Release Engineering is needed) <!-- REQUIRED FOR SYSTEM WIDE AS WELL AS FOR SELF CONTAINED CHANGES -->
+
* '''Django libraries owners:''' Either drop Python 2 subpackages (eventually retire the package if no subpackages are left) or use {{package|python2-django1.11}} as a dependency for the python 2 subpackages iff those are needed by apps (the second option applies to {{package|python2-django-tagging}} only!). When removing subpackages, add proper Obosletes tags to their Python 3 counterparts. When orphaning entire packages, add Obosletes to the {{package|python3-django}} package.
 +
 
 +
* '''Release engineering:''' [https://pagure.io/releng/issue/7211 #7211] (a check of an impact with Release Engineering is needed) <!-- REQUIRED FOR SYSTEM WIDE AS WELL AS FOR SELF CONTAINED CHANGES -->
 
<!-- Does this feature require coordination with release engineering (e.g. changes to installer image generation or update package delivery)?  Is a mass rebuild required?  include a link to the releng issue.  
 
<!-- Does this feature require coordination with release engineering (e.g. changes to installer image generation or update package delivery)?  Is a mass rebuild required?  include a link to the releng issue.  
 
The issue is required to be filed prior to feature submission, to ensure that someone is on board to do any process development work and testing, and that all changes make it into the pipeline; a bullet point in a change is not sufficient communication -->
 
The issue is required to be filed prior to feature submission, to ensure that someone is on board to do any process development work and testing, and that all changes make it into the pipeline; a bullet point in a change is not sufficient communication -->
** [[Fedora_Program_Management/ReleaseBlocking/Fedora{{FedoraVersionNumber|next}}|List of deliverables]]: N/A (not a System Wide Change) <!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
** releng will help with bulk retirement of packages that fail to keep up with this proposal
 
<!-- Please check the list of Fedora release deliverables and list all the differences the feature brings -->
 
<!-- Please check the list of Fedora release deliverables and list all the differences the feature brings -->
  
Line 69: Line 84:
 
<!-- Do the packaging guidelines or other documents need to be updated for this feature?  If so, does it need to happen before or after the implementation is done?  If a FPC ticket exists, add a link here. -->
 
<!-- Do the packaging guidelines or other documents need to be updated for this feature?  If so, does it need to happen before or after the implementation is done?  If a FPC ticket exists, add a link here. -->
  
* Trademark approval: N/A (not needed for this Change)
+
List of packages requiring  {{package|python2-django}}/ {{package|python-django}} without having <code>django</code> in their name:
<!-- If your Change may require trademark approval (for example, if it is a new Spin), file a ticket ( https://fedorahosted.org/council/ ) requesting trademark approval from the Fedora Council. This approval will be done via the Council's consensus-based process. -->
+
 
 +
* {{package|cobbler-web}}
 +
* {{package|fts-monitoring}}
 +
* {{package|gramps-webapp}}
 +
* {{package|graphite-web}} (requires {{package|python2-django-tagging}}, the only library that needs to have py2 version)
 +
* {{package|pony}}
 +
* {{package|pulp-server}}
 +
* {{package|python2-kobo-admin}}
 +
* {{package|python2-kobo-hub}}
 +
* {{package|python2-pelican}} (removed)
 +
* {{package|python2-testfixtures-tests}}
 +
* {{package|python2-whitenoise}}
 +
* {{package|python2-xmlrunner}}
  
 
== Upgrade/compatibility impact ==
 
== Upgrade/compatibility impact ==
 
<!-- What happens to systems that have had a previous versions of Fedora installed and are updated to the version containing this change? Will anything require manual configuration or data migration? Will any existing functionality be no longer supported? -->
 
<!-- What happens to systems that have had a previous versions of Fedora installed and are updated to the version containing this change? Will anything require manual configuration or data migration? Will any existing functionality be no longer supported? -->
  
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
The obsoletes added to {{package|python2-django1.11}} and others should make the upgrade work seamlessly.
N/A (not a System Wide Change)
 
  
 
== How To Test ==
 
== How To Test ==
Line 94: Line 120:
  
 
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
 
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
You should be able to install two web-apps, one requiring python2-django and one requiring python3-django. (TODO: provide actual package names)
+
You should be able to install two web-apps, one requiring {{package|python2-django1.11}} and one requiring {{package|python3-django}}. (TODO: provide actual package names)
 
# dnf install (package 1)
 
# dnf install (package 1)
# see python2-django is installed as dependency
+
# see python2-django1.11 is installed as dependency
 
# run that package
 
# run that package
 
# dnf install (package 2)
 
# dnf install (package 2)
Line 108: Line 134:
 
<!-- If this change proposal is noticeable by its target audience, how will their experiences change as a result?  Describe what they will see or notice. -->
 
<!-- If this change proposal is noticeable by its target audience, how will their experiences change as a result?  Describe what they will see or notice. -->
 
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
 
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
N/A (not a System Wide Change)
 
 
== Dependencies ==
 
<!-- What other packages (RPMs) depend on this package?  Are there changes outside the developers' control on which completion of this change depends?  In other words, completion of another change owned by someone else and might cause you to not be able to finish on time or that you would need to coordinate?  Other upstream projects like the kernel (if this is not a kernel change)? -->
 
  
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
Users using RPM installed Django to develop Django apps might be affected by this change. We shall recommend either using venvs or using Python 3. See the developer portal, we are already [https://developer.fedoraproject.org/tech/languages/python/django-installation.html recommending both].
N/A (not a System Wide Change)
 
  
 
== Contingency Plan ==
 
== Contingency Plan ==
  
 
<!-- If you cannot complete your feature by the final development freeze, what is the backup plan?  This might be as simple as "Revert the shipped configuration".  Or it might not (e.g. rebuilding a number of dependent packages).  If you feature is not completed in time we want to assure others that other parts of Fedora will not be in jeopardy.  -->
 
<!-- If you cannot complete your feature by the final development freeze, what is the backup plan?  This might be as simple as "Revert the shipped configuration".  Or it might not (e.g. rebuilding a number of dependent packages).  If you feature is not completed in time we want to assure others that other parts of Fedora will not be in jeopardy.  -->
* Contingency mechanism: (What to do?  Who will do it?) N/A (not a System Wide Change)  <!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
* Contingency mechanism: (What to do?  Who will do it?) Proposal owners will add <code>python2-django</code> and <code>python-django</code> virtual provides to {{package|python2-django1.11}} if everything goes south.
 
<!-- When is the last time the contingency mechanism can be put in place?  This will typically be the beta freeze. -->
 
<!-- When is the last time the contingency mechanism can be put in place?  This will typically be the beta freeze. -->
* Contingency deadline: N/A (not a System Wide Change)  <!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
* Contingency deadline: beta freeze
 
<!-- Does finishing this feature block the release, or can we ship with the feature in incomplete state? -->
 
<!-- Does finishing this feature block the release, or can we ship with the feature in incomplete state? -->
* Blocks release? N/A (not a System Wide Change), Yes/No <!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
* Blocks release? No
* Blocks product? product <!-- Applicable for Changes that blocks specific product release/Fedora.next -->
+
* Blocks product? No
  
 
== Documentation ==
 
== Documentation ==
 
<!-- Is there upstream documentation on this change, or notes you have written yourself?  Link to that material here so other interested developers can get involved. -->
 
<!-- Is there upstream documentation on this change, or notes you have written yourself?  Link to that material here so other interested developers can get involved. -->
  
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
+
TBD
N/A (not a System Wide Change)
 
  
 
== Release Notes ==
 
== Release Notes ==
Line 139: Line 159:
 
-->
 
-->
  
[[Category:ChangePageIncomplete]]
+
TBD
 +
 
 +
[[Category:ChangeAcceptedF28]]
 
<!-- When your change proposal page is completed and ready for review and announcement -->
 
<!-- When your change proposal page is completed and ready for review and announcement -->
 
<!-- remove Category:ChangePageIncomplete and change it to Category:ChangeReadyForWrangler -->
 
<!-- remove Category:ChangePageIncomplete and change it to Category:ChangeReadyForWrangler -->

Latest revision as of 14:40, 2 March 2018


Django 2.0

Summary

This change is about upgrading Package-x-generic-16.pngpython-django to version 2.0. The latest Django release drops support for Python 2, but a few Django apps packaged in Fedora do not yet support Python 3. A compatibility package will be provided for those.

Owner

Current status

Detailed Description

The latest Django release 2.0 finally drops support for Python 2.7. Not all dependent applications in Fedora can keep up with Djangos pace. This change describes a way how to enable both, keeping 2.7 compatibility and also leveraging the latest version.

The Package-x-generic-16.pngpython-django package will be updated to 2.0, Python 2 subpackage(s) will be removed. A new compatibility Package-x-generic-16.pngpython2-django1.11 package will be created with Python 2 version of Django 1.11. The Django 1.11.x series is the last to support Python 2.7, it also has Long Term Support (supported until April 2020 by upstream). See the Django 2.0 release notes for details about Django compatibility with various Python versions.

The new Package-x-generic-16.pngpython2-django1.11 package will obsolete python2-django < 2 and python-django < 2, but it will deliberately not provide either of those. This will render packages depending on python(2)-django FTBFS (or broken runtime dependencies if they don't require Django at buildtime). This is intentional. If we don't do that, all Django packages in Fedora will just keep dragging the Legacy Python dependency chain forever. Package owners of Django applications requiring Python 2 will need to manually adjust their dependencies to use Package-x-generic-16.pngpython2-django1.11 or move to Python 3 only (this is preferred but not always possible). Package owners of Django libraries will need to coordinate this with package owners of the applications. The rule of thumb is: If the library is not required by an application (packaged in Fedora) that uses Legacy Python, remove the Python 2 subpackage (or retire the package, if it cannot support Python 3).

There will be packages that fail to build or have broken dependencies. Package owners shall fix those by the steps described above. Proposal owners will send dist-git Pull Requests or Bugzilla patches to help. Proven packager powers will be used to merge those after 14 days of no activity. The removal of leftover packages from Fedora will be coordinated with FESCo (for approval) and releng (for execution).

Most of the Django packages in Fedora are already Python 3 compatible.

Note that we are aware that naming the compatibility package Package-x-generic-16.pngpython2-django would make this entire change much easier. But we'd very much like to retire the entire Python 2 based Django ecosystem at this point already. Creating Package-x-generic-16.pngpython2-django1.11 and not providing python2-django is a compromise. Also, we plan to provide it as a contingency plan if necessary, see bellow.

Benefit to Fedora

Fedora will be able to provide both: latest and current release of Django and also a fallback for applications, which do not support Python 3 yet.

This will also remove some legacy packages nobody is actively taking care of.


Scope

  • Django libraries owners: Either drop Python 2 subpackages (eventually retire the package if no subpackages are left) or use Package-x-generic-16.pngpython2-django1.11 as a dependency for the python 2 subpackages iff those are needed by apps (the second option applies to Package-x-generic-16.pngpython2-django-tagging only!). When removing subpackages, add proper Obosletes tags to their Python 3 counterparts. When orphaning entire packages, add Obosletes to the Package-x-generic-16.pngpython3-django package.
  • Release engineering: #7211 (a check of an impact with Release Engineering is needed)
    • releng will help with bulk retirement of packages that fail to keep up with this proposal
  • Policies and guidelines:
    • Python packaging guidelines
    • Documentation should be provided

List of packages requiring Package-x-generic-16.pngpython2-django/ Package-x-generic-16.pngpython-django without having django in their name:

Upgrade/compatibility impact

The obsoletes added to Package-x-generic-16.pngpython2-django1.11 and others should make the upgrade work seamlessly.

How To Test

You should be able to install two web-apps, one requiring Package-x-generic-16.pngpython2-django1.11 and one requiring Package-x-generic-16.pngpython3-django. (TODO: provide actual package names)

  1. dnf install (package 1)
  2. see python2-django1.11 is installed as dependency
  3. run that package
  4. dnf install (package 2)
  5. verify python3-django is installed as dependency
  6. package 1 still works
  7. package 2 works as well
  8. dnf remove package 1
  9. package 2 still works

User Experience

Users using RPM installed Django to develop Django apps might be affected by this change. We shall recommend either using venvs or using Python 3. See the developer portal, we are already recommending both.

Contingency Plan

  • Contingency mechanism: (What to do? Who will do it?) Proposal owners will add python2-django and python-django virtual provides to Package-x-generic-16.pngpython2-django1.11 if everything goes south.
  • Contingency deadline: beta freeze
  • Blocks release? No
  • Blocks product? No

Documentation

TBD

Release Notes

TBD