Skip to content

Commit

Permalink
Platstdlib does not contain dist-packages, so we have to add it ourse…
Browse files Browse the repository at this point in the history
…lves.
  • Loading branch information
Kasper Peeters committed Nov 29, 2024
1 parent 706ee3a commit 1edd061
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/pythoncdb/py_helpers.cc
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ namespace cadabra {
// try again with `platstdlib`.
if(!std::filesystem::is_regular_file(dpath / "cadabra2_defaults.py")) {
py::object result = sysconfig.attr("get_path")("platstdlib");
std::string spath2 = result.cast<std::string>();
std::string spath2 = result.cast<std::string>()+"/dist-packages";
auto dpath2 = std::filesystem::path(spath);
if(!std::filesystem::is_regular_file(dpath2 / "cadabra2_defaults.py")) {
throw std::logic_error("Cannot find cadabra2_defaults.py at either "+spath+
Expand Down

0 comments on commit 1edd061

Please sign in to comment.