Skip to content

Commit 1b20bcb

Browse files
authored
Merge pull request #33 from marselester/deprecate-lt-3.6
Deprecate Python versions below 3.6
2 parents bf41c57 + ffeabc8 commit 1b20bcb

File tree

5 files changed

+10
-13
lines changed

5 files changed

+10
-13
lines changed

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2015 Marsel Mavletkulov
3+
Copyright (c) 2024 Marsel Mavletkulov
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

json_log_formatter/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import logging
2-
from datetime import datetime
2+
from datetime import datetime, timezone
33

44
import json
55

@@ -120,7 +120,7 @@ def json_record(self, message, extra, record):
120120
"""
121121
extra['message'] = message
122122
if 'time' not in extra:
123-
extra['time'] = datetime.utcnow()
123+
extra['time'] = datetime.now(timezone.utc)
124124

125125
if record.exc_info:
126126
extra['exc_info'] = self.formatException(record.exc_info)

pyproject.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,20 +7,19 @@ packages = ["json_log_formatter"]
77

88
[project]
99
name = "JSON-log-formatter"
10-
version = "0.5.2"
10+
version = "1.0"
1111
description = "JSON log formatter"
1212
readme = "README.rst"
13-
requires-python = ">=2.7"
13+
requires-python = ">=3.6"
1414
license = {text = "MIT"}
1515
authors = [
16-
{name = "Marsel Mavletkulov", email = "marselester@ya.ru"},
16+
{name = "Marsel Mavletkulov"},
1717
]
1818
classifiers=[
1919
"License :: OSI Approved :: MIT License",
2020
"Intended Audience :: Developers",
2121
"Operating System :: OS Independent",
2222
"Programming Language :: Python",
23-
"Programming Language :: Python :: 2",
2423
"Programming Language :: Python :: 3",
2524
"Topic :: Software Development :: Libraries :: Python Modules"
2625
]

setup.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,10 @@
22

33
setup(
44
name='JSON-log-formatter',
5-
version='0.5.2',
5+
version='1.0',
66
license='MIT',
77
packages=['json_log_formatter'],
88
author='Marsel Mavletkulov',
9-
author_email='marselester@ya.ru',
109
url='https://github.com/marselester/json-log-formatter',
1110
description='JSON log formatter',
1211
long_description=open('README.rst').read(),
@@ -15,7 +14,6 @@
1514
'Intended Audience :: Developers',
1615
'Operating System :: OS Independent',
1716
'Programming Language :: Python',
18-
'Programming Language :: Python :: 2',
1917
'Programming Language :: Python :: 3',
2018
'Topic :: Software Development :: Libraries :: Python Modules'
2119
],

tox.ini

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
[tox]
2-
envlist=py27,py35,py36,py37,py38,py39,py310,py311,py312
2+
envlist=py36,py37,py38,py39,py310,py311,py312
33

44
[testenv]
55
deps=
66
pytest
7-
ujson==5.9.0
8-
simplejson==3.19.2
7+
ujson
8+
simplejson
99
django
1010
commands=
1111
pytest -s tests.py

0 commit comments

Comments
 (0)