Skip to content

Comments

Fix haiway exports#481

Merged
KaQuMiQ merged 1 commit intomainfrom
feature/exports
Jan 13, 2026
Merged

Fix haiway exports#481
KaQuMiQ merged 1 commit intomainfrom
feature/exports

Conversation

@KaQuMiQ
Copy link
Collaborator

@KaQuMiQ KaQuMiQ commented Jan 13, 2026

No description provided.

@coderabbitai
Copy link

coderabbitai bot commented Jan 13, 2026

Walkthrough

The pull request updates the project version from 0.96.0 to 0.96.1 in pyproject.toml and adds the Disposables class to the public API exports in src/draive/init.py by importing it from haiway and including it in the module's __all__ list.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

  • Update dependencies #480: Directly related as it involves the same Disposables export surface in src/draive/init.py, with opposite operation (removal vs. addition).
🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description check ❓ Inconclusive No description was provided, making it impossible to evaluate whether it relates to the changeset. Add a description explaining what haiway exports were fixed and why the change was necessary.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Fix haiway exports' is directly related to the main change: adding Disposables to the public exports from haiway in the init.py file.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

📜 Recent review details

Configuration used: Repository UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 96fd98b and 0fac958.

📒 Files selected for processing (2)
  • pyproject.toml
  • src/draive/__init__.py
🧰 Additional context used
📓 Path-based instructions (3)
**/*.py

📄 CodeRabbit inference engine (AGENTS.md)

**/*.py: Ensure latest, most strict typing syntax available from Python 3.13+; use no untyped public APIs and no loose Any unless required by third-party boundaries
Prefer explicit attribute access with static types; avoid dynamic getattr except at narrow boundaries
In public types, prefer abstract immutable protocols like Mapping, Sequence, Iterable over concrete dict, list, set
Use final where applicable; avoid inheritance and prefer type composition
Use precise unions (|) and narrow with match/isinstance; avoid cast unless provably safe and localized
Favor structural typing (Protocols) for async clients and adapters; use runtime-checkable protocols like HTTPRequesting to keep boundaries explicit
Guard immutability with assertions when crossing context boundaries; failure messages should aid debugging but never leak secrets
All I/O is async; keep boundaries async and use ctx.spawn for detached tasks, avoiding custom threading
Ensure structured concurrency concepts and valid coroutine usage; rely on haiway and asyncio packages
Await long-running operations directly; never block the event loop with sync calls
Translate provider/SDK errors into appropriate typed exceptions; wrap third-party exceptions at the boundary with actionable context (provider, operation, identifiers) while redacting sensitive payloads
Don't raise bare Exception; preserve contextual information in exception construction
Use observability hooks (ctx.log_*, ctx.record) from ctx helper instead of print/logging; tests assert on emitted events

Files:

  • src/draive/__init__.py
src/draive/**/*.py

📄 CodeRabbit inference engine (AGENTS.md)

src/draive/**/*.py: Import symbols from draive directly (e.g., from draive import State, ctx) rather than internal module paths
Use context scoping (ctx.scope(...)) to bind scoped Disposables, active State instances, and avoid global state
Add NumPy-style docstrings to public symbols; include Parameters, Returns, and Raises sections with rationale
Avoid docstrings for internal and private helpers; keep names self-explanatory
Skip module-level docstrings

Files:

  • src/draive/__init__.py
src/draive/__init__.py

📄 CodeRabbit inference engine (AGENTS.md)

Centralize public exports in src/draive/__init__.py; update this file when adding or modifying public APIs

Files:

  • src/draive/__init__.py
🧠 Learnings (4)
📓 Common learnings
Learnt from: CR
Repo: miquido/draive PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T14:30:08.757Z
Learning: Applies to src/draive/__init__.py : Centralize public exports in `src/draive/__init__.py`; update this file when adding or modifying public APIs
📚 Learning: 2025-06-16T10:28:07.434Z
Learnt from: KaQuMiQ
Repo: miquido/draive PR: 338
File: src/draive/lmm/__init__.py:1-2
Timestamp: 2025-06-16T10:28:07.434Z
Learning: The draive project requires Python 3.12+ as specified in pyproject.toml with "requires-python = ">=3.12"" and uses Python 3.12+ specific features like PEP 695 type aliases and generic syntax extensively throughout the codebase.

Applied to files:

  • pyproject.toml
📚 Learning: 2025-12-02T14:30:08.757Z
Learnt from: CR
Repo: miquido/draive PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T14:30:08.757Z
Learning: Applies to src/draive/__init__.py : Centralize public exports in `src/draive/__init__.py`; update this file when adding or modifying public APIs

Applied to files:

  • src/draive/__init__.py
📚 Learning: 2025-12-02T14:30:08.757Z
Learnt from: CR
Repo: miquido/draive PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T14:30:08.757Z
Learning: Applies to src/draive/**/*.py : Use context scoping (`ctx.scope(...)`) to bind scoped `Disposables`, active `State` instances, and avoid global state

Applied to files:

  • src/draive/__init__.py
🔇 Additional comments (3)
pyproject.toml (1)

8-8: LGTM!

Patch version bump is appropriate for this additive, non-breaking change that exposes a missing Disposables export.

src/draive/__init__.py (2)

239-241: LGTM!

The "Disposables" entry is correctly added to __all__ in alphabetical order, consistent with the import addition above.


22-24: LGTM!

The Disposables import is correctly placed in alphabetical order after Disposable. This aligns with the project's convention of centralizing public exports in this file. The import is actively used throughout the codebase (e.g., in stages/stage.py and mcp/server.py) with the async context manager pattern.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@KaQuMiQ KaQuMiQ merged commit 8a869ca into main Jan 13, 2026
2 of 3 checks passed
@KaQuMiQ KaQuMiQ deleted the feature/exports branch January 13, 2026 15:33
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