Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
SMoraisAnsys committed Dec 2, 2024
1 parent 8943d5f commit 3e36038
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions src/pyedb/dotnet/clr_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,20 +35,6 @@ def custom_show_warning(message, category, filename, lineno, file=None, line=Non
sys.path.append(str(pyedb_path / "dlls" / "PDFReport"))


def find_runtime_config(dotnet_root: Path) -> Path:
"""Find dotnet runtime configuration file path."""
sdk_path = dotnet_root / "sdk"
if not sdk_path.is_dir():
raise EnvironmentError(f"The 'sdk' directory could not be found in: {dotnet_root}")
sdk_versions = sorted(sdk_path.iterdir(), key=lambda x: x.name, reverse=True)
if not sdk_versions:
raise FileNotFoundError("No SDK versions were found.")
runtime_config = sdk_versions[0] / "dotnet.runtimeconfig.json"
if not runtime_config.is_file():
raise FileNotFoundError(f"The configuration file '{runtime_config}' does not exist.")
return runtime_config


if is_linux: # pragma: no cover
from pythonnet import load

Expand Down

0 comments on commit 3e36038

Please sign in to comment.