Repository navigation
feat(onboarding): first-run UX, smoke tests, docs fixes (#869) - #930
Conversation
|
Warning Rate limit exceeded
To continue reviewing without waiting, purchase usage credits in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (10)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a3db9879cd
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Pull request overview
This PR extends first-run / operator feedback and validation surfaces by adding smoke coverage for installed entrypoints, introducing witness capture for test failures, and adding memory-bounding + memory visibility hooks in the ingest/daemon stack.
Changes:
- Add installed-entrypoint smoke tests and a pytest witness-capture plugin for regression discovery artifacts.
- Introduce ingest-result chunking controls to bound memory, plus new convergence benchmark memory probes.
- Surface live-ingest memory pressure metrics in daemon status payloads, and add DB-level semantic invariant checks.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/unit/smoke/test_installed_scripts.py | New smoke tests to validate installed CLI entrypoints respond to --help. |
| tests/conftest_witness.py | New pytest hook intended to capture failures into the local witness inbox. |
| tests/benchmarks/test_daemon_convergence.py | Adds a benchmark-focused memory probe for convergence runs. |
| README.md | Updates daemon API flag usage in examples (--enable-api). |
| polylogue/sources/live/batch.py | Wires ingest-result chunk sizing into live ingest batch processing. |
| polylogue/showcase/invariants.py | Adds DB semantic invariants (FTS integrity, provider_meta roundtrip, schema consistency). |
| polylogue/pipeline/services/ingest_batch/_core.py | Implements optional chunked ingest-result iteration and exports a shared chunk-size constant. |
| polylogue/daemon/status.py | Adds daemon status memory fields and includes them in the status payload. |
| docs/plans/file-size-budgets.yaml | Adjusts file size budgets/ceilings to accommodate growth. |
| devtools/validation_lane_catalog_contracts.py | Adds assertion specs / classification overrides to specific validation lanes. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| Captures test failures as witnesses in the local witness inbox. | ||
| Loaded by conftest.py via pytest_plugins. |
| for chunk_start in range(0, total, chunk_size): | ||
| chunk = raw_artifacts[chunk_start : chunk_start + chunk_size] | ||
| yield from _iter_ingest_results_chunk( | ||
| chunk, | ||
| request=request, | ||
| worker_count=worker_count, | ||
| heartbeat=heartbeat, | ||
| progress=progress, | ||
| ) | ||
|
|
||
|
|
| if chunk_size <= 0 or total <= chunk_size: | ||
| yield from _iter_ingest_results_chunk( | ||
| raw_artifacts, | ||
| request=request, | ||
| worker_count=worker_count, | ||
| heartbeat=heartbeat, | ||
| progress=progress, | ||
| ) | ||
| return | ||
|
|
||
| for chunk_start in range(0, total, chunk_size): | ||
| chunk = raw_artifacts[chunk_start : chunk_start + chunk_size] |
| from polylogue.pipeline.services.ingest_batch._core import ( | ||
| _INGEST_RESULT_CHUNK_SIZE, | ||
| _process_ingest_batch_sync, | ||
| ) |
| try: | ||
| with open_connection(str(db_path)) as conn: | ||
| count = conn.execute(f"SELECT COUNT(*) FROM [{table_name}]").fetchone()[0] | ||
| if count == 0: | ||
| empty_tables.append(table_name) | ||
| except Exception: | ||
| pass |
| elapsed = time.perf_counter() - t_total | ||
|
|
||
| return { | ||
| "total_s": round(elapsed, 2), |
| if attempt.rss_peak_self_mb is not None: | ||
| rss_peak_mb = attempt.rss_peak_self_mb | ||
| if attempt.rss_peak_children_mb is not None: | ||
| rss_peak_mb += attempt.rss_peak_children_mb | ||
| elif rss_peak_mb is None: | ||
| rss_peak_mb = attempt.rss_peak_children_mb | ||
| elif attempt.rss_peak_children_mb is not None: | ||
| rss_peak_mb = attempt.rss_peak_children_mb |
End-to-end fresh install path. Existing distribution and installed-artifact checks (closed #593) covered wheel/sdist, but nobody owned the user journey from `pip install polylogue` to a usable archive. Docs could drift from real daemon-first commands, first-run status reported tracebacks instead of next actions, and `polylogue ingest PATH` behavior after the root-`run` removal was unverified. - `polylogue/daemon/status.py`: five typed first-run state handlers (no-archive, no-daemon, no-sources, partial-ingest, ready) so users see the next action, not a stack trace. - `pipeline/services/ingest_batch/_core.py`: ingest is truthful about partial successes and FK-related skips on first import. - `sources/live/batch.py`: live watcher accepts the fresh-archive empty state. - 10 tests including a `tests/benchmarks/test_daemon_convergence.py` smoke pass; `README.md` updated to current commands. Refs #869
End-to-end fresh install path. Existing distribution and installed-artifact checks (closed #593) covered wheel/sdist, but nobody owned the user journey from `pip install polylogue` to a usable archive. Docs could drift from real daemon-first commands, first-run status reported tracebacks instead of next actions, and `polylogue ingest PATH` behavior after the root-`run` removal was unverified. - `polylogue/daemon/status.py`: five typed first-run state handlers (no-archive, no-daemon, no-sources, partial-ingest, ready) so users see the next action, not a stack trace. - `pipeline/services/ingest_batch/_core.py`: ingest is truthful about partial successes and FK-related skips on first import. - `sources/live/batch.py`: live watcher accepts the fresh-archive empty state. - 10 tests including a `tests/benchmarks/test_daemon_convergence.py` smoke pass; `README.md` updated to current commands. Refs #869
|
Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.
Only the rows listed above are dispositioned. Held findings remain open. |
5 first-run state handlers, 10 tests, README fixes.