Skip to content
New issue

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

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

Already on GitHub? # to your account

fix: trim the trailing params in SourcePRURL #17

Merged
merged 3 commits into from
Jun 19, 2023

Conversation

ran-huang
Copy link
Contributor

Problem:

When you run create translate PR on a PR page with a complicated URL (such as https://github.com/pingcap/docs-cn/pull/13637/files#diff-bd6f4007c98142e46e6906361bc0cabc0f45a5be07136472602de9a84156c393R24-R28), the created translate PR will have all the trailing params in its description.

For example:
image

Fix:
This fix removes anything that comes after the pr number so that the source PR URL is clean.

ran-huang and others added 2 commits June 16, 2023 14:41
Signed-off-by: Ran <huangran.alex@gmail.com>
Signed-off-by: Aolin <aolin.zhang@pingcap.com>
@Oreoxmt
Copy link
Owner

Oreoxmt commented Jun 16, 2023

@ran-huang 👋🏼 Thanks for your work on improving the URL handling in the CreateTransPR function. I have reviewed this PR and created a patch ran-huang#1 with some modifications that I think could be more compatible with future releases and updates. PTAL

@ran-huang
Copy link
Contributor Author

@ran-huang 👋🏼 Thanks for your work on improving the URL handling in the CreateTransPR function. I have reviewed this PR and created a patch ran-huang#1 with some modifications that I think could be more compatible with future releases and updates. PTAL

I have reviewed your patch and it looks excellent!

make sure the pr number does not include #... (Oreoxmt#11)
@Oreoxmt Oreoxmt merged commit 13d2a4b into Oreoxmt:main Jun 19, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants