loongson/pypi/: markerlib-0.6.0 metadata and description

Homepage Simple index

A compiler for PEP 345 environment markers.

author Daniel Holth
author_email dholth@fastmail.fm
classifiers
  • Development Status :: 4 - Beta
  • Intended Audience :: Developers
  • Programming Language :: Python
  • Programming Language :: Python :: 2
  • Programming Language :: Python :: 3
  • Programming Language :: Python :: 2.4
  • Programming Language :: Python :: 2.5
  • Programming Language :: Python :: 2.6
  • Programming Language :: Python :: 2.7
  • Programming Language :: Python :: 3.2
  • Programming Language :: Python :: 3.3
keywords packaging pep345
license MIT
platform
  • UNKNOWN

Because this project isn't in the mirror_whitelist, no releases from root/pypi are included.

File Tox results History
markerlib-0.6.0-py2-none-any.whl
Size
4 KB
Type
Python Wheel
Python
2
markerlib-0.6.0-py3-none-any.whl
Size
4 KB
Type
Python Wheel
Python
3

markerlib

Compile or interpret PEP 345 environment markers.

Usage:

>>> import markerlib
>>> marker = markerlib.compile("os.name == 'posix'")
>>> marker(environment=markerlib.default_environment(),
           override={'os.name':'posix'})
True
>>> marker(environment=markerlib.default_environment(),
           override={'os.name':'nt'})
False

The implementation uses the ast to compile environment markers as Python statements with a limited set of allowed node types.

0.6.0

  • Allow _ where . was previously used (‘os.name’ -> ‘os_name’)

0.5.2

  • Restore ‘as_function’ bw/compat synonym for ‘compile’

0.5.1

  • Include ‘empty marker’ heuristic in markerlib itself

0.5

  • One final release until it’s just a part of distribute

0.4

  • Cache compiled marker functions with weakref.WeakValueDictionary
  • Rename markerlib.as_function to markerlib.compile

0.3

  • Might work on Python 2.5 (includes needed parts of the ast module from Python 2.6+)
  • Include 100% test coverage, tox config file

0.1

  • Initial version