1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
3 NAMEBASE= python-jmespath
7 SDESC[py310]= JSON Matching Expressions (3.10)
8 SDESC[py39]= JSON Matching Expressions (3.9)
9 HOMEPAGE= https://github.com/jmespath/jmespath.py
10 CONTACT= Python_Automaton[python@ironwolf.systems]
13 SITES[main]= PYPIWHL/31/b4/b9b800c45527aadd64d5b442f9b932b00648617eb5d63d2c7a6587b7cafc
14 DISTFILE[1]= jmespath-1.0.1-py3-none-any.whl:main
19 OPTIONS_AVAILABLE= PY39 PY310
20 OPTIONS_STANDARD= none
21 VOPTS[py310]= PY39=OFF PY310=ON
22 VOPTS[py39]= PY39=ON PY310=OFF
24 DISTNAME= jmespath-1.0.1.dist-info
28 [PY39].USES_ON= python:py39,wheel
30 [PY310].USES_ON= python:py310,wheel
32 [FILE:2647:descriptions/desc.single]
36 JMESPath (pronounced "james path") allows you to declaratively specify how
38 extract elements from a JSON document.
40 For example, given this document::
42 {"foo": {"bar": "baz"}}
44 The jmespath expression ``foo.bar`` will return "baz".
46 JMESPath also supports:
48 Referencing elements in a list. Given the data::
50 {"foo": {"bar": ["one", "two"]}}
52 The expression: ``foo.bar[0]`` will return "one".
53 You can also reference all the items in a list using the ``*``
56 {"foo": {"bar": [{"name": "one"}, {"name": "two"}]}}
58 The expression: ``foo.bar[*].name`` will return ["one", "two"].
59 Negative indexing is also supported (-1 refers to the last element
60 in the list). Given the data above, the expression
61 ``foo.bar[-1].name`` will return "two".
63 The ``*`` can also be used for hash types::
65 {"foo": {"bar": {"name": "one"}, "baz": {"name": "two"}}}
67 The expression: ``foo.*.name`` will return ["one", "two"].
72 You can install JMESPath from pypi with:
81 The ``jmespath.py`` library has two functions
82 that operate on python data structures. You can use search
83 and give it the jmespath expression and the data:
88 >>> path = jmespath.search('foo.bar', {'foo': {'bar': 'baz'}})
91 Similar to the re module, you can use the compile function
92 to compile the JMESPath expression and use this parsed expression
93 to perform repeated searches:
98 >>> expression = jmespath.compile('foo.bar')
99 >>> expression.search({'foo': {'bar': 'baz'}})
101 >>> expression.search({'foo': {'bar': 'other'}})
104 This is useful if you're going to use the same jmespath expression to
105 search multiple documents. This avoids having to reparse the
106 JMESPath expression each time you search a new document.
111 You can provide an instance of ``jmespath.Options`` to control how
112 a JMESPath expression is evaluated. The most common scenario for
113 using an Options instance is if you want to have ordered output
114 of your dict keys. To do this you can use either of these options:
119 >>> jmespath.search('{a: a, b: b}',
121 ... jmespath.Options(dict_cls=collections.OrderedDict))
124 >>> parsed = jmespath.compile('{a: a, b: b}')
125 >>> parsed.search(mydata,
126 ... jmespath.Options(dict_cls=collections.OrderedDict))
131 The JMESPath language has numerous
136 02e2e4cc71b5bcab88332eebf907519190dd9e6e82107fa7f83b1003a6252980 20256 jmespath-1.0.1-py3-none-any.whl