Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

feat: import ethermint without forking #378

Merged
merged 6 commits into from
Jul 28, 2021
Merged

Conversation

fedekunze
Copy link
Contributor

@fedekunze fedekunze commented Jul 28, 2021

Closes: #293

Description


For contributor use:

  • Targeted PR against correct branch (see CONTRIBUTING.md)
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards.
  • Wrote unit and integration tests
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/)
  • Added relevant godoc comments.
  • Added a relevant changelog entry to the Unreleased section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer

For admin use:

  • Added appropriate labels to PR (ex. WIP, R4R, docs, etc)
  • Reviewers assigned
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)

@github-actions github-actions bot added the Type: CI continuous integration label Jul 28, 2021
@github-actions github-actions bot added C:CLI C:JSON-RPC JSON-RPC client C:Types common types, interfaces and functions from /types labels Jul 28, 2021
@codecov
Copy link

codecov bot commented Jul 28, 2021

Codecov Report

Merging #378 (34819e9) into main (bc2a2eb) will decrease coverage by 0.61%.
The diff coverage is 21.73%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #378      +/-   ##
==========================================
- Coverage   52.59%   51.97%   -0.62%     
==========================================
  Files          46       47       +1     
  Lines        4609     4660      +51     
==========================================
- Hits         2424     2422       -2     
- Misses       2086     2139      +53     
  Partials       99       99              
Impacted Files Coverage Δ
app/app.go 83.64% <ø> (-0.22%) ⬇️
types/chain_id.go 57.89% <ø> (+5.51%) ⬆️
types/coin.go 0.00% <ø> (ø)
types/hdpath.go 0.00% <0.00%> (ø)
server/config/config.go 17.85% <35.71%> (ø)

@@ -42,29 +42,6 @@ func InitConfig(cmd *cobra.Command) error {
return viper.BindPFlag(cli.OutputFlag, cmd.PersistentFlags().Lookup(cli.OutputFlag))
}

// GenerateChainID wraps a cobra command with a RunE function with base 10 integer chain-id random generation
// when a chain-id is not provided.
func GenerateChainID(baseCmd *cobra.Command) *cobra.Command {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not used

Comment on lines +20 to +24
# API defines a list of JSON-RPC namespaces that should be enabled
api = "{{ .EVMRPC.API }}"

# EnableUnsafeCORS defines if CORS should be enabled (unsafe - use it at your own risk)
enable-unsafe-cors = "{{ .EVMRPC.EnableUnsafeCORS }}"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these were missing

@@ -47,8 +46,3 @@ func ParseChainID(chainID string) (*big.Int, error) {

return chainIDInt, nil
}

// GenerateRandomChainID returns a random chain-id in the valid format.
func GenerateRandomChainID() string {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto, not used


// HDPathIterator receives a base path as a string and a boolean for the desired iterator type and
// returns a function that iterates over the base HD path, returning the string.
func NewHDPathIterator(basePath string, ledgerIter bool) (HDPathIterator, error) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to create an iterator for the personal API, otherwise, every new account that is created will use the same hdpath

@fedekunze fedekunze marked this pull request as ready for review July 28, 2021 08:55
@fedekunze fedekunze changed the title cmd: cleanup feat: import ethermint without forking Jul 28, 2021
@fedekunze
Copy link
Contributor Author

tested locally with a dummy app from starport

@fedekunze fedekunze merged commit 09746c6 into main Jul 28, 2021
@fedekunze fedekunze deleted the fedekunze/cleanup-cmd branch July 28, 2021 09:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
C:CLI C:JSON-RPC JSON-RPC client C:Types common types, interfaces and functions from /types Type: CI continuous integration
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Start other network without forking
1 participant