-
Notifications
You must be signed in to change notification settings - Fork 620
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FIX] AttributeError: 'ExperimentWriter' object has no attribute 'add_figure' #1694
base: main
Are you sure you want to change the base?
Conversation
…_figure' This fixes the AttributeError failure by checking that `add_figure` exists before attempting to call it. See sktime#1256
Note that I've added an additional check for Although related, it's not specifically about the linked issue. If preferred, I can create a new issue and split that off into it. |
I have not run $ pre-commit run --all-files
[INFO] Installing environment for https://github.com/pre-commit/pre-commit-hooks.
[INFO] Once installed this environment will be reused.
[INFO] This may take a few minutes...
An unexpected error has occurred: AssertionError: BUG: expected environment for python to be healthy() immediately after install, please open an issue describing your environment
Check the log at /.../.cache/pre-commit/pre-commit.log
version information
error information
|
Ah! I just realised Running it on this branch produces the following:
Which is the same result as running it on
|
Hm, question - is this an issue if Because currently, Nothing wrong with more defensive programming, but it feels like there is a larger issue to discuss about |
It impacts me with |
Description
This PR is a bugfix for #1256.
At present, the
AttributeError
is raised (and the script exits) if the logger used does not have theadd_figure
method.This fix adds a simple check prior to calling
add_figure
.Checklist
pre-commit install
.To run hooks independent of commit, execute
pre-commit run --all-files
Make sure to have fun coding!