spr icon indicating copy to clipboard operation
spr copied to clipboard

[Critical Bug] Error when updating an existing PR

Open dukeofcool199 opened this issue 1 year ago • 4 comments

i get the following error when trying to run spr diff on an existing pr

🔁 Commit was changed - updating Pull Request #378 🛑 GitHub: Validation Failed Documentation URL: https://docs.github.com/rest/pulls/pulls#update-a-pull-request Errors: - {"code":"invalid","field":"base","message":"Proposed base branch 'refs/heads/spr/dukeofcool199/ is invalid","resource":"PullRequest"}

dukeofcool199 avatar Jul 20 '23 23:07 dukeofcool199

@sven-of-cord I just got a very similar error while trying to spr land:

❯ spr land
dc3afed Minor bugfixes for Doc and Engine.instantiate_doc
  #️⃣   Pull Request #18
  🛫  Getting started...
  🛑  GitHub: Validation Failed
      Documentation URL: https://docs.github.com/rest/pulls/pulls#update-a-pull-request
      Errors:
      - {"code":"invalid","field":"base","message":"Proposed base branch 'refs/heads/main' is invalid","resource":"PullRequest"}

indigoviolet avatar Aug 08 '23 01:08 indigoviolet

I just got this for spr land not clear why it says invalid base :-/ any workaround?

❯ spr land
05b36a4 [SI-97] Integrate new scheduler in chat
  #️⃣   Pull Request #5489
  🛫  Getting started...
  🛑  GitHub: Validation Failed
      Documentation URL: https://docs.github.com/rest/pulls/pulls#update-a-pull-request
      Errors:
      - {"code":"invalid","field":"base","message":"Proposed base branch 'refs/heads/main' is invalid","resource":"PullRequest"}

eko-wibowo avatar Aug 10 '23 17:08 eko-wibowo

a temporary fix is to go onto GitHub and change the base branch manually to be main. Only do this after you landed the dependent PR's. Then spr land works.

SlowSnowFox avatar Aug 22 '23 16:08 SlowSnowFox

building from source completely removes this problem. So removing the latest version from homebrew(1.3.4) and building from scratch (1.3.5-beta.1) is the way to go.

SlowSnowFox avatar Sep 28 '23 19:09 SlowSnowFox