pulsar-edit / github

:octocat: Git and GitHub integration for Pulsar
MIT License
5 stars 3 forks source link

GitHub package gets 404 error getting pull request info #32

Open mjrodgers opened 1 year ago

mjrodgers commented 1 year ago

Thanks in advance for your bug report!

What happened?

The GitHub package automatically pulls up info on a "checked out pull request" associated with the currently active repo.

I'm getting 404 errors in the console because the package is attempting to pull this info from the wrong url, namely

Pulsar version

1.105.0

Which OS does this happen on?

🍎 macOS

OS details

12.6.6

Which CPU architecture are you running this on?

64-bit(x86_64)

What steps are needed to reproduce this?

Additional Information:

No response

confused-Techie commented 1 year ago

Thanks a ton for reporting this error, we will have to see what we can find out about this one

mjrodgers commented 1 year ago

Sure no problem! Seems to be related to this line here, at least in some cases where <this.props.owner>/<this.props.repo> points to the repo originating the PR instead of the target repo (when the PR is from a branch into another from the same repo, I guess it wouldn't result in the 404)

mjrodgers commented 1 year ago

I'm not sure, but this seems to be fixed in the latest update?

Daeraxa commented 1 year ago

I think I was the only one to make any changes to this package at all in the last couple of months and it was only to add a menu item. Maybe GitHub's API was being flaky that day?

mjrodgers commented 1 year ago

It's possible it was just a flaky day, but... the console error definitely had a url it was trying to reach that was incorrect, and modifying the url manually (to replace my github username with the owner of the upstream repo) would pull up the data. On startup after the update, a bunch of my repos asked me to choose a remote to use for pull request data (either origin or upstream), which I had never seen before, and now it works. If no one else ever recreated this issue, I'm happy to write it off as weirdness and mark as closed.