Custom Query (121 matches)
Results (31 - 33 of 121)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #173 | invalid | Python regular expression named groups breaks (?) pyyaml | xi | anonymous |
| Description |
I'm using pyyaml 3.09 in Python 2.6.5 on Ubuntu 10.04 LTS. I have a yaml file I used for configuration of a web server (tornado), and the section of my file causing issues looks like this: RequestHandlers: # [ path, handler class, [whitelist] ] - [/stats, myapp.core.Stats, [127.0.0.1, 10.0.0.0/8]] - [r'/(?P<id>.*)', myapp.core.Foo, [127.0.0.1, 192.168.0.0/16]] - [/.*, myapp.core.MainHandler, []] When this gets loaded, pyyaml yells at me. Here's a python interpreter session: ============================================ Python 2.6.5 (r265:79063, Apr 16 2010, 13:09:56)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import yaml
>>> stream = open('etc/subzero.yaml')
>>> config = yaml.load(stream)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "build/bdist.linux-i686/egg/yaml/__init__.py", line 58, in load
File "build/bdist.linux-i686/egg/yaml/constructor.py", line 42, in get_single_data
File "build/bdist.linux-i686/egg/yaml/composer.py", line 36, in get_single_node
File "build/bdist.linux-i686/egg/yaml/composer.py", line 55, in compose_document
File "build/bdist.linux-i686/egg/yaml/composer.py", line 84, in compose_node
File "build/bdist.linux-i686/egg/yaml/composer.py", line 133, in compose_mapping_node
File "build/bdist.linux-i686/egg/yaml/composer.py", line 82, in compose_node
File "build/bdist.linux-i686/egg/yaml/composer.py", line 111, in compose_sequence_node
File "build/bdist.linux-i686/egg/yaml/composer.py", line 82, in compose_node
File "build/bdist.linux-i686/egg/yaml/composer.py", line 110, in compose_sequence_node
File "build/bdist.linux-i686/egg/yaml/parser.py", line 93, in check_event
File "build/bdist.linux-i686/egg/yaml/parser.py", line 479, in parse_flow_sequence_entry
yaml.parser.ParserError: while parsing a flow sequence
in "etc/myapp.yaml", line 35, column 5
expected ',' or ']', but got '?'
in "etc/myapp.yaml", line 35, column 10
============================================ Line 35 is: - [r'/(?P<id>.*)', myapp.core.Foo, [127.0.0.1, 192.168.0.0/16]] I'm wondering why it's choking here. Disabling this line causes everything to work perfectly well. The question mark is a special case in YAML, but (I thought) only when it's accompanied by a space. I don't recall ever needing to escape anything inside of a yaml file, but I tried escaping the '?'. Not sure what to try next. If I double-quote like "r'/(?P<id>.*)'" then it'll be a double-quoted string on the other end of the load as well, which doesn't help me. Clue hereby solicited. |
|||
| #87 | fixed | front page example has broken delete for yaml_event_delete | xi | anonymous R |
| Description |
In the PARSER API Synopsis example program there is a memory bug. the while loop checks the type of the event.type but the event has already been deleted. the delete invalidates the event type under debian on my x86 system. to fix the bug, i had to introduce another integer variable to hold the type so that the loop can check that to know when to end. |
|||
| #44 | fixed | easy_install b0rked | xi | anseljh@… |
| Description |
All I want is to easy_install pysyck... :( Here's what happens on my Mac (OS X 10.4.8; Python 2.4.4): $ sudo easy_install pysyck Password: Searching for pysyck Reading http://cheeseshop.python.org/pypi/pysyck/ Couldn't find index page for 'pysyck' (maybe misspelled?) Scanning index of all packages (this may take a while) Reading http://cheeseshop.python.org/pypi/ Reading http://cheeseshop.python.org/pypi/PySyck/0.61.2 Reading http://pyyaml.org/wiki/PySyck Best match: PySyck 0.61.2 Downloading http://pyyaml.org/download/pysyck/PySyck-0.61.2.zip Processing PySyck-0.61.2.zip Running PySyck-0.61.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-y67SG5/PySyck-0.61.2/egg-dist-tmp-pDzaUo ./_check_syck.c:2:18: error: syck.h: No such file or directory ./_check_syck.c:2:18: error: syck.h: No such file or directory ./_check_syck.c: In function 'main': ./_check_syck.c:7: error: 'SYCK_VERSION' undeclared (first use in this function) ./_check_syck.c:7: error: (Each undeclared identifier is reported only once ./_check_syck.c:7: error: for each function it appears in.) ./_check_syck.c: In function 'main': ./_check_syck.c:7: error: 'SYCK_VERSION' undeclared (first use in this function) ./_check_syck.c:7: error: (Each undeclared identifier is reported only once ./_check_syck.c:7: error: for each function it appears in.) lipo: can't figure out the architecture type of: /var/tmp//ccX0yyzM.out error: Setup script exited with error: syck.h is not found, try to uncomment the include_dirs parameter in setup.cfg ...and on my Fedora Core 6 box (also Python 2.4.4): $ sudo easy_install pysyck Password: Searching for pysyck Reading http://cheeseshop.python.org/pypi/pysyck/ Couldn't find index page for 'pysyck' (maybe misspelled?) Scanning index of all packages (this may take a while) Reading http://cheeseshop.python.org/pypi/ Reading http://cheeseshop.python.org/pypi/PySyck/0.61.2 Reading http://pyyaml.org/wiki/PySyck Best match: PySyck 0.61.2 Downloading http://pyyaml.org/download/pysyck/PySyck-0.61.2.zip Processing PySyck-0.61.2.zip Running PySyck-0.61.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-waHbzc/PySyck-0.61.2/egg-dist-tmp-ltTkBA ./_check_syck.c:2:18: error: syck.h: No such file or directory ./_check_syck.c: In function ‘main’: ./_check_syck.c:5: warning: implicit declaration of function ‘syck_free_parser’ ./_check_syck.c:5: warning: implicit declaration of function ‘syck_new_parser’ ./_check_syck.c:6: warning: implicit declaration of function ‘syck_free_emitter’ ./_check_syck.c:6: warning: implicit declaration of function ‘syck_new_emitter’ ./_check_syck.c:7: error: ‘SYCK_VERSION’ undeclared (first use in this function) ./_check_syck.c:7: error: (Each undeclared identifier is reported only once ./_check_syck.c:7: error: for each function it appears in.) error: Setup script exited with error: syck.h is not found, try to uncomment the include_dirs parameter in setup.cfg Help? |
|||
