near / bos-loader

MIT License
19 stars 5 forks source link

Do not throw error on encountering `REPL_ACCOUNT` in replacements file #8

Open mpeterdev opened 10 months ago

mpeterdev commented 10 months ago

Originally it was decided to error out if REPL_ACCOUNT was defined in the replacements file since the value will not be used. The account supplied to serve the components under always takes precedence and I believed not throwing an error would lead to confusion where a user doesn't realize their value in the replacements file is being ignored.

This has proven to be a headache, since replacement files may be shared between bos-loader and CI but REPL_ACCOUNT must be supplied in CI. In https://github.com/near/near-discovery-components we find ourselves needing to locally delete the REPL_ACCOUNT line from the replacements file in order to run bos-loader and then revert that change before committing.

If REPL_ACCOUNT is defined in the replacements file, we should print a warning message that the value is not being used but otherwise proceed with normal execution