open-dollar / od-sdk

MIT License
2 stars 1 forks source link

Remove duplicate definition warning #5

Closed pi0neerpat closed 1 year ago

pi0neerpat commented 1 year ago

How can we remove all these console logs from the sdk?

Duplicate definition of ModifyParameters (ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,bytes32,uint256))
Duplicate definition of ModifyParameters (ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,address))
Duplicate definition of ModifyParameters (ModifyParameters(bytes32,bytes32,uint256), ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,address), ModifyParameters(bytes32,uint256,uint256), ModifyParameters(bytes32,uint256,uint256,address))
Duplicate definition of ModifyParameters (ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,address), ModifyParameters(bytes32,bytes32,uint256), ModifyParameters(bytes32,bytes32,address))
jahabeebs commented 1 year ago

How can we remove all these console logs from the sdk?

Duplicate definition of ModifyParameters (ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,bytes32,uint256))
Duplicate definition of ModifyParameters (ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,address))
Duplicate definition of ModifyParameters (ModifyParameters(bytes32,bytes32,uint256), ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,address), ModifyParameters(bytes32,uint256,uint256), ModifyParameters(bytes32,uint256,uint256,address))
Duplicate definition of ModifyParameters (ModifyParameters(bytes32,uint256), ModifyParameters(bytes32,address), ModifyParameters(bytes32,bytes32,uint256), ModifyParameters(bytes32,bytes32,address))

@pi0neerpat

This specific log can't be turned off in ethers 5 so we have a couple of options:

1) only allow ethers logging in dev and not in prod (I think this might be best since we still need ethers logging for debugging in dev) 2) turn off ethers logging for dev and prod 3) migrate ethers to v6 (would require refactoring of how we use BigNumbers and providers in the SDK--see here: https://docs.ethers.org/v6/migrating/)

related issues: https://github.com/ethers-io/ethers.js/issues/1029 https://github.com/Midas-Protocol/monorepo/issues/1126

pi0neerpat commented 1 year ago

Closing for now. Not high enough priority to continue