Skip to content

Commit 6cd5b44

Browse files
committed
Revert "Andrewmwells/protobufs (#1277)"
This reverts commit 6b16db5. Signed-off-by: Shaobo He <[email protected]>
1 parent 01c34e3 commit 6cd5b44

File tree

26 files changed

+0
-2976
lines changed

26 files changed

+0
-2976
lines changed

.github/workflows/build_and_test.yml

-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ jobs:
1818

1919
steps:
2020
- uses: actions/checkout@v4
21-
- run: sudo apt-get install protobuf-compiler
2221
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
2322
- run: ./panic_safety.sh
2423
- run: cargo doc --all-features --no-deps
@@ -44,7 +43,6 @@ jobs:
4443

4544
steps:
4645
- uses: actions/checkout@v4
47-
- run: sudo apt-get install protobuf-compiler
4846
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
4947
# Clippy is configured by `.cargo/config.toml` to deny on lints like
5048
# `unwrap_used`. They aren't detected by `panic_safety.sh` which only

.github/workflows/ci.yml

-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ jobs:
4040
# `cargo semver-checks` doesn't understand `rlib` crates.
4141
- run: >-
4242
sed -i -E 's/^(crate-type = \["rlib", "cdylib"\]|crate-type = \["rlib"\])$/crate-type = ["lib"]/' {head,base}/cedar-policy/Cargo.toml
43-
- run: sudo apt-get install protobuf-compiler
4443
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
4544
- run: cargo install cargo-semver-checks
4645
- run: cargo semver-checks check-release --package cedar-policy --baseline-root ../base

cedar-policy-core/Cargo.toml

-6
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,6 @@ serde-wasm-bindgen = { version = "0.6", optional = true }
3737
tsify = { version = "0.4.5", optional = true }
3838
wasm-bindgen = { version = "0.2.82", optional = true }
3939

40-
# protobuf dependency
41-
prost = { version = "0.13.3", optional = true }
42-
4340
[features]
4441
# by default, enable all Cedar extensions
4542
default = ["ipaddr", "decimal"]
@@ -55,12 +52,9 @@ test-util = []
5552
# Experimental features.
5653
partial-eval = []
5754
wasm = ["serde-wasm-bindgen", "tsify", "wasm-bindgen"]
58-
protobufs = ["dep:prost", "dep:prost-build"]
5955

6056
[build-dependencies]
6157
lalrpop = "0.22.0"
62-
# protobuf dependency
63-
prost-build = { version = "0.13.3", optional = true }
6458

6559
[dev-dependencies]
6660
cool_asserts = "2.0"

cedar-policy-core/build.rs

-11
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616

1717
fn main() {
1818
generate_parsers();
19-
#[cfg(feature = "protobufs")]
20-
generate_schemas();
2119
}
2220

2321
/// Reads parser grammar files (.lalrpop) and generates Rust modules
@@ -28,12 +26,3 @@ fn generate_parsers() {
2826
.process_dir("src/parser/")
2927
.expect("parser synth");
3028
}
31-
32-
#[cfg(feature = "protobufs")]
33-
/// Reads protobuf schema files (.proto) and generates Rust modules
34-
fn generate_schemas() {
35-
// PANIC SAFETY: static file compiled at build time
36-
#[allow(clippy::expect_used)]
37-
prost_build::compile_protos(&["./protobuf_schema/AST.proto"], &["./protobuf_schema"])
38-
.expect("failed to compile `.proto` schema files");
39-
}

0 commit comments

Comments
 (0)