Changes between Version 131 and Version 132 of RemovingTheMagic
- Timestamp:
- May 1, 2006, 9:06:44 PM (19 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
RemovingTheMagic
v131 v132 1 1 = Removing the magic = 2 2 3 The "magic-removal" branch aims to make several sweeping changes to the Django codebase, removing warts that Django hasaccumulated over the years. Most changes involve the database API and removing some of its unneeded magic, and other changes involve improving the framework's simplicity and usability.4 5 These changes will be integrated into the next Django release, 0.92.6 7 This document explains the changes in the branch.3 The "magic-removal" branch has made several sweeping changes to the Django codebase, removing warts that Django accumulated over the years. Most changes involve the database API and removing some of its unneeded magic, and other changes involve improving the framework's simplicity and usability. 4 5 As of May 1, 2006, these changes have been integrated into the Django development version (Subversion's trunk), and they'll be released officially in the next Django release, 0.95. 6 7 This document explains all changes. 8 8 9 9 [[TOC(inline, RemovingTheMagic)]] … … 11 11 == How to get the branch == 12 12 13 Play with it! The branch is available via Subversion at http://code.djangoproject.com/svn/django/branches/magic-removal . 13 If you're running Django 0.91 at the moment and want to start playing with the new, magic-removal version, just check out Django's development version using this command: 14 15 {{{ 16 svn co http://code.djangoproject.com/svn/django/trunk/ 17 }}} 14 18 15 19 === Using two versions of Django side-by-side === 16 20 17 Here's one way to use Django 's trunk and magic-removal branch on the same machine. This assumes Django's trunk (or a release such as 0.90 or 0.91)is installed:18 19 {{{ 20 # Get the magic-removalcode somewhere on your filesystem. In this example, we use /home/python/django.21 Here's one way to use Django 0.91 and the magic-removal trunk versions on the same machine. This assumes a release such as 0.90 or 0.91 is installed: 22 23 {{{ 24 # Get the development/trunk code somewhere on your filesystem. In this example, we use /home/python/django. 21 25 $ cd /home/python/django 22 $ svn co http://code.djangoproject.com/svn/django/ branches/magic-removal23 24 # This will have created a " magic-removal" directory.25 26 # Whenever you want to use magic-removal, set the environment variable {{{PYTHONPATH}}} to the directory containing magic-removal.27 export PYTHONPATH=/home/python/django/ magic-removal26 $ svn co http://code.djangoproject.com/svn/django/trunk 27 28 # This will have created a "trunk" directory. 29 30 # Whenever you want to use trunk, set the environment variable {{{PYTHONPATH}}} to the directory containing trunk. 31 export PYTHONPATH=/home/python/django/trunk 28 32 }}} 29 33 30 34 == Overview == 31 35 32 The biggest changes in magic-removalare:36 The biggest changes are: 33 37 34 38 * The magic package {{{django.models}}} no longer exists. To use models, just import the model class from wherever it lives on the Python path. Similarly, the magic modules (such as {{{django.models.polls}}} in the tutorial) no longer exist; now, you interact directly with the model class. … … 36 40 * The database API has changed in several ways. 37 41 * Various packages, such as the Django template system (previously in {{{django.core.template}}}), have been moved around to make importing less verbose and easier to remember. 38 39 == Status ==40 41 Have at it! It's pretty stable, and we just need people to hack at it and make sure all is well.42 42 43 43 == Database changes you'll need to make == … … 448 448 from django.db import connection 449 449 cursor = connection.cursor() 450 450 451 451 452 }}} … … 887 888 == Documentation status == 888 889 889 Adrian is proofreading each document in {{{docs/}}} to make sure all is well. Here's the status. 890 The documentation on djangoproject.com has been updated to focus on trunk. [http://www.djangoproject.com/documentation/0_91/ Documentation for 0.91] has been archived. 891 892 A few improvements still need to be made to the new documentation, however. Adrian is proofreading each document to make sure all is well. Here's the status. 890 893 891 894 ||Document||Edited by Adrian||