Custom Query (121 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (22 - 24 of 121)

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
Ticket Resolution Summary Owner Reporter
#169 wontfix PyYAML fails to load mapping keys of sequence type xi sedie@…

Reported by sedie@…, 4 years ago.

Description

The following YAML code is taken directly from an example given in the YAML 1.1 specification and fails to load with PyYAML, giving the error message: found unacceptable key (unhashable type: 'list').

---
? - Detroit Tigers
  - Chicago cubs
:
  - 2001-07-23

? [ New York Yankees,
    Atlanta Braves ]
: [ 2001-07-02, 2001-08-12,
    2001-08-14 ]
...

The problem most likely arises because Python lists are not hashable and cannot be used as dict keys. A possible solution may be to detect this special case and coerce YAML !!seq types to Python tuples before constructing the dictionaries that they are a part of.

#21 duplicate yaml emitter bug xi rwb123@…

Reported by rwb123@…, 8 years ago.

Description

The following code produces bad yaml output, which subsequently dies in the yaml.load(). This is with pyyaml 3.0.3 on python 2.4.1.

import yaml

e = {"texas: '": 92.5}
yammy = yaml.dump(e)
print yammy
e2 = yaml.load(yammy)
print e2

The yaml output is:

$ python yamlbug2.py
{'texas: '': 92.5}

Traceback (most recent call last):
  File "yamlbug2.py", line 10, in ?
    e2 = yaml.load(yammy)
  File "/home/blahblah/dl/yaml/PyYAML-3.03/lib/yaml/__init__.py", line 61, in load
    return loader.get_data()
 ... etc.
#32 fixed patch to make libyaml compile in visual studio xi roel _ dot _ vanhout _ at _ gmail _ dot _ com

Reported by roel _ dot _ vanhout _ at _ gmail _ dot _ com, 8 years ago.

Description

2 issues:

  • pointer arithmetic on void*'s is a gcc-ism. I 'solved' it by casting them all to a unsigned char (typedef'd), I'm not sure if a unsigned char is guaranteed to be the same size as a void* on all architectures - it worked on 32-bit Windows, FWIW.
  • A shorthand struct assignment didn't work, I'm not sure if it's valid C or not but whatever, by writing it out in full it compiled ok.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
Note: See TracQuery for help on using queries.