specs

Classes

BinstarSpec

spec = BinstarSpec('darth/deathstar')

RequirementsSpec

Reads dependencies from a requirements.txt file

YamlFileSpec

Functions

get_spec_class_from_file(→ FileSpecTypes)

Determine spec class to use from the provided filename

detect(→ SpecTypes)

Return the appropriate spec type to use.

Attributes

FileSpecTypes

SpecTypes

class BinstarSpec(name=None)

spec = BinstarSpec('darth/deathstar') spec.can_handle() # => True / False spec.environment # => YAML string spec.msg # => Error messages :raises: EnvironmentFileNotDownloaded

msg
can_handle() bool

Validates loader can process environment definition. :return: True or False

valid_name() bool

Validates name :return: True or False

valid_package() bool

Returns True if package has an environment file :return: True or False

binstar() types.ModuleType
file_data() list[dict[str, str]]
environment() conda_env.env.Environment
package()
username() str
packagename() str
class RequirementsSpec(filename=None, name=None, **kwargs)

Reads dependencies from a requirements.txt file and returns an Environment object from it.

property environment
msg
extensions
_valid_file()
_valid_name()
can_handle()
class YamlFileSpec(filename=None, **kwargs)
property environment
_environment
extensions
can_handle()
FileSpecTypes
get_spec_class_from_file(filename: str) FileSpecTypes

Determine spec class to use from the provided filename

Raises

EnvironmentFileExtensionNotValid | EnvironmentFileNotFound --

SpecTypes
detect(name: str = None, filename: str = None, directory: str = None, remote_definition: str = None) SpecTypes

Return the appropriate spec type to use.

Raises