types

Implements all conda.notices types.

Classes

ChannelNotice

Represents an individual channel notice.

ChannelNoticeResultSet

Represents a list of a channel notices, plus some accompanying

ChannelNoticeResponse

class ChannelNotice

Bases: NamedTuple

Represents an individual channel notice.

id: str | None
channel_name: str | None
message: str | None
level: conda.base.constants.NoticeLevel
created_at: datetime | None
expired_at: datetime | None
interval: int | None
class ChannelNoticeResultSet

Bases: NamedTuple

Represents a list of a channel notices, plus some accompanying metadata such as viewed_channel_notices.

channel_notices: Sequence[ChannelNotice]
total_number_channel_notices: int
viewed_channel_notices: int
class ChannelNoticeResponse

Bases: NamedTuple

property notices: Sequence[ChannelNotice]
url: str
name: str
json_data: dict | None
static _parse_notice_level(level: str | None) conda.base.constants.NoticeLevel

We use this to validate notice levels and provide reasonable defaults if any are invalid.

static _parse_iso_timestamp(iso_timestamp: str | None) datetime | None

Parse ISO timestamp and fail over to a default value of none.

classmethod get_cache_key(url: str, cache_dir: pathlib.Path) pathlib.Path

Returns where this channel response will be cached by hashing the URL.