MinaProtocol / mina

Mina is a cryptocurrency protocol with a constant size blockchain, improving scaling while maintaining decentralization and security.
https://minaprotocol.com
Apache License 2.0
1.99k stars 529 forks source link

archive-migration package missing dependencies #15257

Open emberian opened 8 months ago

emberian commented 8 months ago

Preliminary Checks

Description

when installing mina-archive-migration package, the migration tool fails if gsutil or jq are not installed.

Steps to Reproduce

  1. install mina-archive-migration on a fresh debian
  2. notice gsutil is still not installed
  3. try to run migration, fails ...

Expected Result

runs

Actual Result

(monitor.ml.Error (Failure "Could not get JSON item with filter .protocol_state.body.consensus_state.last_vrf_output for state hash 3NKgyJZxH7a6Kw1GYA9KaD64gGzMAC3v4MnfgZAwEW1pPi3HV3Ke, error: (Unix.Unix_error \"No such file or directory\" Core.Unix.create_process\" \n \"((prog jq) (args (.protocol_state.body.consensus_state.last_vrf_output mainnet-UMT-2-3NKgyJZxH7a6Kw1GYA9KaD64gGzMAC3v4MnfgZAwEW1pPi3HV3Ke.json)) (env (Extend ())))\")" ("Raised at Stdlib.failwith in file \"stdlib.ml\", line 29, characters 17-33" "Called from Async_kernel__Deferred1.M.map.(fun) in file \"src/deferred1.ml\", line 17, characters 40-45" "Called from Async_kernelJob_queue.run_job in file \"src/job_queue.ml\" (inlined), line 128, characters 2-5" "Called from Async_kernelJob_queue.run_jobs in file \"src/job_queue.ml\", line 169, characters 6-47"))

Daemon version

umt2.0.0

How frequently do you see this issue?

Always

What is the impact of this issue on your ability to run a node?

Low

Status

N/A

Additional information

No response

emberian commented 8 months ago

workaround: manually install google-cloud-sdk and jq package

echo "deb https://packages.cloud.google.com/apt cloud-sdk main" | sudo tee -a /etc/apt/sources.list.d/google-cloud-sdk.list || echo "Failed to add Google Cloud SDK repo"
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add - || echo "Failed to add Google Cloud SDK key"

apt-get update && apt-get install -y google-cloud-sdk jq
mrmr1993 commented 7 months ago

google-cloud-sdk jq

It feels more natural to add these to the apt dependencies. We still have to document the annoying key thing, but everything else should be automatic then.