okupy is a Django based CMS which proposed to replace Gorg on gentoo.org, with LDAP frontend. This project was done a year back, at that time stable version of django(python web frame that cms uses) was 1.3. Now, new stable version of Django is released -- v1.4. As its always a good idea to keep all applications updated to latest versions, specially in case of webapps. Hence I have started the upgrade process of okupy to v1.4. At first look, okupy seems to work fine with 1.4 but there are Deprecation Warnings encountered while running okupy cms. Basically, the ADMIN_MEDIA_PREFIX setting has been Deprecated & we should remove this from okupy. Reproducible: Always Steps to Reproduce: 1.make sure you are running django 1.4. Else, Upgrade using following command(if using pip): $ pip install Django --upgrade 2. run, $ python manage.py runserver 3. Watch the warnings appear Actual Results: ---------------------- /usr/local/lib/python2.6/dist-packages/django/conf/__init__.py:75: DeprecationWarning: The ADMIN_MEDIA_PREFIX setting has been removed; use STATIC_URL instead. "use STATIC_URL instead.", DeprecationWarning) warnings.warn("The SECRET_KEY setting must not be empty.", DeprecationWarning) /usr/local/lib/python2.6/dist-packages/django/conf/__init__.py:75: DeprecationWarning: The ADMIN_MEDIA_PREFIX setting has been removed; use STATIC_URL instead. "use STATIC_URL instead.", DeprecationWarning) Validating models... 0 errors found Django version 1.4, using settings 'okupy.settings' Development server is running at http://127.0.0.1:8000/ Quit the server with CONTROL-C. --------------------------------- Expected Results: No warnings ---------------------- Validating models... 0 errors found Django version 1.4, using settings 'okupy.settings' Development server is running at http://127.0.0.1:8000/ Quit the server with CONTROL-C. --------------------------------- The release notes which detail the removal of setting can be found in release notes: https://docs.djangoproject.com/en/dev/ref/settings/#id5
do you want me to do it or do you prefer to send me a patch instead?
Created attachment 308173 [details, diff] remove deprecation warnings
The warning says to replace it with STATIC_URL instead
Yes you are correct but as STATIC_URL has already defined (http://git.overlays.gentoo.org/gitweb/?p=proj/okupy.git;a=blob;f=settings/base.py;h=d2f789f31b1b3fd28fa56a3f7e75803623e02b9c;hb=HEAD#l30) . According to release notes, Django will now expect to find the admin static files under the URL /static/admin/ without need to for setting explicitly specifying it. https://docs.djangoproject.com/en/dev/releases/1.4/#django-contrib-admin PS: I am doing this bugfix as part of gentoo's requirement to fix one bug while applying for gsoc.
Pushed, thanks
Perfect Thanks!