From nobody Tue Mar 21 19:26:56 2023 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Ph1nY44L4z40hCq; Tue, 21 Mar 2023 19:26:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Ph1nX5nNsz4L9P; Tue, 21 Mar 2023 19:26:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679426816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6MGPcpys8mZmwslvWRoyEFCJaHgw4cjcSxZwotpn5wc=; b=I8nRAAHKH+isztSepCPmMCuy+LaS1PXYKCZXRpvxwsDM35K270yNjqWVimil4pjzGL1nC/ HATVd4mSWtgiq9Y+VEgzDUuz/Gtt11m8Cz6adbe2ikifSHRTKK8yk3Of33wo23lxCJ4vJd r92To2LUHpAKbyp2aChmRRJtmJdB+/kqQLzuBZgzijYSiYihiIKuVAD8TDgI1wdaPPZLGY fWyGytxQnPDvU0BYb0KObnRVJuZHczB3gLUG31NQzyU5BXtkBWG4JR0SAZy7ZXlpQRejk4 VGTEi2HTr+eyqhjbmqO1Lhktd5KGGFjM/43qe+8HtzUbagmuncwqpzdgLTZf6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679426816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6MGPcpys8mZmwslvWRoyEFCJaHgw4cjcSxZwotpn5wc=; b=GqYlKCrKP136HJvEU3Eq2LLJh/xPP9ro8MuiniCPYYqwpH+Jpc3cqda7DxV16xfE9ISFQ3 ZOViSbhjWlyZ8ZNGfEIdAdBlonBsO3cruWxObmPTR3ONFYo1PVqXuw+LLfzeSFnHmHfNl+ eSLRF6TFfrn/dsizlYMn+ZcGpDwfLiSvwA2m4tLhefAH+Ba7ZN8JzlhWcXnoytWAE3n91L IrOCfsgqDpn3OXNvq7CqK6LpWLtKqJXMK+pkZ3s53REi2hoCkvk1oyUolb6rsY9glUN4QG n3QPLwKsjO11Gi252xeO2g+vl0OzB8vYqpB5Gom1CrGb26+Ejknr1Lpj5lmOGA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1679426816; a=rsa-sha256; cv=none; b=B2AJSgUMec6IQd3qBrtVfzKnkokrSww7bHs2CeyBpJRH8zAswbCLmMtA2lz25tuGdMDRJY xcvLl7IwhFIMM5wVHiQiA/jnF8UhUQFQgipd0woU6E5X27eOlBaJcOvxuXZZrlt4bmiXZC g9gns+mzi7buK54u2eb9oNnIQZ9Kn8gbzBluYLqaeZ2HOoTOmvHeyyWX8k6v15WAwhsNsy cClvx+juPnNuWRctLYrME247heIB9gAgJymkocAdyyUaPx9v1gVRAwErBMozwVgoTxCEt3 asX+cLZY5LAS5DpdMKR6ApT/wuT8kfNCNDIDTRk+oaXwkor93JtpdnvJQNWusg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Ph1nX4qt1zPMZ; Tue, 21 Mar 2023 19:26:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 32LJQuQd030413; Tue, 21 Mar 2023 19:26:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 32LJQuPZ030412; Tue, 21 Mar 2023 19:26:56 GMT (envelope-from git) Date: Tue, 21 Mar 2023 19:26:56 GMT Message-Id: <202303211926.32LJQuPZ030412@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Po-Chuan Hsieh Subject: git: e8204c43e0b0 - main - devel/py-datadog: Convert to USE_PYTHON=pep517 List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sunpoet X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e8204c43e0b0943e57058c7be116c67705d1d8da Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=e8204c43e0b0943e57058c7be116c67705d1d8da commit e8204c43e0b0943e57058c7be116c67705d1d8da Author: Po-Chuan Hsieh AuthorDate: 2023-03-21 18:42:41 +0000 Commit: Po-Chuan Hsieh CommitDate: 2023-03-21 19:20:34 +0000 devel/py-datadog: Convert to USE_PYTHON=pep517 - Bump PORTREVISION for dependency and package change --- devel/py-datadog/Makefile | 8 +++---- devel/py-datadog/files/setup.py | 53 ----------------------------------------- 2 files changed, 3 insertions(+), 58 deletions(-) diff --git a/devel/py-datadog/Makefile b/devel/py-datadog/Makefile index 28a1b6820ed9..67f57b3e8a1b 100644 --- a/devel/py-datadog/Makefile +++ b/devel/py-datadog/Makefile @@ -1,5 +1,6 @@ PORTNAME= datadog PORTVERSION= 0.44.0 +PORTREVISION= 1 CATEGORIES= devel python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -11,18 +12,15 @@ WWW= https://github.com/DataDog/datadogpy LICENSE= BSD3CLAUSE LICENSE_FILE= ${WRKSRC}/LICENSE +BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>=0.15.0:devel/py-hatchling@${PY_FLAVOR} RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}requests>=2.6.0:www/py-requests@${PY_FLAVOR} USES= python:3.7+ -USE_PYTHON= autoplist concurrent distutils +USE_PYTHON= autoplist concurrent pep517 NO_ARCH= yes # bin/dog CONFLICTS_INSTALL= dog -post-patch: - @${RM} ${WRKSRC}/pyproject.toml - @${CP} ${FILESDIR}/setup.py ${WRKSRC}/ - .include diff --git a/devel/py-datadog/files/setup.py b/devel/py-datadog/files/setup.py deleted file mode 100644 index dafa20eac958..000000000000 --- a/devel/py-datadog/files/setup.py +++ /dev/null @@ -1,53 +0,0 @@ -# -*- coding: utf-8 -*- -from setuptools import setup - -setup( - name='datadog', - version='0.44.0', - description='The Datadog Python library', - long_description='# The Datadog Python library\n\n[![Unit Tests](https://dev.azure.com/datadoghq/datadogpy/_apis/build/status/DataDog.datadogpy.unit?branchName=master)](https://dev.azure.com/datadoghq/datadogpy/_build/latest?definitionId=10&branchName=master)\n[![Integration Tests](https://dev.azure.com/datadoghq/datadogpy/_apis/build/status/DataDog.datadogpy.integration?branchName=master)](https://dev.azure.com/datadoghq/datadogpy/_build/latest?definitionId=13&branchName=master)\n[![Documentation Status](https://readthedocs.org/projects/datadogpy/badge/?version=latest)](https://readthedocs.org/projects/datadogpy/?badge=latest)\n[![PyPI - Version](https://img.shields.io/pypi/v/datadog.svg)](https://pypi.org/project/datadog)\n[![PyPI - Downloads](https://pepy.tech/badge/datadog)](https://pepy.tech/project/datadog)\n\nThe Datadog Python Library is a collection of tools suitable for inclusion in existing Python projects or for the development of standalone scripts. It provides an a bstraction on top of Datadog\'s raw HTTP interface and the Agent\'s DogStatsD metrics aggregation server, to interact with Datadog and efficiently report events and metrics.\n\n- Library Documentation: https://datadogpy.readthedocs.io/en/latest/\n- HTTP API Documentation: https://docs.datadoghq.com/api/\n- DatadogHQ: https://datadoghq.com\n\nSee [CHANGELOG.md](https://github.com/DataDog/datadogpy/blob/master/CHANGELOG.md) for changes.\n\n## Installation\n\nTo install from pip:\n\n pip install datadog\n\nTo install from source:\n\n python setup.py install\n\n## Datadog API\n\nTo support all Datadog HTTP APIs, a generated library is\navailable which will expose all the endpoints:\n[datadog-api-client-python](https://github.com/DataDog/datadog-api-client-python).\n\nFind below a working example for submitting an event to your Event Stream:\n\n```python\nfrom datadog import initialize, api\n\noptions = {\n "api_key": "",\n "app_key": "",\n}\n\nini tialize(**options)\n\ntitle = "Something big! happened!"\ntext = "And let me tell you all about it here!"\ntags = ["version:1", "application:web"]\n\napi.Event.create(title=title, text=text, tags=tags)\n```\n\n**Consult the full list of supported Datadog API endpoints with working code examples in [the Datadog API documentation](https://docs.datadoghq.com/api/latest/?code-lang=python).**\n\n**Note**: The full list of available Datadog API endpoints is also available in the [Datadog Python Library documentation](https://datadogpy.readthedocs.io/en/latest/)\n\n#### Environment Variables\n\nAs an alternate method to using the `initialize` function with the `options` parameters, set the environment variables `DATADOG_API_KEY` and `DATADOG_APP_KEY` within the context of your application.\n\nIf `DATADOG_API_KEY` or `DATADOG_APP_KEY` are not set, the library attempts to fall back to Datadog\'s APM environment variable prefixes: `DD_API_KEY` and `DD_APP_KEY`.\n\n```python\nfrom datadog import initialize, api\n\n# Assuming you\'ve set `DD_API_KEY` and `DD_APP_KEY` in your env,\n# initialize() will pick it up automatically\ninitialize()\n\ntitle = "Something big happened!"\ntext = "And let me tell you all about it here!"\ntags = ["version:1", "application:web"]\n\napi.Event.create(title=title, text=text, tags=tags)\n```\n\nIn development, you can disable any `statsd` metric collection using `DD_DOGSTATSD_DISABLE=True` (or any not-empty value).\n\n## DogStatsD\n\nIn order to use DogStatsD metrics, the Agent must be [running and available](https://docs.datadoghq.com/developers/dogstatsd/?code-lang=python).\n\n### Instantiate the DogStatsD client with UDP\n\nOnce the Datadog Python Library is installed, instantiate the StatsD client using UDP in your code:\n\n```python\nfrom datadog import initialize, statsd\n\noptions = {\n "statsd_host": "127.0.0.1",\n "statsd_port": 8125,\n}\n\ninitialize(**options)\n```\n\nSee the full list of available [DogStatsD client instantiation parameters](https://docs.datadoghq.com/ developers/dogstatsd/?code-lang=python#clien! t-instant! iation-parameters).\n\n#### Instantiate the DogStatsd client with UDS\n\nOnce the Datadog Python Library is installed, instantiate the StatsD client using UDS in your code:\n```python\n\nfrom datadog import initialize, statsd\n\noptions = {\n "statsd_socket_path": PATH_TO_SOCKET,\n}\n\ninitialize(**options)\n```\n\n#### Origin detection over UDP and UDS\n\nOrigin detection is a method to detect which pod `DogStatsD` packets are coming from in order to add the pod\'s tags to the tag list.\nThe `DogStatsD` client attaches an internal tag, `entity_id`. The value of this tag is the content of the `DD_ENTITY_ID` environment variable if found, which is the pod\'s UID. The Datadog Agent uses this tag to add container tags to the metrics. To avoid overwriting this global tag, make sure to only `append` to the `constant_tags` list.\n\nTo enable origin detection over UDP, add the following lines to your application manifest\n```yaml\nenv:\n - name: DD_ENTITY_ID\n valueFrom:\n fiel dRef:\n fieldPath: metadata.uid\n```\n\n### Usage\n#### Metrics\n\nAfter the client is created, you can start sending custom metrics to Datadog. See the dedicated [Metric Submission: DogStatsD documentation](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python) to see how to submit all supported metric types to Datadog with working code examples:\n\n* [Submit a COUNT metric](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#count).\n* [Submit a GAUGE metric](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#gauge).\n* [Submit a SET metric](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#set)\n* [Submit a HISTOGRAM metric](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#histogram)\n* [Submit a TIMER metric](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#timer)\n* [Submit a DISTRIBUTIO N metric](https://docs.datadoghq.com/metrics! /dogstats! d_metrics_submission/?code-lang=python#distribution)\n\nSome options are supported when submitting metrics, like [applying a Sample Rate to your metrics](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#metric-submission-options) or [tagging your metrics with your custom tags](https://docs.datadoghq.com/metrics/dogstatsd_metrics_submission/?code-lang=python#metric-tagging).\n\n#### Events\n\nAfter the client is created, you can start sending events to your Datadog Event Stream. See the dedicated [Event Submission: DogStatsD documentation](https://docs.datadoghq.com/events/guides/dogstatsd/?code-lang=python) to see how to submit an event to your Datadog Event Stream.\n\n#### Service Checks\n\nAfter the client is created, you can start sending Service Checks to Datadog. See the dedicated [Service Check Submission: DogStatsD documentation](https://docs.datadoghq.com/developers/service_checks/dogstatsd_service_checks_submission/?code-lang=python) to see how to submit a Service Check to Datadog.\n\n### Monitoring this client\n\nThis client automatically injects telemetry about itself in the DogStatsD stream.\nThose metrics will not be counted as custom and will not be billed. This feature can be disabled using the `statsd.disable_telemetry()` method.\n\nSee [Telemetry documentation](https://docs.datadoghq.com/developers/dogstatsd/high_throughput/?code-lang=python#client-side-telemetry) to learn more about it.\n\n### Benchmarks\n\n_Note: You will need to install `psutil` package before running the benchmarks._\n\nIf you would like to get an approximate idea on the throughput that your DogStatsD library\ncan handle on your system, you can run the included local benchmark code:\n\n```sh-session\n$ # Python 2 Example\n$ python2 -m unittest -vvv tests.performance.test_statsd_throughput\n\n$ # Python 3 Example\n$ python3 -m unittest -vvv tests.performance.test_statsd_throughput\n```\n\nYou can also add set `BENCHMARK_*` to customize the r uns:\n```sh-session\n$ # Example #1\n$ BENCH! MARK_NUM_! RUNS=10 BENCHMARK_NUM_THREADS=1 BENCHMARK_NUM_DATAPOINTS=5000 BENCHMARK_TRANSPORT="UDP" python2 -m unittest -vvv tests.performance.test_statsd_throughput\n\n$ # Example #2\n$ BENCHMARK_NUM_THREADS=10 BENCHMARK_TRANSPORT="UDS" python3 -m unittest -vvv tests.performance.test_statsd_throughput\n```\n\n## Maximum packets size in high-throughput scenarios\n\nIn order to have the most efficient use of this library in high-throughput scenarios,\ndefault values for the maximum packets size have already been set for both UDS (8192 bytes)\nand UDP (1432 bytes) in order to have the best usage of the underlying network.\nHowever, if you perfectly know your network and you know that a different value for the maximum packets\nsize should be used, you can set it with the parameter `max_buffer_len`. Example:\n\n```python\nfrom datadog import initialize\n\noptions = {\n "api_key": "",\n "app_key": "",\n "max_buffer_len": 4096,\n}\n\ninitialize(**options)\n```\n\n ## Thread Safety\n\n`DogStatsD` and `ThreadStats` are thread-safe.\n', - author_email='"Datadog, Inc." ', - classifiers=[ - 'License :: OSI Approved :: BSD License', - 'Operating System :: OS Independent', - 'Programming Language :: Python :: 2.7', - 'Programming Language :: Python :: 3.7', - 'Programming Language :: Python :: 3.8', - 'Programming Language :: Python :: 3.9', - 'Programming Language :: Python :: Implementation :: CPython', - 'Programming Language :: Python :: Implementation :: PyPy', - ], - install_requires=[ - 'configparser<5; python_version < "3.0"', - 'requests>=2.6.0', - 'typing; python_version < "3.5"', - ], - entry_points={ - 'console_scripts': [ - 'dog = datadog.dogshell:main', - 'dogshell = datadog.dogshell:main', - 'dogshellwrap = datadog.dogshell.wrap:main', - 'dogwrap = datadog.dogshell.wrap:main', - ], - }, - packages=[ - 'datadog', - 'datadog.api', - 'datadog.dogshell', - 'datadog.dogstatsd', - 'datadog.threadstats', - 'datadog.util', - 'tests', - 'tests.integration', - 'tests.integration.api', - 'tests.integration.dogshell', - 'tests.performance', - 'tests.unit', - 'tests.unit.api', - 'tests.unit.dogstatsd', - 'tests.unit.dogwrap', - 'tests.unit.threadstats', - 'tests.unit.util', - 'tests.util', - ], -)