Upgrade dependencies#514
Open
jhump wants to merge 11 commits into
Open
Conversation
protobuf-es v2 no longer generates message classes: messages are plain objects and operations are top-level functions that take a generated schema descriptor. connect-es v2 drops its own code generator, so service descriptors now come from protoc-gen-es output. - Bump @bufbuild/protobuf, protoplugin and protoc-gen-es to v2, @connectrpc/* to v2, and the @buf knit SDK to its v2 build. Drop protoc-gen-connect-es and the connectrpc_es SDK. - Rewrite protoc-gen-knit-ts against the protoplugin v2 API (descriptor reflection, importShape/import, getOption for custom options). - Regenerate the knit-test-spec fixtures and remove the _connect files. - Migrate the client and gateway runtime to the v2 reflection and serialization APIs. Replace the gateway's Schema message augmentation with internal types, since v2 messages are type aliases and can no longer be augmented via declaration merging. - Bump TypeScript to v6, which protobuf-es v2's typings require.
Rename the turbo.json `pipeline` key to `tasks`, as required by turbo 2.
Bump jest to v30 and ts-jest to 29.4.x. ts-jest's ESM mode now requires an ES module kind, so override `module` for ts-jest in the knit jest config (the shared tsconfig targets CommonJS for the published build).
ESLint 9+ requires the flat config format, so migrate the shared eslint-config-custom package and the per-package configs from eslintrc to flat config, and move from @typescript-eslint v6 to the typescript-eslint v8 meta-package. - Rewrite eslint-config-custom as a flat config array (@eslint/js, typescript-eslint recommendedTypeChecked, turbo, prettier, and the notice license-header rule). The legacy eslint-plugin-notice is shimmed with @eslint/compat for ESLint 10. - Replace each package's .eslintrc with eslint.config.mjs. - Preserve the existing rule set. Two options are tuned to match the prior effective behavior (switch-exhaustiveness-check's default-clause handling), and rules new to v8 that were not previously enforced are left off. - Drop now-redundant type assertions that the upgraded rules flag. - Exclude the generated buf/ directory from prettier, matching spec/.
Update @eslint/js and globals to their latest versions.
Move @buf/bufbuild_knit.bufbuild_es to the 20250213 commit. The only proto delta from the previous pin is an added go_package file option, so the generated TypeScript and runtime behavior are unchanged.
These rules are part of typescript-eslint v8's recommendedTypeChecked preset. prefer-promise-reject-errors surfaced no issues. only-throw-error flagged the throws of KnitError, which is intentionally a structured domain type (it is also returned as an embedded value under the `@catch` error strategy, so it is deliberately not an Error subclass); allow it explicitly rather than disabling the rule.
The protoc-gen-knit-ts README still showed v1 buf.gen.yaml templates and the old dotted import_extension values. Update the examples to the v2 buf.gen.yaml format (remote:/local: plugins) and the v2 option values (import_extension=js, import_extension=ts). The client/query/result docs were unaffected.
- Correct the JSON.stringify typo in the client examples. - Fix the protoc invocation flags to --knit-ts_out / --knit-ts_opt. - Correct the relations example to import buf/knit/v1alpha1/options.proto and reference the buf.knit.v1alpha1.relation option. - Point the knit package license link at this repository.
protobuf-es v2 provides DescMethodUnary and DescMethodServerStreaming, so the custom mapped type is no longer needed. Inline the method-name filter on the service options using those types and drop the standalone export (and its type-level test).
timostamm
approved these changes
Jun 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I had Claude tackle all of the incompatibilities with new dependencies that are blocking the 11 outstanding depend-a-bot PRs. It made short work of them, even including the upgrade to @bufbuild/protobuf and @connectrpc/connect v2.
Resolves #353, #354, and #355.