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

Comment function modifies PR description instead of adding comment #12

Closed
Oreoxmt opened this issue May 25, 2023 · 0 comments · Fixed by #11
Closed

Comment function modifies PR description instead of adding comment #12

Oreoxmt opened this issue May 25, 2023 · 0 comments · Fixed by #11
Assignees
Labels
bug Something isn't working

Comments

@Oreoxmt
Copy link
Owner

Oreoxmt commented May 25, 2023

Issue:

When using the "comment" function in octopus-gihub v0.4, comments are incorrectly being added to the PR description instead of being submitted as issue comments. This behavior is inconsistent with expected functionality and disrupts the review workflow.

Steps to Reproduce:

  1. Navigate to a specific PR link (e.g. *: add instruction for editing config pingcap/docs#13666 (review))

  2. Click the "comment" button provided by octopus-gihub. Write a comment and submit it.

  3. Expected Outcome:

    The comment should appear in the comment section of the PR, maintaining the PR description unaltered.

  4. Actual Outcome:

    The comment is being added to the PR description, modifying the original content of the description.

Proposed Fix:

The issue can be resolved by modifying const url = window.location.href; to const url = window.location.pathname;. This change correctly gets the path of the PR URL, not including the query string or fragment.

@Oreoxmt Oreoxmt added the bug Something isn't working label May 25, 2023
@Oreoxmt Oreoxmt self-assigned this Nov 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant