* Make find_slash_and_platform private-lib
* Add ChannelSpec
* Add ChannelSpec::Type
* Add abs_path_or_url_to_url
* Add ChannelSpec path normalization and type detection
* Add ChannelSpec::location
* Allow any platform string in ChannelSpec
* Channel::platforms is a flat_set
* Move flat_set_caster to own file
* More flat_set in Channel
* Regenerate Python stubs
* Plug ChannelSpec into Channel
* Resolve path in ChannelSpec
* Fix env export channels
* No resolve symlink in ChannelSpec
* Fix tests on Windows
* Add ChannelSpec attribute extractors
* Add raw domain ChannelSpec test
* Use URL in read_channel_configuration
* Fix local channel name
* Improve path_to_url
* Construct from Channel from URL
* Properly parse channel alias
* Fix wrong move
* Channel alias is a CondaURL
* Add defaulted scheme to URL
* Add defaulted host to URL
* CondaURL tokens can only be at the begining
* Add CondaURL::path_without_token
* Add option to remove credentials in URLs
* Add empty cretendial URL tests
* Add str Credential options
* Add credential option to CondaURL::str
* Add split_prefix/suffix
* Add ChannelContext::from_package_path
* URL::pretty_path only on Windows
* Add ChannelContext::from_path
* Do not resolve paths in ChannelSpec
* Change mapping order in path resolving
* Compute URL canonical_name in read_channel_configurations
* Add URL::authority credentials
* Rename private URL::authentification > URL::authentifaction_elems
* Refactor URL::authority
* Refactor some read_channel_configurations
* Remove empty path URL case
* Add path_is_prefix
* Fix url_match
* Add flat_set doctest printer
* Add CondaURL doctest printer
* Alias dynamic_platform_set in ChannelSpec
* Use util:concat
* Restore subdir in matchspecs
* Make find_slash_and_platform private
* Refactored Subdir Metadata
* Plugged downloader into subdirdata
* Simplified Donwloader APIs
* Added DownloadMonitor and plugged it into channel_loader
* Simplified subdir API
* Fixed python bindings
* Changes according to review (on going)
* Added json parsers to subdirmetadata
* Try CI
* Remove useless header
* Try mixing static windows build with Conda
* More packages from conda-forge
* Move to yaml-cpp>=0.8.0
* Ensure proper yaml-cpp target
* Use yaml-cpp-static on Windows
* Fix versions
* Use libsolv-static from Conda-Forge
* [feat] Show other versions with --pretty printing
* [feat] Refine version/build table in search pretty print
* [feat] Change table view to contain further aligned build information
* [feat] Redirect non-wildcard search to single package view
* Fix repoquery test for empty single package view
* Cleanup + add string marker for alignment
* Fix string marker for libmambapy
* Add changes suggested by JH
* Move to unordered_map where it makes sense
* Move to string_view and switch-case constexpr alignment mapping
* Fail lookup for non-existing alignments
* Remove unnecessary reference in constructor
* Replace MTransaction to_remove with PackageInfo
* Add a solution class
* Fix Solution for_each
* Add Solution empty and size
* Make MTransaction::filter const
* Remove unused MTransaction::m_force_reinstall
* Rename MSolver::set_flags
* Refactor MSolver flags
* Call solver.flag() once in MTransaction
* Implement Solution as alias with free functions
* Remove as many MSolver flag setters as possible
* Make Soltion a struct to possibly add more members
* Remove useless function call
* Add Solution::Omit
* Rename template typenames and parameters in Solution
* Fix MSolver const parameter
* Revert "Change brace space in clang-format (#2627)"
This reverts commit 3dce990111.
* Revert "Improvement: Support ZST in mamba and enable ZST by default (#2404)"
This reverts commit 60cd358c39.
* Fusionned ChannelBuilder and ChannelContext and channel cache
* ChannelContext is not a singleton anymore.
* libmambapy now holds singletons for ChannelContext etc.
* formatting
* Simplified libmambapy singleton handling.
* formatting
* Use ObjPool in MPool
* Straightforward wrapper call
* MPool debug callback wrapper
* Fix format
* Use m_real_repo_key
* MRepos need not be stored
* Change MRepo::set_urls call
* Rename real_repo_key
* Awlways set solvable URL
* Rename mrepo_key
* Leaf comment note on package Info
* Ensure proper channel format in query
* Fix set url everywhere
* Rename solvable:noarch
* Fix real_repo_url in pybind
* Bump mamba tool version
* fix: prevent (possible) dangling pointer in query
* Fix url in transaction
* fix: setting url or repo from mamba
* fix: UB string_view of deallocated string
* Use solv:: interface in channel specific dep
* Use new solv:: interface in make_package_info
* Use solv:: interface in add_package_info
* Small implementation changes in MRepo
* Use wrapped reading functions
* kill MRepo::m_url
* Mark MRepo C++ function for Python deprecated
* Add ObjRepo::legacy_read_conda_repodata
* Mark more MRepo functions private
* Remove filename attributes from MRepo
* Fix Mrepo add_extra_pkg_info
* Not ignoring MRepo name
* Split url outside MRepo
* Remove MRepo ctor overload
* 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