Skip to content

Remove commented and unneeded code#3757

Merged
melekes merged 8 commits intotendermint:masterfrom
tac0turtle:marko/cmn-clean
Jun 30, 2019
Merged

Remove commented and unneeded code#3757
melekes merged 8 commits intotendermint:masterfrom
tac0turtle:marko/cmn-clean

Conversation

@tac0turtle
Copy link
Contributor

  • Remove commented out file
  • Remove colors
  • remove newdebugdb
    Currently newdebugDB is used in cosmos-sdk for testing and iavl for testing, If this pr is merged following PRs will be made to eliminate the code in those repos as well
    Signed-off-by: Marko Baricevic marbar3778@yahoo.com
  • Referenced an issue explaining the need for the change
  • Updated all relevant documentation in docs
  • Updated all code comments where relevant
  • Wrote tests
  • Updated CHANGELOG_PENDING.md

- Remove commented out file
- Remove colors
- remove newdebugdb

Signed-off-by: Marko Baricevic <marbar3778@yahoo.com>
@tac0turtle tac0turtle added T:code-hygiene General cleanup and restructuring of code to provide clarity, flexibility, and modularity. ready-for-review labels Jun 27, 2019
@codecov-io
Copy link

codecov-io commented Jun 27, 2019

Codecov Report

Merging #3757 into master will decrease coverage by 0.19%.
The diff coverage is n/a.

@@            Coverage Diff            @@
##           master    #3757     +/-   ##
=========================================
- Coverage   64.06%   63.86%   -0.2%     
=========================================
  Files         242      217     -25     
  Lines       19968    18057   -1911     
=========================================
- Hits        12792    11533   -1259     
+ Misses       6137     5553    -584     
+ Partials     1039      971     -68
Impacted Files Coverage Δ
privval/socket_listeners.go 86.2% <0%> (-6.9%) ⬇️
consensus/reactor.go 70.33% <0%> (-2.23%) ⬇️
consensus/state.go 79.73% <0%> (-0.24%) ⬇️
privval/signer_validator_endpoint.go 85.55% <0%> (ø) ⬆️
types/encoding_helper.go
types/params.go
types/validator_set.go
lite/proxy/block.go
types/block.go
lite/proxy/proof.go
... and 37 more

Copy link
Contributor

@liamsi liamsi left a comment

Choose a reason for hiding this comment

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

Thanks!

@tac0turtle tac0turtle changed the title Remove commented and unneeded code v0.1 Remove commented and unneeded code Jun 27, 2019
//----------------------------------------
// debugDB

type debugDB struct {
Copy link
Contributor

Choose a reason for hiding this comment

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

this can be used for debugging. I've never used it myself, but maybe Cosmos-SDK devs had & need it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

its set as const = false in the code in the sdk. cc @alexanderbez @alessio @jackzampolin @rigelrozanski have you guys used newdbDebug at anytime

Copy link
Contributor

@melekes melekes left a comment

Choose a reason for hiding this comment

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

🏃

@melekes
Copy link
Contributor

melekes commented Jun 27, 2019

This needs a changelog entry.

That said, breaking changes in the following packages will be documented in the
CHANGELOG even if they don't lead to MINOR version bumps:
...
- libs
  - common
  ...
  - db

Signed-off-by: Marko Baricevic <marbar3778@yahoo.com>
* Apps

* Go API
- [libs] Removal of `NewDebugDB`, `colors.go` & `errors.go` (commented out entire file) (@marbar3778)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
- [libs] Removal of `NewDebugDB`, `colors.go` & `errors.go` (commented out entire file) (@marbar3778)
- [libs] Remove unused `db/debugDB` and `common/colors.go` & `errors/errors.go` files (@marbar3778)

@melekes melekes merged commit d4cf204 into tendermint:master Jun 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T:code-hygiene General cleanup and restructuring of code to provide clarity, flexibility, and modularity.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants