From 7e6274b56caf45cfc525fb2ae581bd5dc34cb580 Mon Sep 17 00:00:00 2001 From: Hind Montassif Date: Wed, 3 Jul 2024 18:05:06 +0200 Subject: [PATCH 1/3] Add debug logs --- .github/workflows/windows_impl.yml | 2 +- micromamba/tests/helpers.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/windows_impl.yml b/.github/workflows/windows_impl.yml index ad33f1314d..81d0b7f189 100644 --- a/.github/workflows/windows_impl.yml +++ b/.github/workflows/windows_impl.yml @@ -148,5 +148,5 @@ jobs: $env:TEST_MAMBA_EXE = Join-Path -Path $pwd -ChildPath 'local\bin\mamba.exe' $env:MAMBA_TEST_SHELL_TYPE='powershell' Remove-Item -Path "env:CONDARC" - python -m pytest micromamba/tests/ ` + python -m pytest micromamba/tests/test_install.py::TestInstall::test_no_python_pinning ` ${{ runner.debug == 'true' && '-v --capture=tee-sys' || '--exitfirst' }} diff --git a/micromamba/tests/helpers.py b/micromamba/tests/helpers.py index 51621345bf..5f0d9bd733 100644 --- a/micromamba/tests/helpers.py +++ b/micromamba/tests/helpers.py @@ -136,7 +136,7 @@ def install(*args, default_channel=True, no_rc=True, no_dry_run=False, **kwargs) cmd += ["--offline"] if (dry_run_tests == DryRun.DRY) and "--dry-run" not in args and not no_dry_run: cmd += ["--dry-run"] - cmd += ["--log-level=info"] + cmd += ["--log-level=debug"] # maybe try with trace later? res = subprocess_run(*cmd, **kwargs) From 3d2e956b0976abe8cdb4ffc2b39e49d7badf80c9 Mon Sep 17 00:00:00 2001 From: Hind Montassif Date: Thu, 4 Jul 2024 09:47:30 +0200 Subject: [PATCH 2/3] Comment logs per package --- libmamba/src/solver/libsolv/helpers.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/libmamba/src/solver/libsolv/helpers.cpp b/libmamba/src/solver/libsolv/helpers.cpp index 1bb1366d8c..592cbd3a80 100644 --- a/libmamba/src/solver/libsolv/helpers.cpp +++ b/libmamba/src/solver/libsolv/helpers.cpp @@ -172,11 +172,11 @@ namespace mamba::solver::libsolv } } } - else - { - LOG_DEBUG << "No signatures available for '" << filename - << "'. Downloading without verifying artifacts."; - } + // else + // { + // LOG_DEBUG << "No signatures available for '" << filename + // << "'. Downloading without verifying artifacts."; + // } } [[nodiscard]] auto set_solvable( @@ -388,7 +388,8 @@ namespace mamba::solver::libsolv if (parsed) { on_parsed(fn); - LOG_DEBUG << "Adding package record to repo " << fn; + // LOG_DEBUG << "Adding package record to repo " << + // fn; } else { From d3b03c35a4ec2421614e460f270bf2bf96660b58 Mon Sep 17 00:00:00 2001 From: Hind Montassif Date: Mon, 15 Jul 2024 18:26:44 +0200 Subject: [PATCH 3/3] Not use libsolv debug log --- libmamba/src/core/package_database_loader.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/libmamba/src/core/package_database_loader.cpp b/libmamba/src/core/package_database_loader.cpp index 4cdce150c3..2ca1b57b4a 100644 --- a/libmamba/src/core/package_database_loader.cpp +++ b/libmamba/src/core/package_database_loader.cpp @@ -42,11 +42,12 @@ namespace mamba logger->error(msg); break; case (solver::libsolv::LogLevel::Warning): - logger->warn(msg); - break; case (solver::libsolv::LogLevel::Debug): - logger->debug(msg); + logger->warn(msg); break; + // case (solver::libsolv::LogLevel::Debug): + // logger->debug(msg); + // break; } } );