aeproject icon indicating copy to clipboard operation
aeproject copied to clipboard

dynamically use latest major version on `init`

Open marc0olo opened this issue 2 years ago • 4 comments

in the past we had latest tag for both, compiler & node. this recently lead us to a problem with SDK incompatibility to latest compiler version v7.0.1

I think it makes sense to fetch latest (major) release on project initialization. if e.g. aeproject would define 6 for node and 6 for the compiler it should replace the tags accordingly in docker-compose.yml (which we recently introduced here: https://github.com/aeternity/aeproject/pull/432)

aeproject would then use the version defined in docker-compose.yaml by default to start the environment. only if options nodeVersion or compilerVersion is provided a custom version should be used.

this way we would ensure that a user doesn't run into unforeseen problems.

@thepiwo what do you think?

marc0olo avatar Aug 30 '22 12:08 marc0olo

I would like it as discussed in the other issue, but there is no such tag yet as far as I know

thepiwo avatar Aug 30 '22 15:08 thepiwo

I think we won't get the tag as we discussed 😅

also I see one small issue with the other approach. in case of new releases docker wouldn't automatically download the new node version if not explicitly forced by the user.

marc0olo avatar Aug 30 '22 16:08 marc0olo

yes it would, as we use pull in the env command

thepiwo avatar Aug 31 '22 07:08 thepiwo

yes it would, as we use pull in the env command

ok, that's good to know. anyway, I doubt we will see tags like 6 or 7 on dockerhub based on recent discussion.

using the proposed approach here we would definitely avoid unexpected results based on implicit infrastructure changes. we'd always select the version when the project is initialized and then leave it up to the devs to update node/compiler. I actually like that

marc0olo avatar Aug 31 '22 07:08 marc0olo