python-json-logger 3.0.1__tar.gz → 3.2.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. python_json_logger-3.2.0/NOTICE +5 -0
  2. python_json_logger-3.2.0/PKG-INFO +84 -0
  3. python_json_logger-3.2.0/README.md +35 -0
  4. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/pyproject.toml +29 -9
  5. python_json_logger-3.2.0/src/python_json_logger.egg-info/PKG-INFO +84 -0
  6. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/src/python_json_logger.egg-info/SOURCES.txt +11 -2
  7. python_json_logger-3.2.0/src/python_json_logger.egg-info/requires.txt +33 -0
  8. python_json_logger-3.2.0/src/pythonjsonlogger/__init__.py +29 -0
  9. python_json_logger-3.2.0/src/pythonjsonlogger/core.py +370 -0
  10. python_json_logger-3.2.0/src/pythonjsonlogger/defaults.py +241 -0
  11. python_json_logger-3.2.0/src/pythonjsonlogger/exception.py +27 -0
  12. python_json_logger-3.2.0/src/pythonjsonlogger/json.py +119 -0
  13. python_json_logger-3.2.0/src/pythonjsonlogger/msgspec.py +63 -0
  14. python_json_logger-3.2.0/src/pythonjsonlogger/orjson.py +71 -0
  15. python_json_logger-3.2.0/src/pythonjsonlogger/utils.py +40 -0
  16. python_json_logger-3.2.0/tests/test_deprecation.py +28 -0
  17. python_json_logger-3.2.0/tests/test_formatters.py +638 -0
  18. python_json_logger-3.2.0/tests/test_missing.py +67 -0
  19. python-json-logger-3.0.1/PKG-INFO +0 -234
  20. python-json-logger-3.0.1/README.md +0 -202
  21. python-json-logger-3.0.1/src/python_json_logger.egg-info/PKG-INFO +0 -234
  22. python-json-logger-3.0.1/src/python_json_logger.egg-info/requires.txt +0 -9
  23. python-json-logger-3.0.1/src/pythonjsonlogger/jsonlogger.py +0 -304
  24. python-json-logger-3.0.1/tests/__init__.py +0 -0
  25. python-json-logger-3.0.1/tests/test_jsonlogger.py +0 -309
  26. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/LICENSE +0 -0
  27. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/MANIFEST.in +0 -0
  28. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/setup.cfg +0 -0
  29. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/src/python_json_logger.egg-info/dependency_links.txt +0 -0
  30. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/src/python_json_logger.egg-info/top_level.txt +0 -0
  31. {python-json-logger-3.0.1 → python_json_logger-3.2.0}/src/pythonjsonlogger/py.typed +0 -0
  32. {python-json-logger-3.0.1/src/pythonjsonlogger → python_json_logger-3.2.0/tests}/__init__.py +0 -0
@@ -0,0 +1,5 @@
1
+ This software includes the following licenced software:
2
+ - mkdocstrings-python
3
+ Copyright (c) 2021, Timothée Mazzucotelli
4
+ Licenced under ISC Licence
5
+ Source: https://github.com/mkdocstrings/python
@@ -0,0 +1,84 @@
1
+ Metadata-Version: 2.1
2
+ Name: python-json-logger
3
+ Version: 3.2.0
4
+ Summary: JSON Log Formatter for the Python Logging Package
5
+ Author-email: Zakaria Zajac <zak@madzak.com>, Nicholas Hairs <info+python-json-logger@nicholashairs.com>
6
+ Maintainer-email: Nicholas Hairs <info+python-json-logger@nicholashairs.com>
7
+ License: BSD-2-Clause License
8
+ Project-URL: Homepage, https://nhairs.github.io/python-json-logger
9
+ Project-URL: GitHub, https://github.com/nhairs/python-json-logger
10
+ Classifier: Development Status :: 6 - Mature
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: BSD License
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python :: 3 :: Only
15
+ Classifier: Programming Language :: Python :: 3.8
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Topic :: System :: Logging
22
+ Classifier: Typing :: Typed
23
+ Requires-Python: >=3.8
24
+ Description-Content-Type: text/markdown
25
+ License-File: LICENSE
26
+ License-File: NOTICE
27
+ Requires-Dist: typing_extensions; python_version < "3.10"
28
+ Provides-Extra: dev
29
+ Requires-Dist: orjson; implementation_name != "pypy" and extra == "dev"
30
+ Requires-Dist: msgspec; (implementation_name != "pypy" and python_version < "3.13") and extra == "dev"
31
+ Requires-Dist: msgspec-python313-pre; (implementation_name != "pypy" and python_version == "3.13") and extra == "dev"
32
+ Requires-Dist: validate-pyproject[all]; extra == "dev"
33
+ Requires-Dist: black; extra == "dev"
34
+ Requires-Dist: pylint; extra == "dev"
35
+ Requires-Dist: mypy; extra == "dev"
36
+ Requires-Dist: pytest; extra == "dev"
37
+ Requires-Dist: freezegun; extra == "dev"
38
+ Requires-Dist: backports.zoneinfo; python_version < "3.9" and extra == "dev"
39
+ Requires-Dist: tzdata; extra == "dev"
40
+ Requires-Dist: build; extra == "dev"
41
+ Requires-Dist: mkdocs; extra == "dev"
42
+ Requires-Dist: mkdocs-material>=8.5; extra == "dev"
43
+ Requires-Dist: mkdocs-awesome-pages-plugin; extra == "dev"
44
+ Requires-Dist: mdx_truly_sane_lists; extra == "dev"
45
+ Requires-Dist: mkdocstrings[python]; extra == "dev"
46
+ Requires-Dist: mkdocs-gen-files; extra == "dev"
47
+ Requires-Dist: mkdocs-literate-nav; extra == "dev"
48
+ Requires-Dist: mike; extra == "dev"
49
+
50
+ <!-- [![PyPi](https://img.shields.io/pypi/v/python-json-logger.svg)](https://pypi.python.org/pypi/python-json-logger/)
51
+ [![PyPI - Status](https://img.shields.io/pypi/status/python-json-logger)](https://pypi.python.org/pypi/python-json-logger/)
52
+ [![Python Versions](https://img.shields.io/pypi/pyversions/python-json-logger.svg)](https://github.com/nhairs/python-json-logger) -->
53
+ [![License](https://img.shields.io/github/license/nhairs/python-json-logger.svg)](https://github.com/nhairs/python-json-logger)
54
+ ![Build Status](https://github.com/nhairs/python-json-logger/actions/workflows/test-suite.yml/badge.svg)
55
+ #
56
+ # Python JSON Logger
57
+
58
+ Python JSON Logger enables you produce JSON logs when using Python's `logging` package.
59
+
60
+ JSON logs are machine readable allowing for much easier parsing and ingestion into log aggregation tools.
61
+
62
+
63
+ ### 🚨 Important 🚨
64
+
65
+ This repository is a maintained fork of [madzak/python-json-logger](https://github.com/madzak/python-json-logger) pending [a PEP 541 request](https://github.com/pypi/support/issues/3607) for the PyPI package. The future direction of the project is being discussed [here](https://github.com/nhairs/python-json-logger/issues/1).
66
+
67
+ ## Documentation
68
+
69
+ - [Documentation](https://nhairs.github.io/python-json-logger/latest/)
70
+ - [Quickstart Guide](https://nhairs.github.io/python-json-logger/latest/quickstart/)
71
+ - [Change Log](https://nhairs.github.io/python-json-logger/latest/changelog/)
72
+ - [Contributing](https://nhairs.github.io/python-json-logger/latest/contributing/)
73
+
74
+ ## License
75
+
76
+ This project is licensed under the BSD 2 Clause License - see [`LICENSE`](https://github.com/nhairs/python-json-logger/blob/main/LICENSE)
77
+
78
+ ## Authors and Maintainers
79
+
80
+ This project was originally authored by [Zakaria Zajac](https://github.com/madzak) and our wonderful [contributors](https://github.com/nhairs/python-json-logger/graphs/contributors)
81
+
82
+ It is currently maintained by:
83
+
84
+ - [Nicholas Hairs](https://github.com/nhairs) - [nicholashairs.com](https://www.nicholashairs.com)
@@ -0,0 +1,35 @@
1
+ <!-- [![PyPi](https://img.shields.io/pypi/v/python-json-logger.svg)](https://pypi.python.org/pypi/python-json-logger/)
2
+ [![PyPI - Status](https://img.shields.io/pypi/status/python-json-logger)](https://pypi.python.org/pypi/python-json-logger/)
3
+ [![Python Versions](https://img.shields.io/pypi/pyversions/python-json-logger.svg)](https://github.com/nhairs/python-json-logger) -->
4
+ [![License](https://img.shields.io/github/license/nhairs/python-json-logger.svg)](https://github.com/nhairs/python-json-logger)
5
+ ![Build Status](https://github.com/nhairs/python-json-logger/actions/workflows/test-suite.yml/badge.svg)
6
+ #
7
+ # Python JSON Logger
8
+
9
+ Python JSON Logger enables you produce JSON logs when using Python's `logging` package.
10
+
11
+ JSON logs are machine readable allowing for much easier parsing and ingestion into log aggregation tools.
12
+
13
+
14
+ ### 🚨 Important 🚨
15
+
16
+ This repository is a maintained fork of [madzak/python-json-logger](https://github.com/madzak/python-json-logger) pending [a PEP 541 request](https://github.com/pypi/support/issues/3607) for the PyPI package. The future direction of the project is being discussed [here](https://github.com/nhairs/python-json-logger/issues/1).
17
+
18
+ ## Documentation
19
+
20
+ - [Documentation](https://nhairs.github.io/python-json-logger/latest/)
21
+ - [Quickstart Guide](https://nhairs.github.io/python-json-logger/latest/quickstart/)
22
+ - [Change Log](https://nhairs.github.io/python-json-logger/latest/changelog/)
23
+ - [Contributing](https://nhairs.github.io/python-json-logger/latest/contributing/)
24
+
25
+ ## License
26
+
27
+ This project is licensed under the BSD 2 Clause License - see [`LICENSE`](https://github.com/nhairs/python-json-logger/blob/main/LICENSE)
28
+
29
+ ## Authors and Maintainers
30
+
31
+ This project was originally authored by [Zakaria Zajac](https://github.com/madzak) and our wonderful [contributors](https://github.com/nhairs/python-json-logger/graphs/contributors)
32
+
33
+ It is currently maintained by:
34
+
35
+ - [Nicholas Hairs](https://github.com/nhairs) - [nicholashairs.com](https://www.nicholashairs.com)
@@ -4,18 +4,21 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "python-json-logger"
7
- version = "3.0.1"
7
+ version = "3.2.0"
8
8
  description = "JSON Log Formatter for the Python Logging Package"
9
9
  authors = [
10
10
  {name = "Zakaria Zajac", email = "zak@madzak.com"},
11
+ {name = "Nicholas Hairs", email = "info+python-json-logger@nicholashairs.com"},
11
12
  ]
12
13
  maintainers = [
13
14
  {name = "Nicholas Hairs", email = "info+python-json-logger@nicholashairs.com"},
14
15
  ]
15
16
 
16
17
  # Dependency Information
17
- requires-python = ">=3.7"
18
- # dependencies = []
18
+ requires-python = ">=3.8"
19
+ dependencies = [
20
+ "typing_extensions;python_version<'3.10'",
21
+ ]
19
22
 
20
23
  # Extra information
21
24
  readme = "README.md"
@@ -26,30 +29,47 @@ classifiers = [
26
29
  "License :: OSI Approved :: BSD License",
27
30
  "Operating System :: OS Independent",
28
31
  "Programming Language :: Python :: 3 :: Only",
29
- "Programming Language :: Python :: 3.7",
30
32
  "Programming Language :: Python :: 3.8",
31
33
  "Programming Language :: Python :: 3.9",
32
34
  "Programming Language :: Python :: 3.10",
33
35
  "Programming Language :: Python :: 3.11",
34
36
  "Programming Language :: Python :: 3.12",
37
+ "Programming Language :: Python :: 3.13",
35
38
  "Topic :: System :: Logging",
36
39
  "Typing :: Typed",
37
40
  ]
38
41
 
39
42
  [project.urls]
40
- # homepage = "https://nhairs.github.io/python-json-logger/latest/"
43
+ Homepage = "https://nhairs.github.io/python-json-logger"
41
44
  GitHub = "https://github.com/nhairs/python-json-logger"
42
45
 
43
46
  [project.optional-dependencies]
44
- lint = [
47
+ dev = [
48
+ ## Optional but required for dev
49
+ "orjson;implementation_name!='pypy'",
50
+ "msgspec;implementation_name!='pypy' and python_version<'3.13'",
51
+ "msgspec-python313-pre;implementation_name!='pypy' and python_version=='3.13'",
52
+ ## Lint
45
53
  "validate-pyproject[all]",
46
54
  "black",
47
55
  "pylint",
48
56
  "mypy",
49
- ]
50
-
51
- test = [
57
+ ## Test
52
58
  "pytest",
59
+ "freezegun",
60
+ "backports.zoneinfo;python_version<'3.9'",
61
+ "tzdata",
62
+ ## Build
63
+ "build",
64
+ ## Docs
65
+ "mkdocs",
66
+ "mkdocs-material>=8.5",
67
+ "mkdocs-awesome-pages-plugin",
68
+ "mdx_truly_sane_lists",
69
+ "mkdocstrings[python]",
70
+ "mkdocs-gen-files",
71
+ "mkdocs-literate-nav",
72
+ "mike",
53
73
  ]
54
74
 
55
75
  [tool.setuptools.packages.find]
@@ -0,0 +1,84 @@
1
+ Metadata-Version: 2.1
2
+ Name: python-json-logger
3
+ Version: 3.2.0
4
+ Summary: JSON Log Formatter for the Python Logging Package
5
+ Author-email: Zakaria Zajac <zak@madzak.com>, Nicholas Hairs <info+python-json-logger@nicholashairs.com>
6
+ Maintainer-email: Nicholas Hairs <info+python-json-logger@nicholashairs.com>
7
+ License: BSD-2-Clause License
8
+ Project-URL: Homepage, https://nhairs.github.io/python-json-logger
9
+ Project-URL: GitHub, https://github.com/nhairs/python-json-logger
10
+ Classifier: Development Status :: 6 - Mature
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: BSD License
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python :: 3 :: Only
15
+ Classifier: Programming Language :: Python :: 3.8
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Topic :: System :: Logging
22
+ Classifier: Typing :: Typed
23
+ Requires-Python: >=3.8
24
+ Description-Content-Type: text/markdown
25
+ License-File: LICENSE
26
+ License-File: NOTICE
27
+ Requires-Dist: typing_extensions; python_version < "3.10"
28
+ Provides-Extra: dev
29
+ Requires-Dist: orjson; implementation_name != "pypy" and extra == "dev"
30
+ Requires-Dist: msgspec; (implementation_name != "pypy" and python_version < "3.13") and extra == "dev"
31
+ Requires-Dist: msgspec-python313-pre; (implementation_name != "pypy" and python_version == "3.13") and extra == "dev"
32
+ Requires-Dist: validate-pyproject[all]; extra == "dev"
33
+ Requires-Dist: black; extra == "dev"
34
+ Requires-Dist: pylint; extra == "dev"
35
+ Requires-Dist: mypy; extra == "dev"
36
+ Requires-Dist: pytest; extra == "dev"
37
+ Requires-Dist: freezegun; extra == "dev"
38
+ Requires-Dist: backports.zoneinfo; python_version < "3.9" and extra == "dev"
39
+ Requires-Dist: tzdata; extra == "dev"
40
+ Requires-Dist: build; extra == "dev"
41
+ Requires-Dist: mkdocs; extra == "dev"
42
+ Requires-Dist: mkdocs-material>=8.5; extra == "dev"
43
+ Requires-Dist: mkdocs-awesome-pages-plugin; extra == "dev"
44
+ Requires-Dist: mdx_truly_sane_lists; extra == "dev"
45
+ Requires-Dist: mkdocstrings[python]; extra == "dev"
46
+ Requires-Dist: mkdocs-gen-files; extra == "dev"
47
+ Requires-Dist: mkdocs-literate-nav; extra == "dev"
48
+ Requires-Dist: mike; extra == "dev"
49
+
50
+ <!-- [![PyPi](https://img.shields.io/pypi/v/python-json-logger.svg)](https://pypi.python.org/pypi/python-json-logger/)
51
+ [![PyPI - Status](https://img.shields.io/pypi/status/python-json-logger)](https://pypi.python.org/pypi/python-json-logger/)
52
+ [![Python Versions](https://img.shields.io/pypi/pyversions/python-json-logger.svg)](https://github.com/nhairs/python-json-logger) -->
53
+ [![License](https://img.shields.io/github/license/nhairs/python-json-logger.svg)](https://github.com/nhairs/python-json-logger)
54
+ ![Build Status](https://github.com/nhairs/python-json-logger/actions/workflows/test-suite.yml/badge.svg)
55
+ #
56
+ # Python JSON Logger
57
+
58
+ Python JSON Logger enables you produce JSON logs when using Python's `logging` package.
59
+
60
+ JSON logs are machine readable allowing for much easier parsing and ingestion into log aggregation tools.
61
+
62
+
63
+ ### 🚨 Important 🚨
64
+
65
+ This repository is a maintained fork of [madzak/python-json-logger](https://github.com/madzak/python-json-logger) pending [a PEP 541 request](https://github.com/pypi/support/issues/3607) for the PyPI package. The future direction of the project is being discussed [here](https://github.com/nhairs/python-json-logger/issues/1).
66
+
67
+ ## Documentation
68
+
69
+ - [Documentation](https://nhairs.github.io/python-json-logger/latest/)
70
+ - [Quickstart Guide](https://nhairs.github.io/python-json-logger/latest/quickstart/)
71
+ - [Change Log](https://nhairs.github.io/python-json-logger/latest/changelog/)
72
+ - [Contributing](https://nhairs.github.io/python-json-logger/latest/contributing/)
73
+
74
+ ## License
75
+
76
+ This project is licensed under the BSD 2 Clause License - see [`LICENSE`](https://github.com/nhairs/python-json-logger/blob/main/LICENSE)
77
+
78
+ ## Authors and Maintainers
79
+
80
+ This project was originally authored by [Zakaria Zajac](https://github.com/madzak) and our wonderful [contributors](https://github.com/nhairs/python-json-logger/graphs/contributors)
81
+
82
+ It is currently maintained by:
83
+
84
+ - [Nicholas Hairs](https://github.com/nhairs) - [nicholashairs.com](https://www.nicholashairs.com)
@@ -1,5 +1,6 @@
1
1
  LICENSE
2
2
  MANIFEST.in
3
+ NOTICE
3
4
  README.md
4
5
  pyproject.toml
5
6
  src/python_json_logger.egg-info/PKG-INFO
@@ -8,7 +9,15 @@ src/python_json_logger.egg-info/dependency_links.txt
8
9
  src/python_json_logger.egg-info/requires.txt
9
10
  src/python_json_logger.egg-info/top_level.txt
10
11
  src/pythonjsonlogger/__init__.py
11
- src/pythonjsonlogger/jsonlogger.py
12
+ src/pythonjsonlogger/core.py
13
+ src/pythonjsonlogger/defaults.py
14
+ src/pythonjsonlogger/exception.py
15
+ src/pythonjsonlogger/json.py
16
+ src/pythonjsonlogger/msgspec.py
17
+ src/pythonjsonlogger/orjson.py
12
18
  src/pythonjsonlogger/py.typed
19
+ src/pythonjsonlogger/utils.py
13
20
  tests/__init__.py
14
- tests/test_jsonlogger.py
21
+ tests/test_deprecation.py
22
+ tests/test_formatters.py
23
+ tests/test_missing.py
@@ -0,0 +1,33 @@
1
+
2
+ [:python_version < "3.10"]
3
+ typing_extensions
4
+
5
+ [dev]
6
+ validate-pyproject[all]
7
+ black
8
+ pylint
9
+ mypy
10
+ pytest
11
+ freezegun
12
+ tzdata
13
+ build
14
+ mkdocs
15
+ mkdocs-material>=8.5
16
+ mkdocs-awesome-pages-plugin
17
+ mdx_truly_sane_lists
18
+ mkdocstrings[python]
19
+ mkdocs-gen-files
20
+ mkdocs-literate-nav
21
+ mike
22
+
23
+ [dev:implementation_name != "pypy"]
24
+ orjson
25
+
26
+ [dev:implementation_name != "pypy" and python_version < "3.13"]
27
+ msgspec
28
+
29
+ [dev:implementation_name != "pypy" and python_version == "3.13"]
30
+ msgspec-python313-pre
31
+
32
+ [dev:python_version < "3.9"]
33
+ backports.zoneinfo
@@ -0,0 +1,29 @@
1
+ ### IMPORTS
2
+ ### ============================================================================
3
+ ## Future
4
+
5
+ ## Standard Library
6
+ import warnings
7
+
8
+ ## Installed
9
+
10
+ ## Application
11
+ import pythonjsonlogger.json
12
+ import pythonjsonlogger.utils
13
+
14
+ ### CONSTANTS
15
+ ### ============================================================================
16
+ ORJSON_AVAILABLE = pythonjsonlogger.utils.package_is_available("orjson")
17
+ MSGSPEC_AVAILABLE = pythonjsonlogger.utils.package_is_available("msgspec")
18
+
19
+
20
+ ### DEPRECATED COMPATIBILITY
21
+ ### ============================================================================
22
+ def __getattr__(name: str):
23
+ if name == "jsonlogger":
24
+ warnings.warn(
25
+ "pythonjsonlogger.jsonlogger has been moved to pythonjsonlogger.json",
26
+ DeprecationWarning,
27
+ )
28
+ return pythonjsonlogger.json
29
+ raise AttributeError(f"module {__name__} has no attribute {name}")