Created attachment 192282 [details] py-djangorestframework38.shar Hello, attached is the shar file of the Python package py-djangorestframework38, the 3.8.x branch of the Django REST framework. Normally I would have sent a patch to update the existing www/py-djangorestframework port from 3.6.4 to v3.8.1 but this would break ports that depends on Django v1.8 (see also: https://svnweb.freebsd.org/ports?view=revision&revision=457543). At the moment only three ports depends on www/py-djangorestframework: - www/seahub (depends on Django 1.8 at the moment, no support for Django 1.11 from upstream) - www/py-django-filter (works for Django v1.8+) - www/py-django-rest-swagger (works for Django v1.8+) There might be two approaches to add the latest Django REST framework to the ports tree: Option A (easiest, but might not be the preferred method, I assume): - create the www/py-djangorestframework38 port with the attached shar file - Django v1.11+ ports will use then the newly created port Option B (more work required, but the outcome might be better): - rename www/py-djangorestframework to www/py-djangorestframework36 - create then the Django REST framework v3.8.1 as www/py-djangorestframework - set the dependencies of the of three ports listed above accordingly QA (for option A as described above): ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - poudriere (11.1-RELEASE amd64 + i386) for each py27 and py36 flavor -> OK - portlint -> OK Please let me know, which method will suit best for the ports tree. I would supply further patches if required.
(In reply to Kai from comment #0) I would opt for option B, since there will probably be version 4.0, 4.1 etc.
I vote for option B.
Created attachment 192288 [details] adds new DRF and moves old DRF - version 1 Thank you for your feedback. I created a patch for option B that does following: - copy www/py-djangorestframework to www/py-djangorestframework36 - add new www/py-djangorestframework (v3.8.1) - modify dependencies for ports www/py-django-annotations and www/seahub QA: ~~~ - poudriere (11.1-RELEASE amd64 + i386) for each py27 and py36 flavor -> OK
Created attachment 192570 [details] adds new DRF and moves old DRF - version 2 Meanwhile the Django REST Framework has been updated to 3.8.2 and the PORTREVISION of www/seahub has increased. The revised patch supplies the new DRF version (with some optional dependencies removed) and sets the PORTREVISION for seahub accordingly. The rest is the same as in v1 of the now obsoleted patch. QA: ~~~ - poudriere (11.1-RELEASE amd64 + i386) for each py27 and py36 flavor -> OK
testbuilds@work
Committed, thanks. I'll keep it open for a few days in case some problem pops up.
A commit references this bug: Author: pi Date: Tue Apr 17 19:25:06 UTC 2018 New revision: 467652 URL: https://svnweb.freebsd.org/changeset/ports/467652 Log: New port: www/py-djangorestframework as version 3.8.x - py-djangorestframework 3.6.x lives on as py-djangorestframework36 - seahub and django-annotations stay on -36 PR: 227319 Submitted by: Kai <freebsd_ports@k-worx.org> Reviewed by: antoine, sunpoet Changes: head/www/Makefile head/www/py-django-annotations/Makefile head/www/py-djangorestframework/Makefile head/www/py-djangorestframework/distinfo head/www/py-djangorestframework/pkg-descr head/www/py-djangorestframework36/ head/www/py-djangorestframework36/Makefile head/www/seahub/Makefile
(In reply to Kurt Jaeger from comment #6) Thank you very much for committing this small but rather extensive patch. Thanks also to antoine and sunpoet for the feedback that led to this diff. Well, let's see and wait what will happen in the next few days then.
This update brokes www/py-django18 restframework fail to import django.urls, prev was django.conf.urls, also functions names changed in urls.
Switch to www/py-djangorestframework36 fix issue with import urls
(In reply to rozhuk.im from comment #10) That was expected because the latest version of DRF is no longer compatible with Django v1.8. Thus the previous version (v3.6.4) has been repo-copied to www/py-djangorestframework36 for backward compatibility. Edit: Mid air collision while I was trying to send my comment. You were faster and found it out yourself. :-)
(In reply to rozhuk.im from comment #10) I'm in no way familiar with django, please explain ? django18 does not depend on djangorestframework ? How would a patch look like to fix the broken django18 ?
(In reply to Kurt Jaeger from comment #12) We have some product with web GUI based on django 1.8 and some set of additional staff, like py-djangorestframework. I am not python dev so I know nothing, but django 1.8 and py-djangorestframework38 incompatible. Ask Kai, looks like he can tell you more details.
(In reply to rozhuk.im from comment #13) Hello Rozhuk, that's right as already stated in comment #11. Django v1.8 is not compatible with DRF v3.8.x and thus Django v1.8 systems must use the www/py-djangorestframework36 port. Are there any issues still open in your Django v1.8 environment or have you already solved your initial reported problem by switching from www/py-djangorestframework to www/py-djangorestframework36 ?
(In reply to Kai from comment #14) We are switch www/py-djangorestframework36 and no problem.
Close, this has been sorted.