Skip to content

feat(api): consolidate temporal-context stored-request GET and CLI - #464

Draft
seonghobae wants to merge 3 commits into
feat/temporal-context-retrieval-get-gap-003afrom
feat/temporal-context-stored-request-cli-gap-003a
Draft

feat(api): consolidate temporal-context stored-request GET and CLI#464
seonghobae wants to merge 3 commits into
feat/temporal-context-retrieval-get-gap-003afrom
feat/temporal-context-stored-request-cli-gap-003a

Conversation

@seonghobae

@seonghobae seonghobae commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Consolidated landing vehicle

This PR folds predecessor #463 into one LineageWeave-facing Analysis Run / temporal-context application-adapter vehicle. The current head contains #463 as its direct ancestor; retargeting to #463's former base preserves the stored-request GET implementation and tests while eliminating one open micro-PR. #463 remains available as immutable review/history evidence.

Preserved GET behavior from #463: /v1/temporal-context/{idempotency_key}/request extra-segment parsing, hostile identity/body/consumer refusals, LineageWeave-only ownership, metric-free output, temporal_association_only semantics, and focused HTTP/retrieval tests.

CLI behavior on this head: published tepp-temporal-context-request get, empty-stdin admission, public-bind/localhost/http-origin/credential/consumer/identity refusals, stored-request rendering, and the external real-127.0.0.1 TCP contract test added after review. NaruonLiveService remains POST-only.

This is an application/adapter landing vehicle, not a bounded context. ADR 0091/0092 are implementation lineage pending #437 normalization. Further compatible temporal-context route/CLI mechanics should fold into this vehicle or its coherent successor rather than opening one-operation PRs.

Merge only after fresh exact-head hosted checks, resolved review threads, and the live ruleset's qualifying independent approval. No predecessor-head evidence transfer or bypass.

… GET

GAP-003A unique slice: GET /v1/temporal-context/{idempotency_key}/request returns the accepted LineageWeave create request on AnalysisRunLiveService / tepp-loopback. Metric-free of RMSE/tepp.scientific_acceptance.v1. inference_status remains temporal_association_only. Naruon refused. NaruonLiveService stays POST-only. ADR 0091.
@coderabbitai

coderabbitai Bot commented Sep 1, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 6597df87-68ff-43c1-b283-ec014b07701d

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

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.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Note

This report is out of date. Scroll down for Devin Review's latest report on this PR.

Devin Review found 2 potential issues.

Devin Review

Comment thread crates/tepp_api/src/temporal_context_stored_request_cli.rs
Comment on lines +340 to +341
let bytes = read_bounded(&mut stream, MAXIMUM_HTTP_RESPONSE_BYTES)?;
parse_http_response(&bytes)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

📝 Info: EOF framing matches listener lifetime

read_bounded waits for EOF, but the bundled listener closes each connection after one response. Successful reads therefore complete before the timeout.

Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Note

This report is out of date. Scroll down for Devin Review's latest report on this PR.

Devin Review found 1 new potential issue.

Devin Review

Comment on lines +27 to +32
let mut request_bytes = [0_u8; 4096];
let received = stream.read(&mut request_bytes).expect("read request");
let request = std::str::from_utf8(&request_bytes[..received]).expect("utf8 request");
assert!(request.starts_with("GET /v1/temporal-context/idem-tcp/request HTTP/1.1\r\n"));
assert!(request.contains("tepp-consumer: lineageweave\r\n"));
assert!(request.contains("content-length: 0\r\n\r\n"));

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔍 TCP fragmentation can fail the test

A single read can return only part of the request. Valid executions then fail header assertions nondeterministically.

Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@seonghobae seonghobae changed the title feat(api): mint temporal-context stored-request GET from a dedicated CLI feat(api): consolidate temporal-context stored-request GET and CLI Sep 1, 2026
@seonghobae
seonghobae changed the base branch from feat/temporal-context-stored-request-get-gap-003a to feat/temporal-context-retrieval-get-gap-003a September 1, 2026 16:03

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Devin Review found 1 new potential issue.

Devin Review

Comment on lines +254 to +262
let consumer = require_headers(headers, self.bound_addr, false)?;
if consumer != LINEAGEWEAVE_CONSUMER_CODE {
return Err(ApiError::InvalidWirePayload);
}
let replay_key = format!("{consumer}\u{1f}{idempotency_key}");
let (stored_request, projection) = self
.accepted_temporal_contexts
.get(&replay_key)
.ok_or(ApiError::InvalidWirePayload)?;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟥 Stored requests lack caller authentication

Any local process knowing an idempotency key can retrieve the original request. Event labels and actor references are exposed without caller authentication.

Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@seonghobae seonghobae left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

exact-head COMMENT only (not APPROVE) on 1b3a477242336634be2c7867b29d39979e9a6dca. Devin COMMENTED is not independent APPROVE.

Unique remains tepp-temporal-context-request + ADR 0092 (GET /v1/temporal-context/{idempotency_key}/request). LineageWeave stored-request GET after validate_temporal_context_registry_identity; Naruon refused; NaruonLiveService stays POST-only. Metric/causal keys stay in FORBIDDEN_STORED_REQUEST_KEYS. Do not duplicate this surface. Do not ship a second temporal-context stored-request GET/CLI. Do not treat consumer-only scoping as a tenant oracle. Do not un-quarantine export stored-request-by-client-key (that is ADR 0099 on #466, not this adapter).

Still draft. Do not un-draft. Zero exact-head APPROVEs. Do not merge without two independent current-head APPROVEs under ruleset 18156473. #451 CLOSED — do not reopen.

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