SMAC3 icon indicating copy to clipboard operation
SMAC3 copied to clipboard

Don't use mutable default argument.

Open bpkroth opened this issue 1 year ago • 4 comments

If this isn't respected, then additional_configs can be built up overtime when multiple optimizers are created in a single process.

This can occur when the use_default_config option is set True and/or when additional_configs are provided.

When different ConfigSpaces are provided this can result in an error due to mismatched defaults, for instance.

In other cases it can result in non-deterministic behavior due to the random ordering of the configs that get added (e.g., with different parallel pytest runs).

  • [x] Cleanup other sources of this error as well elsewhere in the code.
  • [x] Add pylint checks for this issue.

bpkroth avatar Aug 15 '23 20:08 bpkroth

Thanks for spotting and addressing this issue! We will discuss how we want to adapt the pre-commit hooks.

helegraf avatar Sep 05 '23 12:09 helegraf

Could you please add a line to the CHANGELOG.md mentioning the bugfix?

helegraf avatar Sep 05 '23 12:09 helegraf

Could you please add a line to the CHANGELOG.md mentioning the bugfix?

Hey, did that again. Anything else? Thanks!

bpkroth avatar Nov 16 '23 22:11 bpkroth

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jan 19 '24 14:01 stale[bot]

Closed by #1097

benjamc avatar Mar 12 '24 10:03 benjamc