Custom Query (121 matches)
Results (25 - 27 of 121)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #117 | invalid | Key Ordering | xi | pschmitt@… |
| Description |
I dont understand how PyYAML reads YML files with "Block Mapping", (I call these "Nested variables" in my example): >>> document = """ Variable 1: x: a y: b z: c Variable 2: 1: a 2: b 3: c """ >>> yml=yaml.load(document) >>> yml.keys() ['Variable 2', 'Variable 1'] >>> yml["Variable 1"].keys() ['y', 'x', 'z'] So it looks like PyYAML loads the document in reverse order, "Variable 2" is read before "Variable 1". That's fine. But why is ymlVariable 1?.keys() in a random order? It seems like it should either be chronological (x,y,z) or reverse chronological (z,y,x). I'm having a hard time parsing tickets #29 and #116, which might be related... Can you offer up some insight? PS: Sorry if this is the wrong place for a question... I couldn't find a mailing list. |
|||
| #95 | invalid | Libyaml svn revision 298 does not compile | xi | michael.the.drummer@… |
| Description |
Current trunk (revision 298) of libyaml does not compile no either my Ubuntu box or on OSX Tiger. There are 2 separate issues. The first is a simple error in yaml_private.h. A Diff of this file is below.
Index: src/yaml_private.h
===================================================================
--- src/yaml_private.h (revision 298)
+++ src/yaml_private.h (working copy)
@@ -1231,7 +1231,7 @@
* The information of a node being emitted.
*/
-struct typedef yaml_node_data_s {
+typedef struct yaml_node_data_s {
/* The node id. */
int id;
/* The collection iterator. */
The second problem I am not sure about. Build log is attached. Michael |
|||
| #42 | wontfix | List objects are unhashable | xi | dfnord@… |
| Description |
Even though yaml specification allows lists ("flow collections on yaml jargon") to be keys, pyaml fails to use them, as lists are unhashable. For instance, loading "[1, 2]: something" gives the error "found unacceptable key (list objects are unhashable)" As a away around this, flow collections could be translated into a simple hasheable subclass of list, such as: class HasheableList(list):
#############################
## Public Methods
#############################
def __hash__(self):
return hash(tuple(self))
|
|||
