Merge branch 'release/0.9.2' master philo-0.9.2
authorJoseph Spiros <joseph.spiros@ithinksw.com>
Wed, 1 Feb 2012 15:08:43 +0000 (10:08 -0500)
committerJoseph Spiros <joseph.spiros@ithinksw.com>
Wed, 1 Feb 2012 15:08:43 +0000 (10:08 -0500)
* release/0.9.2:
  Bumped version number and wrote release notes for 0.9.2 in preparation for release.
  Fixed an exception with JSONAttributes using DateField or DateTimeField as their field template when the stored value is None. Fixes #178.
  Updated copyright date range to end in 2012 instead of 2011.
  Added include_package_data option to setup.py to ensure MANIFEST.in is actually heeded.

LICENSE
docs/conf.py
docs/index.rst
docs/releases/0.9.2.rst [new file with mode: 0644]
philo/__init__.py
philo/models/fields/entities.py
setup.py

diff --git a/LICENSE b/LICENSE
index 78171e9..97551fc 100644 (file)
--- a/LICENSE
+++ b/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2009-2011, iThink Software.
+Copyright (c) 2009-2012, iThink Software.
 
 Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
 
index 2e703d0..d41e6e0 100644 (file)
@@ -54,7 +54,7 @@ master_doc = 'index'
 
 # General information about the project.
 project = u'Philo'
-copyright = u'2009-2011, iThink Software'
+copyright = u'2009-2012, iThink Software'
 
 # The version info for the project you're documenting, acts as replacement for
 # |version| and |release|, also used in various other places throughout the
index 05422dd..1c71285 100644 (file)
@@ -8,7 +8,7 @@
 Welcome to Philo's documentation!
 =================================
 
-Philo is a foundation for developing web content management systems. Please, read the :doc:`notes for our latest release <releases/0.9.1>`.
+Philo is a foundation for developing web content management systems. Please, read the :doc:`notes for our latest release <releases/0.9.2>`.
 
 Prerequisites:
 
diff --git a/docs/releases/0.9.2.rst b/docs/releases/0.9.2.rst
new file mode 100644 (file)
index 0000000..c1983ae
--- /dev/null
@@ -0,0 +1,4 @@
+Philo version 0.9.2 release notes
+=================================
+
+The primary focus of the 0.9.2 release was repairing the setuptools configuration so that Philo can be installed and updated reliably. In addition, a bug involving the use of :class:`DateTimeField` or :class:`DateField` as the field template for a :class:`JSONAttribute` has been fixed.
\ No newline at end of file
index 4e4f145..3a055a1 100644 (file)
@@ -1 +1 @@
-VERSION = (0, 9, 1)
+VERSION = (0, 9, 2)
index 0558d3e..167fd39 100644 (file)
@@ -2,7 +2,7 @@ import datetime
 from itertools import tee
 
 from django import forms
-from django.core.exceptions import FieldError
+from django.core.exceptions import FieldError, ValidationError
 from django.db import models
 from django.db.models.fields import NOT_PROVIDED
 from django.utils.text import capfirst
@@ -193,7 +193,10 @@ class JSONAttribute(AttributeProxyField):
                """If the field template is a :class:`DateField` or a :class:`DateTimeField`, this will convert the default return value to a datetime instance."""
                value = super(JSONAttribute, self).value_from_object(obj)
                if isinstance(self.field_template, (models.DateField, models.DateTimeField)):
-                       value = self.field_template.to_python(value)
+                       try:
+                               value = self.field_template.to_python(value)
+                       except ValidationError:
+                               value = None
                return value
        
        def get_storage_value(self, value):
index 82ba104..8a91d14 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -1,7 +1,5 @@
 #!/usr/bin/env python
-
 import os
-
 from setuptools import setup, find_packages
 
 
@@ -17,6 +15,7 @@ setup(
        maintainer = "iThink Software",
        maintainer_email = "contact@ithinksw.com",
        packages = find_packages(),
+       include_package_data=True,
        
        classifiers = [
                'Environment :: Web Environment',
@@ -47,4 +46,4 @@ setup(
        dependency_links = [
                'https://github.com/django-mptt/django-mptt/tarball/master#egg=django-mptt-dev'
        ]
-)
\ No newline at end of file
+)