Skip to content

Commit

Permalink
Revert "Add pyproject.toml file (#11305)"
Browse files Browse the repository at this point in the history
This reverts commit 882a70d.
  • Loading branch information
mx-psi authored Feb 8, 2022
1 parent 08a382d commit 2066bad
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 79 deletions.
62 changes: 0 additions & 62 deletions datadog_checks_downloader/pyproject.toml

This file was deleted.

13 changes: 13 additions & 0 deletions datadog_checks_downloader/requirements.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#
# At the time of writing (Jan 30 2020), this was the latest version of these
# libraries.
#
tuf==0.17.0; python_version < "3.0"
tuf==0.19.0; python_version > "3.0"
in-toto==1.0.1
#
# Make sure TUF and in-toto use the same version of this library, which they
# both use in common. At the time of writing (Jan 30 2020), this was the latest
# version of the library.
#
securesystemslib[crypto,pynacl]==0.20.1
17 changes: 1 addition & 16 deletions datadog_checks_downloader/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,6 @@ def get_dependencies():
return f.readlines()


def parse_pyproject_array(name):
import os
import re
from ast import literal_eval

pattern = r'^{} = (\[.+?\])$'.format(name)

with open(os.path.join(HERE, 'pyproject.toml'), 'r', encoding='utf-8') as f:
# Windows \r\n prevents match
contents = '\n'.join(line.rstrip() for line in f.readlines())

array = re.search(pattern, contents, flags=re.MULTILINE | re.DOTALL).group(1)
return literal_eval(array)


setup(
# Version should always match one from an agent release
version=ABOUT["__version__"],
Expand All @@ -67,7 +52,7 @@ def parse_pyproject_array(name):
],
packages=['datadog_checks.downloader'],
# Run-time dependencies
extras_require={'deps': parse_pyproject_array('deps')},
extras_require={'deps': get_dependencies()},
# NOTE: Copy over TUF directories, and root metadata.
package_data={
'datadog_checks.downloader': [
Expand Down
2 changes: 1 addition & 1 deletion datadog_checks_downloader/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ envdir =
py38: {toxworkdir}/py38
dd_check_style = true
usedevelop = true
extras = deps
deps =
-e../datadog_checks_base[deps]
-rrequirements-dev.txt
commands =
pip install -r requirements.in
pytest -v {posargs} --capture=no --log-cli-level=debug

0 comments on commit 2066bad

Please sign in to comment.