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

Add instruction status such as deprecated or archived #263

Open
lorisleiva opened this issue Oct 29, 2024 · 0 comments
Open

Add instruction status such as deprecated or archived #263

lorisleiva opened this issue Oct 29, 2024 · 0 comments
Labels
proposal Suggesting a change / new feature

Comments

@lorisleiva
Copy link
Member

lorisleiva commented Oct 29, 2024

It is not uncommon for program developers to sunset their instructions by first, logging a deprecation warning and then removing it completely by throwing an error when the archived instruction is recognised by the program.

It would be nice for Codama to keep track of that information via a status attribute or even a dedicated InstructionStatusNode. The instruction status could be things like:

  • live if the instruction is accessible (the default state).
  • deprecated if the instruction is about to be archived.
  • archived if the instruction is no longer accessible. Note that this is better than simply removing the instruction from the Codama IDL as explorers would still need to parse old instruction for the program.

We could even imagine more advanced statuses like:

  • draft if the instruction is accessible but not fully implemented yet.
  • unaudited if the instruction is accessible and fully implemented but no audit was performed for it yet.

Additionally, an optional statusMessage attribute could be useful for program maintainers to provide more information about the current status to their consumers.

@lorisleiva lorisleiva added the proposal Suggesting a change / new feature label Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
proposal Suggesting a change / new feature
Projects
None yet
Development

No branches or pull requests

1 participant