prr icon indicating copy to clipboard operation
prr copied to clipboard

Scoped comments not accepted

Open drahnr opened this issue 3 years ago • 4 comments

Create a few scoped comments, got this:

Error: Error during POST: Status code: 422 Unprocessable Entity, Body: {"message":"Unprocessable Entity","errors":["Pull request review thread start line must precede the end line."],"documentation_url":"https://docs.github.com/rest/reference/pulls#create-a-review-for-a-pull-request"}

It would be awesome if the scoped comments would be displayed and checked for consistency with possible error messages on the line numbers.

drahnr avatar Aug 30 '22 08:08 drahnr

Error checking would be good. Do you have a reproducer I can test with?

danobi avatar Aug 31 '22 15:08 danobi

I do, just need to vet for any leaks, could I sent you this on another channel after I vetted it?

drahnr avatar Aug 31 '22 15:08 drahnr

Sure. Try my email in the git log.

danobi avatar Aug 31 '22 16:08 danobi

I have an example of this happening.

In particular, it deleting line 13 (thus removing the "scope block" format) will allow this to submit, but including the empty line will not.

6.prr.txt

prr get danobi/prr-test-repo/6
# edit it to match the above
prr submit danobi/prr-test-repo/6

Related but side question, how do you mix and match scoped and inline comments? In this linked example (also based on this file) it doesn't apply an inline comment and usage is a bit ambigious.

https://github.com/danobi/prr-test-repo/pull/6#discussion_r967576012

keevan avatar Sep 10 '22 03:09 keevan