¡Hola Drew!

El 2026-09-16 a las 22:44 +0200, Drew Parsons escribió:
Source: custodian
Followup-For: Bug #1145147
X-Debbugs-Cc: Maximiliano Curia <[email protected]>
Control: tags -1 ftbfs moreinfo

Maximiliano Curia wrote:
To solve this issue, I created a patch to normalize the file path to
an absolute path when caching VASP outputs. This patch should likely be
sent upstream as well.

Thanks for the patch, Maximiliano.

I have a question though: what is the point of creating the separate
functions _load_vasprun and _load_outcar ?

As far as I can see your idea would work just adding the abspath()
wrapping directly within the existing
 return Vasprun(filepath, **vasprun_kwargs)

i.e.
 return Vasprun(os.path.abspath(filepath), **vasprun_kwargs)

What's the reason for separating the fix out into the extra functions?

The thing is that the functions are lru_cached but the path they receive
could be a relative path, so we need to move the cache to the function
that receives the absolute path, and we keep the old one as a wrapper to
the cached function.

Happy hacking,
--
"First, solve the problem. Then, write the code." -- John Johnson
Saludos /\/\ /\ >< `/

Attachment: signature.asc
Description: PGP signature

Reply via email to