Closed guydavis closed 2 years ago
I'm not sure I like the overhead of propagating these values across all object constructors. Since this is a global configuration that must be accessed by majority components in the system, I think it'll be better to define the values globally instead. What do you think?
Benefit of that is that the default value will only be defined in a single place as well and easy to change, compared to now having default values hardcoded in all constructors and making it hard to change / maintain.
Agreed. How would you suggest I best define the values globally, that fits in with the current code base? I want to follow best practice here. Thanks for the review!
Extracted the
coin_symbol
(default: xch),coin_name
(default: chia), andprefix
(default:chia
) as configurable settings in config.yaml. This allows me to run Chiadog against blockchain forks such as Flax, NChain, HDDCoin, and Chives.All 3 new configuration values are optional and have defaults as shown above so any existing Chia-only users will not need to touch their config.yaml at all. This PR just adds the possibility of monitoring other blockchain forks without detracting in any way from the existing Chia monitoring.