Skip to content

Send app_path and ignore_logs to the collector - #276

Open
unflxw wants to merge 2 commits into
mainfrom
send-app-path-and-ignore-logs
Open

Send app_path and ignore_logs to the collector#276
unflxw wants to merge 2 commits into
mainfrom
send-app-path-and-ignore-logs

Conversation

@unflxw

@unflxw unflxw commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Fixes #273.
Fixes #275.

Send the app path to the collector

The processor strips the app path from each backtrace line, and decides
whether a frame belongs to the application by checking that its path is
relative. Without the app path, every frame keeps its absolute path, so
no line is recognized as the application's own.

Add the ignore_logs option

Collector mode sends log records, and the collector filters out the ones
matching this option when the resource carries it. The package had no
option for it because agent mode sends no logs at all, which is also why
it is not passed on to the agent.

The option is documented in https://github.com/appsignal/appsignal-docs/pull/192,
including that it only has an effect in collector mode.

@backlog-helper

backlog-helper Bot commented Aug 25, 2026

Copy link
Copy Markdown

鉁旓笍 All good!

New issue guide | Backlog management | Rules | Feedback

Comment thread .changesets/add-the-ignore-logs-option.md Outdated
Comment thread .changesets/send-the-app-path-to-the-collector.md Outdated
@unflxw
unflxw force-pushed the send-app-path-and-ignore-logs branch from b5dda91 to 754e0d3 Compare August 25, 2026 16:08
The processor strips the app path from each backtrace line, and decides
whether a frame belongs to the application by checking that its path is
relative. Without the app path, every frame keeps its absolute path, so
no line is recognized as the application's own.
@unflxw
unflxw force-pushed the send-app-path-and-ignore-logs branch from 754e0d3 to bb004b7 Compare August 25, 2026 16:17
@unflxw unflxw added the bug Confirmed and unconfirmed bugs reported by us and customers. label Aug 25, 2026
@unflxw
unflxw requested a lite review from Copilot August 25, 2026 16:20

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the AppSignal Python integration鈥檚 OpenTelemetry resource attributes so the collector receives (1) the application root path needed for correct backtrace parsing and (2) the new ignore_logs configuration for log filtering in collector mode.

Changes:

  • Add appsignal.config.app_path to the OpenTelemetry Resource so the collector/processor can correctly relativize and classify backtrace frames.
  • Add ignore_logs configuration (env + options) and send it as appsignal.config.ignore_logs in the OpenTelemetry Resource.
  • Extend config/resource tests and add changesets documenting both changes.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/test_config.py Extends env/config parsing assertions and validates new OTel resource attributes (app_path, ignore_logs).
src/appsignal/opentelemetry.py Adds app_path and ignore_logs to the OTel Resource attributes sent to the collector.
src/appsignal/config.py Adds the ignore_logs option to config typing and loads it from APPSIGNAL_IGNORE_LOGS.
.changesets/send-the-app-path-to-the-collector.md Documents the backtrace/app-frame fix in collector mode (patch).
.changesets/add-the-ignore-logs-option.md Documents the new ignore_logs option and its collector-mode-only behavior (minor).

馃挕 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/appsignal/config.py
Collector mode sends log records, and the collector filters out the ones
matching this option when the resource carries it. The package had no
option for it because agent mode sends no logs at all, which is also why
it is not passed on to the agent.
@unflxw
unflxw force-pushed the send-app-path-and-ignore-logs branch from bb004b7 to 723fc30 Compare August 25, 2026 16:30
@unflxw
unflxw requested a lite review from Copilot August 25, 2026 16:33

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Comment thread src/appsignal/config.py
Comment thread .changesets/add-the-ignore-logs-option.md
@unflxw
unflxw marked this pull request as ready for review August 25, 2026 18:48
@unflxw
unflxw requested a review from lipskis August 25, 2026 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Confirmed and unconfirmed bugs reported by us and customers.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add the ignore_logs option now that collector mode sends logs Send app_path as a resource attribute in collector mode

2 participants