* Fix compression of split with different status
* Fix size issue in truncated strings
* Add versions_and_build_strings_trunc
* Use zipped versions and builds
* Better handling of virutal nodes
* Don't merge same name user requirements
* Fix NamedList tests
* Adjust NamedList bindings
* Regenerate stubgens
* Bind ProblemsGraph and CompressProblemGraph
* Rename summary error message
* Fix Python static property
* Add stubgens for problems bindings
* Give a little help to Windows
* Windows
* Hang in there MSVC
* Fix Pybind init
* Add graph all successors accessor
* Change graph bindings to raw data
* Add NamedList remove_duplicates py::arg
* Regenerate stubgens
* Remove termcolor for fmt
* Reimplement termcolor::is_atty
* Switch to fmt::terminal_color
* Add missing header for to_utf8
* Add Context color palette
* Refactor progress bar to use palette
* Remove misleading flag-like enum
* Fix windows build
* Remove output::format
* Add visited colors for repoquery
* Use palette in SAT error messages
* Console::stream() clear line
* Add experimental flag for error messages
* Bind MSolver::explain_problems
* Use Solver.explain_problems in mamba
* Rename MSolver::solve > MSolver::try_solve
* Add MSolver::must_solve
* Add [[nodiscard]] to MSolver
* Change solve -> try_solve in tests
* Used shared_ptr for MPool
* Make MSolverProblem a flat data type
* Add deprecation warnings for Solver.solve
* Add tree error message to MSolver
Co-authored-by: Danny <dan@cyrusbio.com>
Co-authored-by: Jonas Haag <jonas@lophus.org>
Co-authored-by: Wolf Vollprecht <w.vollprecht@gmail.com>
Co-authored-by: Johan Mabille <johan.mabille@gmail.com>
* Add support for proxy settings in .condarc
This commit is based on https://github.com/mamba-org/mamba/pull/161/
* Add test for proxy configuration
* Remove env variables from proxy servers configurable
They are already handled by curl
* Add tests for proxy_match
* Remove and improve debug messages
* Use EXPECT_STREQ for proxy match tests
* Use std:string instead of char*
* Add micromamba proxy tests
* Retrigger CI
* Try to fix proxy tests in CI
* Add missing file and fix executable name
* Try to fix windows build
* Use install xtensor package for proxy test
* Try to fix tests on windows
* Pass proxy settings between libmamba and mamba
* Use long form of `--script` parameter for mitmproxy
Co-authored-by: Jonas Haag <jonas@lophus.org>
* Clarify variable name
Co-authored-by: Jonas Haag <jonas@lophus.org>
* Add docstring to dump_proxy_connections.py
* Add explanation to micromamba proxy test
* Cleanup proxy_match function
* Redact passwords in proxy urls when logging
* Renamed redact_url to redact_url_password
* Revert "Renamed redact_url to redact_url_password"
This reverts commit ca39afda21.
* Revert "Redact passwords in proxy urls when logging"
This reverts commit 270eb70420.
* Use existing hide_secrets function to hide password in proxy url
* Rewrite proxy_match function to be in line with conda
Co-authored-by: Jonas Haag <jonas@lophus.org>
In C++ namespace-scope static object are created and destructed in an
unspecified order before and after `main()` execution, respectively.
The only guarantee is that such objects in the same translation unit
shall be constructed in apparition order in the file and destructed in
the reverse order. Another guarantee is that local (inside functoins)
static object are guaranteed to be created only at the first call to
that function, but then there is no guarantee on the destruction order.
This is fine until these objects interacts, that is, at least one of
these objects have a dependency/usage of another object defined in a
different translation unit.
We currently have singletons which are implemented as global statics
spread through various translation units, and several of these
singletons are also accessed through construction and destruction of
other singletons. Basically, we have undefined behavior around their
creation and destruction, so it is not always visible because often
memory looks like valid objects even if it is not. Some recent fixes
made this even more visible (which is helpful).
This change moves all the singleton object definitions into the same
translation unit to begin improving guarantees on their construction
and destruction order after `main()` execution.
Scopes lifetime of any thread used by libmamba to `main()`'s scope.
This fixes undefined behavior when threads are running after `main()`
is finished. At the end of `main()`, static objects are destroyed in
an unspecified order which can also lead easilly to undefined behaviors.
This change should fix both issues.
For now the implementation of `MainExecutor` is simple: it spawn a
new thread for each task scheduled and does not provide means to track
the progress and/or end of tasks. This reflects the previous behavior.
The intent is to enabled changing the implementation of `MainExecutor`
in the future to improve execution speed and/or execution resources
usage.
* Fixed: `--json` throwing exceptions in some situations (lockfiles)
* Refactored Console pimpl handling
* Automatic json printing instead of explicit.
* added a way to cancel the print of json log from libmamba, used in mamba which already output the right json;
From now on the json output will be automatically printed at the end of the program
(after `main()` call) instead of explicitly invoked.
* refactor progress bars
* use fmt to better format progress bars fields
* add a Chrono class to handle time and status/state
* add a ProgressBarRepr class to handle representation of the bars
* add capability to remove progress bars from a manager
* add capability to set width when computing bars repr and printing
* handle no_progress_bars context value in all situations
* also ensure quiet, not a tty, and json modes are handled
* add and update tests
* make it optional to display sub-bars in aggregated mode
* display a carrousel of downloading or extracting packages is the aggregated bar
* make sure extracting packages from cache are printed by the progress bars manager
* remove postfix when printing the completed download status
* protect chrono state against modifications when sorting bars
* fix to_human_readable_filesize free function
* only wait for watch_print thread to exit if started
* store speed, also compute average speed from member or Chrono elapsed time
* use the average speed on download aggregated bar if cURL info is missing
* allows to get average speed on total elapsed time
* improved color scheme of progress bars
* collect and show the in-progress status using cyan
* init the progress randomly when activating spinner
* control sorting of multi downloads using an option
* use C-style options also for fastfail
* make sure pbar manager is init on multi bars when dl channels
* refactor on api changes
use MAMBA_EXTRACT_THREADS env var in mamba
set max extract threads before transaction
make sure the context value is used by setting context value in fetch_extract_packages
add error handling in mamba in case env var can't be converted to integer
split verbosity and log level
use backtrace to replay logs on critical error
use backtrace to replay logs emitted before setting the log level, with the appropriate level
make libmamba compile time log level a cmake option
break circular dependencies
remove hard-coded config loading sequence
create a libmamba-full-static target to expose static deps
remove automagic activation of libmamba build options to fix packaging
add find_package libmamba in micromamba and libmambapy
add umamba MICROMAMBA_LINKAGE option to select libmamba target
update documentation
* make a clear split between CMake targets
* split versions between libmamba and mamba
* add libmambapy target for python bindings and make mamba depend on it
* rename CMake options to make them homogeneous, simplify CMake
* remove termcolor from thirdparties, use it as a dependency
* remove unnecessary version global vars and convert to functions
* update CI workflows