Skip to content

Conversation

@mstoykov
Copy link
Contributor

What?

Fix very likely most usage of gRPC module.

Why?

The bug makes a lot of gRPC usage practically impossible, making this a bigger issue than it might first seem.

Checklist

  • I have performed a self-review of my code.
  • I have commented on my code, particularly in hard-to-understand areas.
  • I have added tests for my changes.
  • I have run linter and tests locally (make check) and all pass.

Checklist: Documentation (only for k6 maintainers and if relevant)

Please do not merge this PR until the following items are filled out.

  • I have added the correct milestone and labels to the PR.
  • I have updated the release notes: link
  • I have updated or added an issue to the k6-documentation: grafana/k6-docs#NUMBER if applicable
  • I have updated or added an issue to the TypeScript definitions: grafana/k6-DefinitelyTyped#NUMBER if applicable

Related PR(s)/Issue(s)

After #5017 turned out that k6 does not propagate the types it loads when making gRPC calls. This means that in many of the cases the globalTypes will be used, which will lead to errors.

This likely is not just around Any but is how it was reported.

This commit goes and propagates the types in each place where 
they will be marshaled/unmarshalled.

The added test is not perfect, but does catch the problem without
needing #4981 which I would expect would've also caught this.
As currently the server will load the prototypes in the global types
and k6/net/grpc will load them in their local types.
And then they will technically work.
@mstoykov mstoykov added this to the v1.2.3 milestone Aug 26, 2025
@mstoykov mstoykov requested a review from a team as a code owner August 26, 2025 08:01
@mstoykov mstoykov requested review from AgnesToulet and joanlopez and removed request for a team August 26, 2025 08:01
@mstoykov mstoykov merged commit 6a20768 into v1.2.x Aug 26, 2025
43 of 44 checks passed
@mstoykov mstoykov deleted the backport5089 branch August 26, 2025 13:07
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.

3 participants