Skip to content

Commit

Permalink
Add python agent release notes for 10.0
Browse files Browse the repository at this point in the history
  • Loading branch information
hmstepanek committed Sep 24, 2024
1 parent 329d884 commit 4f010b5
Showing 1 changed file with 76 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
---
subject: 'Python agent'
releaseDate: '2024-08-08'
version: 10.0.0
downloadLink: 'https://pypi.python.org/pypi/newrelic'
features: ['Remove Python2.7 support', 'Add Kafka server metric', 'Add capturing of memcache host and port', 'Add support for kafka-python-ng', 'Add support for uvicorn_workers', 'Automatically detect function signature in LangChasimilarity search', 'Add environment variable for GC runtime metrics']
bugs: ['Fix bug in graphql entity name detection', 'Fix issue in LangChain where a thread is started and the transaction context is lost', 'Fix parsing of request and response when running OpenAI via LangChain', 'Instrument new path to OpenAI chat class', 'Fix pyscopg v3 API incompatibilities']
security: []
---

## Notes

This release of the Python agent drops support for Python2.7, adds a Kafka server metric, capturing of memcache host and port, support for [kafka-python-ng](https://pypi.org/project/kafka-python-ng/), support for [uvicorn_worker](https://pypi.org/project/uvicorn-worker/), an environment variable for GC runtime metrics, and automatically detects the function signature in [LangChain](https://pypi.org/project/langchain/) `similarity_search`. It also fixes a bug in [graphql](https://pypi.org/project/graphql/) entity name detection, an issue in [LangChain](https://pypi.org/project/langchain/) where a thread is started and the transaction context is lost, parsing of the request and response when running [OpenAI](https://pypi.org/project/openai/) via [LangChain](https://pypi.org/project/langchain/), [pyscopg](https://pypi.org/project/psycopg/) v3 API incompatibilities, and instruments a new path to the [OpenAI](https://pypi.org/project/openai/) chat class.

Install the agent using `easy_install/pip/distribute` via the [Python Package Index](https://pypi.python.org/pypi/newrelic) or download it directly from the [New Relic download site](https://download.newrelic.com/python_agent/release).

## New features

* Add Kafka server metric

* Adds a metric to capture the host and port information for Kafka entities on both consumers and producers. This metric allows the UI to link AWS information with AWS MSK entities in the service map.

* Add capturing of memcache host and port

* Adds capturing of host and port info on memcache libraries; bmemcached, aiomcache, and pymemcache. This allows the UI to link AWS information with AWS memcache entities in the service map.

* Add support for [kafka-python-ng](https://pypi.org/project/kafka-python-ng/)

* [kafka-python](https://pypi.org/project/kafka-python/) has been released under a new name: [kafka-python-ng](https://pypi.org/project/kafka-python-ng/). This continues to support kafka-python under the new package name.

* Add support for [uvicorn_worker](https://pypi.org/project/uvicorn-worker/)

* `uvicorn.workers` has been moved to a separate package called `uvicorn_worker`. This checks for both names of the module when reporting dispatcher information.

* Automatically detect function signature in [LangChain](https://pypi.org/project/langchain/) `similarity_search`

* Automatically detect the function signature when wrapping `similarity_search`.

* Add environment variable for GC runtime metrics

* GC runtime metircs can now be enabled/disabled via the following environment variable: NEW_RELIC_GC_RUNTIME_METRICS_ENABLED.

## Deprecations

* Remove Python2.7 Support

* Removes compatibility with Python2.7. Also removes instrumentations that were only supported on Python2.7.

## Bug fixes

* Fix bug in graphql entity name detection

* Previously, the graphql channel entity name would be missing the first couple characters. This bug has been fixed.

* Fix issue in [LangChain](https://pypi.org/project/langchain/) where a thread is started and the transaction context is lost

* Previously, when calling some chains like retreival chains, the transaction would be lost and instrumentation would be broken because a thread would be started by [LangChain](https://pypi.org/project/langchain/). This has been fixed so the transaction context is passed across threads and instrumentation still works for retreival chains.

* Fix parsing of request and response when running [OpenAI](https://pypi.org/project/openai/) via [LangChain](https://pypi.org/project/langchain/)

* Previously, when running [OpenAI](https://pypi.org/project/openai/) via [LangChain](https://pypi.org/project/langchain/) the request and response were a different format and were not being recorded. This issue has been fixed.

* Instrument new path to [OpenAI](https://pypi.org/project/openai/) chat class

* [OpenAI](https://pypi.org/project/openai/) moved the ChatCompletions class to a different path which prevented the instrumentation from being applied. This has been fixed.

* Fix [pyscopg](https://pypi.org/project/psycopg/) v3 API incompatibilities

* Expand DBAPI2 wrappers to allow arbitrary `kwargs` on `executemany()`. Upgrade [psycopg](https://pypi.org/project/psycopg/) v3 instrumentation to allow arbitrary `kwargs` on `executemany()`. Rename existing psycopg v3 wrapper arguments to match the upstream library's names for compatibility.


## Support statement

We recommend updating to the latest agent version as soon as it's available. If you can't upgrade to the latest version, update your agents to a version no more than 90 days old. Read [more](/docs/new-relic-solutions/new-relic-one/install-configure/update-new-relic-agent/) about keeping agents up to date.

See the New Relic Python agent [EOL policy](/docs/apm/agents/python-agent/getting-started/python-agent-eol-policy/) for information about agent releases and support dates.

0 comments on commit 4f010b5

Please sign in to comment.