Notes
This release of the Python agent adds support for the following:
- Custom tasks in Celery
- Graphene-Django monitoring
- Middleware filtering in Django
- AWS Bedrock Converse API
- W3CTraceParent header sampled flag
This release also provides the following fixes:
- Safeguards for the deepest unique path in GraphQL
- Safeguards for web URL request parsing
- Fallback for ElasticSearch and GraphQL when
trace.settings==None
- Remove
options
method from async ElasticSearch client list
Install the agent using easy_install/pip/distribute
via the Python Package Index or download it directly from the New Relic download site.
New features
Adds support for custom tasks in Celery
Adds support for Graphene-Django
- Add monitoring support for synchronous schemas created with Graphene-Django. Previously, schemas created with Graphene-Django would only be partially monitored, resulting in missing GraphQL related attributes.
Adds support for middleware filtering in Django
Users are now able to filter which Django middleware to monitor. There are now three additional settings:
instrumentation.middleware.django.enabled
(Default istrue
)instrumentation.middleware.django.exclude
instrumentation.middleware.django.include
See the Django Middleware Filtering page for more information and examples.
Adds support for AWS Bedrock Converse API
- Add monitoring support for non-streaming Converse API. This includes support for
converse
chat completion calls made usingboto3
andaioboto3
clients.
- Add monitoring support for non-streaming Converse API. This includes support for
Adds support for W3CTraceParent header sampled flag
- When an upstream service sends the W3CTraceParent header with the sampling flag set, New Relic will take into account that sampling decision when deciding whether the current transaction will be sampled.
Added support for sampling decisions based on whether the remote parent is sampled
Added support for two new configuration options:
distributed_tracing.sampler.remote_parent_sampled
distributed_tracing.sampler.remote_parent_not_sampled
default
is the default behavior and behaves as it did before this change (it passes the sampling decision to the adaptive sampling algorithm to determine whether the transaction will be sampled).always_on
means that the trace that has a remote parent sampled or remote parent not sampled will always be sampled.always_off
means that the trace that has a remote parent sampled or remote parent not sampled will never be sampled.
Bug fixes
Add safeguard for deepest unique path in GraphQL
- Some users were experiencing issues with the deepest unique path in GraphQL not being generated due to a field name returning
None
. This issue has been fixed.
- Some users were experiencing issues with the deepest unique path in GraphQL not being generated due to a field name returning
Add safeguard for web request parsing
- Some users experienced a parsing error when
request_uri
was malformed or contained invalid characters. This can happen at this point if therequest_uri
in the request header is invalid and does not match the (valid) URL originally given. While this safeguard has now been put in place in New Relic,urllib
has resolved this issue for versions of Python released after Jan 31, 2025.
- Some users experienced a parsing error when
Fix crash in ElasticSearch and GraphQL when
trace.settings==None
- In cases where
trace.settings
isNone
, the instrumentation for ElasticSearch crashed the application. Aglobal_settings
fallback has been put in place. This also resolves the same issue found in GraphQL.
- In cases where
Remove
options
method from async ElasticSearch client list- The previous instrumentation of ElasticSearch caused a crash because
options
was in the list of async methods. This method is no longer wrapped in aDatastoreTrace
since it is not one that conducts any datastore operations/requests.
- The previous instrumentation of ElasticSearch caused a crash because
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 about keeping agents up to date.
See the New Relic Python agent EOL policy for information about agent releases and support dates.
メモ
このリリースの Python エージェントでは、新しいRedis関数のサポートが追加され、すべての内部パスがos.path
からpathlib.Path
に変換され、JSON エンコード PosixPaths に関する問題が修正されました。
Python パッケージ インデックス経由でeasy_install/pip/distribute
を使用してエージェントをインストールするか、 New Relic ダウンロード サイトから直接ダウンロードします。
新機能
新しいRedis関数のサポートを追加
- 新しいRedis関数の計装を追加します。
すべての内部パスを
os.path
からpathlib.Path
- Windows パスをサポートするための準備として、文字列ベースのパスと
os.path
のすべての内部使用をpathlib.Path
に変換します。
- Windows パスをサポートするための準備として、文字列ベースのパスと
バグ修正
JSON エンコード PosixPath の問題を修正
- 一部のユーザーで JSON エンコード
PosixPath
構成設定に関する問題が発生していました。この問題は修正されました。
- 一部のユーザーで JSON エンコード
サポートステートメント
最新のエージェント バージョンが利用可能になったらすぐに更新することをお勧めします。最新バージョンにアップグレードできない場合は、エージェントを 90 日以内のバージョンに更新してください。エージェントを最新の状態に保つ方法の詳細については、こちらをご覧ください。
エージェントのリリースとサポート日については、New Relic Python エージェントのEOL ポリシーを参照してください。
メモ
このリリースの Python エージェントでは、 oracledbのサポートが追加され、Kombu および Kafka でMessageTransaction
オブジェクトに属性destination_name
がないバグが修正され、AWS での使用率メタデータの消失が修正されました。
Python パッケージ インデックス経由でeasy_install/pip/distribute
を使用してエージェントをインストールするか、 New Relic ダウンロード サイトから直接ダウンロードします。
新機能
oracledbのサポートを追加
- oracledbの計装を追加します。
バグ修正
「
MessageTransaction
オブジェクトに属性destination_name
がありません」というバグを修正しました- MessageBroker モジュールの、シリアル化メソッドが
MessageTransaction
のdestination_name
プロパティを検索していたが、それが存在しないというバグを修正しました。
- MessageBroker モジュールの、シリアル化メソッドが
AWS と K8s を一緒に実行する際における AWS 使用率メタデータの問題を修正
- AWS EC2インスタンス上で動作するK8s Podの権限設定により、初めて使用状況メタデータを取得できるようになります。 ただし、アプリケーションが継続的に実行されたままになっていると、エージェントは再接続され、使用率メタデータの読み込みに失敗します。このような場合、使用率メタデータはエージェント インスタンスごとにキャッシュされ、取得できるようになります。
サポートステートメント
最新のエージェント バージョンが利用可能になったらすぐに更新することをお勧めします。最新バージョンにアップグレードできない場合は、エージェントを 90 日以内のバージョンに更新してください。エージェントを最新の状態に保つ方法の詳細については、こちらをご覧ください。
エージェントのリリースとサポート日については、New Relic Python エージェントのEOL ポリシーを参照してください。
メモ
このリリースの Python エージェントでは、Azure Function Appsとprotobuf v6 のサポートが追加されました。
Python パッケージ インデックス経由でeasy_install/pip/distribute
を使用してエージェントをインストールするか、 New Relic ダウンロード サイトから直接ダウンロードします。
新機能
Azure Function Apps のサポートを追加
- HTTPTrigger タイプのAzure Function Appsのサポートを追加します。
バグ修正
protobuf v6 サポートを有効にするために pb2 ファイルを追加します
- 以前は、 protobuf v6 のサポートが不足していたため、いくつかの Google パッケージは New Relic と互換性がありませんでした。これは解決されました。
サポートステートメント
最新のエージェント バージョンが利用可能になったらすぐに更新することをお勧めします。最新バージョンにアップグレードできない場合は、エージェントを 90 日以内のバージョンに更新してください。エージェントを最新の状態に保つ方法の詳細については、こちらをご覧ください。
エージェントのリリースとサポート日については、New Relic Python エージェントのEOL ポリシーを参照してください。
メモ
このリリースの Python エージェントでは、モデル コンテキスト プロトコル (MCP) のサポートが追加され、 importlib.metadata
およびpkg_resources
のインポート ロジックが修正されました。
Python パッケージ インデックス経由でeasy_install/pip/distribute
を使用してエージェントをインストールするか、 New Relic ダウンロード サイトから直接ダウンロードします。
新機能
モデルコンテキストプロトコル (MCP) のサポートを追加
バグ修正
importlib.metadata
のインポートロジックを修正し、pkg_resources
importlib.metadata
のインポートに関するロジックを更新して、pkg_resources.*
にフォールバックする前にimportlib_metadata
バックポートも使用するようにします。これにより、sys.version
条件の使用も削除され、importlib.metadata
が使用可能であるにもかかわらず Python 3.9 でpkg_resources
しか使用できなかった問題も修正されます。
サポートステートメント
最新のエージェント バージョンが利用可能になったらすぐに更新することをお勧めします。最新バージョンにアップグレードできない場合は、エージェントを 90 日以内のバージョンに更新してください。エージェントを最新の状態に保つ方法の詳細については、こちらをご覧ください。
エージェントのリリースとサポート日については、New Relic Python エージェントのEOL ポリシーを参照してください。
Notes
This release of the Python agent adds support for Redis v6.0.0 and fixes conflicts with the opentelemetry-proto package.
Install the agent using easy_install/pip/distribute
via the Python Package Index or download it directly from the New Relic download site.
New features
Add support for Redis v6.0.0
- Adds support for all client methods introduced in Redis v6.0.0.
Bug fixes
Fix conflicts with opentelemetry-proto package
- Fixes an issue where the agent's internal copy of opentelemetry-proto would conflict with any other packages relying on opentelemetry-proto (such as ChromaDB). This should now be treated as a separate package by OpenTelemetry and prevent any conflicts.
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 about keeping agents up to date.
See the New Relic Python agent EOL policy for information about agent releases and support dates.