Skip to content

examples: fix broken examples and unblock their type checks#594

Open
Nelson-PROIA wants to merge 1 commit into
mainfrom
nelsonproia/fix-broken-examples
Open

examples: fix broken examples and unblock their type checks#594
Nelson-PROIA wants to merge 1 commit into
mainfrom
nelsonproia/fix-broken-examples

Conversation

@Nelson-PROIA

Copy link
Copy Markdown
Contributor

Fixes the examples that fail when run against the API, plus the type-check errors that block them.

  • async_chat_with_image_no_streaming.py: image URL pointed at a deleted asset (API returned 400 invalid_request_file); use a live image.
  • async_structured_outputs.py: mistral-large-2411 is rejected as invalid_model; use mistral-large-latest.
  • run_example_scripts.yaml: install the [telemetry] extra so the observability/ examples run instead of ModuleNotFound.
  • redaction.py: import SpanExporter as the conditional base so mypy accepts it (fixes a valid-type error).
  • add pydantic to the pyright pre-commit hook deps.

Verified: full example suite passes locally (except skill_lifecycle, which is the AIR-1188 skills-API 500, server-side).

- chat_with_image: dead image URL returned 400; use a live image
- structured_outputs: mistral-large-2411 rejected as invalid model; use mistral-large-latest
- run_example_scripts.yaml: install the [telemetry] extra so observability examples run
- redaction.py: import SpanExporter as the base class so mypy accepts it (valid-type)
- pre-commit: add pydantic to the pyright hook deps
- guard optional message access in the two examples
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