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

[CLI]Minor code improvement in CLI, remove ts-ignore-next-line #796

Merged
merged 3 commits into from
Sep 4, 2019

Conversation

ashishb
Copy link
Contributor

@ashishb ashishb commented Aug 29, 2019

Description

Minor code improvement in CLI, remove ts-ignore-next-line.
Use new Web3().eth.accounts.privateKeyToAccount(privateKey).address

Tested

packages/cli] $ yarn run celocli account:new
yarn run v1.17.3
$ /Users/ashishb/celo/celo-monorepo5/node_modules/.bin/celocli account:new
TypeError: web3_1.default is not a constructor
    at Function.generateAccountAddressFromPrivateKey (~/celo/celo-monorepo5/packages/cli/src/commands/account/new.ts:33:12)
    at NewAccount.run (~/celo/celo-monorepo5/packages/cli/src/commands/account/new.ts:41:39)
    at NewAccount._run (~/celo/celo-monorepo5/node_modules/@oclif/command/lib/command.js:44:31)
    at <anonymous>
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

@ashishb ashishb added the automerge Have PR merge automatically when checks pass label Sep 4, 2019
@codecov
Copy link

codecov bot commented Sep 4, 2019

Codecov Report

Merging #796 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #796   +/-   ##
=======================================
  Coverage   67.05%   67.05%           
=======================================
  Files         241      241           
  Lines        7134     7134           
  Branches      475      475           
=======================================
  Hits         4784     4784           
  Misses       2273     2273           
  Partials       77       77
Flag Coverage Δ
#mobile 67.05% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dfe34f4...d2fc456. Read the comment docs.

@ashishb ashishb merged commit 2f82c5b into master Sep 4, 2019
@ashishb ashishb deleted the ashishb/cli_cleanup branch September 4, 2019 18:47
aaronmgdr added a commit that referenced this pull request Sep 5, 2019
* master:
  Export geth metrics from StatefulSet tx-nodes and validators (#827)
  Adjust governance end-to-end gold total supply block number  (#853)
  [Blockchain API] Add currency conversion endpoint to blockchain api (#855)
  [Wallet] Fix Payment Requests and DRY up confirmation card code (#831)
  Use HTTPS instead of SSH for ethereumjs-vm (#850)
  Kill end-to-end celo-blockchain instances with SIGINT (#849)
  [CLI]Minor code improvement in CLI, remove ts-ignore-next-line (#796)
  [wallet] Always allow users to view backup key (#825)
  [contractkit] Complete Exchange Wrapper (#801)
  [Wallet] Fix web3 syncing sagas (#809)
  Aaronmgdr/social links connect (#792)
  Deploy integration (#806)
  [wallet] upgrade react-redux (#812)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Have PR merge automatically when checks pass
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants