[cc-commits] [git]cc.license (branch master) updated. d1e0c11678a2a35e8c8e0539eb965e932115976d

git version control webmaster at creativecommons.org
Tue Jul 13 18:56:28 EDT 2010


The branch, master has been updated
       via  d1e0c11678a2a35e8c8e0539eb965e932115976d (commit)
      from  6ecf440180174539507f71ebe5213d4b8ed81574 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit d1e0c11678a2a35e8c8e0539eb965e932115976d
Author: JED3 <jed at jedpad.(none)>
Date:   Tue Jul 13 15:55:44 2010 -0700

    Fixing an error with invalid jurisdiction code selectors and updating the version number of cc.license

-----------------------------------------------------------------------

Summary of changes (followed by patch):
 cc/license/jurisdictions/__init__.py |    4 ++++
 setup.py                             |    2 +-
 2 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/cc/license/jurisdictions/__init__.py b/cc/license/jurisdictions/__init__.py
index 6a6e0d7..fe2fd78 100644
--- a/cc/license/jurisdictions/__init__.py
+++ b/cc/license/jurisdictions/__init__.py
@@ -53,6 +53,8 @@ def _list():
 def by_code(code):
     if code == '':
         return cc.license.Jurisdiction('')
+    if code not in list_codes():
+        raise cc.license.CCLicenseError, 'Invalid jurisdiction'
     uri = 'http://creativecommons.org/international/%s/' % code
     return cc.license.Jurisdiction(uri)
 
@@ -69,6 +71,8 @@ def uri2code(uri):
 def get_licenses_by_code(code):
     if code == '':
         return cc.license.Jurisdiction('')
+    if code not in list_codes():
+        raise cc.license.CCLicenseError, 'Invalid jurisdiction'
     uri = 'http://creativecommons.org/international/%s/' % code
     return rdf_helper.get_jurisdiction_licenses(uri)
 
diff --git a/setup.py b/setup.py
index 27fe291..8a603c6 100644
--- a/setup.py
+++ b/setup.py
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
 import sys, os
 
 setup(name='cc.license',
-      version='0.13.10',
+      version='0.13.11',
       namespace_packages = ['cc',],
       description="License selection based on ccREL-based metadata.",
       classifiers=[],


hooks/post-receive
-- 
cc.license



More information about the cc-commits mailing list