Skip to content

Conversation

@collinvandyck
Copy link

@collinvandyck collinvandyck commented Nov 18, 2025

What changed?

This fixes an issue in the JSONPBEncoder which does not close the opening [ with a ] when encoding an empty slice. The fix was to move the line which emitted ] outside of the for loop.

Why?

While working on another project which uses the JSONPBEncoder I saw that an empty slice was getting encoded as [.

How did you test it?

  • built
  • run locally and tested manually
  • covered by existing tests
  • added new unit test(s)
  • added new functional test(s)

Potential risks

I'm not too familiar with the OSS temporal code, but I would not imagine there would be anything that would be dependent on invalid json being emitted.

@collinvandyck collinvandyck requested review from a team as code owners November 18, 2025 14:50
@CLAassistant
Copy link

CLAassistant commented Nov 18, 2025

CLA assistant check
All committers have signed the CLA.

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