Merge branch 'release/0.9.1' into develop
authorJoseph Spiros <joseph.spiros@ithinksw.com>
Sun, 9 Oct 2011 02:25:22 +0000 (22:25 -0400)
committerJoseph Spiros <joseph.spiros@ithinksw.com>
Sun, 9 Oct 2011 02:25:22 +0000 (22:25 -0400)
* release/0.9.1:
  Edited the READMEs and documentation to be cleaner and more consistent.
  Bumped version number to 0.9.1 in preparation for release.
  Tweaked manifest file. Removed a bunch of hackery from setup.py in favor of setuptools.find_packages, since we're using setuptools anyway. Addresses bug #177.
  Abstracted email resetting during the email change process onto the AccountForm. Addresses bug #173.
  This will include non *.py files in our distribution for setup.py, easy_install, pip, &c. purposes.
  Removed python requirement line from setup.py, since easy_install and pip can't do anything with it and will choke on it for e.g. pypy.
  Correction to waldo login view to pass the request into the login_form for GET requests as well.
  Added release notes for 0.9.1.
  Merged the contribution information from the ithinksw.org philo wiki into the documentation.
  Removed philo.models.Tag entry from the docs.
  Incremented version number to 0.9.1rc and cleaned up README a tiny bit.

14 files changed:
MANIFEST.in [new file with mode: 0644]
README
README.markdown
docs/cla/ithinksw-ccla.txt [new file with mode: 0644]
docs/cla/ithinksw-icla.txt [new file with mode: 0644]
docs/conf.py
docs/contributing.rst
docs/index.rst
docs/models/miscellaneous.rst
docs/releases/0.9.1.rst [new file with mode: 0644]
philo/__init__.py
philo/contrib/waldo/forms.py
philo/contrib/waldo/models.py
setup.py

diff --git a/MANIFEST.in b/MANIFEST.in
new file mode 100644 (file)
index 0000000..0e076d9
--- /dev/null
@@ -0,0 +1,12 @@
+include README
+include README.markdown
+include LICENSE
+include MANIFEST.in
+recursive-include philo/templates *.html
+recursive-include philo/contrib/sobol/templates *.html
+recursive-include philo/fixtures *.json
+recursive-include philo/static *.css *.js
+recursive-include philo/contrib/sobol/static *.css *.js
+recursive-include docs *.py *.rst *.bat *.txt Makefile
+global-exclude *~
+prune docs/_build
\ No newline at end of file
diff --git a/README b/README
index 69c0c52..630ea76 100644 (file)
--- a/README
+++ b/README
@@ -1,22 +1,19 @@
-Philo is a foundation for developing web content management systems.
+Philo <http://philocms.org/> is a foundation for developing web content management systems.
 
 Prerequisites:
        * Python 2.5.4+ <http://www.python.org/>
        * Django 1.3+ <http://www.djangoproject.com/>
        * django-mptt e734079+ <https://github.com/django-mptt/django-mptt/>
-       * (philo.contrib.penfield) django-taggit 0.9.3+ <https://github.com/alex/django-taggit>
-       * (Optional) django-grappelli 2.0+ <http://code.google.com/p/django-grappelli/>
-       * (Optional) south 0.7.2+ <http://south.aeracode.org/>
-       * (Optional) recaptcha-django r6 <http://code.google.com/p/recaptcha-django/>
+       * (optional) django-grappelli 2.0+ <http://code.google.com/p/django-grappelli/>
+       * (optional) south 0.7.2+ <http://south.aeracode.org/>
+       * (philo.contrib.penfield) django-taggit 0.9.3+ <https://github.com/alex/django-taggit/>
+       * (philo.contrib.waldo, optional) recaptcha-django r6+ <http://code.google.com/p/recaptcha-django/>
 
-====
-Using philo
-====
-After installing philo and mptt on your python path, make sure to complete the following steps:
+After installing philo and mptt on your PYTHONPATH, make sure to complete the following steps:
 
-1. add 'philo.middleware.RequestNodeMiddleware' to settings.MIDDLEWARE_CLASSES.
-2. add 'philo' and 'mptt' to settings.INSTALLED_APPS.
-3. include 'philo.urls' somewhere in your urls.py file.
+1. Add 'philo.middleware.RequestNodeMiddleware' to settings.MIDDLEWARE_CLASSES.
+2. Add 'philo' and 'mptt' to settings.INSTALLED_APPS.
+3. Include 'philo.urls' somewhere in your urls.py file.
 4. Optionally add a root node to your current Site.
 
-Philo should be ready to go! All that's left is to learn more <http://philo.readthedocs.org> and contribute <http://philo.readthedocs.org/en/latest/contribute.html>.
+Philo should be ready to go! All that's left is to learn more <http://docs.philocms.org/> and contribute <http://docs.philocms.org/en/latest/contribute.html>.
index c6a198a..77ebb65 100644 (file)
@@ -1,26 +1,20 @@
-Philo is a foundation for developing web content management systems.
+[Philo](http://philocms.org/) is a foundation for developing web content management systems.
 
 Prerequisites:
 
- * [Python 2.5.4+ &lt;http://www.python.org&gt;](http://www.python.org/)
- * [Django 1.3+ &lt;http://www.djangoproject.com/&gt;](http://www.djangoproject.com/)
- * [django-mptt e734079+ &lt;https://github.com/django-mptt/django-mptt/&gt;](https://github.com/django-mptt/django-mptt/)
- * (philo.contrib.penfield) [django-taggit 0.9.3+ &lt;https://github.com/alex/django-taggit&gt;](https://github.com/alex/django-taggit)
- * (Optional) [django-grappelli 2.0+ &lt;http://code.google.com/p/django-grappelli/&gt;](http://code.google.com/p/django-grappelli/)
- * (Optional) [south 0.7.2+ &lt;http://south.aeracode.org/)](http://south.aeracode.org/)
- * (Optional) [recaptcha-django r6 &lt;http://code.google.com/p/recaptcha-django/&gt;](http://code.google.com/p/recaptcha-django/)
+ * [Python 2.5.4+](http://www.python.org/)
+ * [Django 1.3+](http://www.djangoproject.com/)
+ * [django-mptt e734079+](https://github.com/django-mptt/django-mptt/)
+ * (optional) [django-grappelli 2.0+](http://code.google.com/p/django-grappelli/)
+ * (optional) [south 0.7.2+](http://south.aeracode.org/)
+ * (philo.contrib.penfield) [django-taggit 0.9.3+](https://github.com/alex/django-taggit/)
+ * (philo.contrib.waldo, optional) [recaptcha-django r6+](http://code.google.com/p/recaptcha-django/)
 
-To contribute, please visit the [project website](http://project.philocms.org/) and/or make a fork of the git repository on [GitHub](http://github.com/ithinksw/philo) or [Gitorious](http://gitorious
-.org/ithinksw/philo). Feel free to join us on IRC at [irc://irc.oftc.net/#philo](irc://irc.oftc.net/#philo).
+After installing philo and mptt on your PYTHONPATH, make sure to complete the following steps:
 
-Using philo
-===========
-
-After installing philo and mptt on your python path, make sure to complete the following steps:
-
-1. add 'philo.middleware.RequestNodeMiddleware' to settings.MIDDLEWARE_CLASSES.
-2. add 'philo' and 'mptt' to settings.INSTALLED_APPS.
-3. include 'philo.urls' somewhere in your urls.py file.
+1. Add 'philo.middleware.RequestNodeMiddleware' to settings.MIDDLEWARE_CLASSES.
+2. Add 'philo' and 'mptt' to settings.INSTALLED_APPS.
+3. Include 'philo.urls' somewhere in your urls.py file.
 4. Optionally add a root node to your current Site.
 
-Philo should be ready to go! All that's left is to [learn more](http://philo.readthedocs.org) and [contribute](http://philo.readthedocs.org/en/latest/contribute.html).
+Philo should be ready to go! All that's left is to [learn more](http://docs.philocms.org/) and [contribute](http://docs.philocms.org/en/latest/contribute.html).
diff --git a/docs/cla/ithinksw-ccla.txt b/docs/cla/ithinksw-ccla.txt
new file mode 100644 (file)
index 0000000..0e6b2ae
--- /dev/null
@@ -0,0 +1,140 @@
+                           iThink Software
+     Corporate Contributor License Agreement ("Agreement") v1.0
+
+Thank you for your interest in iThink Software. In order to clarify
+the intellectual property license granted with Contributions from
+any person or entity, iThink Software must have a Contributor
+License Agreement ("CLA") on file that has been signed by each
+Contributor, indicating agreement to the license terms below. This
+license is for your protection as a Contributor as well as the
+protection of iThink Software and its users; it does not change
+your rights to use your own Contributions for any other purpose.
+
+This version of the Agreement allows an entity (the "Corporation")
+to submit Contributions to iThink Software, to authorize Contributions
+submitted by its designated employees to iThink Software, and to grant
+copyright and patent licenses thereto.
+
+If you have not already done so, please complete and sign, then scan
+and email a pdf file of this Agreement to contact@ithinksw.com.
+Alternatively, you may send an original signed Agreement to
+iThink Software, 261 West Lorain Street, Oberlin, OH 44074, U.S.A.
+Please read this document carefully before signing and
+keep a copy for your records.
+
+  Corporation name:    ______________________________________________
+
+  Corporation address: ______________________________________________
+
+                       ______________________________________________
+
+                       ______________________________________________
+
+  Point of Contact:    ______________________________________________
+
+         E-Mail:       ______________________________________________
+
+         Telephone:    ____________________ Fax: ____________________
+
+
+You accept and agree to the following terms and conditions for Your
+present and future Contributions submitted to iThink Software. Except
+for the license granted herein to iThink Software and recipients of
+software distributed by iThink Software, You reserve all right,
+title, and interest in and to Your Contributions.
+
+1. Definitions.
+
+   "You" (or "Your") shall mean the copyright owner or legal entity
+   authorized by the copyright owner that is making this Agreement
+   with iThink Software. For legal entities, the entity making a
+   Contribution and all other entities that control, are controlled
+   by, or are under common control with that entity are considered to
+   be a single Contributor. For the purposes of this definition,
+   "control" means (i) the power, direct or indirect, to cause the
+   direction or management of such entity, whether by contract or
+   otherwise, or (ii) ownership of fifty percent (50%) or more of the
+   outstanding shares, or (iii) beneficial ownership of such entity.
+
+   "Contribution" shall mean any original work of authorship,
+   including any modifications or additions to an existing work, that
+   is intentionally submitted by You to iThink Software for inclusion
+   in, or documentation of, any of the products owned or managed by
+   iThink Software (the "Work"). For the purposes of this definition,
+   "submitted" means any form of electronic, verbal, or written
+   communication sent to iThink Software or its representatives,
+   including but not limited to communication on electronic mailing
+   lists, source code control systems, and issue tracking systems that
+   are managed by, or on behalf of, iThink Software for the purpose of
+   discussing and improving the Work, but excluding communication that
+   is conspicuously marked or otherwise designated in writing by You
+   as "Not a Contribution."
+
+2. Grant of Copyright License. Subject to the terms and conditions of
+   this Agreement, You hereby grant to iThink Software and to
+   recipients of software distributed by iThink Software a perpetual,
+   worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+   copyright license to reproduce, prepare derivative works of,
+   publicly display, publicly perform, sublicense, and distribute Your
+   Contributions and such derivative works.
+
+3. Grant of Patent License. Subject to the terms and conditions of
+   this Agreement, You hereby grant to iThink Software and to
+   recipients of software distributed by iThink Software a perpetual,
+   worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+   (except as stated in this section) patent license to make, have
+   made, use, offer to sell, sell, import, and otherwise transfer the
+   Work, where such license applies only to those patent claims
+   licensable by You that are necessarily infringed by Your
+   Contribution(s) alone or by combination of Your Contribution(s)
+   with the Work to which such Contribution(s) were submitted. If any
+   entity institutes patent litigation against You or any other entity
+   (including a cross-claim or counterclaim in a lawsuit) alleging
+   that your Contribution, or the Work to which you have contributed,
+   constitutes direct or contributory patent infringement, then any
+   patent licenses granted to that entity under this Agreement for
+   that Contribution or Work shall terminate as of the date such
+   litigation is filed.
+
+4. You represent that You are legally entitled to grant the above
+   license. You represent further that each employee of the
+   Corporation designated on Schedule A below (or in a subsequent
+   written modification to that Schedule) is authorized to submit
+   Contributions on behalf of the Corporation.
+
+5. You represent that each of Your Contributions is Your original
+   creation (see section 7 for submissions on behalf of others).
+
+6. You are not expected to provide support for Your Contributions,
+   except to the extent You desire to provide support. You may provide
+   support for free, for a fee, or not at all. Unless required by
+   applicable law or agreed to in writing, You provide Your
+   Contributions on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
+   OF ANY KIND, either express or implied, including, without
+   limitation, any warranties or conditions of TITLE, NON-
+   INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE.
+
+7. Should You wish to submit work that is not Your original creation,
+   You may submit it to iThink Software separately from any
+   Contribution, identifying the complete details of its source and of
+   any license or other restriction (including, but not limited to,
+   related patents, trademarks, and license agreements) of which you
+   are personally aware, and conspicuously marking the work as
+   "Submitted on behalf of a third-party: [named here]".
+
+8. It is your responsibility to notify iThink Software when any change
+   is required to the list of designated employees authorized to submit
+   Contributions on behalf of the Corporation, or to the Corporation's
+   Point of Contact with iThink Software.
+
+
+Please sign: __________________________________ Date: _______________
+
+Title:       __________________________________
+
+Corporation: __________________________________
+
+
+Schedule A
+
+   [Initial list of designated employees.]
diff --git a/docs/cla/ithinksw-icla.txt b/docs/cla/ithinksw-icla.txt
new file mode 100644 (file)
index 0000000..929452e
--- /dev/null
@@ -0,0 +1,130 @@
+                           iThink Software
+    Individual Contributor License Agreement ("Agreement") v1.0.1
+
+Thank you for your interest in iThink Software. In order to clarify
+the intellectual property license granted with Contributions from
+any person or entity, iThink Software must have a Contributor
+License Agreement ("CLA") on file that has been signed by each
+Contributor, indicating agreement to the license terms below. This
+license is for your protection as a Contributor as well as the
+protection of iThink Software and its users; it does not change
+your rights to use your own Contributions for any other purpose.
+If you have not already done so, please complete and sign, then scan
+and email a pdf file of this Agreement to contact@ithinksw.com.
+Alternatively, you may send an original signed Agreement to
+iThink Software, 261 West Lorain Street, Oberlin, OH 44074, U.S.A.
+Please read this document carefully before signing and
+keep a copy for your records.
+
+  Full name: ______________________________________________________
+
+  Mailing Address: ________________________________________________
+
+  _________________________________________________________________
+
+  Country:   ______________________________________________________
+
+  Telephone: ______________________________________________________
+
+  Facsimile: ______________________________________________________
+
+  E-Mail:    ______________________________________________________
+
+You accept and agree to the following terms and conditions for Your
+present and future Contributions submitted to iThink Software. Except
+for the license granted herein to iThink Software and recipients of
+software distributed by iThink Software, You reserve all right,
+title, and interest in and to Your Contributions.
+
+1. Definitions.
+
+   "You" (or "Your") shall mean the copyright owner or legal entity
+   authorized by the copyright owner that is making this Agreement
+   with iThink Software. For legal entities, the entity making a
+   Contribution and all other entities that control, are controlled
+   by, or are under common control with that entity are considered to
+   be a single Contributor. For the purposes of this definition,
+   "control" means (i) the power, direct or indirect, to cause the
+   direction or management of such entity, whether by contract or
+   otherwise, or (ii) ownership of fifty percent (50%) or more of the
+   outstanding shares, or (iii) beneficial ownership of such entity.
+
+   "Contribution" shall mean any original work of authorship,
+   including any modifications or additions to an existing work, that
+   is intentionally submitted by You to iThink Software for inclusion
+   in, or documentation of, any of the products owned or managed by
+   iThink Software (the "Work"). For the purposes of this definition,
+   "submitted" means any form of electronic, verbal, or written
+   communication sent to iThink Software or its representatives,
+   including but not limited to communication on electronic mailing
+   lists, source code control systems, and issue tracking systems that
+   are managed by, or on behalf of, iThink Software for the purpose of
+   discussing and improving the Work, but excluding communication that
+   is conspicuously marked or otherwise designated in writing by You
+   as "Not a Contribution."
+
+2. Grant of Copyright License. Subject to the terms and conditions of
+   this Agreement, You hereby grant to iThink Software and to
+   recipients of software distributed by iThink Software a perpetual,
+   worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+   copyright license to reproduce, prepare derivative works of,
+   publicly display, publicly perform, sublicense, and distribute Your
+   Contributions and such derivative works.
+
+3. Grant of Patent License. Subject to the terms and conditions of
+   this Agreement, You hereby grant to iThink Software and to
+   recipients of software distributed by iThink Software a perpetual,
+   worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+   (except as stated in this section) patent license to make, have
+   made, use, offer to sell, sell, import, and otherwise transfer the
+   Work, where such license applies only to those patent claims
+   licensable by You that are necessarily infringed by Your
+   Contribution(s) alone or by combination of Your Contribution(s)
+   with the Work to which such Contribution(s) were submitted. If any
+   entity institutes patent litigation against You or any other entity
+   (including a cross-claim or counterclaim in a lawsuit) alleging
+   that your Contribution, or the Work to which you have contributed,
+   constitutes direct or contributory patent infringement, then any
+   patent licenses granted to that entity under this Agreement for
+   that Contribution or Work shall terminate as of the date such
+   litigation is filed.
+
+4. You represent that you are legally entitled to grant the above
+   license. If your employer(s) has rights to intellectual property
+   that you create that includes your Contributions, you represent
+   that you have received permission to make Contributions on behalf
+   of that employer, that your employer has waived such rights for
+   your Contributions to iThink Software, or that your employer has
+   executed a separate Corporate CLA with iThink Software.
+
+5. You represent that each of Your Contributions is Your original
+   creation (see section 7 for submissions on behalf of others).  You
+   represent that Your Contribution submissions include complete
+   details of any third-party license or other restriction (including,
+   but not limited to, related patents and trademarks) of which you
+   are personally aware and which are associated with any part of Your
+   Contributions.
+
+6. You are not expected to provide support for Your Contributions,
+   except to the extent You desire to provide support. You may provide
+   support for free, for a fee, or not at all. Unless required by
+   applicable law or agreed to in writing, You provide Your
+   Contributions on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
+   OF ANY KIND, either express or implied, including, without
+   limitation, any warranties or conditions of TITLE, NON-
+   INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE.
+
+7. Should You wish to submit work that is not Your original creation,
+   You may submit it to iThink Software separately from any
+   Contribution, identifying the complete details of its source and of
+   any license or other restriction (including, but not limited to,
+   related patents, trademarks, and license agreements) of which you
+   are personally aware, and conspicuously marking the work as
+   "Submitted on behalf of a third-party: [named here]".
+
+8. You agree to notify iThink Software of any facts or circumstances of
+   which you become aware that would make these representations
+   inaccurate in any respect.
+
+
+Please sign: __________________________________ Date: ________________
index 4e6a624..2e703d0 100644 (file)
@@ -62,7 +62,7 @@ copyright = u'2009-2011, iThink Software'
 #
 # The short X.Y version.
 from philo import VERSION
-version = '%s.%s' % (VERSION[0], VERSION[1])
+version = '.'.join([str(v) for v in VERSION])
 # The full version, including alpha/beta/rc tags.
 release = version
 
index 9354c72..4c9fb7d 100644 (file)
@@ -3,6 +3,32 @@ Contributing to Philo
 
 So you want to contribute to Philo? That's great! Here's some ways you can get started:
 
-* **Report bugs and request features.** :mod:`philo` uses a Redmine installation located at `http://ithinksw.org/projects/philo/issues <http://ithinksw.org/projects/philo/issues>`_ for issue tracking. In order to report an issue, you will need to register for an account with the tracker.
-* **Contribute code.** Philo uses git to manage its code. You can fork philo's repository either on `GitHub <http://github.com/ithinksw/philo>`_ or `Gitorious <http://gitorious.org/ithinksw/philo>`_. If you are contributing to Philo, you may need to submit a `Contributor License Agreement <http://en.wikipedia.org/wiki/Contributor_License_Agreement>`_.
-* **Join the discussion** on IRC at `irc://irc.oftc.net/#philo <irc://irc.oftc.net/#philo>`_ if you have any questions or suggestions or just want to chat about the project. You can also keep in touch via :mod:`philo`'s mailing lists: `philo@ithinksw.org <mailto:philo@ithinksw.org>`_ and `philo-devel@ithinksw.org <mailto:philo-devel@ithinksw.org>`_.
+* **Report bugs and request features** using the issue tracker at the `project site <http://project.philocms.org/>`_.
+* **Contribute code** using `git <http://git-scm.com/>`_. You can fork philo's repository either on `GitHub <http://github.com/ithinksw/philo/>`_ or `Gitorious <http://gitorious.org/ithinksw/philo/>`_. If you are contributing to Philo, you will need to submit a :ref:`Contributor License Agreement <cla>`.
+* **Join the discussion** on IRC at `irc://irc.oftc.net/#philo <irc://irc.oftc.net/#philo>`_ if you have any questions or suggestions or just want to chat about the project. You can also keep in touch using the project mailing lists: `philo@ithinksw.org <mailto:philo@ithinksw.org>`_ and `philo-devel@ithinksw.org <mailto:philo-devel@ithinksw.org>`_.
+
+
+Branches and Code Style
++++++++++++++++++++++++
+
+We use `A successful Git branching model`__ with the blessed repository. To make things easier, you probably should too. This means that you should work on and against the develop branch in most cases, and leave it to the release manager to create the commits on the master branch if and when necessary. When pulling changes into the blessed repository at your request, the release manager will usually merge them into the develop branch unless you explicitly note they be treated otherwise.
+
+__ http://nvie.com/posts/a-successful-git-branching-model/
+
+Philo adheres to PEP8 for its code style, with two exceptions: tabs are used rather than spaces, and lines are not truncated at 79 characters.
+
+.. _cla:
+
+Licensing and Legal
++++++++++++++++++++
+
+In order for the release manager to merge your changes into the blessed repository, you will need to have already submitted a signed CLA. Our CLAs are based on the Apache Software Foundation's CLAs, which is the same source as the `Django Project's CLAs`_. You might, therefore, find the `Django Project's CLA FAQ`_. helpful.
+
+.. _`Django Project's CLAs`: https://www.djangoproject.com/foundation/cla/
+.. _`Django Project's CLA FAQ`: https://www.djangoproject.com/foundation/cla/faq/
+
+If you are an individual not doing work for an employer, then you can simply submit the :download:`Individual CLA <cla/ithinksw-icla.txt>`.
+
+If you are doing work for an employer, they will need to submit the :download:`Corporate CLA <cla/ithinksw-ccla.txt>` and you will need to submit the Individual CLA :download:`Individual CLA <cla/ithinksw-icla.txt>` as well.
+
+Both documents include information on how to submit them.
index 743fa39..05422dd 100644 (file)
@@ -8,16 +8,17 @@
 Welcome to Philo's documentation!
 =================================
 
-Philo is a foundation for developing web content management systems.
+Philo is a foundation for developing web content management systems. Please, read the :doc:`notes for our latest release <releases/0.9.1>`.
 
 Prerequisites:
 
-* `Python 2.5.4+ <http://www.python.org>`_
-* `Django 1.2+ <http://www.djangoproject.com/>`_
+* `Python 2.5.4+ <http://www.python.org/>`_
+* `Django 1.3+ <http://www.djangoproject.com/>`_
 * `django-mptt e734079+ <https://github.com/django-mptt/django-mptt/>`_
-* (Optional) `django-grappelli 2.0+ <http://code.google.com/p/django-grappelli/>`_
-* (Optional) `south 0.7.2+ <http://south.aeracode.org/>`_
-* (Optional) `recaptcha-django r6 <http://code.google.com/p/recaptcha-django/>`_
+* (optional) `django-grappelli 2.0+ <http://code.google.com/p/django-grappelli/>`_
+* (optional) `south 0.7.2+ <http://south.aeracode.org/>`_
+* (:mod:`philo.contrib.penfield`) `django-taggit 0.9.3+ <https://github.com/alex/django-taggit/>`_
+* (:mod:`philo.contrib.waldo`, optional) `recaptcha-django r6+ <http://code.google.com/p/recaptcha-django/>`_
 
 Contents
 ++++++++
index 80b654b..005e112 100644 (file)
@@ -2,7 +2,4 @@ Miscellaneous Models
 =============================
 .. autoclass:: philo.models.nodes.TargetURLModel
        :members:
-       :exclude-members: get_target_url
-
-.. autoclass:: philo.models.base.Tag
-       :members:
\ No newline at end of file
+       :exclude-members: get_target_url
\ No newline at end of file
diff --git a/docs/releases/0.9.1.rst b/docs/releases/0.9.1.rst
new file mode 100644 (file)
index 0000000..2003350
--- /dev/null
@@ -0,0 +1,13 @@
+Philo version 0.9.1 release notes
+=================================
+
+The primary focus of the 0.9.1 release has been streamlining and optimization. Requests in 0.9.1 are served two to three times faster than in 0.9. A number of bugs in code, documentation, and migrations have also been corrected.
+
+New Features and backwards-incompatible changes
++++++++++++++++++++++++++++++++++++++++++++++++
+
+* :class:`.FeedView` and related syndication code has been migrated to :mod:`philo.contrib.winer` so it can be used independently of :mod:`philo.contrib.penfield`.
+* :class:`.FeedView` has been refactored; the result of :meth:`.FeedView.get_object` is now passed into :meth:`.FeedView.get_items` to allow for more flexibility and for :class:`.FeedView`\ s which do not have a :class:`ForeignKey` relationship to the items that the feed is for.
+* :class:`.BlogView` has been refactored to take advantage of the more flexible :meth:`~.BlogView.get_object` method. Many of its former entry-fetching methods have been removed.
+* :class:`.EmbedWidget` is now used for text fields on, for example, :class:`BlogEntry`. The widget allows javascript-based generation of embed tags for model instances, using the same popup interface as raw id fields.
+* :class:`philo.models.Tag` has been removed in favor of an optional requirement for ``django-taggit``. This will allow :mod:`philo` to remain more focused. Migrations are provided for :mod:`philo.contrib.penfield` which losslessly convert :mod:`philo` :class:`~philo.models.Tag`\ s to ``django-taggit`` :class:`Tags`.
index c07c373..4e4f145 100644 (file)
@@ -1 +1 @@
-VERSION = (0, 9)
+VERSION = (0, 9, 1)
index eb53598..8e14ba5 100644 (file)
@@ -74,6 +74,30 @@ class UserAccountForm(forms.ModelForm):
                kwargs['instance'] = user
                super(UserAccountForm, self).__init__(*args, **kwargs)
        
+       def email_changed(self):
+               """Returns ``True`` if the email field changed value and ``False`` if it did not, or if there is no email field on the form. This method must be supplied by account forms used with :mod:`~philo.contrib.waldo`."""
+               return 'email' in self.changed_data
+       
+       def reset_email(self):
+               """
+               ModelForms modify their instances in-place during :meth:`_post_clean`; this method resets the email value to its initial state and returns the altered value. This is a method on the form to allow unusual behavior such as storing email on a :class:`UserProfile`.
+               
+               """
+               email = self.instance.email
+               self.instance.email = self.initial['email']
+               self.cleaned_data.pop('email')
+               return email
+       
+       @classmethod
+       def set_email(cls, user, email):
+               """
+               Given a valid instance and an email address, correctly set the email address for that instance and save the changes. This is a class method in order to allow unusual behavior such as storing email on a :class:`UserProfile`.
+               
+               """
+               user.email = email
+               user.save()
+               
+       
        class Meta:
                model = User
                fields = ('first_name', 'last_name', 'email')
index 025cfbe..cdadead 100644 (file)
@@ -107,7 +107,7 @@ class LoginMultiView(MultiView):
                                
                                return HttpResponseRedirect(redirect)
                else:
-                       form = self.login_form()
+                       form = self.login_form(request)
                
                request.session.set_test_cookie()
                
@@ -444,15 +444,8 @@ class AccountMultiView(RegistrationMultiView):
                        if form.is_valid():
                                message = "Account information saved."
                                redirect = self.get_requirement_redirect(request, default='')
-                               if 'email' in form.changed_data and self.email_change_confirmation_email:
-                                       # ModelForms modify their instances in-place during
-                                       # validation, so reset the instance's email to its
-                                       # previous value here, then remove the new value
-                                       # from cleaned_data. We only do this if an email
-                                       # change confirmation email is available.
-                                       request.user.email = form.initial['email']
-                                       
-                                       email = form.cleaned_data.pop('email')
+                               if form.email_changed() and self.email_change_confirmation_email:
+                                       email = form.reset_email()
                                        
                                        current_site = Site.objects.get_current()
                                        
@@ -464,7 +457,7 @@ class AccountMultiView(RegistrationMultiView):
                                        }
                                        self.send_confirmation_email('Confirm account email change at %s' % current_site.domain, email, self.email_change_confirmation_email, context)
                                        
-                                       message = "An email has be sent to %s to confirm the email%s." % (email, bool(request.user.email) and " change" or "")
+                                       message = "An email has be sent to %s to confirm the email%s." % (email, " change" if bool(request.user.email) else "")
                                        if not request.user.email:
                                                message += " You will need to confirm the email before accessing pages that require a valid account."
                                                redirect = ''
@@ -538,8 +531,7 @@ class AccountMultiView(RegistrationMultiView):
                        raise Http404
                
                if token_generator.check_token(user, email, token):
-                       user.email = email
-                       user.save()
+                       self.account_form.set_email(user, email)
                        messages.add_message(request, messages.SUCCESS, 'Email changed successfully.')
                        if self.manage_account_page:
                                redirect = self.reverse('account', node=request.node)
index 3d740f8..82ba104 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -1,54 +1,22 @@
 #!/usr/bin/env python
 
-from setuptools import setup
 import os
 
-
-# Shamelessly cribbed from django's setup.py file.
-def fullsplit(path, result=None):
-       """
-       Split a pathname into components (the opposite of os.path.join) in a
-       platform-neutral way.
-       """
-       if result is None:
-               result = []
-       head, tail = os.path.split(path)
-       if head == '':
-               return [tail] + result
-       if head == path:
-               return result
-       return fullsplit(head, [tail] + result)
-
-# Compile the list of packages available, because distutils doesn't have
-# an easy way to do this. Shamelessly cribbed from django's setup.py file.
-packages, data_files = [], []
-root_dir = os.path.dirname(__file__)
-if root_dir != '':
-    os.chdir(root_dir)
-philo_dir = 'philo'
-
-for dirpath, dirnames, filenames in os.walk(philo_dir):
-       # Ignore dirnames that start with '.'
-       for i, dirname in enumerate(dirnames):
-               if dirname.startswith('.'): del dirnames[i]
-       if '__init__.py' in filenames:
-               packages.append('.'.join(fullsplit(dirpath)))
-       elif filenames:
-               data_files.append([dirpath, [os.path.join(dirpath, f) for f in filenames]])
+from setuptools import setup, find_packages
 
 
 version = __import__('philo').VERSION
 
+
 setup(
        name = 'philo',
        version = '.'.join([str(v) for v in version]),
        url = "http://philocms.org/",
        description = "A foundation for developing web content management systems.",
-       long_description = open(os.path.join(root_dir, 'README')).read(),
+       long_description = open(os.path.join(os.path.dirname(__file__), 'README')).read(),
        maintainer = "iThink Software",
        maintainer_email = "contact@ithinksw.com",
-       packages = packages,
-       data_files = data_files,
+       packages = find_packages(),
        
        classifiers = [
                'Environment :: Web Environment',
@@ -65,7 +33,6 @@ setup(
        
        install_requires = [
                'django>=1.3',
-               'python>=2.5.4',
                'django-mptt>0.4.2,==dev',
        ],
        extras_require = {