Files
codex/bazel/schema/BUILD.bazel
T
jif b75d1e8966 Use a dedicated binary for Bazel schema generation (#58083)
## Why

The schema exporter sits on application builds' critical path, but compiling it as a test harness also compiles and registers unit tests that schema generation does not need.

## What changed

Build the exporter with `--cfg=test` to retain test-only schema derives without the test harness, and disable its debug metadata. Run schema generation directly on a thread with an 8 MiB stack.

Share the environment-driven schema writer with the existing ignored test, allow a configurable crate root in `schema_sources`, and switch the public schema bundle to the dedicated generator.

GitOrigin-RevId: 317e24f77e153b9ba0c5c583837eed3bcd3774fd
2026-10-29 13:37:06 +00:00

24 lines
573 B
Python

load("//bazel/rules:schema_bundle.bzl", "schema_bundle")
schema_bundle(
name = "public-schema-bundle",
testonly = True,
generator = "//codex-rs/app-server-protocol:schema-generator-on-demand",
tags = ["manual"],
)
schema_bundle(
name = "app-server",
generator = "//codex-rs/app-server-protocol:schema-generator-on-demand",
tags = ["manual"],
visibility = ["//visibility:public"],
)
filegroup(
name = "stable",
srcs = [":app-server"],
output_group = "stable",
tags = ["manual"],
visibility = ["//visibility:public"],
)