[cc-commits] [git]cc.license (branch master) updated. 6e22b5a189fd94d9bcd26128ebb067ffe2bbdb6d
git version control
webmaster at creativecommons.org
Tue Jul 13 14:34:23 EDT 2010
The branch, master has been updated
via 6e22b5a189fd94d9bcd26128ebb067ffe2bbdb6d (commit)
via 619a1d732471065518c31bedea15fa83073e67ac (commit)
via 90d837c3c016ffaa04804044b468dadb1b796a73 (commit)
via 3fab0c1cca8ba83566e336299de1312c360578c8 (commit)
via 8bb490238aa9faafe8327cf1ce32a4fa51c3738b (commit)
from cc4140f79d729d216f4acde28e851d409ac8d7db (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 6e22b5a189fd94d9bcd26128ebb067ffe2bbdb6d
Author: JED3 <jed at jedpad.(none)>
Date: Tue Jul 13 11:33:39 2010 -0700
Adding get_jurisdiction_licenses to the RDF queries
commit 619a1d732471065518c31bedea15fa83073e67ac
Merge: 90d837c3c016ffaa04804044b468dadb1b796a73 cc4140f79d729d216f4acde28e851d409ac8d7db
Author: JED3 <jed at jedpad.(none)>
Date: Tue Jul 13 10:56:19 2010 -0700
Merge branch 'master' of code.creativecommons.org:cc.license
commit 90d837c3c016ffaa04804044b468dadb1b796a73
Merge: 3fab0c1cca8ba83566e336299de1312c360578c8 3f65ecd10ba9848d9c1f6332fb84a4ddb745f9ee
Author: JED3 <jed at jedpad.(none)>
Date: Fri Jun 25 10:53:39 2010 -0700
Merge branch 'master' of code.creativecommons.org:cc.license
commit 3fab0c1cca8ba83566e336299de1312c360578c8
Merge: 8bb490238aa9faafe8327cf1ce32a4fa51c3738b 17f6164bcdff55d1fd0968c7b9873c4a5e8705e6
Author: JED3 <jed at jedpad.(none)>
Date: Fri Jun 25 10:53:30 2010 -0700
Merge branch 'master' of code.creativecommons.org:cc.license
Conflicts:
setup.py
commit 8bb490238aa9faafe8327cf1ce32a4fa51c3738b
Author: JED3 <jed at jedpad.(none)>
Date: Wed Mar 17 16:39:14 2010 -0700
Cranking the version num
-----------------------------------------------------------------------
Summary of changes (followed by patch):
cc/license/_lib/rdf_helper.py | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/cc/license/_lib/rdf_helper.py b/cc/license/_lib/rdf_helper.py
index 8da41e1..2ac07a1 100644
--- a/cc/license/_lib/rdf_helper.py
+++ b/cc/license/_lib/rdf_helper.py
@@ -203,6 +203,22 @@ def get_jurisdiction(model, uri):
else:
return cc.license.Jurisdiction(str(solns[0]['jurisdiction'].uri))
+def get_jurisdiction_licenses(uri):
+ qstring = """
+ PREFIX cc: <http://creativecommons.org/ns#>
+
+ SELECT ?license
+ WHERE {
+ ?license cc:jurisdiction <%s> .
+ }
+ """
+ query = RDF.Query(qstring % uri, query_language='sparql')
+ solns = list(query.execute(ALL_MODEL))
+ if len(solns) == 0:
+ return [ ] # empty string makes 'Unported'
+ else:
+ return [ str( l['license'].uri ) for l in solns ]
+
def get_deprecated(model, uri):
qstring = """
PREFIX cc: <http://creativecommons.org/ns#>
hooks/post-receive
--
cc.license
More information about the cc-commits
mailing list