-
Notifications
You must be signed in to change notification settings - Fork 324
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(ioctl): project register contract addr config #4039
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #4039 +/- ##
==========================================
+ Coverage 75.38% 76.26% +0.88%
==========================================
Files 303 331 +28
Lines 25923 28288 +2365
==========================================
+ Hits 19541 21573 +2032
- Misses 5360 5617 +257
- Partials 1022 1098 +76 ☔ View full report in Codecov by Sentry. |
ioctl/cmd/ws/wsproject.go
Outdated
config.TranslateInLang(_flagProjectRegisterContractAddressUsages, config.UILanguage), | ||
) | ||
_ = wsProject.MarkFlagRequired("contract-address") | ||
wsProjectRegisterContractAddress = config.ReadConfig.WsProjectRegisterContract |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why this one is special, get value from config.ReadConfig
ioctl/config/config.go
Outdated
@@ -69,6 +69,8 @@ type Config struct { | |||
AnalyserEndpoint string `json:"analyserEndpoint" yaml:"analyserEndpoint"` | |||
// WsEndpoint w3bstream endpoint | |||
WsEndpoint string `json:"wsEndpoint" yaml:"wsEndpoint"` | |||
// WsProjectRegisterContract w3bstream project register contract address | |||
WsProjectRegisterContract string `json:"wsProjectRegisterContract" yaml:"wsProjectRegisterContract"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: just make it simple WsRegisterContract
?
75b9f49
to
3afc065
Compare
@@ -28,12 +28,14 @@ const ( | |||
_endpointPattern = "(" + _ipPattern + "|(" + _domainPattern + ")" + "|(" + _localPattern + "))" + `(:\d{1,5})?` | |||
_defaultAnalyserEndpoint = "https://iotex-analyser-api-mainnet.chainanalytics.org" | |||
_defaultWsEndpoint = "sprout-staging.w3bstream.com:9000" | |||
// _defaultProjectRegisterContract default project register contract address | |||
_defaultProjectRegisterContract = "0x4F7e678B0203e0444E17512108dba4B08B39512e" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
register a new contract, for the "0x4F7e678B0203e0444E17512108dba4B08B39512e" contains much localhost uri
@@ -35,12 +35,14 @@ const ( | |||
_defaultAnalyserEndpoint = "https://iotex-analyser-api-mainnet.chainanalytics.org" | |||
_defaultWsEndpoint = "sprout-staging.w3bstream.com:9000" | |||
_defaultConfigFileName = "config.default" | |||
// _defaultWsProjectRegisterContract default w3bstream project register contract address | |||
_defaultWsProjectRegisterContract = "0x4F7e678B0203e0444E17512108dba4B08B39512e" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same above
3afc065
to
812160b
Compare
Quality Gate failedFailed conditions 8.2% Duplication on New Code (required ≤ 3%) |
Description
project register contract address config
Fixes #(issue)
Type of change
How Has This Been Tested?
Checklist: