Skip to content

Commit ff718a1

Browse files
committed
fix: enable --experimental_editions in protoc
When protoc compiles proto files that use the experimental Editions feature (like google/showcase/v1beta1/testing.proto), it throws a fatal error unless the --experimental_editions flag is explicitly passed. This commit updates the generator to always pass this flag to protoc, ensuring it doesn't crash when encountering these newer proto files now that we are relying on the system protoc (v25+).
1 parent 98d0c01 commit ff718a1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

core/generator/gapic-generator-typescript/typescript/src/gapic-generator-typescript.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,7 @@ async function main(processArgv: string[]) {
201201
const protocCommand = [
202202
`--plugin=protoc-gen-typescript_gapic=${protocPlugin}`,
203203
`--typescript_gapic_out=${outputDir}`,
204+
`--experimental_editions`,
204205
];
205206
if (gapicValidatorOut && validation === 'true') {
206207
protocCommand.push(`--gapic-validator_out=${gapicValidatorOut}`);

0 commit comments

Comments
 (0)