From 4e25198ec298732409217321be10e1e06be2fcbd Mon Sep 17 00:00:00 2001 From: Juan Catalano Date: Sun, 24 Mar 2013 22:48:23 -0700 Subject: Fixed #20104 -- Changed VersionDirective in order to avoid ambiguity. As explained in ticket #20104, the use of versionchanged/versionadded was confusing. To solve this ambiguity these directives no longer accept a second argument but now they only receive the version number (1st arg) and then a content with the proper comment. --- docs/internals/contributing/writing-documentation.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/internals') diff --git a/docs/internals/contributing/writing-documentation.txt b/docs/internals/contributing/writing-documentation.txt index 469f8614b9..2944dea504 100644 --- a/docs/internals/contributing/writing-documentation.txt +++ b/docs/internals/contributing/writing-documentation.txt @@ -188,8 +188,8 @@ Our policy for new features is: release, not the development version. Our preferred way for marking new features is by prefacing the features' -documentation with: "``.. versionadded:: X.Y``", followed by an optional one -line comment and a mandatory blank line. +documentation with: "``.. versionadded:: X.Y``", followed by a a mandatory +blank line and an optional content (indented). General improvements, or other changes to the APIs that should be emphasized should use the "``.. versionchanged:: X.Y``" directive (with the same format -- cgit v1.3 From 8f7276b782e4e10f3e361f9d833f4e415e70bb28 Mon Sep 17 00:00:00 2001 From: Claude Paroz Date: Thu, 25 Apr 2013 10:32:27 +0200 Subject: Updated Transifex links to the Django project Translations for the Django framework are now hosted on the django-core Transifex project, and the django project is only dedicated to a team-only hub project. --- .tx/config | 30 +++++++++++++++--------------- docs/internals/contributing/localizing.txt | 2 +- scripts/manage_translations.py | 4 ++-- 3 files changed, 18 insertions(+), 18 deletions(-) (limited to 'docs/internals') diff --git a/.tx/config b/.tx/config index cb617326b9..fdd7a576f7 100644 --- a/.tx/config +++ b/.tx/config @@ -2,77 +2,77 @@ host = https://www.transifex.com lang_map = sr@latin:sr_Latn -[django.core] +[django-core.core] file_filter = django/conf/locale//LC_MESSAGES/django.po source_file = django/conf/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-admin] +[django-core.contrib-admin] file_filter = django/contrib/admin/locale//LC_MESSAGES/django.po source_file = django/contrib/admin/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-admin-js] +[django-core.contrib-admin-js] file_filter = django/contrib/admin/locale//LC_MESSAGES/djangojs.po source_file = django/contrib/admin/locale/en/LC_MESSAGES/djangojs.po source_lang = en -[django.contrib-admindocs] +[django-core.contrib-admindocs] file_filter = django/contrib/admindocs/locale//LC_MESSAGES/django.po source_file = django/contrib/admindocs/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-auth] +[django-core.contrib-auth] file_filter = django/contrib/auth/locale//LC_MESSAGES/django.po source_file = django/contrib/auth/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-comments] +[django-core.contrib-comments] file_filter = django/contrib/comments/locale//LC_MESSAGES/django.po source_file = django/contrib/comments/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-contenttypes] +[django-core.contrib-contenttypes] file_filter = django/contrib/contenttypes/locale//LC_MESSAGES/django.po source_file = django/contrib/contenttypes/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-flatpages] +[django-core.contrib-flatpages] file_filter = django/contrib/flatpages/locale//LC_MESSAGES/django.po source_file = django/contrib/flatpages/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-formtools] +[django-core.contrib-formtools] file_filter = django/contrib/formtools/locale//LC_MESSAGES/django.po source_file = django/contrib/formtools/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-gis] +[django-core.contrib-gis] file_filter = django/contrib/gis/locale//LC_MESSAGES/django.po source_file = django/contrib/gis/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-humanize] +[django-core.contrib-humanize] file_filter = django/contrib/humanize/locale//LC_MESSAGES/django.po source_file = django/contrib/humanize/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-messages] +[django-core.contrib-messages] file_filter = django/contrib/messages/locale//LC_MESSAGES/django.po source_file = django/contrib/messages/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-redirects] +[django-core.contrib-redirects] file_filter = django/contrib/redirects/locale//LC_MESSAGES/django.po source_file = django/contrib/redirects/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-sessions] +[django-core.contrib-sessions] file_filter = django/contrib/sessions/locale//LC_MESSAGES/django.po source_file = django/contrib/sessions/locale/en/LC_MESSAGES/django.po source_lang = en -[django.contrib-sites] +[django-core.contrib-sites] file_filter = django/contrib/sites/locale//LC_MESSAGES/django.po source_file = django/contrib/sites/locale/en/LC_MESSAGES/django.po source_lang = en diff --git a/docs/internals/contributing/localizing.txt b/docs/internals/contributing/localizing.txt index 0cde77882c..01b88d8d9a 100644 --- a/docs/internals/contributing/localizing.txt +++ b/docs/internals/contributing/localizing.txt @@ -62,5 +62,5 @@ Django source tree, as for any code change: .. _Transifex: https://www.transifex.com/ .. _Django i18n mailing list: http://groups.google.com/group/django-i18n/ -.. _Django project page: https://www.transifex.com/projects/p/django/ +.. _Django project page: https://www.transifex.com/projects/p/django-core/ .. _Transifex User Guide: http://help.transifex.com/ diff --git a/scripts/manage_translations.py b/scripts/manage_translations.py index b90b26e1f8..3e58040187 100644 --- a/scripts/manage_translations.py +++ b/scripts/manage_translations.py @@ -47,9 +47,9 @@ def _get_locale_dirs(include_core=True): def _tx_resource_for_name(name): """ Return the Transifex resource name """ if name == 'core': - return "django.core" + return "django-core.core" else: - return "django.contrib-%s" % name + return "django-core.contrib-%s" % name def _check_diff(cat_name, base_path): """ -- cgit v1.3 From a5becad9094e5c5403b692b9a7b3a6ffaabf64a3 Mon Sep 17 00:00:00 2001 From: Florian Apolloner Date: Wed, 3 Apr 2013 12:42:33 +0200 Subject: Fixed #19252 -- Added support for wheel packages. Signed-off-by: Jannis Leidel --- MANIFEST.in | 2 + django/bin/__init__.py | 0 docs/internals/howto-release-django.txt | 13 +++-- extras/Makefile | 9 ++++ setup.cfg | 5 ++ setup.py | 96 ++++++++++++++++----------------- 6 files changed, 69 insertions(+), 56 deletions(-) delete mode 100644 django/bin/__init__.py create mode 100644 extras/Makefile (limited to 'docs/internals') diff --git a/MANIFEST.in b/MANIFEST.in index 0e0aba1268..e9c5a409be 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -10,7 +10,9 @@ recursive-include docs * recursive-include scripts * recursive-include extras * recursive-include tests * +recursive-include django/conf/app_template * recursive-include django/conf/locale * +recursive-include django/conf/project_template * recursive-include django/contrib/*/locale * recursive-include django/contrib/admin/templates * recursive-include django/contrib/admin/static * diff --git a/django/bin/__init__.py b/django/bin/__init__.py deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/docs/internals/howto-release-django.txt b/docs/internals/howto-release-django.txt index a49251da76..fd985ddafc 100644 --- a/docs/internals/howto-release-django.txt +++ b/docs/internals/howto-release-django.txt @@ -175,13 +175,13 @@ OK, this is the fun part, where we actually push out a release! #. Make sure you have an absolutely clean tree by running ``git clean -dfx``. -#. Run ``python setup.py sdist`` to generate the release package. This will - create the release package in a ``dist/`` directory. +#. Run ``make -f extras/Makefile`` to generate the release packages. This will + create the release packages in a ``dist/`` directory. -#. Generate the hashes of the release package:: +#. Generate the hashes of the release packages:: - $ md5sum dist/Django-.tar.gz - $ sha1sum dist/Django-.tar.gz + $ md5sum dist/Django-* + $ sha1sum dist/Django-* *FIXME: perhaps we should switch to sha256?* @@ -221,6 +221,9 @@ Now you're ready to actually put the release out there. To do this: $ mktmpenv $ pip install https://www.djangoproject.com/m/releases/1.5/Django-1.5.1.tar.gz $ deactivate + $ mktmpenv + $ pip install https://www.djangoproject.com/m/releases/1.5/Django-1.5.1-py2.py3-none-any.whl + $ deactivate This just tests that the tarballs are available (i.e. redirects are up) and that they install correctly, but it'll catch silly mistakes. diff --git a/extras/Makefile b/extras/Makefile new file mode 100644 index 0000000000..ff14f404e2 --- /dev/null +++ b/extras/Makefile @@ -0,0 +1,9 @@ +all: sdist bdist_wheel + +sdist: + python setup.py sdist + +bdist_wheel: + python -c "import setuptools;__file__='setup.py';exec(compile(open(__file__).read().replace('\\r\\n', '\\n'), __file__, 'exec'))" bdist_wheel + +.PHONY : sdist bdist_wheel diff --git a/setup.cfg b/setup.cfg index e189ffb47b..330eff6977 100644 --- a/setup.cfg +++ b/setup.cfg @@ -2,3 +2,8 @@ doc_files = docs extras AUTHORS INSTALL LICENSE README.rst install-script = scripts/rpm-install.sh +[metadata] +license-file = LICENSE + +[wheel] +universal = 1 # use py2.py3 tag for pure-python dist diff --git a/setup.py b/setup.py index 006cba4137..7f848a56ff 100644 --- a/setup.py +++ b/setup.py @@ -1,10 +1,9 @@ -from distutils.core import setup -from distutils.command.install_data import install_data -from distutils.command.install import INSTALL_SCHEMES -from distutils.sysconfig import get_python_lib import os import sys +from distutils.core import setup +from distutils.sysconfig import get_python_lib + # Warn if we are installing over top of an existing installation. This can # cause issues where files that were deleted from a more recent Django are # still present in site-packages. See #18115. @@ -23,28 +22,11 @@ if "install" in sys.argv: overlay_warning = True break -class osx_install_data(install_data): - # On MacOS, the platform-specific lib dir is /System/Library/Framework/Python/.../ - # which is wrong. Python 2.5 supplied with MacOS 10.5 has an Apple-specific fix - # for this in distutils.command.install_data#306. It fixes install_lib but not - # install_data, which is why we roll our own install_data class. - - def finalize_options(self): - # By the time finalize_options is called, install.install_lib is set to the - # fixed directory, so we set the installdir to install_lib. The - # install_data class uses ('install_data', 'install_dir') instead. - self.set_undefined_options('install', ('install_lib', 'install_dir')) - install_data.finalize_options(self) - -if sys.platform == "darwin": - cmdclasses = {'install_data': osx_install_data} -else: - cmdclasses = {'install_data': install_data} def fullsplit(path, result=None): """ - Split a pathname into components (the opposite of os.path.join) in a - platform-neutral way. + Split a pathname into components (the opposite of os.path.join) + in a platform-neutral way. """ if result is None: result = [] @@ -55,15 +37,23 @@ def fullsplit(path, result=None): return result return fullsplit(head, [tail] + result) -# Tell distutils not to put the data_files in platform-specific installation -# locations. See here for an explanation: -# http://groups.google.com/group/comp.lang.python/browse_thread/thread/35ec7b2fed36eaec/2105ee4d9e8042cb -for scheme in INSTALL_SCHEMES.values(): - scheme['data'] = scheme['purelib'] + +EXCLUDE_FROM_PACKAGES = ['django.conf.project_template', + 'django.conf.app_template', + 'django.bin'] + + +def is_package(package_name): + for pkg in EXCLUDE_FROM_PACKAGES: + if package_name.startswith(pkg): + return False + return True + # Compile the list of packages available, because distutils doesn't have # an easy way to do this. -packages, data_files = [], [] +packages, package_data = [], {} + root_dir = os.path.dirname(__file__) if root_dir != '': os.chdir(root_dir) @@ -72,33 +62,37 @@ django_dir = 'django' for dirpath, dirnames, filenames in os.walk(django_dir): # Ignore PEP 3147 cache dirs and those whose names start with '.' dirnames[:] = [d for d in dirnames if not d.startswith('.') and d != '__pycache__'] - if '__init__.py' in filenames: - packages.append('.'.join(fullsplit(dirpath))) + parts = fullsplit(dirpath) + package_name = '.'.join(parts) + if '__init__.py' in filenames and is_package(package_name): + packages.append(package_name) elif filenames: - data_files.append([dirpath, [os.path.join(dirpath, f) for f in filenames]]) + relative_path = [] + while '.'.join(parts) not in packages: + relative_path.append(parts.pop()) + relative_path.reverse() + path = os.path.join(*relative_path) + package_files = package_data.setdefault('.'.join(parts), []) + package_files.extend([os.path.join(path, f) for f in filenames]) -# Small hack for working with bdist_wininst. -# See http://mail.python.org/pipermail/distutils-sig/2004-August/004134.html -if len(sys.argv) > 1 and sys.argv[1] == 'bdist_wininst': - for file_info in data_files: - file_info[0] = '\\PURELIB\\%s' % file_info[0] # Dynamically calculate the version based on django.VERSION. version = __import__('django').get_version() + setup( - name = "Django", - version = version, - url = 'http://www.djangoproject.com/', - author = 'Django Software Foundation', - author_email = 'foundation@djangoproject.com', - description = 'A high-level Python Web framework that encourages rapid development and clean, pragmatic design.', - license = "BSD", - packages = packages, - cmdclass = cmdclasses, - data_files = data_files, - scripts = ['django/bin/django-admin.py'], - classifiers = [ + name='Django', + version=version, + url='http://www.djangoproject.com/', + author='Django Software Foundation', + author_email='foundation@djangoproject.com', + description=('A high-level Python Web framework that encourages ' + 'rapid development and clean, pragmatic design.'), + license='BSD', + packages=packages, + package_data=package_data, + scripts=['django/bin/django-admin.py'], + classifiers=[ 'Development Status :: 5 - Production/Stable', 'Environment :: Web Environment', 'Framework :: Django', @@ -115,7 +109,7 @@ setup( 'Topic :: Internet :: WWW/HTTP :: WSGI', 'Topic :: Software Development :: Libraries :: Application Frameworks', 'Topic :: Software Development :: Libraries :: Python Modules', - ], + ], ) if overlay_warning: @@ -136,4 +130,4 @@ should manually remove the directory and re-install Django. -""" % { "existing_path": existing_path }) +""" % {"existing_path": existing_path}) -- cgit v1.3 From d48b7230a8b8d44607b19749fb4a0a8a25d50cf1 Mon Sep 17 00:00:00 2001 From: Daniel Lindsley Date: Fri, 3 May 2013 00:46:04 -0700 Subject: Added myself to the committers list. --- docs/internals/committers.txt | 34 ++++++++++++++++++++++++---------- 1 file changed, 24 insertions(+), 10 deletions(-) (limited to 'docs/internals') diff --git a/docs/internals/committers.txt b/docs/internals/committers.txt index a0649f38a2..f891bc4eb7 100644 --- a/docs/internals/committers.txt +++ b/docs/internals/committers.txt @@ -15,7 +15,7 @@ Journal-World`_ of Lawrence, Kansas, USA. He was lead developer at World Online for 2.5 years, during which time Django was developed and implemented on World Online's sites. He was the - leader and founder of EveryBlock_, a "news feed for your block." He now + leader and founder of EveryBlock_, a "news feed for your block." He now develops for Soundslice_. Adrian lives in Chicago, USA. @@ -41,7 +41,7 @@ Journal-World`_ of Lawrence, Kansas, USA. `Wilson Miner`_ Wilson's design-fu is what makes Django look so nice. He designed the Web site you're looking at right now, as well as Django's acclaimed admin - interface. Wilson was the designer for EveryBlock and Rdio_. He now + interface. Wilson was the designer for EveryBlock and Rdio_. He now designs for Facebook. Wilson lives in San Francisco, USA. @@ -105,8 +105,8 @@ Malcolm Tredinnick .. _russell keith-magee: http://cecinestpasun.com/ Joseph Kocherhans - Joseph was the director of lead development at EveryBlock and previously - developed at the Lawrence Journal-World. He is treasurer of the `Django + Joseph was the director of lead development at EveryBlock and previously + developed at the Lawrence Journal-World. He is treasurer of the `Django Software Foundation`_. He often disappears for several days into the woods, attempts to teach himself computational linguistics, and annoys his neighbors with his Charango_ playing. @@ -386,17 +386,17 @@ Florian Apolloner .. _Ubuntuusers webteam: http://wiki.ubuntuusers.de/ubuntuusers/Webteam Jeremy Dunck - Jeremy was rescued from corporate IT drudgery by Free Software and, in part, + Jeremy was rescued from corporate IT drudgery by Free Software and, in part, Django. Many of Jeremy's interests center around access to information. - Jeremy was the lead developer of Pegasus News, one of the first uses of - Django outside World Online, and has since joined Votizen, a startup intent + Jeremy was the lead developer of Pegasus News, one of the first uses of + Django outside World Online, and has since joined Votizen, a startup intent on reducing the influence of money in politics. - He serves as DSF Secretary, organizes and helps organize sprints, cares - about the health and equity of the Django community. He has gone an + He serves as DSF Secretary, organizes and helps organize sprints, cares + about the health and equity of the Django community. He has gone an embarrassingly long time without a working blog. - + Jeremy lives in Mountain View, CA, USA. `Bryan Veloso`_ @@ -441,6 +441,20 @@ Jeremy Dunck .. _Ultimate Frisbee: http://www.montrealultimate.ca .. _Reptiletech: http://www.reptiletech.com +`Daniel Lindsley`_ + Pythonista since 2003, Djangonaut since 2006. Daniel started with Django + just after the v0.90 release (back when ``Manipulators`` looked good) & fell + in love. Since then, he wrote third-party apps like Haystack & Tastypie + & has run the annual Django Dash since 2007. One of the testing faithful, + Daniel's contributions include rewriting the ``Forms`` test suite & the + addition of ``request.is_ajax``. Daniel currently works as a Python + developer at `Amazon Web Services`_ on the ``boto`` library. + + Daniel lives in Seattle, WA, USA. + +.. _`Daniel Lindsley`: http://toastdriven.com/ +.. _`Amazon Web Services`: https://aws.amazon.com/ + Specialists ----------- -- cgit v1.3