materialsproject / pymatgen

Python Materials Genomics (pymatgen) is a robust materials analysis code that defines classes for structures and molecules with support for many electronic structure codes. It powers the Materials Project.
https://pymatgen.org
Other
1.52k stars 867 forks source link

`matplotlib` test use non-interactive `agg` backend #4168

Closed DanielYang59 closed 1 week ago

DanielYang59 commented 1 week ago

Summary

The names of builtin backends are case-insensitive; e.g., 'QtAgg' and 'qtagg' are equivalent.

The tk backend might emit intermittent failures like:

>       self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
E       _tkinter.TclError: invalid command name "tcl_findLibrary"

Or:

>       self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
E       _tkinter.TclError: Can't find a usable init.tcl in the following directories: 
E           C:/Users/runneradmin/micromamba/envs/pmg/Library/lib/tcl8.6 C:/Users/runneradmin/micromamba/envs/lib/tcl8.6 C:/Users/runneradmin/micromamba/lib/tcl8.6 C:/Users/runneradmin/micromamba/envs/library C:/Users/runneradmin/micromamba/library C:/Users/runneradmin/micromamba/tcl8.6.13/library C:/Users/runneradmin/tcl8.6.13/library
E       
E       C:/Users/runneradmin/micromamba/envs/pmg/Library/lib/tcl8.6/init.tcl: couldn't read file "C:/Users/runneradmin/micromamba/envs/pmg/Library/lib/tcl8.6/init.tcl": No error
E       couldn't read file "C:/Users/runneradmin/micromamba/envs/pmg/Library/lib/tcl8.6/init.tcl": No error
E           while executing
E       "source C:/Users/runneradmin/micromamba/envs/pmg/Library/lib/tcl8.6/init.tcl"
E           ("uplevel" body line 1)
E           invoked from within
E       "uplevel #0 [list source $tclfile]"
E       
E       
E       This probably means that Tcl wasn't installed properly.