Mercurial > code > home > repos > homeauto
annotate service/arduinoNode/rdflib_patch.py @ 1388:3e9d9cbbb13f
release 0.7.0
Ignore-this: 91592ac0e434c1585a7afbb0313f0f05
darcs-hash:21e99b27f648db4b42a8b74a1963d3f6fa3e1453
author | drewp <drewp@bigasterisk.com> |
---|---|
date | Fri, 10 May 2019 02:10:05 -0700 |
parents | f707210c13bd |
children |
rev | line source |
---|---|
974
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
1 |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
2 def fixQnameOfUriWithTrailingSlash(): |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
3 import rdflib.namespace |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
4 old_split = rdflib.namespace.split_uri |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
5 def new_split(uri): |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
6 try: |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
7 return old_split(uri) |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
8 except Exception: |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
9 return uri, '' |
f707210c13bd
new /output to post statements which devices can handle. led and lcd output working
drewp <drewp@bigasterisk.com>
parents:
diff
changeset
|
10 rdflib.namespace.split_uri = new_split |