Metadata-Version: 2.1
Name: pprint-ordered-sets
Version: 1.0.0
Summary: The standard library pprint module, but sets are always ordered.
Home-page: https://github.com/bbonenfant/pprint_ordered_sets
License: MIT
Keywords: pprint,sets
Author: Ben Bonenfant
Author-email: bonenfan5ben@gmail.com
Requires-Python: >=3.6.1,<4.0.0
Classifier: License :: OSI Approved :: MIT License
Classifier: License :: OSI Approved :: Python Software Foundation License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Project-URL: Repository, https://github.com/bbonenfant/pprint_ordered_sets
Description-Content-Type: text/markdown

# PPrint Ordered Sets
The standard library `pprint` module, but with the feature that
  all sets are ordered.

## Why does this package exist?
This package is a backport for the bug-fix [bpo-27495](https://bugs.python.org/issue27495).
This package ensures that `set` and `frozenset` objects are always ordered, which
  is not true of the `pprint` module.

As of writing this, the [pull request that fixes this bug](https://github.com/python/cpython/pull/22977)
  has not been merged.

## Example
```python
>>> import pprint_ordered_sets as pprint
>>> obj = set("abcdefg")
>>> print(obj)  # Will be different on different systems.
{'d', 'f', 'b', 'g', 'e', 'a', 'c'}
>>> pprint.pp(obj)  # Will be same on all systems.
{'a', 'b', 'c', 'd', 'e', 'f', 'g'}
```

## License
This code is licensed under the Python Software Foundation license, as this
  is a derivative work. My changes are adding the default ordering of `set` and
  `frozenset` objects, writing additional tests to cover these features, and renaming
  of this module to `pprint_ordered_sets`.

## Testing
This package requires no dependencies to test, simply run:
```bash
python -m unittest test_pprint_ordered_sets.py
```

