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

Move contracts publickey in a settings toml file #38

Open
giacomo-cc opened this issue Dec 12, 2022 · 0 comments
Open

Move contracts publickey in a settings toml file #38

giacomo-cc opened this issue Dec 12, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@giacomo-cc
Copy link

Currently we have all the chain smart contracts public keys hardcoded in the codebase:

vyper-cli/src/main.rs

Lines 35 to 38 in c9fc594

const VYPER_CORE_ID: &str = "vyPErCcGJKQQBeeQ59gXcWrDyU4vBrq8qQfacwmsAsp";
const REDEEM_LOGIC_FORWARD: &str = "BrpV1re8MshA8qskKVxcEG8zXG3vf2uLX6myeTKAyhsK";
const RATE_SWITCHBOARD: &str = "2hGXiH1oEQwjCXRx8bNdHTi49ScZp7Mj2bxcjxtULKe1";
const OTC: &str = "8aHSkExY28qCvg4gnTLU7y1Ev6HnpJ1NxuWb9XtEesVt";

We should move these parameters to an external file for easy tuning. For example it could be a settings.toml file (in order to prepare the field also for future user settings/preferences).

Once created the settings.toml file we can create a new command to open it in a text editor in order to allow users to change it, for example:

vyper-cli settings open

I would avoid creating a command for changing each setting entry from the suite, for now it's not needed.

@giacomo-cc giacomo-cc added the enhancement New feature or request label Dec 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant