Skip to content

fix(sessions): Enable shared session delivery by default - #6588

Open
mmabrouk wants to merge 1 commit into
release/v0.115.1from
fix/release-1151-m2-defaults
Open

fix(sessions): Enable shared session delivery by default#6588
mmabrouk wants to merge 1 commit into
release/v0.115.1from
fix/release-1151-m2-defaults

Conversation

@mmabrouk

@mmabrouk mmabrouk commented Sep 5, 2026

Copy link
Copy Markdown
Member

Context

A deployment without session feature overrides still used the older delivery path, even after upgrading to v0.115.1. The shared session reader, durable record sequencing and runner live frames were disabled by default.

Changes

Default AGENTA_SESSIONS_SHARED_READER, AGENTA_SESSIONS_SEQUENCE_WRITES and AGENTA_RUNNER_LIVE_FRAMES to true. Explicit false still disables each feature. Align Docker Compose runner fallbacks and the environment/Helm examples with those defaults.

How to review

Start with the two API configuration defaults and the runner flag parser, then check the Compose fallbacks. The tests cover unset, empty and explicit values; the persistence test now distinguishes the live batch from durable records.

Tests

  • API configuration suite: 19 passed.
  • Runner live-frame and persistence suites: 34 passed.
  • Runner TypeScript check, Python formatting/lint and diff whitespace checks passed.

Apply the release's existing database migrations before starting the new API. This PR adds no migration or runtime behavior beyond the three defaults.

@vercel

vercel Bot commented Sep 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
agenta-documentation Ready Ready Preview Sep 5, 2026 10:12pm UTC

Request Review

@mmabrouk

mmabrouk commented Sep 5, 2026

Copy link
Copy Markdown
Member Author

🤖 The AI agent says: The three defaults are enabled, explicit false overrides remain supported, and focused API/runner tests and checks passed. The follow-up is ready for review; it has not been merged. @coderabbitai review

@coderabbitai

coderabbitai Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Important

Review skipped

No new commits to review since the last review.

⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Team

Run ID: 20dbf717-090f-42e1-b086-d5e0678e6ebe

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Summary

Summary by CodeRabbit

  • New Features

    • Live runner frames are now enabled by default across Docker Compose and Helm deployments.
    • Session coordination features, including shared reading and sequence writes, are enabled by default.
    • These features can still be disabled through their respective environment settings.
  • Documentation

    • Environment and deployment configuration examples now reflect the enabled-by-default behavior and explain how to disable these features.
  • Tests

    • Added coverage confirming default behavior and configuration overrides for live frames and session coordination.

Walkthrough

The change enables session coordination features and runner live-frame publishing by default. Environment variables still allow explicit disabling. Docker Compose, Helm, and environment examples now document the enabled-by-default behavior.

Changes

Session feature defaults

Layer / File(s) Summary
Redis session defaults
api/oss/src/utils/env.py, api/oss/tests/pytest/unit/utils/test_env_runner_config.py
sequence_writes and shared_reader default to true. Tests cover unset, empty, and explicit environment values.
Live-frame runtime behavior
services/runner/src/sessions/live-frames.ts, services/runner/tests/unit/*
Live-frame publishing defaults to enabled. Tests validate default publishing and exclude live batches when checking persisted records.
Deployment configuration defaults
hosting/docker-compose/*, hosting/kubernetes/helm/*
Docker Compose and Helm defaults enable live frames. Environment examples enable live frames, shared-reader mode, and sequence writes, and document explicit disabling.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Merge Risk: 🔵 Low · up to e074a

This change enables shared session delivery, sequenced writes, and runner live frames by default while retaining false overrides. The runtime behavior is covered for default and explicit values, but the session-default regression test can miss swapped configuration inputs, leaving a bounded configuration-correctness risk before merge.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 60.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 5 files. (13 skipped: 1… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly identifies the primary change: enabling shared session delivery by default. It is concise and directly related to the changeset.
Description check ✅ Passed The description accurately explains the default changes, preserved overrides, configuration updates, tests, and migration requirement.
Full details: Docstring Coverage

Explanation

Docstring coverage is 0.00% which is insufficient. The required threshold is 60.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 5 files. (13 skipped: 13 unsupported.)

✨ Finishing Touches 💡 2
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/release-1151-m2-defaults

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Team

Run ID: e60b468d-6b77-4201-9d02-5d48758e71b6

📥 Commits

Reviewing files that changed from the base of the PR and between 2528652 and e074a54.

📒 Files selected for processing (18)
  • api/oss/src/utils/env.py
  • api/oss/tests/pytest/unit/utils/test_env_runner_config.py
  • hosting/docker-compose/ee/docker-compose.dev.yml
  • hosting/docker-compose/ee/docker-compose.gh.local.yml
  • hosting/docker-compose/ee/docker-compose.gh.yml
  • hosting/docker-compose/ee/env.ee.dev.example
  • hosting/docker-compose/ee/env.ee.gh.example
  • hosting/docker-compose/oss/docker-compose.dev.yml
  • hosting/docker-compose/oss/docker-compose.gh.local.yml
  • hosting/docker-compose/oss/docker-compose.gh.ssl.yml
  • hosting/docker-compose/oss/docker-compose.gh.yml
  • hosting/docker-compose/oss/env.oss.dev.example
  • hosting/docker-compose/oss/env.oss.gh.example
  • hosting/kubernetes/helm/values.schema.json
  • hosting/kubernetes/helm/values.yaml
  • services/runner/src/sessions/live-frames.ts
  • services/runner/tests/unit/live-frames.test.ts
  • services/runner/tests/unit/session-persist.test.ts

Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review.

Comment on lines +117 to +118
@pytest.mark.parametrize(
"configured, expected", [(None, True), ("", True), ("true", True), ("false", False)]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Cover independent overrides in the regression test.

The test assigns the same value to AGENTA_SESSIONS_SHARED_READER and AGENTA_SESSIONS_SEQUENCE_WRITES for every case. A regression that reads the wrong variable can therefore pass all assertions. Add mixed cases such as shared_reader=false, sequence_writes=true and the reverse, then assert both fields independently.

@coderabbitai

coderabbitai Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

@mmabrouk I will review the changes in #6588.

⚠️ Action not completed

Already reviewed the last commit. Use @coderabbitai full review to rerun a review of the entire changeset.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Railway Preview Environment

Preview URL https://gateway-pr-6588.up.railway.app/w
Project agenta-oss-clone-spike
Image tag pr-6588-fdec6fe
Status Deployed
Railway logs Open logs
Workflow logs View workflow run
Updated at 2026-09-05T22:44:21.942Z

@mmabrouk

mmabrouk commented Sep 5, 2026

Copy link
Copy Markdown
Member Author

🤖 The AI agent says:

Closing this unmerged default-on change at Mahmoud's request. Release v0.115.1 retains false defaults for the shared reader, sequence writes, and runner live frames. Production EU and US secret values have also been set to false for the user's redeployment. The reader lifecycle and transcript fixes will target v0.115.2.

@mmabrouk mmabrouk closed this Sep 5, 2026
@mmabrouk mmabrouk reopened this Sep 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant