scs / substrate-api-client

Library for connecting to substrate API over WebSockets
Apache License 2.0
259 stars 122 forks source link

Use new docker image of substrate in CI #720

Closed masapr closed 3 months ago

masapr commented 7 months ago

The CI gives warnings: Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.

After checking, I saw that we are still using an old docker image from parity for our tests: https://github.com/scs/substrate-api-client/blob/839ba6f0c8fcda0efc0733f635056a91b6df4355/.github/workflows/ci.yml#L178

I'm not sure, which is the correct new one. So this should be checked and then the CI code updated

haerdib commented 7 months ago

There does not seem to be an up-to-date Substrate docker atm: https://github.com/paritytech/polkadot-sdk/issues/2750

I wonder if it's worth the effort to self-build a node, or if we wait for parity to fix this?

masapr commented 7 months ago

I would expect that Parity has some docker image, that let's you run a node, no? Or do you think they don't have that anymore? Are you sure it's not called differently or that there is another way of running a dummy substrate node?

haerdib commented 7 months ago

If they do, I didn't find it in docker hub (see https://hub.docker.com/search?q=parity). And also I'd also expect them to update their doc accordingly, but they haven't: https://github.com/paritytech/polkadot-sdk/blob/master/substrate/docker/run.sh#L11

So I guess the above linked issue, especially the comment https://github.com/paritytech/polkadot-sdk/issues/2750#issuecomment-1862636921 is the issue here.

masapr commented 7 months ago

ok, I see. Thanks for checking. Then let's close this issue. Looks like there will be a new docker image eventually with the same name on dockerhub

haerdib commented 7 months ago

Let's keep it so we don't forget about it. Maybe there will be a renaming or something.

Option: paritypr/substrate, which is used for zombienet. https://github.com/paritytech/polkadot-sdk/blob/5fc7622cb312f2d32ec8365012ee0a49622db8c8/substrate/zombienet/0001-basic-warp-sync/generate-warp-sync-database.toml#L4 This still seems to be updated. But no idea what kind of node is run there.

haerdib commented 7 months ago

After discussion: We could try to use the paritypr image one. Lets see if CI accepts that.

masapr commented 7 months ago

Unfortunately the change to the paritypr image #721 did not remove the warning above (see https://github.com/scs/substrate-api-client/actions/runs/7956482028). @haerdib can you check, if this warning is really introduced by the substrate node? Maybe I got this wrong ...