Expand description
rattler-conda-types contains data models for types commonly found within
the Conda ecosystem. The library itself doesnt provide any functionality
besides parsing the data types.
Re-exports§
pub use match_spec::condition::MatchSpecCondition;pub use match_spec::package_name_matcher::PackageNameMatcher;pub use match_spec::package_name_matcher::PackageNameMatcherParseError;pub use match_spec::matcher::StringMatcher;pub use match_spec::matcher::StringMatcherParseError;pub use match_spec::parse::ParseMatchSpecError;pub use match_spec::MatchSpec;pub use match_spec::MatchSpecUrlError;pub use match_spec::Matches;pub use match_spec::NamelessMatchSpec;pub use minimal_prefix_record::collect_minimal_prefix_records;pub use minimal_prefix_record::MinimalPrefixCollection;pub use minimal_prefix_record::MinimalPrefixRecord;pub use platform::Arch;pub use platform::ParseArchError;pub use platform::ParsePlatformError;pub use platform::Platform;pub use prefix_record::PrefixRecord;pub use version_spec::VersionSpec;
Modules§
- backup
- Utilities for excluding directories from backups.
- compression_
level - This module defines the
CompressionLevelenum, which is used to specify the compression level for Conda packages to be created. - match_
spec - Query language for conda packages.
- menuinst
- Define types that can be serialized into a
PrefixRecordto track menu entries installed into the system. - minimal_
prefix_ record - Minimal prefix record reading for fast environment change detection.
- package
- Contains models of files that are found in the
info/directory of a package. - platform
- Platform-specific code.
- prefix
- Defines the
[Prefix]struct. - prefix_
record - Defines the
[PrefixRecord]struct. - utils
- This module contains utility functions for url and serde
- version_
spec - This module contains code to work with “versionspec”. It represents the
version part of
crate::MatchSpec, e.g.:>=3.4,<4.0.
Structs§
- Channel
Channels are the primary source of package information.- Channel
Config - The
ChannelConfigdescribes properties that are required to resolve “simple” channel names to channel URLs. - Channel
Data ChannelDatais an index of subdirectories and packages stored within a Channel.- Channel
Data Package - Information on a single package in a channel.
- Channel
Info - Information about subdirectory of channel in the Conda
RepoData - Channel
Url - Represents a channel base url. This is a wrapper around an url that is normalized:
- Environment
Yaml - A representation of an
environment.yamlfile. - Explicit
Environment Entry - A single entry in an
ExplicitEnvironmentSpec. This is basically a representation of a package URL. Package URLS can also have an associated URL hash which signifies the expected hash of the package archive. - Explicit
Environment Spec - An
ExplicitEnvironmentSpecrepresents an explicit environment specification. Packages are represented by a URL that defines from where they should be downloaded and they are already in an explicit installation order. This ensures that there is no need to run the solver or to download repodata which makes using explicit environments for installation of environments very fast. - Generic
Virtual Package - A
GenericVirtualPackageis a Conda package description that contains anameand aversionand abuild_string. - NoArch
Type - Noarch packages are packages that are not architecture specific and
therefore only have to be built once. A
NoArchTypeis either specific to an architecture or not. SeeNoArchKindfor more information on the different types ofnoarch. - Package
Name - A representation of a conda package name. This struct both stores the source string from which this instance was created as well as a normalized name that can be used to compare different names. The normalized name is guaranteed to be a valid conda package name.
- Package
Record - A single record in the Conda repodata. A single record refers to a single binary distribution of a package on a Conda channel.
- Package
Record Patch - Contains items that overwrite metadata values stored for a single
super::PackageRecord. - Parse
Match Spec Options - Options for parsing match specifications.
- Parse
Strictness With Name Matcher - Defines how strict a parser should behave.
- Parse
Version Error - An error that occurred during parsing of a string to a version.
- Patch
Instructions - Repodata patch instructions for a single subdirectory. See
RepoDataPatchfor more information. - Repo
Data RepoDatais an index of package binaries available on in a subdirectory of a Conda channel.- Repo
Data Patch - Represents a Conda repodata patch.
- Repo
Data Record - Information about a package from repodata. It includes a
crate::PackageRecordbut it also stores the source of the data (like the url and the channel). - Shard
- An individual shard that contains repodata for a single package name.
- Sharded
Repodata - The sharded repodata holds a hashmap of package name -> shard (hash).
This index file is stored under
<channel>/<subdir>/repodata_shards.msgpack.zst - Sharded
Subdir Info - Information about a sharded subdirectory that is stored inside the index file.
- Solver
Result - Struct for the solver result containing records and their features
- Strict
Version - Version that only has equality when it is exactly the same
e.g for
Version1.0.0 == 1.0 while inStrictVersionthis is not equal. Useful in ranges where we are talking about equality over version ranges instead of specific version instances - Subdir
RunExports Json - Represents
Channelglobal map from package file names toRunExportsJson. - Version
- This class implements an order relation between version strings. Version strings can contain the usual alphanumeric characters (A-Za-z0-9), separated into segments by dots and underscores. Empty segments (i.e. two consecutive dots, a leading/trailing underscore) are not permitted. An optional epoch number - an integer followed by ‘!’ - can precede the actual version string (this is useful to indicate a change in the versioning scheme itself). Version comparison is case-insensitive.
- Version
With Source - Holds a version and the string it was created from. This is useful if you want to retain the
original string the version was created from. This might be useful in cases where you have
multiple strings that are represented by the same
Versionbut you still want to be able to distinguish them. - WhlPackage
Record - A record in the
packages.whlsection of therepodata.json.
Enums§
- Component
- Either a number, literal or the infinity.
- Convert
Subdir Error - An error that can occur when parsing a platform from a string.
- Invalid
Package Name Error - An error that is returned when conversion from a string to a
PackageNamefails. - Match
Spec OrSub Section - A matchspec or a subsection, as part of the
dependenciessection of anenvironment.yamlfile. - Named
Channel OrUrl - Represents a channel description as either a name (e.g.
conda-forge) or a base url. - NoArch
Kind - Defines the type of noarch that a package could be.
- OrdOperator
- An operator to compare two versions.
- Package
Archive Hash - Package urls in explicit environments can have an optional hash that signifies a hash of the
package archive. See
ExplicitEnvironmentEntry::package_archive_hash. - Parse
Build Number Spec Error - Composition of possible errors when parsing the spec for build numbers
- Parse
Channel Error - Error that can occur when parsing a channel.
- Parse
Explicit Environment Spec Error - An error that can occur when parsing an
ExplicitEnvironmentSpecfrom a string - Parse
Package Archive Hash Error - An error that can occur when parsing a
PackageArchiveHashfrom a string - Parse
Strictness - Defines how strict a version parser should behave.
- Parse
Version Error Kind - The type of parse error that occurred when parsing a version string.
- RawNo
Arch Type - Noarch packages are packages that are not architecture specific and therefore only have to be built once. Noarch packages are either generic or Python.
- RunExport
Kind - Type of runtime export.
See more info in the conda docs
crate::package::RunExportsJson - UrlOr
Path - Represents either an absolute URL or a relative path to the base url of a channel
- Validate
Package Records Error - An error when validating package records.
- Version
Bump Error VersionBumpErroris used to specify the type of error that occurred when bumping a version.- Version
Bump Type VersionBumpTypeis used to specify the type of bump to perform on a version.- Version
Extend Error - Error that can occur when extending a version to a certain length.
Traits§
- HasArtifact
Identification Refs - A trait for types that allows identifying record uniquely within a subdirectory.
- Record
From Path - Trait to allow for generic deserialization of records from a path.
Functions§
- compute_
package_ url - Computes the URL for a package.
Type Aliases§
- Build
Number - Named type for the build number of a package instead of explicit u64 floating about the project.
- Build
Number Spec - Define match from
OrdOperatorandBuildNumberas Element - Package
Url - An package identifier that can be used to identify packages across package ecosystems.