Glom

Latest version: v23.5.0

Safety actively analyzes 623608 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 4

23.5.0

_(November 26, 2023)_

Add TOML support to the CLI. Thanks, [Julian](https://github.com/Julian)!
Uses the built-in [tomllib](https://docs.python.org/3/library/tomllib.html) on Python 3.11+.
`pip install glom[toml]` on Python 3.10 and earlier.

23.4.0

_(November 7, 2023)_

Officially add Python 3.11 support, fixing traceback formatting issues.

Also, change the implementation of T under the hood, no expected behavioral changes.

23.3.0

_(March 30, 2023)_

Officially drop Python 2/3.6 support and fix a small warning caused by a docstring ([258][i258]).

[i258]: https://github.com/mahmoud/glom/issues/258

23.1.1

_(January 19, 2023)_

Fix a dependency issue by pinning the `face` library.

23.1.0

_(January 18, 2023)_

Note: Planned last release to support Python 2.

Two long-awaited big changes in this release, with a couple smaller ones:

- Enabled the star/wildcard (`*`/`**`) behavior initially released in 22.1.0 (see below) by default.
- If you had a spec broken by this, you can quick-fix it without downgrading by setting `glom.core.PATH_STAR = False`.
- You can fix the broken paths by using the `Path` spec type explicitly, e.g., `Path('a', '*')` instead of simply `'a.*'`.
- `**` now includes the current target element itself. Useful for `**`-prefixed specs (e.g., `'**.key'`) so that the root element is considered.
- Rationalized argument behavior for several spec types
- Affected spec types: `Coalesce, Call, T, Match, And, Or, Not, Check, Assign`
- In short, before 23.1.0, each of these implemented their own logic around interpreting arguments. Some treated them as literals, others had varying support for specs.
- Now they all use `glom.core.arg_val` to consistently handle arguments. In brief, they now all support conservative evaluation of specs (such as explicit `T` objects), very useful for when you want your spec's `default` to reference the target.
- More docs forthcoming.
- We did our best to make this as seamless and sane as possible. If this breaks something, please file an issue, we're eager to hear from you.
- Patched an issue where OrderedDict would be treated as a plain object by Delete ([246][i246]).
- Even better fix forthcoming.
- Tweaked `Iter()` to use `Pipe()` for `.all()`, mostly for benefits to the repr.

[i246]: https://github.com/mahmoud/glom/issues/246

22.1.0

_(January 24, 2022)_

Adds optional `*` and `**` expansion to the default glom access (i.e.,
`glom.glom('a.b.*')` will get all items under `b` as a list). `**` is
similar, except recursive.

This functionality is off by default in this version, as it
technically would break code using `'*'` and `'**'` as plain
keys. Note that this behavior will break in the next couple months,
and an in-library warning has been added to this effect.

Set `glom.core.PATH_STAR = True` to enable the new feature and take it
for a spin!

Page 1 of 4

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.