The GitHub Actions job "npm_and_yarn in /website for postcss - Update 
#1478907899" on burr.git/main has failed.
Run started by GitHub user dependabot[bot] (triggered by dependabot[bot]).

Head commit for run:
805131a742b6ac5742e494fe45c74400c60455d5 / Han Nguyen 
<[email protected]>
feat: add Langfuse tracing integration (LangfuseBridge) (#844)

* feat: add Langfuse integration (LangfuseBridge) (#206)

Implements all features scoped in #206 via lifecycle hooks, built on
OpenTelemetryBridge and the OTel-native Langfuse SDK:

- One trace per application execution call (via the #203 interface)
- One span per step; one span per __tracer span call
- State observations: action inputs/read state and results/written state
  as observation input/output (capture_state=False to disable);
  log_attributes as observation metadata
- Access to the Langfuse client via bridge.langfuse_client
- app_id/partition_key map to Langfuse session/user (overridable)
- Injects a should_export_span filter so Burr spans survive langfuse
  v4's default LLM-only export filtering (public: burr_span_export_filter)

Uses the OTel bridge instead of the tracking/client.py pattern per the
issue thread (May 31): the SDK's OTel rewrite and the closure of #205
made this the cleaner path, and it nests third-party OTel LLM
instrumentation inside step spans automatically.

Includes tests, docs, a runnable example, and a langfuse pyproject extra.

* fix: JSON-serialize complex logged attributes for Langfuse metadata

OTel attributes reject sequences of non-primitives, so list-of-dict values
(e.g. chat_history logged by @trace) were dropped with a warning. Complex
values are now JSON-serialized into observation metadata.

* fix(langfuse): preserve OTel provider context

Route Burr spans through custom tracer providers and propagate session and user 
attributes to child instrumentation. Serialize mixed-type sequences before 
passing them to OpenTelemetry.

* fix: import propagate_attributes defensively for langfuse<3.9

Propagate_attributes was added in langfuse 3.9.0 and  Python 3.9 CI resolves an 
older 3.x (v4 requires py3.10+), so the unconditional import failed and was 
masked as 'plugin missing'. Falls back to per-span session/user attributes on 
older SDKs, with a regression test.

* fix(langfuse): support v3 attribute API

Langfuse 3.7 is the latest SDK available on Python 3.9 and does not export 
propagate_attributes. Fall back to per-span legacy attributes.

---------

Co-authored-by: jernejfrank <[email protected]>

Report URL: https://github.com/apache/burr/actions/runs/30085298286

With regards,
GitHub Actions via GitBox

Reply via email to