Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: fix python readMessageBegin return value type error #2879

Merged
merged 1 commit into from
Feb 25, 2024

Conversation

bwangelme
Copy link
Contributor

@bwangelme bwangelme commented Nov 6, 2023

What did this PR do?

In the function transport.TTransport.readAll, when the sz<0, the type of name is str.

But when the sz>0, the type of name is bytes.

They should return the same types.

I use the binary_to_str to convert the type of name

Test

I write a unittest method test_TBinaryProtocol_no_strict_write_read to test my changes. It passed.

  • Did you create an Apache Jira ticket? (Request account here, not required for trivial changes)
  • If a ticket exists: Does your pull request title follow the pattern "THRIFT-NNNN: describe my issue"?
  • Did you squash your changes to a single commit? (not required, but preferred)
  • Did you do your best to avoid breaking changes? If one was needed, did you label the Jira ticket with "Breaking-Change"?
  • If your change does not involve any code, include [skip ci] anywhere in the commit message to free up build resources.

@bwangelme bwangelme changed the title Fix: fix readMessageBegin return value name type error Fix: fix python readMessageBegin return value name type error Nov 6, 2023
@bwangelme bwangelme changed the title Fix: fix python readMessageBegin return value name type error Fix: fix python readMessageBegin return value type error Nov 6, 2023
@fishy fishy added the python label Nov 6, 2023
@Jens-G
Copy link
Member

Jens-G commented Nov 6, 2023

It is not a trivial change, so I didn't create an Apache Jira ticket.

Sorry but that gives no meaning.

@bwangelme
Copy link
Contributor Author

Sorry but that gives no meaning.

Ok, Delete it from the description.​

@bwangelme
Copy link
Contributor Author

bwangelme commented Nov 8, 2023

  • cross-test (java, go,rs) (pull_request)
  • cross-test (kotlin, go,rs) (pull_request)
  • cross-test (go, java,kotlin) (pull_request)
  • cross-test (rs, java,kotlin) (pull_request)
  • cross-test (rs, swift) (pull_request)
  • cross-test (rs, go,rs) (pull_request)
  • cross-test (swift, go,rs) (pull_request)

These ci are failed. It seems unrelated to my python changes.

@Jens-G Jens-G merged commit 58000cc into apache:master Feb 25, 2024
17 of 25 checks passed
@bwangelme bwangelme deleted the fix_type_error branch February 26, 2024 01:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants