Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Copilot Lvl 2
Message 1 of 3

Improved context in Pull Requests

Pull Requests are incredibly important but it is hard to properly peer review code using just a snippet of information, you cant see context, you cant see methods that called into the method you are reviewing, this all makes people just accept PR without properly understanding the context of the changes.

 

I know you can expand to 'see more' but you cant see outside of that area, what about the function impacted by the change, or the function that called the one that has been changed.

 

Can I suggest, just as a slight improvement, would be to offer a link to view the full source file that contains the change with the diff in place ... as the only way i can do that now, is to go to the code view, find the branch, change branch, find the source file somewhere in the tree, then look and now i have forgotten what the changes were.

 

I hope you understand the point I am attempting to make :-)

2 Replies
Community Manager
Message 2 of 3

Re: Improved context in Pull Requests

Hi @danpetitt,

 

Thanks for this feedback! We're always working to improve GitHub and the GitHub Community Forum, and we consider every suggestion we receive. I've logged your feature request in our internal feature request list. Though I can't guarantee anything or share a timeline for this, I can tell you that it's been shared with the appropriate teams for consideration.

 

Please let me know if you have any other questions.

Cheers!

Thanks for being here, sharing, and keeping our community awesome!
Best,
AndreaG

Mark helpful posts with Accept as Solution to help other users locate important info. Don't forget to give Kudos for great content!

Pilot Lvl 1
Message 3 of 3

Re: Improved context in Pull Requests

I'm interested in implementing something like this in my own app that collaborates with GitHub via v3 and v4 api. I'm successfully showing the diff of particlar PR but I want to improve it by providing an option of showing the whole file content along side its diff. So, I'm wondering @danpetitt @AndreaGriffiths11 do you know about a way to achieve that via GitHub's api. The ideal endpoint will be similar to `/<owner>/<repo>/compare/<sha1>..<sha2>` but should allow me to target a specific file + should accept `application/vnd.github.v3.diff` as a format.