palantir / godel

Go tool for formatting, checking, building, distributing and publishing projects

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Problem updating Godel since it is no longer published to palantir.bintray.com.

jameycribbs opened this issue · comments

What happened?

Godel version: 2.26.0
Go version: 1.15.6

Hi! I tried to do a ./godelw update, but it failed with a "curl: (22) The requested URL returned error: 403 Forbidden". I read back through the release notes and I see that you have started publishing to Github instead of bintray. So, I went into godel.properties and changed the line to read:

distributionURL=https://github.com/palantir/godel/archive/refs/tags/v2.26.0.tar.gz

and then tried to do a "./godelw update --sync", but I got this error:

"Error: update failed: downloaded file /home/jameycribbs/.godel/downloads/v2.26.0.tar.gz is not a valid godel package: tgz /home/jameycribbs/.godel/downloads/v2.26.0.tar.gz does not contain a valid package: failed to find godel-2.26.0/bin.".

I'm sure I'm just doing something wrong, but I was hoping you could point me in the right direction. Did I get the new url for the tar file wrong? Or do I need to upgrade Go to 1.16?

Thanks very much for Godel I've been using it for a while and I love it!

Jamey Cribbs

Thanks for the feedback! Yes, with Bintray shutting down there's a bit of a migration that needs to occur. Hopefully will update the first-class documentation, but for now there are a few options:

Option 1. Use the latest version of godelinit in the repository to update the repository -- pretty sure that should work

Option 2. Download the latest godel release TGZ from GitHub, then run ./godelw install {pathToDownloadedTgz} in your repository. That should work, but I believe there's a chance that the resolver URL in godel.properties will not be updated properly. You can update that file manually if you'd like -- it should be of the form (example for 2.36.0):

distributionURL=https://github.com/palantir/godel/releases/download/v2.36.0/godel-2.36.0.tgz
distributionSHA256=91137f4fb9e1b4491d6dd821edf6ed39eb66f21410bf645a062f687049c45492

Option 3. Run ./godelw update --version=2.34.0 in your repository, then run ./godelw update again. Version 2.34.0 is published to both GitHub and Bintray but has support for updating to GitHub after that, so that workflow should work. However, if the Bintray download doesn't work for 2.34.0, then this won't work.

Thanks for the feedback, and let me know if the above options don't work.

That was quick! :)

I tried option 3, but it could not download it from Bintray. So, then I tried option 2 and it worked great.

Thank you very much for the quick solution! Very much appreciated.

Option 3 worked like a charm for me.

Thanks for providing three excellent options.