Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: versioning for deploys #325

Open
anna-carroll opened this issue May 31, 2022 · 8 comments
Open

feat: versioning for deploys #325

anna-carroll opened this issue May 31, 2022 · 8 comments
Labels
help wanted Extra attention is needed typescript

Comments

@anna-carroll
Copy link
Member

anna-carroll commented May 31, 2022

Package

deploy, contracts-core, contracts-bridge, contracts-router

Describe the feature you would like

need to design how we will handle versioning between contracts-core, contracts-bridge, contracts-router, and deploy packages

As the contract code changes, the deploy script must sometimes also change (namely, if constructor / initialize / setup function interfaces change)

However, these packages are used in different places which each have different needs

Use cases:

  • production deploys: always want to deploy from tagged contract version
  • development + staging deploys: probably want to deploy from tagged contract version?
  • local environment testing: by default, want the local workspace version; may also want to be able to choose tagged versions too

We cannot just update the package.json of deploy package to choose which contracts to use, as we also need to use the right version of the deploy package itself

Additional context

Relevant: all comments / discussion on this PR: #312

@anna-carroll anna-carroll added help wanted Extra attention is needed typescript labels May 31, 2022
@anna-carroll anna-carroll changed the title feat: production deploys from tagged contract versions feat: versioning for deploys May 31, 2022
@anna-carroll
Copy link
Member Author

anna-carroll commented May 31, 2022

from @prestwich #312 (comment)

ya, for any given commit, CI should guarantee that the version of deploy in that commit is compatible with its dependency. So when we tag a contract release, we need to bump the deploy script dependency version. If we always do that correctly, we should keep things in sync I guess? 🤔

my response is.. hmmmm.. wdyt @Imti 😅

@anna-carroll
Copy link
Member Author

@prestwich logistically how would we check whether version of deploy is compatible with version of contracts-* deps? there may be multiple versions on each side that are compatible with each other

@anna-carroll
Copy link
Member Author

anna-carroll commented May 31, 2022

in other words, it's not a 1:1 mapping between deploy and contracts-* package versions - what's the suggested way to log compatibilities
(we may tag a new contracts release which doesn't change the deploy script; or we may update the deploy script without changing the contracts)

@prestwich
Copy link
Member

I'm saying that CI already will fail to build if deploy specifies a contracts-* version that deploy's code is type-system incompatible with

@anna-carroll
Copy link
Member Author

I'm saying that CI already will fail to build if deploy specifies a contracts-* version that deploy's code is type-system incompatible with

ah, yes. this is true.

but.. how do we deploy from past versions? i guess just check out that version in a branch.

@prestwich
Copy link
Member

but.. how do we deploy from past versions? i guess just check out that version in a branch.

yes

@Imti
Copy link
Contributor

Imti commented Jun 1, 2022

I agree with @prestwich, basically following the convention for npm packages releases. Let me know if you need help setting this up.

@odyslam
Copy link
Contributor

odyslam commented Jul 27, 2022

I think we have fixed this @anna-carroll ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed typescript
Projects
None yet
Development

No branches or pull requests

4 participants