WARNING: This server is unstable and will be retired in the next days.
If you want to keep this forum available, please request immediately a migration
on the Nabble Support forum.
Forums that don't receive any migration request will be deleted forever.
Larry Stone wrote:
> I've been working with cwm 1.2.1, running it under python 2.4 on
> a Linux i386 (32-bit) system. The original code as I downloaded it wouldn't
> handle any SPARQL queries (the --sparql options) until I applied the
> attached patches to the source. It still doesn't handle DESCRIBE
> queries, but it appears that is simply not implemented, not a bug.
Describe is not implemented. Reading the standard never allowed me to
understand what it is supposed to do.
> The fix to "cwm" is pretty self-explanatory.
Thanks. That feature is not adequately tested, thus the obvious error.
> The other changes were to work around a fatal error -- I've never
> worked with Python so it didn't make much sense, but might be an
> incompatibilty in the regular expression implementation.
Python comes in two types of builds: wide and narrow. Wide builds use 32
bit values for unicode, which narrow use 16. You are correct that those
regular expressions have issues on narrow builds (which tend to be the
default on most platforms). The solution is ... to delete
sparql_tokens_table.py (and sparql_tokens_table.pyc). It will recreate
itself. The code to generate it was fixed long ago. However, the version
on my box has stayed, and still works for me, so I never changed it.
Next week I will look into releasing a fixed version.
You can tell what kind of python build you have by running:
$ python -c 'unichr(0x1000000)'
It will tell you
ValueError: unichr() arg not in range(0x110000) (wide Python build)
ValueError: unichr() arg not in range(0x10000) (narrow Python build)
> Hope this is of use,
> -- Larry Stone
> MIT Libraries