Skip to content

Add runnable Sentry host-integration example - #24

Merged
ejames-dev merged 6 commits into
mainfrom
add-sentry-optional-hook
Sep 4, 2026
Merged

ejames-dev merged 6 commits into
mainfrom
add-sentry-optional-hook

Conversation

@ejames-dev

Copy link
Copy Markdown
Owner

Summary

  • Adds examples/sentry_integration.py, a runnable demo of the host app owning sentry_sdk.init() while AgentEase forwards exceptions to it (per agentease/telemetry/sentry.py's existing contract)
  • Adds SENTRY_DSN placeholder to .env.example
  • Points README's Sentry section at the new example

Test plan

  • python examples/sentry_integration.py runs end-to-end in offline mode with sentry-sdk installed
  • ruff check / ruff format --check pass on the new file

🤖 Generated with Claude Code

https://claude.ai/code/session_01Loy9A4KTAC89kAyGywzo4a

ejames-dev and others added 2 commits August 30, 2026 11:53
Adds a sentry extra and a capture_exception() helper that forwards
provider/workflow-pipeline exceptions to a Sentry client the host app has
already initialized. AgentEase never initializes its own client or ships a
DSN, so this stays a no-op without the host opting in, preserving the
existing "no hosted telemetry" guarantee.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LE37KoRF65NssAgS3SD2DG
Demonstrates the documented pattern where the host app owns
sentry_sdk.init() and AgentEase only forwards exceptions to it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Loy9A4KTAC89kAyGywzo4a
Comment thread examples/sentry_integration.py Outdated
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015bk3CYr8RPkXWrH1u8dSPp
@ejames-dev ejames-dev closed this Sep 3, 2026
@ejames-dev ejames-dev reopened this Sep 3, 2026
ejames-dev and others added 3 commits September 4, 2026 15:38
The main-branch merge left a duplicated sentry-sdk entry that uv
itself couldn't parse. Regenerated the lockfile from pyproject.toml
instead of trusting the text merge.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MAVeY8HZhca5nJ2Hij7Bwr
sentry-sdk captures local stack-frame variables by default; combined
with send_default_pii=True, an exception raised during PII scrubbing
would send raw (unscrubbed) workflow input to Sentry, contradicting
the SDK's privacy guarantee. Flagged by Sentry's own PR review bot.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MAVeY8HZhca5nJ2Hij7Bwr
@ejames-dev
ejames-dev merged commit 61f7ad7 into main Sep 4, 2026
8 of 9 checks passed
@ejames-dev
ejames-dev deleted the add-sentry-optional-hook branch September 4, 2026 18:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant