slapperwan / gh4a

Github client for Android
Apache License 2.0
1.73k stars 221 forks source link

Issues should reference PRs that close them #891

Open tjkirch opened 5 years ago

tjkirch commented 5 years ago

When a PR closes an issue, the GitHub web interface adds some text like "closed in #N" that links to the pull request. This gives valuable context as to why an issue was closed.

(This issue was split out of #811 which handles PRs referencing issues in comments rather than in the merge commit; #811 should be possible with the v3 timeline API, whereas this is not possible with v3 according to @maniac103.)

Browser shows "closed in #N": issue-in-firefox

OctoDroid just shows "closed this issue": issue-in-octodroid

Lomanic commented 4 years ago

I see this is labeled "needs-api-support" but Forkhub is able to get this information. Does this label mean this is not returned by the last API used in Octodroid but is returned by a previous version (I didn't check in which API they get this information)?

maniac103 commented 4 years ago

Does Forkhub really show the PR number or just the commit hash? From what I can gather from the docs, one only can get the commit hash, and Octodroid already supports that (try e.g. with this issue) ... for the 'closed with PR #N' format (example), I don't see any PR reference in the timeline output (for the example, one can fetch it e.g. running curl -H "Accept: application/vnd.github.mockingbird-preview" https://api.github.com/repos/openhab/openhab-android/issues/1723/timeline).

Lomanic commented 4 years ago

Sorry I was mistaken, Forkhub shows when a PR is referencing an issue, but it doesn't show if this issue is closing it or not.

Screenshot of #930 in Octodroid

![Screenshot_20191218-174315](https://user-images.githubusercontent.com/5020919/71528386-d4216d80-28df-11ea-92fb-76d9fab0929e.png)

Screenshot of #930 in Forkhub

![Screenshot_20191218-174308](https://user-images.githubusercontent.com/5020919/71528418-029f4880-28e0-11ea-9358-aa78e8bcd3af.png)

Screenshot of openhab/openhab-android#1723 in Octodroid

![Screenshot_20191218-174355](https://user-images.githubusercontent.com/5020919/71528498-688bd000-28e0-11ea-9444-ae683e038f1a.png)

Screenshot of openhab/openhab-android#1723 in Forkhub

![Screenshot_20191218-174404](https://user-images.githubusercontent.com/5020919/71528516-7b9ea000-28e0-11ea-89f6-012fbfeb1d6c.png)

Octodroid doesn't show PRs referencing issues while Forkhub does, but this is what #811 is about, not this issue.