Skip to content

Conversation

@cbornet
Copy link
Contributor

@cbornet cbornet commented May 30, 2022

Motivation

Protobuf latest 4.21 version broke compatibility with files generated with protoc < 3.19
As a result all current CI tests fail.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

Modifications

This fix downgrades protobuf python package to 3.20.1.

Verifying this change

  • Make sure that the change passes the CI checks.

This change is a trivial rework / code cleanup without any test coverage.

Does this pull request potentially affect one of the following parts:

no

If yes was chosen, please highlight the changes

  • Dependencies (does it add or upgrade a dependency): (yes / no)
  • The public API: (yes / no)
  • The schema: (yes / no / don't know)
  • The default values of configurations: (yes / no)
  • The wire protocol: (yes / no)
  • The rest endpoints: (yes / no)
  • The admin cli options: (yes / no)
  • Anything that affects deployment: (yes / no / don't know)

Documentation

Check the box below or label this PR directly.

Need to update docs?

  • doc-required
    (Your PR needs to update docs and you will update later)

  • doc-not-needed
    fix

  • doc
    (Your PR contains doc changes)

  • doc-complete
    (Docs have been already added)

…atest protobuf package

Protobuf latest 4.21 version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06
@github-actions github-actions bot added the doc-not-needed Your PR changes do not impact docs label May 30, 2022
@cbornet cbornet changed the title [fix][python]Fix generated Python protobuf code not compatible with l… [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package May 30, 2022
Copy link
Contributor

@hangc0276 hangc0276 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job!

Copy link
Member

@zymap zymap left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we regenerate the code to support the latest protobuf?

@lhotari
Copy link
Member

lhotari commented May 31, 2022

Shouldn't we regenerate the code to support the latest protobuf?

@zymap I suppose you are referring to #15827. That makes sense. However, this PR doesn't conflict with that and there's no reason to block this PR with requesting changes. Let's keep the PRs separate.

@zymap
Copy link
Member

zymap commented May 31, 2022

Make sense to me

@lhotari lhotari force-pushed the fix-python-protobuf branch from 7614503 to 78c976b Compare May 31, 2022 04:46
@lhotari
Copy link
Member

lhotari commented May 31, 2022

I added another commit to this PR to limit the version to 3.20.* in setup.py for the Pulsar Python client's dependencies. This would be a useful fix also for maintenance branches.

Copy link
Contributor

@eolivelli eolivelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great catch!

@lhotari
Copy link
Member

lhotari commented May 31, 2022

@zymap Why did you restart all tests and not just the failed ones? I'm taking care of the restarts and investigating any flakiness issues, so please don't restart the failed builds for this PR. In general, it's a bad practice to restart failed builds without investigating and reporting the flaky tests.

@zymap
Copy link
Member

zymap commented May 31, 2022

Sorry it’s my fault. I wanted to rerun the failed test but accidentally clicked the wrong one

Copy link
Contributor

@codelipenghui codelipenghui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice fix!

@Technoboy- Technoboy- added this to the 2.11.0 milestone May 31, 2022
@lhotari lhotari merged commit 7800fbd into apache:master May 31, 2022
@cbornet cbornet deleted the fix-python-protobuf branch May 31, 2022 09:32
lhotari added a commit that referenced this pull request May 31, 2022
…atest protobuf package (#15846)

* [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package
Protobuf latest 4.21 (v21) version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

* Limit protobuf version to 3.20.* in setup.py

Co-authored-by: Lari Hotari <lhotari@apache.org>
(cherry picked from commit 7800fbd)
lhotari added a commit that referenced this pull request May 31, 2022
…atest protobuf package (#15846)

* [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package
Protobuf latest 4.21 (v21) version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

* Limit protobuf version to 3.20.* in setup.py

Co-authored-by: Lari Hotari <lhotari@apache.org>
(cherry picked from commit 7800fbd)
(cherry picked from commit 7fb23cf)
lhotari added a commit that referenced this pull request May 31, 2022
…atest protobuf package (#15846)

* [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package
Protobuf latest 4.21 (v21) version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

* Limit protobuf version to 3.20.* in setup.py

Co-authored-by: Lari Hotari <lhotari@apache.org>
(cherry picked from commit 7800fbd)
(cherry picked from commit 7fb23cf)
lhotari added a commit that referenced this pull request May 31, 2022
…atest protobuf package (#15846)

* [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package
Protobuf latest 4.21 (v21) version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

* Limit protobuf version to 3.20.* in setup.py

Co-authored-by: Lari Hotari <lhotari@apache.org>
(cherry picked from commit 7800fbd)
(cherry picked from commit 7fb23cf)
@lhotari lhotari added cherry-picked/branch-2.7 Archived: 2.7 is end of life cherry-picked/branch-2.8 Archived: 2.8 is end of life cherry-picked/branch-2.9 Archived: 2.9 is end of life release/2.7.5 cherry-picked/branch-2.10 labels May 31, 2022
nicoloboschi pushed a commit to datastax/pulsar that referenced this pull request Jun 1, 2022
…atest protobuf package (apache#15846)

* [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package
Protobuf latest 4.21 (v21) version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

* Limit protobuf version to 3.20.* in setup.py

Co-authored-by: Lari Hotari <lhotari@apache.org>
(cherry picked from commit 7800fbd)
(cherry picked from commit 7fb23cf)
nicoloboschi pushed a commit to datastax/pulsar that referenced this pull request Jun 1, 2022
…atest protobuf package (apache#15846)

* [fix][python]Fix generated Python protobuf code not compatible with latest protobuf package
Protobuf latest 4.21 (v21) version broke compatibility with files generated with protoc < 3.19
This fix downgrades protobuf python package to 3.20.1.
See https://developers.google.com/protocol-buffers/docs/news/2022-05-06

* Limit protobuf version to 3.20.* in setup.py

Co-authored-by: Lari Hotari <lhotari@apache.org>
(cherry picked from commit 7800fbd)
(cherry picked from commit 7fb23cf)
(cherry picked from commit 945cc75)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants