[BUG]: create_pull_request_comment
's line
needs to be optional to use optional subject_type
#1710
Closed
1 task done
Labels
Status: Up for grabs
Issues that are ready to be worked on by anyone
Type: Bug
Something isn't working as documented
What happened?
Trying to leave a comment on a file-level does not work using the
create_pull_request_comment
because i have to passnil
as the line number, and then theoption
hash{ subject_type: "file" }
(as per the GitHub docs, line is optional when usingsubject_type: file
(screenshot))However, doing so passes the explicit key
line: nil
to the GitHub endpoint and that results in the following error:Locally i put a breakpoint after line 215 here and manually deleted the
line
key from theoptions
hash, then let the post request continue with the modified hash and the comment was created successfully on the PR.Versions
Octokit.rb v9.1.0
Ruby 3.3.1
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: