Skip to main content

Crate rattler_conda_types

Crate rattler_conda_types 

Source
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 CompressionLevel enum, 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 PrefixRecord to 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.
ChannelConfig
The ChannelConfig describes properties that are required to resolve “simple” channel names to channel URLs.
ChannelData
ChannelData is an index of subdirectories and packages stored within a Channel.
ChannelDataPackage
Information on a single package in a channel.
ChannelInfo
Information about subdirectory of channel in the Conda RepoData
ChannelUrl
Represents a channel base url. This is a wrapper around an url that is normalized:
EnvironmentYaml
A representation of an environment.yaml file.
ExplicitEnvironmentEntry
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.
ExplicitEnvironmentSpec
An ExplicitEnvironmentSpec represents 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.
GenericVirtualPackage
A GenericVirtualPackage is a Conda package description that contains a name and a version and a build_string.
NoArchType
Noarch packages are packages that are not architecture specific and therefore only have to be built once. A NoArchType is either specific to an architecture or not. See NoArchKind for more information on the different types of noarch.
PackageName
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.
PackageRecord
A single record in the Conda repodata. A single record refers to a single binary distribution of a package on a Conda channel.
PackageRecordPatch
Contains items that overwrite metadata values stored for a single super::PackageRecord.
ParseMatchSpecOptions
Options for parsing match specifications.
ParseStrictnessWithNameMatcher
Defines how strict a parser should behave.
ParseVersionError
An error that occurred during parsing of a string to a version.
PatchInstructions
Repodata patch instructions for a single subdirectory. See RepoDataPatch for more information.
RepoData
RepoData is an index of package binaries available on in a subdirectory of a Conda channel.
RepoDataPatch
Represents a Conda repodata patch.
RepoDataRecord
Information about a package from repodata. It includes a crate::PackageRecord but 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.
ShardedRepodata
The sharded repodata holds a hashmap of package name -> shard (hash). This index file is stored under <channel>/<subdir>/repodata_shards.msgpack.zst
ShardedSubdirInfo
Information about a sharded subdirectory that is stored inside the index file.
SolverResult
Struct for the solver result containing records and their features
StrictVersion
Version that only has equality when it is exactly the same e.g for Version 1.0.0 == 1.0 while in StrictVersion this is not equal. Useful in ranges where we are talking about equality over version ranges instead of specific version instances
SubdirRunExportsJson
Represents Channel global map from package file names to RunExportsJson.
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.
VersionWithSource
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 Version but you still want to be able to distinguish them.
WhlPackageRecord
A record in the packages.whl section of the repodata.json.

Enums§

Component
Either a number, literal or the infinity.
ConvertSubdirError
An error that can occur when parsing a platform from a string.
InvalidPackageNameError
An error that is returned when conversion from a string to a PackageName fails.
MatchSpecOrSubSection
A matchspec or a subsection, as part of the dependencies section of an environment.yaml file.
NamedChannelOrUrl
Represents a channel description as either a name (e.g. conda-forge) or a base url.
NoArchKind
Defines the type of noarch that a package could be.
OrdOperator
An operator to compare two versions.
PackageArchiveHash
Package urls in explicit environments can have an optional hash that signifies a hash of the package archive. See ExplicitEnvironmentEntry::package_archive_hash.
ParseBuildNumberSpecError
Composition of possible errors when parsing the spec for build numbers
ParseChannelError
Error that can occur when parsing a channel.
ParseExplicitEnvironmentSpecError
An error that can occur when parsing an ExplicitEnvironmentSpec from a string
ParsePackageArchiveHashError
An error that can occur when parsing a PackageArchiveHash from a string
ParseStrictness
Defines how strict a version parser should behave.
ParseVersionErrorKind
The type of parse error that occurred when parsing a version string.
RawNoArchType
Noarch packages are packages that are not architecture specific and therefore only have to be built once. Noarch packages are either generic or Python.
RunExportKind
Type of runtime export. See more info in the conda docs crate::package::RunExportsJson
UrlOrPath
Represents either an absolute URL or a relative path to the base url of a channel
ValidatePackageRecordsError
An error when validating package records.
VersionBumpError
VersionBumpError is used to specify the type of error that occurred when bumping a version.
VersionBumpType
VersionBumpType is used to specify the type of bump to perform on a version.
VersionExtendError
Error that can occur when extending a version to a certain length.

Traits§

HasArtifactIdentificationRefs
A trait for types that allows identifying record uniquely within a subdirectory.
RecordFromPath
Trait to allow for generic deserialization of records from a path.

Functions§

compute_package_url
Computes the URL for a package.

Type Aliases§

BuildNumber
Named type for the build number of a package instead of explicit u64 floating about the project.
BuildNumberSpec
Define match from OrdOperator and BuildNumber as Element
PackageUrl
An package identifier that can be used to identify packages across package ecosystems.