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

test(dm): update python2 to python3 #7533

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

lance6716
Copy link
Contributor

Signed-off-by: lance6716 lance6716@gmail.com

What problem does this PR solve?

Issue Number: ref #4159

What is changed and how it works?

CI base image does not pre-install requests library, and this library does not support python2 now. We might always use python3 for integration tests

Check List

Tests

  • No code

Questions

Will it cause performance regression or break compatibility?
Do you need to update user documentation, design documentation or monitoring documentation?

Release note

`None`.

Signed-off-by: lance6716 <lance6716@gmail.com>
@ti-chi-bot
Copy link
Member

[REVIEW NOTIFICATION]

This pull request has not been approved.

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added the release-note-none Denotes a PR that doesn't merit a release note. label Nov 4, 2022
@lance6716
Copy link
Contributor Author

/cc @purelind

@ti-chi-bot ti-chi-bot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Nov 4, 2022
@lance6716
Copy link
Contributor Author

/run-dm-integration-test

@purelind
Copy link
Collaborator

purelind commented Nov 7, 2022

/run-dm-integration-test

@purelind
Copy link
Collaborator

purelind commented Nov 7, 2022

/run-dm-integration-test

need fix UnicodeEncodeError in python3

[2022-11-07T07:28:28.217Z] get_illegal_char_task_status_failed resp= Traceback (most recent call last):

[2022-11-07T07:28:28.217Z]   File "/home/jenkins/agent/workspace/dm_ghpr_integration_test/go/src/github.com/pingcap/tiflow/dm/tests/openapi/client/openapi_task_check", line 736, in <module>

[2022-11-07T07:28:28.217Z]     func(*sys.argv[2:])

[2022-11-07T07:28:28.217Z]   File "/home/jenkins/agent/workspace/dm_ghpr_integration_test/go/src/github.com/pingcap/tiflow/dm/tests/openapi/client/openapi_task_check", line 360, in get_illegal_char_task_status_failed

[2022-11-07T07:28:28.217Z]     print("get_illegal_char_task_status_failed resp=", resp.json())

[2022-11-07T07:28:28.217Z] UnicodeEncodeError: 'ascii' codec can't encode character '\xcb' in position 120: ordinal not in range(128)

@lance6716
Copy link
Contributor Author

/run-dm-integration-test

need fix UnicodeEncodeError in python3

[2022-11-07T07:28:28.217Z] get_illegal_char_task_status_failed resp= Traceback (most recent call last):

[2022-11-07T07:28:28.217Z]   File "/home/jenkins/agent/workspace/dm_ghpr_integration_test/go/src/github.com/pingcap/tiflow/dm/tests/openapi/client/openapi_task_check", line 736, in <module>

[2022-11-07T07:28:28.217Z]     func(*sys.argv[2:])

[2022-11-07T07:28:28.217Z]   File "/home/jenkins/agent/workspace/dm_ghpr_integration_test/go/src/github.com/pingcap/tiflow/dm/tests/openapi/client/openapi_task_check", line 360, in get_illegal_char_task_status_failed

[2022-11-07T07:28:28.217Z]     print("get_illegal_char_task_status_failed resp=", resp.json())

[2022-11-07T07:28:28.217Z] UnicodeEncodeError: 'ascii' codec can't encode character '\xcb' in position 120: ordinal not in range(128)

I can pass this test in my Python 3.10.8 local environment

@lance6716
Copy link
Contributor Author

UnicodeEncodeError

@purelind and after some searching, this more often happens in python2 not python3 🤔

@purelind
Copy link
Collaborator

purelind commented Nov 7, 2022

I just test this in Python 3.6.8 and will test in Python 3.10.8 later

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note-none Denotes a PR that doesn't merit a release note. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants