code
string
repo_name
string
path
string
language
string
license
string
size
int64
import logging import os import re import string import typing from itertools import chain as _chain _logger = logging.getLogger(__name__) # ------------------------------------------------------------------------------------- # PEP 440 VERSION_PATTERN = r""" v? (?: (?:(?P<epoch>[0-9]+)!)? # epoch (?P<release>[0-9]+(?:\.[0-9]+)*) # release segment (?P<pre> # pre-release [-_\.]? (?P<pre_l>(a|b|c|rc|alpha|beta|pre|preview)) [-_\.]? (?P<pre_n>[0-9]+)? )? (?P<post> # post release (?:-(?P<post_n1>[0-9]+)) | (?: [-_\.]? (?P<post_l>post|rev|r) [-_\.]? (?P<post_n2>[0-9]+)? ) )? (?P<dev> # dev release [-_\.]? (?P<dev_l>dev) [-_\.]? (?P<dev_n>[0-9]+)? )? ) (?:\+(?P<local>[a-z0-9]+(?:[-_\.][a-z0-9]+)*))? # local version """ VERSION_REGEX = re.compile(r"^\s*" + VERSION_PATTERN + r"\s*$", re.X | re.I) def pep440(version: str) -> bool: return VERSION_REGEX.match(version) is not None # ------------------------------------------------------------------------------------- # PEP 508 PEP508_IDENTIFIER_PATTERN = r"([A-Z0-9]|[A-Z0-9][A-Z0-9._-]*[A-Z0-9])" PEP508_IDENTIFIER_REGEX = re.compile(f"^{PEP508_IDENTIFIER_PATTERN}$", re.I) def pep508_identifier(name: str) -> bool: return PEP508_IDENTIFIER_REGEX.match(name) is not None try: try: from packaging import requirements as _req except ImportError: # pragma: no cover # let's try setuptools vendored version from setuptools._vendor.packaging import requirements as _req # type: ignore def pep508(value: str) -> bool: try: _req.Requirement(value) return True except _req.InvalidRequirement: return False except ImportError: # pragma: no cover _logger.warning( "Could not find an installation of `packaging`. Requirements, dependencies and " "versions might not be validated. " "To enforce validation, please install `packaging`." ) def pep508(value: str) -> bool: return True def pep508_versionspec(value: str) -> bool: """Expression that can be used to specify/lock versions (including ranges)""" if any(c in value for c in (";", "]", "@")): # In PEP 508: # conditional markers, extras and URL specs are not included in the # versionspec return False # Let's pretend we have a dependency called `requirement` with the given # version spec, then we can re-use the pep508 function for validation: return pep508(f"requirement{value}") # ------------------------------------------------------------------------------------- # PEP 517 def pep517_backend_reference(value: str) -> bool: module, _, obj = value.partition(":") identifiers = (i.strip() for i in _chain(module.split("."), obj.split("."))) return all(python_identifier(i) for i in identifiers if i) # ------------------------------------------------------------------------------------- # Classifiers - PEP 301 def _download_classifiers() -> str: import ssl from email.message import Message from urllib.request import urlopen url = "https://pypi.org/pypi?:action=list_classifiers" context = ssl.create_default_context() with urlopen(url, context=context) as response: headers = Message() headers["content_type"] = response.getheader("content-type", "text/plain") return response.read().decode(headers.get_param("charset", "utf-8")) class _TroveClassifier: """The ``trove_classifiers`` package is the official way of validating classifiers, however this package might not be always available. As a workaround we can still download a list from PyPI. We also don't want to be over strict about it, so simply skipping silently is an option (classifiers will be validated anyway during the upload to PyPI). """ def __init__(self): self.downloaded: typing.Union[None, False, typing.Set[str]] = None self._skip_download = False # None => not cached yet # False => cache not available self.__name__ = "trove_classifier" # Emulate a public function def _disable_download(self): # This is a private API. Only setuptools has the consent of using it. self._skip_download = True def __call__(self, value: str) -> bool: if self.downloaded is False or self._skip_download is True: return True if os.getenv("NO_NETWORK") or os.getenv("VALIDATE_PYPROJECT_NO_NETWORK"): self.downloaded = False msg = ( "Install ``trove-classifiers`` to ensure proper validation. " "Skipping download of classifiers list from PyPI (NO_NETWORK)." ) _logger.debug(msg) return True if self.downloaded is None: msg = ( "Install ``trove-classifiers`` to ensure proper validation. " "Meanwhile a list of classifiers will be downloaded from PyPI." ) _logger.debug(msg) try: self.downloaded = set(_download_classifiers().splitlines()) except Exception: self.downloaded = False _logger.debug("Problem with download, skipping validation") return True return value in self.downloaded or value.lower().startswith("private ::") try: from trove_classifiers import classifiers as _trove_classifiers def trove_classifier(value: str) -> bool: return value in _trove_classifiers or value.lower().startswith("private ::") except ImportError: # pragma: no cover trove_classifier = _TroveClassifier() # ------------------------------------------------------------------------------------- # Non-PEP related def url(value: str) -> bool: from urllib.parse import urlparse try: parts = urlparse(value) if not parts.scheme: _logger.warning( "For maximum compatibility please make sure to include a " "`scheme` prefix in your URL (e.g. 'http://'). " f"Given value: {value}" ) if not (value.startswith("/") or value.startswith("\\") or "@" in value): parts = urlparse(f"http://{value}") return bool(parts.scheme and parts.netloc) except Exception: return False # https://packaging.python.org/specifications/entry-points/ ENTRYPOINT_PATTERN = r"[^\[\s=]([^=]*[^\s=])?" ENTRYPOINT_REGEX = re.compile(f"^{ENTRYPOINT_PATTERN}$", re.I) RECOMMEDED_ENTRYPOINT_PATTERN = r"[\w.-]+" RECOMMEDED_ENTRYPOINT_REGEX = re.compile(f"^{RECOMMEDED_ENTRYPOINT_PATTERN}$", re.I) ENTRYPOINT_GROUP_PATTERN = r"\w+(\.\w+)*" ENTRYPOINT_GROUP_REGEX = re.compile(f"^{ENTRYPOINT_GROUP_PATTERN}$", re.I) def python_identifier(value: str) -> bool: return value.isidentifier() def python_qualified_identifier(value: str) -> bool: if value.startswith(".") or value.endswith("."): return False return all(python_identifier(m) for m in value.split(".")) def python_module_name(value: str) -> bool: return python_qualified_identifier(value) def python_entrypoint_group(value: str) -> bool: return ENTRYPOINT_GROUP_REGEX.match(value) is not None def python_entrypoint_name(value: str) -> bool: if not ENTRYPOINT_REGEX.match(value): return False if not RECOMMEDED_ENTRYPOINT_REGEX.match(value): msg = f"Entry point `{value}` does not follow recommended pattern: " msg += RECOMMEDED_ENTRYPOINT_PATTERN _logger.warning(msg) return True def python_entrypoint_reference(value: str) -> bool: module, _, rest = value.partition(":") if "[" in rest: obj, _, extras_ = rest.partition("[") if extras_.strip()[-1] != "]": return False extras = (x.strip() for x in extras_.strip(string.whitespace + "[]").split(",")) if not all(pep508_identifier(e) for e in extras): return False _logger.warning(f"`{value}` - using extras for entry points is not recommended") else: obj = rest module_parts = module.split(".") identifiers = _chain(module_parts, obj.split(".")) if rest else module_parts return all(python_identifier(i.strip()) for i in identifiers)
castiel248/Convert
Lib/site-packages/setuptools/config/_validate_pyproject/formats.py
Python
mit
8,736
"""Utility functions to expand configuration directives or special values (such glob patterns). We can split the process of interpreting configuration files into 2 steps: 1. The parsing the file contents from strings to value objects that can be understand by Python (for example a string with a comma separated list of keywords into an actual Python list of strings). 2. The expansion (or post-processing) of these values according to the semantics ``setuptools`` assign to them (for example a configuration field with the ``file:`` directive should be expanded from a list of file paths to a single string with the contents of those files concatenated) This module focus on the second step, and therefore allow sharing the expansion functions among several configuration file formats. **PRIVATE MODULE**: API reserved for setuptools internal usage only. """ import ast import importlib import io import os import pathlib import sys import warnings from glob import iglob from configparser import ConfigParser from importlib.machinery import ModuleSpec from itertools import chain from typing import ( TYPE_CHECKING, Callable, Dict, Iterable, Iterator, List, Mapping, Optional, Tuple, TypeVar, Union, cast ) from pathlib import Path from types import ModuleType from distutils.errors import DistutilsOptionError from .._path import same_path as _same_path if TYPE_CHECKING: from setuptools.dist import Distribution # noqa from setuptools.discovery import ConfigDiscovery # noqa from distutils.dist import DistributionMetadata # noqa chain_iter = chain.from_iterable _Path = Union[str, os.PathLike] _K = TypeVar("_K") _V = TypeVar("_V", covariant=True) class StaticModule: """Proxy to a module object that avoids executing arbitrary code.""" def __init__(self, name: str, spec: ModuleSpec): module = ast.parse(pathlib.Path(spec.origin).read_bytes()) vars(self).update(locals()) del self.self def _find_assignments(self) -> Iterator[Tuple[ast.AST, ast.AST]]: for statement in self.module.body: if isinstance(statement, ast.Assign): yield from ((target, statement.value) for target in statement.targets) elif isinstance(statement, ast.AnnAssign) and statement.value: yield (statement.target, statement.value) def __getattr__(self, attr): """Attempt to load an attribute "statically", via :func:`ast.literal_eval`.""" try: return next( ast.literal_eval(value) for target, value in self._find_assignments() if isinstance(target, ast.Name) and target.id == attr ) except Exception as e: raise AttributeError(f"{self.name} has no attribute {attr}") from e def glob_relative( patterns: Iterable[str], root_dir: Optional[_Path] = None ) -> List[str]: """Expand the list of glob patterns, but preserving relative paths. :param list[str] patterns: List of glob patterns :param str root_dir: Path to which globs should be relative (current directory by default) :rtype: list """ glob_characters = {'*', '?', '[', ']', '{', '}'} expanded_values = [] root_dir = root_dir or os.getcwd() for value in patterns: # Has globby characters? if any(char in value for char in glob_characters): # then expand the glob pattern while keeping paths *relative*: glob_path = os.path.abspath(os.path.join(root_dir, value)) expanded_values.extend(sorted( os.path.relpath(path, root_dir).replace(os.sep, "/") for path in iglob(glob_path, recursive=True))) else: # take the value as-is path = os.path.relpath(value, root_dir).replace(os.sep, "/") expanded_values.append(path) return expanded_values def read_files(filepaths: Union[str, bytes, Iterable[_Path]], root_dir=None) -> str: """Return the content of the files concatenated using ``\n`` as str This function is sandboxed and won't reach anything outside ``root_dir`` (By default ``root_dir`` is the current directory). """ from setuptools.extern.more_itertools import always_iterable root_dir = os.path.abspath(root_dir or os.getcwd()) _filepaths = (os.path.join(root_dir, path) for path in always_iterable(filepaths)) return '\n'.join( _read_file(path) for path in _filter_existing_files(_filepaths) if _assert_local(path, root_dir) ) def _filter_existing_files(filepaths: Iterable[_Path]) -> Iterator[_Path]: for path in filepaths: if os.path.isfile(path): yield path else: warnings.warn(f"File {path!r} cannot be found") def _read_file(filepath: Union[bytes, _Path]) -> str: with io.open(filepath, encoding='utf-8') as f: return f.read() def _assert_local(filepath: _Path, root_dir: str): if Path(os.path.abspath(root_dir)) not in Path(os.path.abspath(filepath)).parents: msg = f"Cannot access {filepath!r} (or anything outside {root_dir!r})" raise DistutilsOptionError(msg) return True def read_attr( attr_desc: str, package_dir: Optional[Mapping[str, str]] = None, root_dir: Optional[_Path] = None ): """Reads the value of an attribute from a module. This function will try to read the attributed statically first (via :func:`ast.literal_eval`), and only evaluate the module if it fails. Examples: read_attr("package.attr") read_attr("package.module.attr") :param str attr_desc: Dot-separated string describing how to reach the attribute (see examples above) :param dict[str, str] package_dir: Mapping of package names to their location in disk (represented by paths relative to ``root_dir``). :param str root_dir: Path to directory containing all the packages in ``package_dir`` (current directory by default). :rtype: str """ root_dir = root_dir or os.getcwd() attrs_path = attr_desc.strip().split('.') attr_name = attrs_path.pop() module_name = '.'.join(attrs_path) module_name = module_name or '__init__' _parent_path, path, module_name = _find_module(module_name, package_dir, root_dir) spec = _find_spec(module_name, path) try: return getattr(StaticModule(module_name, spec), attr_name) except Exception: # fallback to evaluate module module = _load_spec(spec, module_name) return getattr(module, attr_name) def _find_spec(module_name: str, module_path: Optional[_Path]) -> ModuleSpec: spec = importlib.util.spec_from_file_location(module_name, module_path) spec = spec or importlib.util.find_spec(module_name) if spec is None: raise ModuleNotFoundError(module_name) return spec def _load_spec(spec: ModuleSpec, module_name: str) -> ModuleType: name = getattr(spec, "__name__", module_name) if name in sys.modules: return sys.modules[name] module = importlib.util.module_from_spec(spec) sys.modules[name] = module # cache (it also ensures `==` works on loaded items) spec.loader.exec_module(module) # type: ignore return module def _find_module( module_name: str, package_dir: Optional[Mapping[str, str]], root_dir: _Path ) -> Tuple[_Path, Optional[str], str]: """Given a module (that could normally be imported by ``module_name`` after the build is complete), find the path to the parent directory where it is contained and the canonical name that could be used to import it considering the ``package_dir`` in the build configuration and ``root_dir`` """ parent_path = root_dir module_parts = module_name.split('.') if package_dir: if module_parts[0] in package_dir: # A custom path was specified for the module we want to import custom_path = package_dir[module_parts[0]] parts = custom_path.rsplit('/', 1) if len(parts) > 1: parent_path = os.path.join(root_dir, parts[0]) parent_module = parts[1] else: parent_module = custom_path module_name = ".".join([parent_module, *module_parts[1:]]) elif '' in package_dir: # A custom parent directory was specified for all root modules parent_path = os.path.join(root_dir, package_dir['']) path_start = os.path.join(parent_path, *module_name.split(".")) candidates = chain( (f"{path_start}.py", os.path.join(path_start, "__init__.py")), iglob(f"{path_start}.*") ) module_path = next((x for x in candidates if os.path.isfile(x)), None) return parent_path, module_path, module_name def resolve_class( qualified_class_name: str, package_dir: Optional[Mapping[str, str]] = None, root_dir: Optional[_Path] = None ) -> Callable: """Given a qualified class name, return the associated class object""" root_dir = root_dir or os.getcwd() idx = qualified_class_name.rfind('.') class_name = qualified_class_name[idx + 1 :] pkg_name = qualified_class_name[:idx] _parent_path, path, module_name = _find_module(pkg_name, package_dir, root_dir) module = _load_spec(_find_spec(module_name, path), module_name) return getattr(module, class_name) def cmdclass( values: Dict[str, str], package_dir: Optional[Mapping[str, str]] = None, root_dir: Optional[_Path] = None ) -> Dict[str, Callable]: """Given a dictionary mapping command names to strings for qualified class names, apply :func:`resolve_class` to the dict values. """ return {k: resolve_class(v, package_dir, root_dir) for k, v in values.items()} def find_packages( *, namespaces=True, fill_package_dir: Optional[Dict[str, str]] = None, root_dir: Optional[_Path] = None, **kwargs ) -> List[str]: """Works similarly to :func:`setuptools.find_packages`, but with all arguments given as keyword arguments. Moreover, ``where`` can be given as a list (the results will be simply concatenated). When the additional keyword argument ``namespaces`` is ``True``, it will behave like :func:`setuptools.find_namespace_packages`` (i.e. include implicit namespaces as per :pep:`420`). The ``where`` argument will be considered relative to ``root_dir`` (or the current working directory when ``root_dir`` is not given). If the ``fill_package_dir`` argument is passed, this function will consider it as a similar data structure to the ``package_dir`` configuration parameter add fill-in any missing package location. :rtype: list """ from setuptools.discovery import construct_package_dir from setuptools.extern.more_itertools import unique_everseen, always_iterable if namespaces: from setuptools.discovery import PEP420PackageFinder as PackageFinder else: from setuptools.discovery import PackageFinder # type: ignore root_dir = root_dir or os.curdir where = kwargs.pop('where', ['.']) packages: List[str] = [] fill_package_dir = {} if fill_package_dir is None else fill_package_dir search = list(unique_everseen(always_iterable(where))) if len(search) == 1 and all(not _same_path(search[0], x) for x in (".", root_dir)): fill_package_dir.setdefault("", search[0]) for path in search: package_path = _nest_path(root_dir, path) pkgs = PackageFinder.find(package_path, **kwargs) packages.extend(pkgs) if pkgs and not ( fill_package_dir.get("") == path or os.path.samefile(package_path, root_dir) ): fill_package_dir.update(construct_package_dir(pkgs, path)) return packages def _nest_path(parent: _Path, path: _Path) -> str: path = parent if path in {".", ""} else os.path.join(parent, path) return os.path.normpath(path) def version(value: Union[Callable, Iterable[Union[str, int]], str]) -> str: """When getting the version directly from an attribute, it should be normalised to string. """ if callable(value): value = value() value = cast(Iterable[Union[str, int]], value) if not isinstance(value, str): if hasattr(value, '__iter__'): value = '.'.join(map(str, value)) else: value = '%s' % value return value def canonic_package_data(package_data: dict) -> dict: if "*" in package_data: package_data[""] = package_data.pop("*") return package_data def canonic_data_files( data_files: Union[list, dict], root_dir: Optional[_Path] = None ) -> List[Tuple[str, List[str]]]: """For compatibility with ``setup.py``, ``data_files`` should be a list of pairs instead of a dict. This function also expands glob patterns. """ if isinstance(data_files, list): return data_files return [ (dest, glob_relative(patterns, root_dir)) for dest, patterns in data_files.items() ] def entry_points(text: str, text_source="entry-points") -> Dict[str, dict]: """Given the contents of entry-points file, process it into a 2-level dictionary (``dict[str, dict[str, str]]``). The first level keys are entry-point groups, the second level keys are entry-point names, and the second level values are references to objects (that correspond to the entry-point value). """ parser = ConfigParser(default_section=None, delimiters=("=",)) # type: ignore parser.optionxform = str # case sensitive parser.read_string(text, text_source) groups = {k: dict(v.items()) for k, v in parser.items()} groups.pop(parser.default_section, None) return groups class EnsurePackagesDiscovered: """Some expand functions require all the packages to already be discovered before they run, e.g. :func:`read_attr`, :func:`resolve_class`, :func:`cmdclass`. Therefore in some cases we will need to run autodiscovery during the evaluation of the configuration. However, it is better to postpone calling package discovery as much as possible, because some parameters can influence it (e.g. ``package_dir``), and those might not have been processed yet. """ def __init__(self, distribution: "Distribution"): self._dist = distribution self._called = False def __call__(self): """Trigger the automatic package discovery, if it is still necessary.""" if not self._called: self._called = True self._dist.set_defaults(name=False) # Skip name, we can still be parsing def __enter__(self): return self def __exit__(self, _exc_type, _exc_value, _traceback): if self._called: self._dist.set_defaults.analyse_name() # Now we can set a default name def _get_package_dir(self) -> Mapping[str, str]: self() pkg_dir = self._dist.package_dir return {} if pkg_dir is None else pkg_dir @property def package_dir(self) -> Mapping[str, str]: """Proxy to ``package_dir`` that may trigger auto-discovery when used.""" return LazyMappingProxy(self._get_package_dir) class LazyMappingProxy(Mapping[_K, _V]): """Mapping proxy that delays resolving the target object, until really needed. >>> def obtain_mapping(): ... print("Running expensive function!") ... return {"key": "value", "other key": "other value"} >>> mapping = LazyMappingProxy(obtain_mapping) >>> mapping["key"] Running expensive function! 'value' >>> mapping["other key"] 'other value' """ def __init__(self, obtain_mapping_value: Callable[[], Mapping[_K, _V]]): self._obtain = obtain_mapping_value self._value: Optional[Mapping[_K, _V]] = None def _target(self) -> Mapping[_K, _V]: if self._value is None: self._value = self._obtain() return self._value def __getitem__(self, key: _K) -> _V: return self._target()[key] def __len__(self) -> int: return len(self._target()) def __iter__(self) -> Iterator[_K]: return iter(self._target())
castiel248/Convert
Lib/site-packages/setuptools/config/expand.py
Python
mit
16,319
""" Load setuptools configuration from ``pyproject.toml`` files. **PRIVATE MODULE**: API reserved for setuptools internal usage only. """ import logging import os import warnings from contextlib import contextmanager from functools import partial from typing import TYPE_CHECKING, Callable, Dict, Optional, Mapping, Union from setuptools.errors import FileError, OptionError from . import expand as _expand from ._apply_pyprojecttoml import apply as _apply from ._apply_pyprojecttoml import _PREVIOUSLY_DEFINED, _WouldIgnoreField if TYPE_CHECKING: from setuptools.dist import Distribution # noqa _Path = Union[str, os.PathLike] _logger = logging.getLogger(__name__) def load_file(filepath: _Path) -> dict: from setuptools.extern import tomli # type: ignore with open(filepath, "rb") as file: return tomli.load(file) def validate(config: dict, filepath: _Path) -> bool: from . import _validate_pyproject as validator trove_classifier = validator.FORMAT_FUNCTIONS.get("trove-classifier") if hasattr(trove_classifier, "_disable_download"): # Improve reproducibility by default. See issue 31 for validate-pyproject. trove_classifier._disable_download() # type: ignore try: return validator.validate(config) except validator.ValidationError as ex: summary = f"configuration error: {ex.summary}" if ex.name.strip("`") != "project": # Probably it is just a field missing/misnamed, not worthy the verbosity... _logger.debug(summary) _logger.debug(ex.details) error = f"invalid pyproject.toml config: {ex.name}." raise ValueError(f"{error}\n{summary}") from None def apply_configuration( dist: "Distribution", filepath: _Path, ignore_option_errors=False, ) -> "Distribution": """Apply the configuration from a ``pyproject.toml`` file into an existing distribution object. """ config = read_configuration(filepath, True, ignore_option_errors, dist) return _apply(dist, config, filepath) def read_configuration( filepath: _Path, expand=True, ignore_option_errors=False, dist: Optional["Distribution"] = None, ): """Read given configuration file and returns options from it as a dict. :param str|unicode filepath: Path to configuration file in the ``pyproject.toml`` format. :param bool expand: Whether to expand directives and other computed values (i.e. post-process the given configuration) :param bool ignore_option_errors: Whether to silently ignore options, values of which could not be resolved (e.g. due to exceptions in directives such as file:, attr:, etc.). If False exceptions are propagated as expected. :param Distribution|None: Distribution object to which the configuration refers. If not given a dummy object will be created and discarded after the configuration is read. This is used for auto-discovery of packages in the case a dynamic configuration (e.g. ``attr`` or ``cmdclass``) is expanded. When ``expand=False`` this object is simply ignored. :rtype: dict """ filepath = os.path.abspath(filepath) if not os.path.isfile(filepath): raise FileError(f"Configuration file {filepath!r} does not exist.") asdict = load_file(filepath) or {} project_table = asdict.get("project", {}) tool_table = asdict.get("tool", {}) setuptools_table = tool_table.get("setuptools", {}) if not asdict or not (project_table or setuptools_table): return {} # User is not using pyproject to configure setuptools if setuptools_table: # TODO: Remove the following once the feature stabilizes: msg = "Support for `[tool.setuptools]` in `pyproject.toml` is still *beta*." warnings.warn(msg, _BetaConfiguration) # There is an overall sense in the community that making include_package_data=True # the default would be an improvement. # `ini2toml` backfills include_package_data=False when nothing is explicitly given, # therefore setting a default here is backwards compatible. orig_setuptools_table = setuptools_table.copy() if dist and getattr(dist, "include_package_data") is not None: setuptools_table.setdefault("include-package-data", dist.include_package_data) else: setuptools_table.setdefault("include-package-data", True) # Persist changes: asdict["tool"] = tool_table tool_table["setuptools"] = setuptools_table try: # Don't complain about unrelated errors (e.g. tools not using the "tool" table) subset = {"project": project_table, "tool": {"setuptools": setuptools_table}} validate(subset, filepath) except Exception as ex: # TODO: Remove the following once the feature stabilizes: if _skip_bad_config(project_table, orig_setuptools_table, dist): return {} # TODO: After the previous statement is removed the try/except can be replaced # by the _ignore_errors context manager. if ignore_option_errors: _logger.debug(f"ignored error: {ex.__class__.__name__} - {ex}") else: raise # re-raise exception if expand: root_dir = os.path.dirname(filepath) return expand_configuration(asdict, root_dir, ignore_option_errors, dist) return asdict def _skip_bad_config( project_cfg: dict, setuptools_cfg: dict, dist: Optional["Distribution"] ) -> bool: """Be temporarily forgiving with invalid ``pyproject.toml``""" # See pypa/setuptools#3199 and pypa/cibuildwheel#1064 if dist is None or ( dist.metadata.name is None and dist.metadata.version is None and dist.install_requires is None ): # It seems that the build is not getting any configuration from other places return False if setuptools_cfg: # If `[tool.setuptools]` is set, then `pyproject.toml` config is intentional return False given_config = set(project_cfg.keys()) popular_subset = {"name", "version", "python_requires", "requires-python"} if given_config <= popular_subset: # It seems that the docs in cibuildtool has been inadvertently encouraging users # to create `pyproject.toml` files that are not compliant with the standards. # Let's be forgiving for the time being. warnings.warn(_InvalidFile.message(), _InvalidFile, stacklevel=2) return True return False def expand_configuration( config: dict, root_dir: Optional[_Path] = None, ignore_option_errors: bool = False, dist: Optional["Distribution"] = None, ) -> dict: """Given a configuration with unresolved fields (e.g. dynamic, cmdclass, ...) find their final values. :param dict config: Dict containing the configuration for the distribution :param str root_dir: Top-level directory for the distribution/project (the same directory where ``pyproject.toml`` is place) :param bool ignore_option_errors: see :func:`read_configuration` :param Distribution|None: Distribution object to which the configuration refers. If not given a dummy object will be created and discarded after the configuration is read. Used in the case a dynamic configuration (e.g. ``attr`` or ``cmdclass``). :rtype: dict """ return _ConfigExpander(config, root_dir, ignore_option_errors, dist).expand() class _ConfigExpander: def __init__( self, config: dict, root_dir: Optional[_Path] = None, ignore_option_errors: bool = False, dist: Optional["Distribution"] = None, ): self.config = config self.root_dir = root_dir or os.getcwd() self.project_cfg = config.get("project", {}) self.dynamic = self.project_cfg.get("dynamic", []) self.setuptools_cfg = config.get("tool", {}).get("setuptools", {}) self.dynamic_cfg = self.setuptools_cfg.get("dynamic", {}) self.ignore_option_errors = ignore_option_errors self._dist = dist def _ensure_dist(self) -> "Distribution": from setuptools.dist import Distribution attrs = {"src_root": self.root_dir, "name": self.project_cfg.get("name", None)} return self._dist or Distribution(attrs) def _process_field(self, container: dict, field: str, fn: Callable): if field in container: with _ignore_errors(self.ignore_option_errors): container[field] = fn(container[field]) def _canonic_package_data(self, field="package-data"): package_data = self.setuptools_cfg.get(field, {}) return _expand.canonic_package_data(package_data) def expand(self): self._expand_packages() self._canonic_package_data() self._canonic_package_data("exclude-package-data") # A distribution object is required for discovering the correct package_dir dist = self._ensure_dist() ctx = _EnsurePackagesDiscovered(dist, self.project_cfg, self.setuptools_cfg) with ctx as ensure_discovered: package_dir = ensure_discovered.package_dir self._expand_data_files() self._expand_cmdclass(package_dir) self._expand_all_dynamic(dist, package_dir) return self.config def _expand_packages(self): packages = self.setuptools_cfg.get("packages") if packages is None or isinstance(packages, (list, tuple)): return find = packages.get("find") if isinstance(find, dict): find["root_dir"] = self.root_dir find["fill_package_dir"] = self.setuptools_cfg.setdefault("package-dir", {}) with _ignore_errors(self.ignore_option_errors): self.setuptools_cfg["packages"] = _expand.find_packages(**find) def _expand_data_files(self): data_files = partial(_expand.canonic_data_files, root_dir=self.root_dir) self._process_field(self.setuptools_cfg, "data-files", data_files) def _expand_cmdclass(self, package_dir: Mapping[str, str]): root_dir = self.root_dir cmdclass = partial(_expand.cmdclass, package_dir=package_dir, root_dir=root_dir) self._process_field(self.setuptools_cfg, "cmdclass", cmdclass) def _expand_all_dynamic(self, dist: "Distribution", package_dir: Mapping[str, str]): special = ( # need special handling "version", "readme", "entry-points", "scripts", "gui-scripts", "classifiers", "dependencies", "optional-dependencies", ) # `_obtain` functions are assumed to raise appropriate exceptions/warnings. obtained_dynamic = { field: self._obtain(dist, field, package_dir) for field in self.dynamic if field not in special } obtained_dynamic.update( self._obtain_entry_points(dist, package_dir) or {}, version=self._obtain_version(dist, package_dir), readme=self._obtain_readme(dist), classifiers=self._obtain_classifiers(dist), dependencies=self._obtain_dependencies(dist), optional_dependencies=self._obtain_optional_dependencies(dist), ) # `None` indicates there is nothing in `tool.setuptools.dynamic` but the value # might have already been set by setup.py/extensions, so avoid overwriting. updates = {k: v for k, v in obtained_dynamic.items() if v is not None} self.project_cfg.update(updates) def _ensure_previously_set(self, dist: "Distribution", field: str): previous = _PREVIOUSLY_DEFINED[field](dist) if previous is None and not self.ignore_option_errors: msg = ( f"No configuration found for dynamic {field!r}.\n" "Some dynamic fields need to be specified via `tool.setuptools.dynamic`" "\nothers must be specified via the equivalent attribute in `setup.py`." ) raise OptionError(msg) def _expand_directive( self, specifier: str, directive, package_dir: Mapping[str, str] ): with _ignore_errors(self.ignore_option_errors): root_dir = self.root_dir if "file" in directive: return _expand.read_files(directive["file"], root_dir) if "attr" in directive: return _expand.read_attr(directive["attr"], package_dir, root_dir) raise ValueError(f"invalid `{specifier}`: {directive!r}") return None def _obtain(self, dist: "Distribution", field: str, package_dir: Mapping[str, str]): if field in self.dynamic_cfg: return self._expand_directive( f"tool.setuptools.dynamic.{field}", self.dynamic_cfg[field], package_dir, ) self._ensure_previously_set(dist, field) return None def _obtain_version(self, dist: "Distribution", package_dir: Mapping[str, str]): # Since plugins can set version, let's silently skip if it cannot be obtained if "version" in self.dynamic and "version" in self.dynamic_cfg: return _expand.version(self._obtain(dist, "version", package_dir)) return None def _obtain_readme(self, dist: "Distribution") -> Optional[Dict[str, str]]: if "readme" not in self.dynamic: return None dynamic_cfg = self.dynamic_cfg if "readme" in dynamic_cfg: return { "text": self._obtain(dist, "readme", {}), "content-type": dynamic_cfg["readme"].get("content-type", "text/x-rst"), } self._ensure_previously_set(dist, "readme") return None def _obtain_entry_points( self, dist: "Distribution", package_dir: Mapping[str, str] ) -> Optional[Dict[str, dict]]: fields = ("entry-points", "scripts", "gui-scripts") if not any(field in self.dynamic for field in fields): return None text = self._obtain(dist, "entry-points", package_dir) if text is None: return None groups = _expand.entry_points(text) expanded = {"entry-points": groups} def _set_scripts(field: str, group: str): if group in groups: value = groups.pop(group) if field not in self.dynamic: msg = _WouldIgnoreField.message(field, value) warnings.warn(msg, _WouldIgnoreField) # TODO: Don't set field when support for pyproject.toml stabilizes # instead raise an error as specified in PEP 621 expanded[field] = value _set_scripts("scripts", "console_scripts") _set_scripts("gui-scripts", "gui_scripts") return expanded def _obtain_classifiers(self, dist: "Distribution"): if "classifiers" in self.dynamic: value = self._obtain(dist, "classifiers", {}) if value: return value.splitlines() return None def _obtain_dependencies(self, dist: "Distribution"): if "dependencies" in self.dynamic: value = self._obtain(dist, "dependencies", {}) if value: return _parse_requirements_list(value) return None def _obtain_optional_dependencies(self, dist: "Distribution"): if "optional-dependencies" not in self.dynamic: return None if "optional-dependencies" in self.dynamic_cfg: optional_dependencies_map = self.dynamic_cfg["optional-dependencies"] assert isinstance(optional_dependencies_map, dict) return { group: _parse_requirements_list(self._expand_directive( f"tool.setuptools.dynamic.optional-dependencies.{group}", directive, {}, )) for group, directive in optional_dependencies_map.items() } self._ensure_previously_set(dist, "optional-dependencies") return None def _parse_requirements_list(value): return [ line for line in value.splitlines() if line.strip() and not line.strip().startswith("#") ] @contextmanager def _ignore_errors(ignore_option_errors: bool): if not ignore_option_errors: yield return try: yield except Exception as ex: _logger.debug(f"ignored error: {ex.__class__.__name__} - {ex}") class _EnsurePackagesDiscovered(_expand.EnsurePackagesDiscovered): def __init__( self, distribution: "Distribution", project_cfg: dict, setuptools_cfg: dict ): super().__init__(distribution) self._project_cfg = project_cfg self._setuptools_cfg = setuptools_cfg def __enter__(self): """When entering the context, the values of ``packages``, ``py_modules`` and ``package_dir`` that are missing in ``dist`` are copied from ``setuptools_cfg``. """ dist, cfg = self._dist, self._setuptools_cfg package_dir: Dict[str, str] = cfg.setdefault("package-dir", {}) package_dir.update(dist.package_dir or {}) dist.package_dir = package_dir # needs to be the same object dist.set_defaults._ignore_ext_modules() # pyproject.toml-specific behaviour # Set `name`, `py_modules` and `packages` in dist to short-circuit # auto-discovery, but avoid overwriting empty lists purposefully set by users. if dist.metadata.name is None: dist.metadata.name = self._project_cfg.get("name") if dist.py_modules is None: dist.py_modules = cfg.get("py-modules") if dist.packages is None: dist.packages = cfg.get("packages") return super().__enter__() def __exit__(self, exc_type, exc_value, traceback): """When exiting the context, if values of ``packages``, ``py_modules`` and ``package_dir`` are missing in ``setuptools_cfg``, copy from ``dist``. """ # If anything was discovered set them back, so they count in the final config. self._setuptools_cfg.setdefault("packages", self._dist.packages) self._setuptools_cfg.setdefault("py-modules", self._dist.py_modules) return super().__exit__(exc_type, exc_value, traceback) class _BetaConfiguration(UserWarning): """Explicitly inform users that some `pyproject.toml` configuration is *beta*""" class _InvalidFile(UserWarning): """The given `pyproject.toml` file is invalid and would be ignored. !!\n\n ############################ # Invalid `pyproject.toml` # ############################ Any configurations in `pyproject.toml` will be ignored. Please note that future releases of setuptools will halt the build process if an invalid file is given. To prevent setuptools from considering `pyproject.toml` please DO NOT include the `[project]` or `[tool.setuptools]` tables in your file. \n\n!! """ @classmethod def message(cls): from inspect import cleandoc return cleandoc(cls.__doc__)
castiel248/Convert
Lib/site-packages/setuptools/config/pyprojecttoml.py
Python
mit
19,304
""" Load setuptools configuration from ``setup.cfg`` files. **API will be made private in the future** """ import os import contextlib import functools import warnings from collections import defaultdict from functools import partial from functools import wraps from typing import (TYPE_CHECKING, Callable, Any, Dict, Generic, Iterable, List, Optional, Tuple, TypeVar, Union) from distutils.errors import DistutilsOptionError, DistutilsFileError from setuptools.extern.packaging.requirements import Requirement, InvalidRequirement from setuptools.extern.packaging.version import Version, InvalidVersion from setuptools.extern.packaging.specifiers import SpecifierSet from setuptools._deprecation_warning import SetuptoolsDeprecationWarning from . import expand if TYPE_CHECKING: from setuptools.dist import Distribution # noqa from distutils.dist import DistributionMetadata # noqa _Path = Union[str, os.PathLike] SingleCommandOptions = Dict["str", Tuple["str", Any]] """Dict that associate the name of the options of a particular command to a tuple. The first element of the tuple indicates the origin of the option value (e.g. the name of the configuration file where it was read from), while the second element of the tuple is the option value itself """ AllCommandOptions = Dict["str", SingleCommandOptions] # cmd name => its options Target = TypeVar("Target", bound=Union["Distribution", "DistributionMetadata"]) def read_configuration( filepath: _Path, find_others=False, ignore_option_errors=False ) -> dict: """Read given configuration file and returns options from it as a dict. :param str|unicode filepath: Path to configuration file to get options from. :param bool find_others: Whether to search for other configuration files which could be on in various places. :param bool ignore_option_errors: Whether to silently ignore options, values of which could not be resolved (e.g. due to exceptions in directives such as file:, attr:, etc.). If False exceptions are propagated as expected. :rtype: dict """ from setuptools.dist import Distribution dist = Distribution() filenames = dist.find_config_files() if find_others else [] handlers = _apply(dist, filepath, filenames, ignore_option_errors) return configuration_to_dict(handlers) def apply_configuration(dist: "Distribution", filepath: _Path) -> "Distribution": """Apply the configuration from a ``setup.cfg`` file into an existing distribution object. """ _apply(dist, filepath) dist._finalize_requires() return dist def _apply( dist: "Distribution", filepath: _Path, other_files: Iterable[_Path] = (), ignore_option_errors: bool = False, ) -> Tuple["ConfigHandler", ...]: """Read configuration from ``filepath`` and applies to the ``dist`` object.""" from setuptools.dist import _Distribution filepath = os.path.abspath(filepath) if not os.path.isfile(filepath): raise DistutilsFileError('Configuration file %s does not exist.' % filepath) current_directory = os.getcwd() os.chdir(os.path.dirname(filepath)) filenames = [*other_files, filepath] try: _Distribution.parse_config_files(dist, filenames=filenames) handlers = parse_configuration( dist, dist.command_options, ignore_option_errors=ignore_option_errors ) dist._finalize_license_files() finally: os.chdir(current_directory) return handlers def _get_option(target_obj: Target, key: str): """ Given a target object and option key, get that option from the target object, either through a get_{key} method or from an attribute directly. """ getter_name = 'get_{key}'.format(**locals()) by_attribute = functools.partial(getattr, target_obj, key) getter = getattr(target_obj, getter_name, by_attribute) return getter() def configuration_to_dict(handlers: Tuple["ConfigHandler", ...]) -> dict: """Returns configuration data gathered by given handlers as a dict. :param list[ConfigHandler] handlers: Handlers list, usually from parse_configuration() :rtype: dict """ config_dict: dict = defaultdict(dict) for handler in handlers: for option in handler.set_options: value = _get_option(handler.target_obj, option) config_dict[handler.section_prefix][option] = value return config_dict def parse_configuration( distribution: "Distribution", command_options: AllCommandOptions, ignore_option_errors=False ) -> Tuple["ConfigMetadataHandler", "ConfigOptionsHandler"]: """Performs additional parsing of configuration options for a distribution. Returns a list of used option handlers. :param Distribution distribution: :param dict command_options: :param bool ignore_option_errors: Whether to silently ignore options, values of which could not be resolved (e.g. due to exceptions in directives such as file:, attr:, etc.). If False exceptions are propagated as expected. :rtype: list """ with expand.EnsurePackagesDiscovered(distribution) as ensure_discovered: options = ConfigOptionsHandler( distribution, command_options, ignore_option_errors, ensure_discovered, ) options.parse() if not distribution.package_dir: distribution.package_dir = options.package_dir # Filled by `find_packages` meta = ConfigMetadataHandler( distribution.metadata, command_options, ignore_option_errors, ensure_discovered, distribution.package_dir, distribution.src_root, ) meta.parse() return meta, options def _warn_accidental_env_marker_misconfig(label: str, orig_value: str, parsed: list): """Because users sometimes misinterpret this configuration: [options.extras_require] foo = bar;python_version<"4" It looks like one requirement with an environment marker but because there is no newline, it's parsed as two requirements with a semicolon as separator. Therefore, if: * input string does not contain a newline AND * parsed result contains two requirements AND * parsing of the two parts from the result ("<first>;<second>") leads in a valid Requirement with a valid marker a UserWarning is shown to inform the user about the possible problem. """ if "\n" in orig_value or len(parsed) != 2: return with contextlib.suppress(InvalidRequirement): original_requirements_str = ";".join(parsed) req = Requirement(original_requirements_str) if req.marker is not None: msg = ( f"One of the parsed requirements in `{label}` " f"looks like a valid environment marker: '{parsed[1]}'\n" "Make sure that the config is correct and check " "https://setuptools.pypa.io/en/latest/userguide/declarative_config.html#opt-2" # noqa: E501 ) warnings.warn(msg, UserWarning) class ConfigHandler(Generic[Target]): """Handles metadata supplied in configuration files.""" section_prefix: str """Prefix for config sections handled by this handler. Must be provided by class heirs. """ aliases: Dict[str, str] = {} """Options aliases. For compatibility with various packages. E.g.: d2to1 and pbr. Note: `-` in keys is replaced with `_` by config parser. """ def __init__( self, target_obj: Target, options: AllCommandOptions, ignore_option_errors, ensure_discovered: expand.EnsurePackagesDiscovered, ): sections: AllCommandOptions = {} section_prefix = self.section_prefix for section_name, section_options in options.items(): if not section_name.startswith(section_prefix): continue section_name = section_name.replace(section_prefix, '').strip('.') sections[section_name] = section_options self.ignore_option_errors = ignore_option_errors self.target_obj = target_obj self.sections = sections self.set_options: List[str] = [] self.ensure_discovered = ensure_discovered @property def parsers(self): """Metadata item name to parser function mapping.""" raise NotImplementedError( '%s must provide .parsers property' % self.__class__.__name__ ) def __setitem__(self, option_name, value): unknown = tuple() target_obj = self.target_obj # Translate alias into real name. option_name = self.aliases.get(option_name, option_name) current_value = getattr(target_obj, option_name, unknown) if current_value is unknown: raise KeyError(option_name) if current_value: # Already inhabited. Skipping. return skip_option = False parser = self.parsers.get(option_name) if parser: try: value = parser(value) except Exception: skip_option = True if not self.ignore_option_errors: raise if skip_option: return setter = getattr(target_obj, 'set_%s' % option_name, None) if setter is None: setattr(target_obj, option_name, value) else: setter(value) self.set_options.append(option_name) @classmethod def _parse_list(cls, value, separator=','): """Represents value as a list. Value is split either by separator (defaults to comma) or by lines. :param value: :param separator: List items separator character. :rtype: list """ if isinstance(value, list): # _get_parser_compound case return value if '\n' in value: value = value.splitlines() else: value = value.split(separator) return [chunk.strip() for chunk in value if chunk.strip()] @classmethod def _parse_dict(cls, value): """Represents value as a dict. :param value: :rtype: dict """ separator = '=' result = {} for line in cls._parse_list(value): key, sep, val = line.partition(separator) if sep != separator: raise DistutilsOptionError( 'Unable to parse option value to dict: %s' % value ) result[key.strip()] = val.strip() return result @classmethod def _parse_bool(cls, value): """Represents value as boolean. :param value: :rtype: bool """ value = value.lower() return value in ('1', 'true', 'yes') @classmethod def _exclude_files_parser(cls, key): """Returns a parser function to make sure field inputs are not files. Parses a value after getting the key so error messages are more informative. :param key: :rtype: callable """ def parser(value): exclude_directive = 'file:' if value.startswith(exclude_directive): raise ValueError( 'Only strings are accepted for the {0} field, ' 'files are not accepted'.format(key) ) return value return parser @classmethod def _parse_file(cls, value, root_dir: _Path): """Represents value as a string, allowing including text from nearest files using `file:` directive. Directive is sandboxed and won't reach anything outside directory with setup.py. Examples: file: README.rst, CHANGELOG.md, src/file.txt :param str value: :rtype: str """ include_directive = 'file:' if not isinstance(value, str): return value if not value.startswith(include_directive): return value spec = value[len(include_directive) :] filepaths = (path.strip() for path in spec.split(',')) return expand.read_files(filepaths, root_dir) def _parse_attr(self, value, package_dir, root_dir: _Path): """Represents value as a module attribute. Examples: attr: package.attr attr: package.module.attr :param str value: :rtype: str """ attr_directive = 'attr:' if not value.startswith(attr_directive): return value attr_desc = value.replace(attr_directive, '') # Make sure package_dir is populated correctly, so `attr:` directives can work package_dir.update(self.ensure_discovered.package_dir) return expand.read_attr(attr_desc, package_dir, root_dir) @classmethod def _get_parser_compound(cls, *parse_methods): """Returns parser function to represents value as a list. Parses a value applying given methods one after another. :param parse_methods: :rtype: callable """ def parse(value): parsed = value for method in parse_methods: parsed = method(parsed) return parsed return parse @classmethod def _parse_section_to_dict_with_key(cls, section_options, values_parser): """Parses section options into a dictionary. Applies a given parser to each option in a section. :param dict section_options: :param callable values_parser: function with 2 args corresponding to key, value :rtype: dict """ value = {} for key, (_, val) in section_options.items(): value[key] = values_parser(key, val) return value @classmethod def _parse_section_to_dict(cls, section_options, values_parser=None): """Parses section options into a dictionary. Optionally applies a given parser to each value. :param dict section_options: :param callable values_parser: function with 1 arg corresponding to option value :rtype: dict """ parser = (lambda _, v: values_parser(v)) if values_parser else (lambda _, v: v) return cls._parse_section_to_dict_with_key(section_options, parser) def parse_section(self, section_options): """Parses configuration file section. :param dict section_options: """ for (name, (_, value)) in section_options.items(): with contextlib.suppress(KeyError): # Keep silent for a new option may appear anytime. self[name] = value def parse(self): """Parses configuration file items from one or more related sections. """ for section_name, section_options in self.sections.items(): method_postfix = '' if section_name: # [section.option] variant method_postfix = '_%s' % section_name section_parser_method: Optional[Callable] = getattr( self, # Dots in section names are translated into dunderscores. ('parse_section%s' % method_postfix).replace('.', '__'), None, ) if section_parser_method is None: raise DistutilsOptionError( 'Unsupported distribution option section: [%s.%s]' % (self.section_prefix, section_name) ) section_parser_method(section_options) def _deprecated_config_handler(self, func, msg, warning_class): """this function will wrap around parameters that are deprecated :param msg: deprecation message :param warning_class: class of warning exception to be raised :param func: function to be wrapped around """ @wraps(func) def config_handler(*args, **kwargs): warnings.warn(msg, warning_class) return func(*args, **kwargs) return config_handler class ConfigMetadataHandler(ConfigHandler["DistributionMetadata"]): section_prefix = 'metadata' aliases = { 'home_page': 'url', 'summary': 'description', 'classifier': 'classifiers', 'platform': 'platforms', } strict_mode = False """We need to keep it loose, to be partially compatible with `pbr` and `d2to1` packages which also uses `metadata` section. """ def __init__( self, target_obj: "DistributionMetadata", options: AllCommandOptions, ignore_option_errors: bool, ensure_discovered: expand.EnsurePackagesDiscovered, package_dir: Optional[dict] = None, root_dir: _Path = os.curdir ): super().__init__(target_obj, options, ignore_option_errors, ensure_discovered) self.package_dir = package_dir self.root_dir = root_dir @property def parsers(self): """Metadata item name to parser function mapping.""" parse_list = self._parse_list parse_file = partial(self._parse_file, root_dir=self.root_dir) parse_dict = self._parse_dict exclude_files_parser = self._exclude_files_parser return { 'platforms': parse_list, 'keywords': parse_list, 'provides': parse_list, 'requires': self._deprecated_config_handler( parse_list, "The requires parameter is deprecated, please use " "install_requires for runtime dependencies.", SetuptoolsDeprecationWarning, ), 'obsoletes': parse_list, 'classifiers': self._get_parser_compound(parse_file, parse_list), 'license': exclude_files_parser('license'), 'license_file': self._deprecated_config_handler( exclude_files_parser('license_file'), "The license_file parameter is deprecated, " "use license_files instead.", SetuptoolsDeprecationWarning, ), 'license_files': parse_list, 'description': parse_file, 'long_description': parse_file, 'version': self._parse_version, 'project_urls': parse_dict, } def _parse_version(self, value): """Parses `version` option value. :param value: :rtype: str """ version = self._parse_file(value, self.root_dir) if version != value: version = version.strip() # Be strict about versions loaded from file because it's easy to # accidentally include newlines and other unintended content try: Version(version) except InvalidVersion: tmpl = ( 'Version loaded from {value} does not ' 'comply with PEP 440: {version}' ) raise DistutilsOptionError(tmpl.format(**locals())) return version return expand.version(self._parse_attr(value, self.package_dir, self.root_dir)) class ConfigOptionsHandler(ConfigHandler["Distribution"]): section_prefix = 'options' def __init__( self, target_obj: "Distribution", options: AllCommandOptions, ignore_option_errors: bool, ensure_discovered: expand.EnsurePackagesDiscovered, ): super().__init__(target_obj, options, ignore_option_errors, ensure_discovered) self.root_dir = target_obj.src_root self.package_dir: Dict[str, str] = {} # To be filled by `find_packages` @classmethod def _parse_list_semicolon(cls, value): return cls._parse_list(value, separator=';') def _parse_file_in_root(self, value): return self._parse_file(value, root_dir=self.root_dir) def _parse_requirements_list(self, label: str, value: str): # Parse a requirements list, either by reading in a `file:`, or a list. parsed = self._parse_list_semicolon(self._parse_file_in_root(value)) _warn_accidental_env_marker_misconfig(label, value, parsed) # Filter it to only include lines that are not comments. `parse_list` # will have stripped each line and filtered out empties. return [line for line in parsed if not line.startswith("#")] @property def parsers(self): """Metadata item name to parser function mapping.""" parse_list = self._parse_list parse_bool = self._parse_bool parse_dict = self._parse_dict parse_cmdclass = self._parse_cmdclass return { 'zip_safe': parse_bool, 'include_package_data': parse_bool, 'package_dir': parse_dict, 'scripts': parse_list, 'eager_resources': parse_list, 'dependency_links': parse_list, 'namespace_packages': self._deprecated_config_handler( parse_list, "The namespace_packages parameter is deprecated, " "consider using implicit namespaces instead (PEP 420).", SetuptoolsDeprecationWarning, ), 'install_requires': partial( self._parse_requirements_list, "install_requires" ), 'setup_requires': self._parse_list_semicolon, 'tests_require': self._parse_list_semicolon, 'packages': self._parse_packages, 'entry_points': self._parse_file_in_root, 'py_modules': parse_list, 'python_requires': SpecifierSet, 'cmdclass': parse_cmdclass, } def _parse_cmdclass(self, value): package_dir = self.ensure_discovered.package_dir return expand.cmdclass(self._parse_dict(value), package_dir, self.root_dir) def _parse_packages(self, value): """Parses `packages` option value. :param value: :rtype: list """ find_directives = ['find:', 'find_namespace:'] trimmed_value = value.strip() if trimmed_value not in find_directives: return self._parse_list(value) # Read function arguments from a dedicated section. find_kwargs = self.parse_section_packages__find( self.sections.get('packages.find', {}) ) find_kwargs.update( namespaces=(trimmed_value == find_directives[1]), root_dir=self.root_dir, fill_package_dir=self.package_dir, ) return expand.find_packages(**find_kwargs) def parse_section_packages__find(self, section_options): """Parses `packages.find` configuration file section. To be used in conjunction with _parse_packages(). :param dict section_options: """ section_data = self._parse_section_to_dict(section_options, self._parse_list) valid_keys = ['where', 'include', 'exclude'] find_kwargs = dict( [(k, v) for k, v in section_data.items() if k in valid_keys and v] ) where = find_kwargs.get('where') if where is not None: find_kwargs['where'] = where[0] # cast list to single val return find_kwargs def parse_section_entry_points(self, section_options): """Parses `entry_points` configuration file section. :param dict section_options: """ parsed = self._parse_section_to_dict(section_options, self._parse_list) self['entry_points'] = parsed def _parse_package_data(self, section_options): package_data = self._parse_section_to_dict(section_options, self._parse_list) return expand.canonic_package_data(package_data) def parse_section_package_data(self, section_options): """Parses `package_data` configuration file section. :param dict section_options: """ self['package_data'] = self._parse_package_data(section_options) def parse_section_exclude_package_data(self, section_options): """Parses `exclude_package_data` configuration file section. :param dict section_options: """ self['exclude_package_data'] = self._parse_package_data(section_options) def parse_section_extras_require(self, section_options): """Parses `extras_require` configuration file section. :param dict section_options: """ parsed = self._parse_section_to_dict_with_key( section_options, lambda k, v: self._parse_requirements_list(f"extras_require[{k}]", v) ) self['extras_require'] = parsed def parse_section_data_files(self, section_options): """Parses `data_files` configuration file section. :param dict section_options: """ parsed = self._parse_section_to_dict(section_options, self._parse_list) self['data_files'] = expand.canonic_data_files(parsed, self.root_dir)
castiel248/Convert
Lib/site-packages/setuptools/config/setupcfg.py
Python
mit
25,198
from distutils.dep_util import newer_group # yes, this is was almost entirely copy-pasted from # 'newer_pairwise()', this is just another convenience # function. def newer_pairwise_group(sources_groups, targets): """Walk both arguments in parallel, testing if each source group is newer than its corresponding target. Returns a pair of lists (sources_groups, targets) where sources is newer than target, according to the semantics of 'newer_group()'. """ if len(sources_groups) != len(targets): raise ValueError( "'sources_group' and 'targets' must be the same length") # build a pair of lists (sources_groups, targets) where source is newer n_sources = [] n_targets = [] for i in range(len(sources_groups)): if newer_group(sources_groups[i], targets[i]): n_sources.append(sources_groups[i]) n_targets.append(targets[i]) return n_sources, n_targets
castiel248/Convert
Lib/site-packages/setuptools/dep_util.py
Python
mit
949
import sys import marshal import contextlib import dis from setuptools.extern.packaging import version from ._imp import find_module, PY_COMPILED, PY_FROZEN, PY_SOURCE from . import _imp __all__ = [ 'Require', 'find_module', 'get_module_constant', 'extract_constant' ] class Require: """A prerequisite to building or installing a distribution""" def __init__( self, name, requested_version, module, homepage='', attribute=None, format=None): if format is None and requested_version is not None: format = version.Version if format is not None: requested_version = format(requested_version) if attribute is None: attribute = '__version__' self.__dict__.update(locals()) del self.self def full_name(self): """Return full package/distribution name, w/version""" if self.requested_version is not None: return '%s-%s' % (self.name, self.requested_version) return self.name def version_ok(self, version): """Is 'version' sufficiently up-to-date?""" return self.attribute is None or self.format is None or \ str(version) != "unknown" and self.format(version) >= self.requested_version def get_version(self, paths=None, default="unknown"): """Get version number of installed module, 'None', or 'default' Search 'paths' for module. If not found, return 'None'. If found, return the extracted version attribute, or 'default' if no version attribute was specified, or the value cannot be determined without importing the module. The version is formatted according to the requirement's version format (if any), unless it is 'None' or the supplied 'default'. """ if self.attribute is None: try: f, p, i = find_module(self.module, paths) if f: f.close() return default except ImportError: return None v = get_module_constant(self.module, self.attribute, default, paths) if v is not None and v is not default and self.format is not None: return self.format(v) return v def is_present(self, paths=None): """Return true if dependency is present on 'paths'""" return self.get_version(paths) is not None def is_current(self, paths=None): """Return true if dependency is present and up-to-date on 'paths'""" version = self.get_version(paths) if version is None: return False return self.version_ok(str(version)) def maybe_close(f): @contextlib.contextmanager def empty(): yield return if not f: return empty() return contextlib.closing(f) def get_module_constant(module, symbol, default=-1, paths=None): """Find 'module' by searching 'paths', and extract 'symbol' Return 'None' if 'module' does not exist on 'paths', or it does not define 'symbol'. If the module defines 'symbol' as a constant, return the constant. Otherwise, return 'default'.""" try: f, path, (suffix, mode, kind) = info = find_module(module, paths) except ImportError: # Module doesn't exist return None with maybe_close(f): if kind == PY_COMPILED: f.read(8) # skip magic & date code = marshal.load(f) elif kind == PY_FROZEN: code = _imp.get_frozen_object(module, paths) elif kind == PY_SOURCE: code = compile(f.read(), path, 'exec') else: # Not something we can parse; we'll have to import it. :( imported = _imp.get_module(module, paths, info) return getattr(imported, symbol, None) return extract_constant(code, symbol, default) def extract_constant(code, symbol, default=-1): """Extract the constant value of 'symbol' from 'code' If the name 'symbol' is bound to a constant value by the Python code object 'code', return that value. If 'symbol' is bound to an expression, return 'default'. Otherwise, return 'None'. Return value is based on the first assignment to 'symbol'. 'symbol' must be a global, or at least a non-"fast" local in the code block. That is, only 'STORE_NAME' and 'STORE_GLOBAL' opcodes are checked, and 'symbol' must be present in 'code.co_names'. """ if symbol not in code.co_names: # name's not there, can't possibly be an assignment return None name_idx = list(code.co_names).index(symbol) STORE_NAME = 90 STORE_GLOBAL = 97 LOAD_CONST = 100 const = default for byte_code in dis.Bytecode(code): op = byte_code.opcode arg = byte_code.arg if op == LOAD_CONST: const = code.co_consts[arg] elif arg == name_idx and (op == STORE_NAME or op == STORE_GLOBAL): return const else: const = default def _update_globals(): """ Patch the globals to remove the objects not available on some platforms. XXX it'd be better to test assertions about bytecode instead. """ if not sys.platform.startswith('java') and sys.platform != 'cli': return incompatible = 'extract_constant', 'get_module_constant' for name in incompatible: del globals()[name] __all__.remove(name) _update_globals()
castiel248/Convert
Lib/site-packages/setuptools/depends.py
Python
mit
5,499
"""Automatic discovery of Python modules and packages (for inclusion in the distribution) and other config values. For the purposes of this module, the following nomenclature is used: - "src-layout": a directory representing a Python project that contains a "src" folder. Everything under the "src" folder is meant to be included in the distribution when packaging the project. Example:: . ├── tox.ini ├── pyproject.toml └── src/ └── mypkg/ ├── __init__.py ├── mymodule.py └── my_data_file.txt - "flat-layout": a Python project that does not use "src-layout" but instead have a directory under the project root for each package:: . ├── tox.ini ├── pyproject.toml └── mypkg/ ├── __init__.py ├── mymodule.py └── my_data_file.txt - "single-module": a project that contains a single Python script direct under the project root (no directory used):: . ├── tox.ini ├── pyproject.toml └── mymodule.py """ import itertools import os from fnmatch import fnmatchcase from glob import glob from pathlib import Path from typing import ( TYPE_CHECKING, Callable, Dict, Iterable, Iterator, List, Mapping, Optional, Tuple, Union ) import _distutils_hack.override # noqa: F401 from distutils import log from distutils.util import convert_path _Path = Union[str, os.PathLike] _Filter = Callable[[str], bool] StrIter = Iterator[str] chain_iter = itertools.chain.from_iterable if TYPE_CHECKING: from setuptools import Distribution # noqa def _valid_name(path: _Path) -> bool: # Ignore invalid names that cannot be imported directly return os.path.basename(path).isidentifier() class _Finder: """Base class that exposes functionality for module/package finders""" ALWAYS_EXCLUDE: Tuple[str, ...] = () DEFAULT_EXCLUDE: Tuple[str, ...] = () @classmethod def find( cls, where: _Path = '.', exclude: Iterable[str] = (), include: Iterable[str] = ('*',) ) -> List[str]: """Return a list of all Python items (packages or modules, depending on the finder implementation) found within directory 'where'. 'where' is the root directory which will be searched. It should be supplied as a "cross-platform" (i.e. URL-style) path; it will be converted to the appropriate local path syntax. 'exclude' is a sequence of names to exclude; '*' can be used as a wildcard in the names. When finding packages, 'foo.*' will exclude all subpackages of 'foo' (but not 'foo' itself). 'include' is a sequence of names to include. If it's specified, only the named items will be included. If it's not specified, all found items will be included. 'include' can contain shell style wildcard patterns just like 'exclude'. """ exclude = exclude or cls.DEFAULT_EXCLUDE return list( cls._find_iter( convert_path(str(where)), cls._build_filter(*cls.ALWAYS_EXCLUDE, *exclude), cls._build_filter(*include), ) ) @classmethod def _find_iter(cls, where: _Path, exclude: _Filter, include: _Filter) -> StrIter: raise NotImplementedError @staticmethod def _build_filter(*patterns: str) -> _Filter: """ Given a list of patterns, return a callable that will be true only if the input matches at least one of the patterns. """ return lambda name: any(fnmatchcase(name, pat) for pat in patterns) class PackageFinder(_Finder): """ Generate a list of all Python packages found within a directory """ ALWAYS_EXCLUDE = ("ez_setup", "*__pycache__") @classmethod def _find_iter(cls, where: _Path, exclude: _Filter, include: _Filter) -> StrIter: """ All the packages found in 'where' that pass the 'include' filter, but not the 'exclude' filter. """ for root, dirs, files in os.walk(str(where), followlinks=True): # Copy dirs to iterate over it, then empty dirs. all_dirs = dirs[:] dirs[:] = [] for dir in all_dirs: full_path = os.path.join(root, dir) rel_path = os.path.relpath(full_path, where) package = rel_path.replace(os.path.sep, '.') # Skip directory trees that are not valid packages if '.' in dir or not cls._looks_like_package(full_path, package): continue # Should this package be included? if include(package) and not exclude(package): yield package # Keep searching subdirectories, as there may be more packages # down there, even if the parent was excluded. dirs.append(dir) @staticmethod def _looks_like_package(path: _Path, _package_name: str) -> bool: """Does a directory look like a package?""" return os.path.isfile(os.path.join(path, '__init__.py')) class PEP420PackageFinder(PackageFinder): @staticmethod def _looks_like_package(_path: _Path, _package_name: str) -> bool: return True class ModuleFinder(_Finder): """Find isolated Python modules. This function will **not** recurse subdirectories. """ @classmethod def _find_iter(cls, where: _Path, exclude: _Filter, include: _Filter) -> StrIter: for file in glob(os.path.join(where, "*.py")): module, _ext = os.path.splitext(os.path.basename(file)) if not cls._looks_like_module(module): continue if include(module) and not exclude(module): yield module _looks_like_module = staticmethod(_valid_name) # We have to be extra careful in the case of flat layout to not include files # and directories not meant for distribution (e.g. tool-related) class FlatLayoutPackageFinder(PEP420PackageFinder): _EXCLUDE = ( "ci", "bin", "doc", "docs", "documentation", "manpages", "news", "changelog", "test", "tests", "unit_test", "unit_tests", "example", "examples", "scripts", "tools", "util", "utils", "python", "build", "dist", "venv", "env", "requirements", # ---- Task runners / Build tools ---- "tasks", # invoke "fabfile", # fabric "site_scons", # SCons # ---- Other tools ---- "benchmark", "benchmarks", "exercise", "exercises", # ---- Hidden directories/Private packages ---- "[._]*", ) DEFAULT_EXCLUDE = tuple(chain_iter((p, f"{p}.*") for p in _EXCLUDE)) """Reserved package names""" @staticmethod def _looks_like_package(_path: _Path, package_name: str) -> bool: names = package_name.split('.') # Consider PEP 561 root_pkg_is_valid = names[0].isidentifier() or names[0].endswith("-stubs") return root_pkg_is_valid and all(name.isidentifier() for name in names[1:]) class FlatLayoutModuleFinder(ModuleFinder): DEFAULT_EXCLUDE = ( "setup", "conftest", "test", "tests", "example", "examples", "build", # ---- Task runners ---- "toxfile", "noxfile", "pavement", "dodo", "tasks", "fabfile", # ---- Other tools ---- "[Ss][Cc]onstruct", # SCons "conanfile", # Connan: C/C++ build tool "manage", # Django "benchmark", "benchmarks", "exercise", "exercises", # ---- Hidden files/Private modules ---- "[._]*", ) """Reserved top-level module names""" def _find_packages_within(root_pkg: str, pkg_dir: _Path) -> List[str]: nested = PEP420PackageFinder.find(pkg_dir) return [root_pkg] + [".".join((root_pkg, n)) for n in nested] class ConfigDiscovery: """Fill-in metadata and options that can be automatically derived (from other metadata/options, the file system or conventions) """ def __init__(self, distribution: "Distribution"): self.dist = distribution self._called = False self._disabled = False self._skip_ext_modules = False def _disable(self): """Internal API to disable automatic discovery""" self._disabled = True def _ignore_ext_modules(self): """Internal API to disregard ext_modules. Normally auto-discovery would not be triggered if ``ext_modules`` are set (this is done for backward compatibility with existing packages relying on ``setup.py`` or ``setup.cfg``). However, ``setuptools`` can call this function to ignore given ``ext_modules`` and proceed with the auto-discovery if ``packages`` and ``py_modules`` are not given (e.g. when using pyproject.toml metadata). """ self._skip_ext_modules = True @property def _root_dir(self) -> _Path: # The best is to wait until `src_root` is set in dist, before using _root_dir. return self.dist.src_root or os.curdir @property def _package_dir(self) -> Dict[str, str]: if self.dist.package_dir is None: return {} return self.dist.package_dir def __call__(self, force=False, name=True, ignore_ext_modules=False): """Automatically discover missing configuration fields and modifies the given ``distribution`` object in-place. Note that by default this will only have an effect the first time the ``ConfigDiscovery`` object is called. To repeatedly invoke automatic discovery (e.g. when the project directory changes), please use ``force=True`` (or create a new ``ConfigDiscovery`` instance). """ if force is False and (self._called or self._disabled): # Avoid overhead of multiple calls return self._analyse_package_layout(ignore_ext_modules) if name: self.analyse_name() # depends on ``packages`` and ``py_modules`` self._called = True def _explicitly_specified(self, ignore_ext_modules: bool) -> bool: """``True`` if the user has specified some form of package/module listing""" ignore_ext_modules = ignore_ext_modules or self._skip_ext_modules ext_modules = not (self.dist.ext_modules is None or ignore_ext_modules) return ( self.dist.packages is not None or self.dist.py_modules is not None or ext_modules or hasattr(self.dist, "configuration") and self.dist.configuration # ^ Some projects use numpy.distutils.misc_util.Configuration ) def _analyse_package_layout(self, ignore_ext_modules: bool) -> bool: if self._explicitly_specified(ignore_ext_modules): # For backward compatibility, just try to find modules/packages # when nothing is given return True log.debug( "No `packages` or `py_modules` configuration, performing " "automatic discovery." ) return ( self._analyse_explicit_layout() or self._analyse_src_layout() # flat-layout is the trickiest for discovery so it should be last or self._analyse_flat_layout() ) def _analyse_explicit_layout(self) -> bool: """The user can explicitly give a package layout via ``package_dir``""" package_dir = self._package_dir.copy() # don't modify directly package_dir.pop("", None) # This falls under the "src-layout" umbrella root_dir = self._root_dir if not package_dir: return False log.debug(f"`explicit-layout` detected -- analysing {package_dir}") pkgs = chain_iter( _find_packages_within(pkg, os.path.join(root_dir, parent_dir)) for pkg, parent_dir in package_dir.items() ) self.dist.packages = list(pkgs) log.debug(f"discovered packages -- {self.dist.packages}") return True def _analyse_src_layout(self) -> bool: """Try to find all packages or modules under the ``src`` directory (or anything pointed by ``package_dir[""]``). The "src-layout" is relatively safe for automatic discovery. We assume that everything within is meant to be included in the distribution. If ``package_dir[""]`` is not given, but the ``src`` directory exists, this function will set ``package_dir[""] = "src"``. """ package_dir = self._package_dir src_dir = os.path.join(self._root_dir, package_dir.get("", "src")) if not os.path.isdir(src_dir): return False log.debug(f"`src-layout` detected -- analysing {src_dir}") package_dir.setdefault("", os.path.basename(src_dir)) self.dist.package_dir = package_dir # persist eventual modifications self.dist.packages = PEP420PackageFinder.find(src_dir) self.dist.py_modules = ModuleFinder.find(src_dir) log.debug(f"discovered packages -- {self.dist.packages}") log.debug(f"discovered py_modules -- {self.dist.py_modules}") return True def _analyse_flat_layout(self) -> bool: """Try to find all packages and modules under the project root. Since the ``flat-layout`` is more dangerous in terms of accidentally including extra files/directories, this function is more conservative and will raise an error if multiple packages or modules are found. This assumes that multi-package dists are uncommon and refuse to support that use case in order to be able to prevent unintended errors. """ log.debug(f"`flat-layout` detected -- analysing {self._root_dir}") return self._analyse_flat_packages() or self._analyse_flat_modules() def _analyse_flat_packages(self) -> bool: self.dist.packages = FlatLayoutPackageFinder.find(self._root_dir) top_level = remove_nested_packages(remove_stubs(self.dist.packages)) log.debug(f"discovered packages -- {self.dist.packages}") self._ensure_no_accidental_inclusion(top_level, "packages") return bool(top_level) def _analyse_flat_modules(self) -> bool: self.dist.py_modules = FlatLayoutModuleFinder.find(self._root_dir) log.debug(f"discovered py_modules -- {self.dist.py_modules}") self._ensure_no_accidental_inclusion(self.dist.py_modules, "modules") return bool(self.dist.py_modules) def _ensure_no_accidental_inclusion(self, detected: List[str], kind: str): if len(detected) > 1: from inspect import cleandoc from setuptools.errors import PackageDiscoveryError msg = f"""Multiple top-level {kind} discovered in a flat-layout: {detected}. To avoid accidental inclusion of unwanted files or directories, setuptools will not proceed with this build. If you are trying to create a single distribution with multiple {kind} on purpose, you should not rely on automatic discovery. Instead, consider the following options: 1. set up custom discovery (`find` directive with `include` or `exclude`) 2. use a `src-layout` 3. explicitly set `py_modules` or `packages` with a list of names To find more information, look for "package discovery" on setuptools docs. """ raise PackageDiscoveryError(cleandoc(msg)) def analyse_name(self): """The packages/modules are the essential contribution of the author. Therefore the name of the distribution can be derived from them. """ if self.dist.metadata.name or self.dist.name: # get_name() is not reliable (can return "UNKNOWN") return None log.debug("No `name` configuration, performing automatic discovery") name = ( self._find_name_single_package_or_module() or self._find_name_from_packages() ) if name: self.dist.metadata.name = name def _find_name_single_package_or_module(self) -> Optional[str]: """Exactly one module or package""" for field in ('packages', 'py_modules'): items = getattr(self.dist, field, None) or [] if items and len(items) == 1: log.debug(f"Single module/package detected, name: {items[0]}") return items[0] return None def _find_name_from_packages(self) -> Optional[str]: """Try to find the root package that is not a PEP 420 namespace""" if not self.dist.packages: return None packages = remove_stubs(sorted(self.dist.packages, key=len)) package_dir = self.dist.package_dir or {} parent_pkg = find_parent_package(packages, package_dir, self._root_dir) if parent_pkg: log.debug(f"Common parent package detected, name: {parent_pkg}") return parent_pkg log.warn("No parent package detected, impossible to derive `name`") return None def remove_nested_packages(packages: List[str]) -> List[str]: """Remove nested packages from a list of packages. >>> remove_nested_packages(["a", "a.b1", "a.b2", "a.b1.c1"]) ['a'] >>> remove_nested_packages(["a", "b", "c.d", "c.d.e.f", "g.h", "a.a1"]) ['a', 'b', 'c.d', 'g.h'] """ pkgs = sorted(packages, key=len) top_level = pkgs[:] size = len(pkgs) for i, name in enumerate(reversed(pkgs)): if any(name.startswith(f"{other}.") for other in top_level): top_level.pop(size - i - 1) return top_level def remove_stubs(packages: List[str]) -> List[str]: """Remove type stubs (:pep:`561`) from a list of packages. >>> remove_stubs(["a", "a.b", "a-stubs", "a-stubs.b.c", "b", "c-stubs"]) ['a', 'a.b', 'b'] """ return [pkg for pkg in packages if not pkg.split(".")[0].endswith("-stubs")] def find_parent_package( packages: List[str], package_dir: Mapping[str, str], root_dir: _Path ) -> Optional[str]: """Find the parent package that is not a namespace.""" packages = sorted(packages, key=len) common_ancestors = [] for i, name in enumerate(packages): if not all(n.startswith(f"{name}.") for n in packages[i+1:]): # Since packages are sorted by length, this condition is able # to find a list of all common ancestors. # When there is divergence (e.g. multiple root packages) # the list will be empty break common_ancestors.append(name) for name in common_ancestors: pkg_path = find_package_path(name, package_dir, root_dir) init = os.path.join(pkg_path, "__init__.py") if os.path.isfile(init): return name return None def find_package_path( name: str, package_dir: Mapping[str, str], root_dir: _Path ) -> str: """Given a package name, return the path where it should be found on disk, considering the ``package_dir`` option. >>> path = find_package_path("my.pkg", {"": "root/is/nested"}, ".") >>> path.replace(os.sep, "/") './root/is/nested/my/pkg' >>> path = find_package_path("my.pkg", {"my": "root/is/nested"}, ".") >>> path.replace(os.sep, "/") './root/is/nested/pkg' >>> path = find_package_path("my.pkg", {"my.pkg": "root/is/nested"}, ".") >>> path.replace(os.sep, "/") './root/is/nested' >>> path = find_package_path("other.pkg", {"my.pkg": "root/is/nested"}, ".") >>> path.replace(os.sep, "/") './other/pkg' """ parts = name.split(".") for i in range(len(parts), 0, -1): # Look backwards, the most specific package_dir first partial_name = ".".join(parts[:i]) if partial_name in package_dir: parent = package_dir[partial_name] return os.path.join(root_dir, parent, *parts[i:]) parent = package_dir.get("") or "" return os.path.join(root_dir, *parent.split("/"), *parts) def construct_package_dir(packages: List[str], package_path: _Path) -> Dict[str, str]: parent_pkgs = remove_nested_packages(packages) prefix = Path(package_path).parts return {pkg: "/".join([*prefix, *pkg.split(".")]) for pkg in parent_pkgs}
castiel248/Convert
Lib/site-packages/setuptools/discovery.py
Python
mit
20,799
# -*- coding: utf-8 -*- __all__ = ['Distribution'] import io import sys import re import os import warnings import numbers import distutils.log import distutils.core import distutils.cmd import distutils.dist import distutils.command from distutils.util import strtobool from distutils.debug import DEBUG from distutils.fancy_getopt import translate_longopt from glob import iglob import itertools import textwrap from typing import List, Optional, TYPE_CHECKING from pathlib import Path from collections import defaultdict from email import message_from_file from distutils.errors import DistutilsOptionError, DistutilsSetupError from distutils.util import rfc822_escape from setuptools.extern import packaging from setuptools.extern import ordered_set from setuptools.extern.more_itertools import unique_everseen, partition from ._importlib import metadata from . import SetuptoolsDeprecationWarning import setuptools import setuptools.command from setuptools import windows_support from setuptools.monkey import get_unpatched from setuptools.config import setupcfg, pyprojecttoml from setuptools.discovery import ConfigDiscovery import pkg_resources from setuptools.extern.packaging import version from . import _reqs from . import _entry_points if TYPE_CHECKING: from email.message import Message __import__('setuptools.extern.packaging.specifiers') __import__('setuptools.extern.packaging.version') def _get_unpatched(cls): warnings.warn("Do not call this function", DistDeprecationWarning) return get_unpatched(cls) def get_metadata_version(self): mv = getattr(self, 'metadata_version', None) if mv is None: mv = version.Version('2.1') self.metadata_version = mv return mv def rfc822_unescape(content: str) -> str: """Reverse RFC-822 escaping by removing leading whitespaces from content.""" lines = content.splitlines() if len(lines) == 1: return lines[0].lstrip() return '\n'.join((lines[0].lstrip(), textwrap.dedent('\n'.join(lines[1:])))) def _read_field_from_msg(msg: "Message", field: str) -> Optional[str]: """Read Message header field.""" value = msg[field] if value == 'UNKNOWN': return None return value def _read_field_unescaped_from_msg(msg: "Message", field: str) -> Optional[str]: """Read Message header field and apply rfc822_unescape.""" value = _read_field_from_msg(msg, field) if value is None: return value return rfc822_unescape(value) def _read_list_from_msg(msg: "Message", field: str) -> Optional[List[str]]: """Read Message header field and return all results as list.""" values = msg.get_all(field, None) if values == []: return None return values def _read_payload_from_msg(msg: "Message") -> Optional[str]: value = msg.get_payload().strip() if value == 'UNKNOWN' or not value: return None return value def read_pkg_file(self, file): """Reads the metadata values from a file object.""" msg = message_from_file(file) self.metadata_version = version.Version(msg['metadata-version']) self.name = _read_field_from_msg(msg, 'name') self.version = _read_field_from_msg(msg, 'version') self.description = _read_field_from_msg(msg, 'summary') # we are filling author only. self.author = _read_field_from_msg(msg, 'author') self.maintainer = None self.author_email = _read_field_from_msg(msg, 'author-email') self.maintainer_email = None self.url = _read_field_from_msg(msg, 'home-page') self.download_url = _read_field_from_msg(msg, 'download-url') self.license = _read_field_unescaped_from_msg(msg, 'license') self.long_description = _read_field_unescaped_from_msg(msg, 'description') if ( self.long_description is None and self.metadata_version >= version.Version('2.1') ): self.long_description = _read_payload_from_msg(msg) self.description = _read_field_from_msg(msg, 'summary') if 'keywords' in msg: self.keywords = _read_field_from_msg(msg, 'keywords').split(',') self.platforms = _read_list_from_msg(msg, 'platform') self.classifiers = _read_list_from_msg(msg, 'classifier') # PEP 314 - these fields only exist in 1.1 if self.metadata_version == version.Version('1.1'): self.requires = _read_list_from_msg(msg, 'requires') self.provides = _read_list_from_msg(msg, 'provides') self.obsoletes = _read_list_from_msg(msg, 'obsoletes') else: self.requires = None self.provides = None self.obsoletes = None self.license_files = _read_list_from_msg(msg, 'license-file') def single_line(val): """ Quick and dirty validation for Summary pypa/setuptools#1390. """ if '\n' in val: # TODO: Replace with `raise ValueError("newlines not allowed")` # after reviewing #2893. warnings.warn("newlines not allowed and will break in the future") val = val.strip().split('\n')[0] return val # Based on Python 3.5 version def write_pkg_file(self, file): # noqa: C901 # is too complex (14) # FIXME """Write the PKG-INFO format data to a file object.""" version = self.get_metadata_version() def write_field(key, value): file.write("%s: %s\n" % (key, value)) write_field('Metadata-Version', str(version)) write_field('Name', self.get_name()) write_field('Version', self.get_version()) summary = self.get_description() if summary: write_field('Summary', single_line(summary)) optional_fields = ( ('Home-page', 'url'), ('Download-URL', 'download_url'), ('Author', 'author'), ('Author-email', 'author_email'), ('Maintainer', 'maintainer'), ('Maintainer-email', 'maintainer_email'), ) for field, attr in optional_fields: attr_val = getattr(self, attr, None) if attr_val is not None: write_field(field, attr_val) license = self.get_license() if license: write_field('License', rfc822_escape(license)) for project_url in self.project_urls.items(): write_field('Project-URL', '%s, %s' % project_url) keywords = ','.join(self.get_keywords()) if keywords: write_field('Keywords', keywords) platforms = self.get_platforms() or [] for platform in platforms: write_field('Platform', platform) self._write_list(file, 'Classifier', self.get_classifiers()) # PEP 314 self._write_list(file, 'Requires', self.get_requires()) self._write_list(file, 'Provides', self.get_provides()) self._write_list(file, 'Obsoletes', self.get_obsoletes()) # Setuptools specific for PEP 345 if hasattr(self, 'python_requires'): write_field('Requires-Python', self.python_requires) # PEP 566 if self.long_description_content_type: write_field('Description-Content-Type', self.long_description_content_type) if self.provides_extras: for extra in self.provides_extras: write_field('Provides-Extra', extra) self._write_list(file, 'License-File', self.license_files or []) long_description = self.get_long_description() if long_description: file.write("\n%s" % long_description) if not long_description.endswith("\n"): file.write("\n") sequence = tuple, list def check_importable(dist, attr, value): try: ep = metadata.EntryPoint(value=value, name=None, group=None) assert not ep.extras except (TypeError, ValueError, AttributeError, AssertionError) as e: raise DistutilsSetupError( "%r must be importable 'module:attrs' string (got %r)" % (attr, value) ) from e def assert_string_list(dist, attr, value): """Verify that value is a string list""" try: # verify that value is a list or tuple to exclude unordered # or single-use iterables assert isinstance(value, (list, tuple)) # verify that elements of value are strings assert ''.join(value) != value except (TypeError, ValueError, AttributeError, AssertionError) as e: raise DistutilsSetupError( "%r must be a list of strings (got %r)" % (attr, value) ) from e def check_nsp(dist, attr, value): """Verify that namespace packages are valid""" ns_packages = value assert_string_list(dist, attr, ns_packages) for nsp in ns_packages: if not dist.has_contents_for(nsp): raise DistutilsSetupError( "Distribution contains no modules or packages for " + "namespace package %r" % nsp ) parent, sep, child = nsp.rpartition('.') if parent and parent not in ns_packages: distutils.log.warn( "WARNING: %r is declared as a package namespace, but %r" " is not: please correct this in setup.py", nsp, parent, ) msg = ( "The namespace_packages parameter is deprecated, " "consider using implicit namespaces instead (PEP 420)." ) warnings.warn(msg, SetuptoolsDeprecationWarning) def check_extras(dist, attr, value): """Verify that extras_require mapping is valid""" try: list(itertools.starmap(_check_extra, value.items())) except (TypeError, ValueError, AttributeError) as e: raise DistutilsSetupError( "'extras_require' must be a dictionary whose values are " "strings or lists of strings containing valid project/version " "requirement specifiers." ) from e def _check_extra(extra, reqs): name, sep, marker = extra.partition(':') if marker and pkg_resources.invalid_marker(marker): raise DistutilsSetupError("Invalid environment marker: " + marker) list(_reqs.parse(reqs)) def assert_bool(dist, attr, value): """Verify that value is True, False, 0, or 1""" if bool(value) != value: tmpl = "{attr!r} must be a boolean value (got {value!r})" raise DistutilsSetupError(tmpl.format(attr=attr, value=value)) def invalid_unless_false(dist, attr, value): if not value: warnings.warn(f"{attr} is ignored.", DistDeprecationWarning) return raise DistutilsSetupError(f"{attr} is invalid.") def check_requirements(dist, attr, value): """Verify that install_requires is a valid requirements list""" try: list(_reqs.parse(value)) if isinstance(value, (dict, set)): raise TypeError("Unordered types are not allowed") except (TypeError, ValueError) as error: tmpl = ( "{attr!r} must be a string or list of strings " "containing valid project/version requirement specifiers; {error}" ) raise DistutilsSetupError(tmpl.format(attr=attr, error=error)) from error def check_specifier(dist, attr, value): """Verify that value is a valid version specifier""" try: packaging.specifiers.SpecifierSet(value) except (packaging.specifiers.InvalidSpecifier, AttributeError) as error: tmpl = ( "{attr!r} must be a string " "containing valid version specifiers; {error}" ) raise DistutilsSetupError(tmpl.format(attr=attr, error=error)) from error def check_entry_points(dist, attr, value): """Verify that entry_points map is parseable""" try: _entry_points.load(value) except Exception as e: raise DistutilsSetupError(e) from e def check_test_suite(dist, attr, value): if not isinstance(value, str): raise DistutilsSetupError("test_suite must be a string") def check_package_data(dist, attr, value): """Verify that value is a dictionary of package names to glob lists""" if not isinstance(value, dict): raise DistutilsSetupError( "{!r} must be a dictionary mapping package names to lists of " "string wildcard patterns".format(attr) ) for k, v in value.items(): if not isinstance(k, str): raise DistutilsSetupError( "keys of {!r} dict must be strings (got {!r})".format(attr, k) ) assert_string_list(dist, 'values of {!r} dict'.format(attr), v) def check_packages(dist, attr, value): for pkgname in value: if not re.match(r'\w+(\.\w+)*', pkgname): distutils.log.warn( "WARNING: %r not a valid package name; please use only " ".-separated package names in setup.py", pkgname, ) _Distribution = get_unpatched(distutils.core.Distribution) class Distribution(_Distribution): """Distribution with support for tests and package data This is an enhanced version of 'distutils.dist.Distribution' that effectively adds the following new optional keyword arguments to 'setup()': 'install_requires' -- a string or sequence of strings specifying project versions that the distribution requires when installed, in the format used by 'pkg_resources.require()'. They will be installed automatically when the package is installed. If you wish to use packages that are not available in PyPI, or want to give your users an alternate download location, you can add a 'find_links' option to the '[easy_install]' section of your project's 'setup.cfg' file, and then setuptools will scan the listed web pages for links that satisfy the requirements. 'extras_require' -- a dictionary mapping names of optional "extras" to the additional requirement(s) that using those extras incurs. For example, this:: extras_require = dict(reST = ["docutils>=0.3", "reSTedit"]) indicates that the distribution can optionally provide an extra capability called "reST", but it can only be used if docutils and reSTedit are installed. If the user installs your package using EasyInstall and requests one of your extras, the corresponding additional requirements will be installed if needed. 'test_suite' -- the name of a test suite to run for the 'test' command. If the user runs 'python setup.py test', the package will be installed, and the named test suite will be run. The format is the same as would be used on a 'unittest.py' command line. That is, it is the dotted name of an object to import and call to generate a test suite. 'package_data' -- a dictionary mapping package names to lists of filenames or globs to use to find data files contained in the named packages. If the dictionary has filenames or globs listed under '""' (the empty string), those names will be searched for in every package, in addition to any names for the specific package. Data files found using these names/globs will be installed along with the package, in the same location as the package. Note that globs are allowed to reference the contents of non-package subdirectories, as long as you use '/' as a path separator. (Globs are automatically converted to platform-specific paths at runtime.) In addition to these new keywords, this class also has several new methods for manipulating the distribution's contents. For example, the 'include()' and 'exclude()' methods can be thought of as in-place add and subtract commands that add or remove packages, modules, extensions, and so on from the distribution. """ _DISTUTILS_UNSUPPORTED_METADATA = { 'long_description_content_type': lambda: None, 'project_urls': dict, 'provides_extras': ordered_set.OrderedSet, 'license_file': lambda: None, 'license_files': lambda: None, } _patched_dist = None def patch_missing_pkg_info(self, attrs): # Fake up a replacement for the data that would normally come from # PKG-INFO, but which might not yet be built if this is a fresh # checkout. # if not attrs or 'name' not in attrs or 'version' not in attrs: return key = pkg_resources.safe_name(str(attrs['name'])).lower() dist = pkg_resources.working_set.by_key.get(key) if dist is not None and not dist.has_metadata('PKG-INFO'): dist._version = pkg_resources.safe_version(str(attrs['version'])) self._patched_dist = dist def __init__(self, attrs=None): have_package_data = hasattr(self, "package_data") if not have_package_data: self.package_data = {} attrs = attrs or {} self.dist_files = [] # Filter-out setuptools' specific options. self.src_root = attrs.pop("src_root", None) self.patch_missing_pkg_info(attrs) self.dependency_links = attrs.pop('dependency_links', []) self.setup_requires = attrs.pop('setup_requires', []) for ep in metadata.entry_points(group='distutils.setup_keywords'): vars(self).setdefault(ep.name, None) _Distribution.__init__( self, { k: v for k, v in attrs.items() if k not in self._DISTUTILS_UNSUPPORTED_METADATA }, ) # Save the original dependencies before they are processed into the egg format self._orig_extras_require = {} self._orig_install_requires = [] self._tmp_extras_require = defaultdict(ordered_set.OrderedSet) self.set_defaults = ConfigDiscovery(self) self._set_metadata_defaults(attrs) self.metadata.version = self._normalize_version( self._validate_version(self.metadata.version) ) self._finalize_requires() def _validate_metadata(self): required = {"name"} provided = { key for key in vars(self.metadata) if getattr(self.metadata, key, None) is not None } missing = required - provided if missing: msg = f"Required package metadata is missing: {missing}" raise DistutilsSetupError(msg) def _set_metadata_defaults(self, attrs): """ Fill-in missing metadata fields not supported by distutils. Some fields may have been set by other tools (e.g. pbr). Those fields (vars(self.metadata)) take precedence to supplied attrs. """ for option, default in self._DISTUTILS_UNSUPPORTED_METADATA.items(): vars(self.metadata).setdefault(option, attrs.get(option, default())) @staticmethod def _normalize_version(version): if isinstance(version, setuptools.sic) or version is None: return version normalized = str(packaging.version.Version(version)) if version != normalized: tmpl = "Normalizing '{version}' to '{normalized}'" warnings.warn(tmpl.format(**locals())) return normalized return version @staticmethod def _validate_version(version): if isinstance(version, numbers.Number): # Some people apparently take "version number" too literally :) version = str(version) if version is not None: try: packaging.version.Version(version) except (packaging.version.InvalidVersion, TypeError): warnings.warn( "The version specified (%r) is an invalid version, this " "may not work as expected with newer versions of " "setuptools, pip, and PyPI. Please see PEP 440 for more " "details." % version ) return setuptools.sic(version) return version def _finalize_requires(self): """ Set `metadata.python_requires` and fix environment markers in `install_requires` and `extras_require`. """ if getattr(self, 'python_requires', None): self.metadata.python_requires = self.python_requires if getattr(self, 'extras_require', None): # Save original before it is messed by _convert_extras_requirements self._orig_extras_require = self._orig_extras_require or self.extras_require for extra in self.extras_require.keys(): # Since this gets called multiple times at points where the # keys have become 'converted' extras, ensure that we are only # truly adding extras we haven't seen before here. extra = extra.split(':')[0] if extra: self.metadata.provides_extras.add(extra) if getattr(self, 'install_requires', None) and not self._orig_install_requires: # Save original before it is messed by _move_install_requirements_markers self._orig_install_requires = self.install_requires self._convert_extras_requirements() self._move_install_requirements_markers() def _convert_extras_requirements(self): """ Convert requirements in `extras_require` of the form `"extra": ["barbazquux; {marker}"]` to `"extra:{marker}": ["barbazquux"]`. """ spec_ext_reqs = getattr(self, 'extras_require', None) or {} tmp = defaultdict(ordered_set.OrderedSet) self._tmp_extras_require = getattr(self, '_tmp_extras_require', tmp) for section, v in spec_ext_reqs.items(): # Do not strip empty sections. self._tmp_extras_require[section] for r in _reqs.parse(v): suffix = self._suffix_for(r) self._tmp_extras_require[section + suffix].append(r) @staticmethod def _suffix_for(req): """ For a requirement, return the 'extras_require' suffix for that requirement. """ return ':' + str(req.marker) if req.marker else '' def _move_install_requirements_markers(self): """ Move requirements in `install_requires` that are using environment markers `extras_require`. """ # divide the install_requires into two sets, simple ones still # handled by install_requires and more complex ones handled # by extras_require. def is_simple_req(req): return not req.marker spec_inst_reqs = getattr(self, 'install_requires', None) or () inst_reqs = list(_reqs.parse(spec_inst_reqs)) simple_reqs = filter(is_simple_req, inst_reqs) complex_reqs = itertools.filterfalse(is_simple_req, inst_reqs) self.install_requires = list(map(str, simple_reqs)) for r in complex_reqs: self._tmp_extras_require[':' + str(r.marker)].append(r) self.extras_require = dict( # list(dict.fromkeys(...)) ensures a list of unique strings (k, list(dict.fromkeys(str(r) for r in map(self._clean_req, v)))) for k, v in self._tmp_extras_require.items() ) def _clean_req(self, req): """ Given a Requirement, remove environment markers and return it. """ req.marker = None return req def _finalize_license_files(self): """Compute names of all license files which should be included.""" license_files: Optional[List[str]] = self.metadata.license_files patterns: List[str] = license_files if license_files else [] license_file: Optional[str] = self.metadata.license_file if license_file and license_file not in patterns: patterns.append(license_file) if license_files is None and license_file is None: # Default patterns match the ones wheel uses # See https://wheel.readthedocs.io/en/stable/user_guide.html # -> 'Including license files in the generated wheel file' patterns = ('LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*') self.metadata.license_files = list( unique_everseen(self._expand_patterns(patterns)) ) @staticmethod def _expand_patterns(patterns): """ >>> list(Distribution._expand_patterns(['LICENSE'])) ['LICENSE'] >>> list(Distribution._expand_patterns(['setup.cfg', 'LIC*'])) ['setup.cfg', 'LICENSE'] """ return ( path for pattern in patterns for path in sorted(iglob(pattern)) if not path.endswith('~') and os.path.isfile(path) ) # FIXME: 'Distribution._parse_config_files' is too complex (14) def _parse_config_files(self, filenames=None): # noqa: C901 """ Adapted from distutils.dist.Distribution.parse_config_files, this method provides the same functionality in subtly-improved ways. """ from configparser import ConfigParser # Ignore install directory options if we have a venv ignore_options = ( [] if sys.prefix == sys.base_prefix else [ 'install-base', 'install-platbase', 'install-lib', 'install-platlib', 'install-purelib', 'install-headers', 'install-scripts', 'install-data', 'prefix', 'exec-prefix', 'home', 'user', 'root', ] ) ignore_options = frozenset(ignore_options) if filenames is None: filenames = self.find_config_files() if DEBUG: self.announce("Distribution.parse_config_files():") parser = ConfigParser() parser.optionxform = str for filename in filenames: with io.open(filename, encoding='utf-8') as reader: if DEBUG: self.announce(" reading {filename}".format(**locals())) parser.read_file(reader) for section in parser.sections(): options = parser.options(section) opt_dict = self.get_option_dict(section) for opt in options: if opt == '__name__' or opt in ignore_options: continue val = parser.get(section, opt) opt = self.warn_dash_deprecation(opt, section) opt = self.make_option_lowercase(opt, section) opt_dict[opt] = (filename, val) # Make the ConfigParser forget everything (so we retain # the original filenames that options come from) parser.__init__() if 'global' not in self.command_options: return # If there was a "global" section in the config file, use it # to set Distribution options. for (opt, (src, val)) in self.command_options['global'].items(): alias = self.negative_opt.get(opt) if alias: val = not strtobool(val) elif opt in ('verbose', 'dry_run'): # ugh! val = strtobool(val) try: setattr(self, alias or opt, val) except ValueError as e: raise DistutilsOptionError(e) from e def warn_dash_deprecation(self, opt, section): if section in ( 'options.extras_require', 'options.data_files', ): return opt underscore_opt = opt.replace('-', '_') commands = list(itertools.chain( distutils.command.__all__, self._setuptools_commands(), )) if ( not section.startswith('options') and section != 'metadata' and section not in commands ): return underscore_opt if '-' in opt: warnings.warn( "Usage of dash-separated '%s' will not be supported in future " "versions. Please use the underscore name '%s' instead" % (opt, underscore_opt) ) return underscore_opt def _setuptools_commands(self): try: return metadata.distribution('setuptools').entry_points.names except metadata.PackageNotFoundError: # during bootstrapping, distribution doesn't exist return [] def make_option_lowercase(self, opt, section): if section != 'metadata' or opt.islower(): return opt lowercase_opt = opt.lower() warnings.warn( "Usage of uppercase key '%s' in '%s' will be deprecated in future " "versions. Please use lowercase '%s' instead" % (opt, section, lowercase_opt) ) return lowercase_opt # FIXME: 'Distribution._set_command_options' is too complex (14) def _set_command_options(self, command_obj, option_dict=None): # noqa: C901 """ Set the options for 'command_obj' from 'option_dict'. Basically this means copying elements of a dictionary ('option_dict') to attributes of an instance ('command'). 'command_obj' must be a Command instance. If 'option_dict' is not supplied, uses the standard option dictionary for this command (from 'self.command_options'). (Adopted from distutils.dist.Distribution._set_command_options) """ command_name = command_obj.get_command_name() if option_dict is None: option_dict = self.get_option_dict(command_name) if DEBUG: self.announce(" setting options for '%s' command:" % command_name) for (option, (source, value)) in option_dict.items(): if DEBUG: self.announce(" %s = %s (from %s)" % (option, value, source)) try: bool_opts = [translate_longopt(o) for o in command_obj.boolean_options] except AttributeError: bool_opts = [] try: neg_opt = command_obj.negative_opt except AttributeError: neg_opt = {} try: is_string = isinstance(value, str) if option in neg_opt and is_string: setattr(command_obj, neg_opt[option], not strtobool(value)) elif option in bool_opts and is_string: setattr(command_obj, option, strtobool(value)) elif hasattr(command_obj, option): setattr(command_obj, option, value) else: raise DistutilsOptionError( "error in %s: command '%s' has no such option '%s'" % (source, command_name, option) ) except ValueError as e: raise DistutilsOptionError(e) from e def _get_project_config_files(self, filenames): """Add default file and split between INI and TOML""" tomlfiles = [] standard_project_metadata = Path(self.src_root or os.curdir, "pyproject.toml") if filenames is not None: parts = partition(lambda f: Path(f).suffix == ".toml", filenames) filenames = list(parts[0]) # 1st element => predicate is False tomlfiles = list(parts[1]) # 2nd element => predicate is True elif standard_project_metadata.exists(): tomlfiles = [standard_project_metadata] return filenames, tomlfiles def parse_config_files(self, filenames=None, ignore_option_errors=False): """Parses configuration files from various levels and loads configuration. """ inifiles, tomlfiles = self._get_project_config_files(filenames) self._parse_config_files(filenames=inifiles) setupcfg.parse_configuration( self, self.command_options, ignore_option_errors=ignore_option_errors ) for filename in tomlfiles: pyprojecttoml.apply_configuration(self, filename, ignore_option_errors) self._finalize_requires() self._finalize_license_files() def fetch_build_eggs(self, requires): """Resolve pre-setup requirements""" resolved_dists = pkg_resources.working_set.resolve( _reqs.parse(requires), installer=self.fetch_build_egg, replace_conflicting=True, ) for dist in resolved_dists: pkg_resources.working_set.add(dist, replace=True) return resolved_dists def finalize_options(self): """ Allow plugins to apply arbitrary operations to the distribution. Each hook may optionally define a 'order' to influence the order of execution. Smaller numbers go first and the default is 0. """ group = 'setuptools.finalize_distribution_options' def by_order(hook): return getattr(hook, 'order', 0) defined = metadata.entry_points(group=group) filtered = itertools.filterfalse(self._removed, defined) loaded = map(lambda e: e.load(), filtered) for ep in sorted(loaded, key=by_order): ep(self) @staticmethod def _removed(ep): """ When removing an entry point, if metadata is loaded from an older version of Setuptools, that removed entry point will attempt to be loaded and will fail. See #2765 for more details. """ removed = { # removed 2021-09-05 '2to3_doctests', } return ep.name in removed def _finalize_setup_keywords(self): for ep in metadata.entry_points(group='distutils.setup_keywords'): value = getattr(self, ep.name, None) if value is not None: ep.load()(self, ep.name, value) def get_egg_cache_dir(self): egg_cache_dir = os.path.join(os.curdir, '.eggs') if not os.path.exists(egg_cache_dir): os.mkdir(egg_cache_dir) windows_support.hide_file(egg_cache_dir) readme_txt_filename = os.path.join(egg_cache_dir, 'README.txt') with open(readme_txt_filename, 'w') as f: f.write( 'This directory contains eggs that were downloaded ' 'by setuptools to build, test, and run plug-ins.\n\n' ) f.write( 'This directory caches those eggs to prevent ' 'repeated downloads.\n\n' ) f.write('However, it is safe to delete this directory.\n\n') return egg_cache_dir def fetch_build_egg(self, req): """Fetch an egg needed for building""" from setuptools.installer import fetch_build_egg return fetch_build_egg(self, req) def get_command_class(self, command): """Pluggable version of get_command_class()""" if command in self.cmdclass: return self.cmdclass[command] eps = metadata.entry_points(group='distutils.commands', name=command) for ep in eps: self.cmdclass[command] = cmdclass = ep.load() return cmdclass else: return _Distribution.get_command_class(self, command) def print_commands(self): for ep in metadata.entry_points(group='distutils.commands'): if ep.name not in self.cmdclass: cmdclass = ep.load() self.cmdclass[ep.name] = cmdclass return _Distribution.print_commands(self) def get_command_list(self): for ep in metadata.entry_points(group='distutils.commands'): if ep.name not in self.cmdclass: cmdclass = ep.load() self.cmdclass[ep.name] = cmdclass return _Distribution.get_command_list(self) def include(self, **attrs): """Add items to distribution that are named in keyword arguments For example, 'dist.include(py_modules=["x"])' would add 'x' to the distribution's 'py_modules' attribute, if it was not already there. Currently, this method only supports inclusion for attributes that are lists or tuples. If you need to add support for adding to other attributes in this or a subclass, you can add an '_include_X' method, where 'X' is the name of the attribute. The method will be called with the value passed to 'include()'. So, 'dist.include(foo={"bar":"baz"})' will try to call 'dist._include_foo({"bar":"baz"})', which can then handle whatever special inclusion logic is needed. """ for k, v in attrs.items(): include = getattr(self, '_include_' + k, None) if include: include(v) else: self._include_misc(k, v) def exclude_package(self, package): """Remove packages, modules, and extensions in named package""" pfx = package + '.' if self.packages: self.packages = [ p for p in self.packages if p != package and not p.startswith(pfx) ] if self.py_modules: self.py_modules = [ p for p in self.py_modules if p != package and not p.startswith(pfx) ] if self.ext_modules: self.ext_modules = [ p for p in self.ext_modules if p.name != package and not p.name.startswith(pfx) ] def has_contents_for(self, package): """Return true if 'exclude_package(package)' would do something""" pfx = package + '.' for p in self.iter_distribution_names(): if p == package or p.startswith(pfx): return True def _exclude_misc(self, name, value): """Handle 'exclude()' for list/tuple attrs without a special handler""" if not isinstance(value, sequence): raise DistutilsSetupError( "%s: setting must be a list or tuple (%r)" % (name, value) ) try: old = getattr(self, name) except AttributeError as e: raise DistutilsSetupError("%s: No such distribution setting" % name) from e if old is not None and not isinstance(old, sequence): raise DistutilsSetupError( name + ": this setting cannot be changed via include/exclude" ) elif old: setattr(self, name, [item for item in old if item not in value]) def _include_misc(self, name, value): """Handle 'include()' for list/tuple attrs without a special handler""" if not isinstance(value, sequence): raise DistutilsSetupError("%s: setting must be a list (%r)" % (name, value)) try: old = getattr(self, name) except AttributeError as e: raise DistutilsSetupError("%s: No such distribution setting" % name) from e if old is None: setattr(self, name, value) elif not isinstance(old, sequence): raise DistutilsSetupError( name + ": this setting cannot be changed via include/exclude" ) else: new = [item for item in value if item not in old] setattr(self, name, old + new) def exclude(self, **attrs): """Remove items from distribution that are named in keyword arguments For example, 'dist.exclude(py_modules=["x"])' would remove 'x' from the distribution's 'py_modules' attribute. Excluding packages uses the 'exclude_package()' method, so all of the package's contained packages, modules, and extensions are also excluded. Currently, this method only supports exclusion from attributes that are lists or tuples. If you need to add support for excluding from other attributes in this or a subclass, you can add an '_exclude_X' method, where 'X' is the name of the attribute. The method will be called with the value passed to 'exclude()'. So, 'dist.exclude(foo={"bar":"baz"})' will try to call 'dist._exclude_foo({"bar":"baz"})', which can then handle whatever special exclusion logic is needed. """ for k, v in attrs.items(): exclude = getattr(self, '_exclude_' + k, None) if exclude: exclude(v) else: self._exclude_misc(k, v) def _exclude_packages(self, packages): if not isinstance(packages, sequence): raise DistutilsSetupError( "packages: setting must be a list or tuple (%r)" % (packages,) ) list(map(self.exclude_package, packages)) def _parse_command_opts(self, parser, args): # Remove --with-X/--without-X options when processing command args self.global_options = self.__class__.global_options self.negative_opt = self.__class__.negative_opt # First, expand any aliases command = args[0] aliases = self.get_option_dict('aliases') while command in aliases: src, alias = aliases[command] del aliases[command] # ensure each alias can expand only once! import shlex args[:1] = shlex.split(alias, True) command = args[0] nargs = _Distribution._parse_command_opts(self, parser, args) # Handle commands that want to consume all remaining arguments cmd_class = self.get_command_class(command) if getattr(cmd_class, 'command_consumes_arguments', None): self.get_option_dict(command)['args'] = ("command line", nargs) if nargs is not None: return [] return nargs def get_cmdline_options(self): """Return a '{cmd: {opt:val}}' map of all command-line options Option names are all long, but do not include the leading '--', and contain dashes rather than underscores. If the option doesn't take an argument (e.g. '--quiet'), the 'val' is 'None'. Note that options provided by config files are intentionally excluded. """ d = {} for cmd, opts in self.command_options.items(): for opt, (src, val) in opts.items(): if src != "command line": continue opt = opt.replace('_', '-') if val == 0: cmdobj = self.get_command_obj(cmd) neg_opt = self.negative_opt.copy() neg_opt.update(getattr(cmdobj, 'negative_opt', {})) for neg, pos in neg_opt.items(): if pos == opt: opt = neg val = None break else: raise AssertionError("Shouldn't be able to get here") elif val == 1: val = None d.setdefault(cmd, {})[opt] = val return d def iter_distribution_names(self): """Yield all packages, modules, and extension names in distribution""" for pkg in self.packages or (): yield pkg for module in self.py_modules or (): yield module for ext in self.ext_modules or (): if isinstance(ext, tuple): name, buildinfo = ext else: name = ext.name if name.endswith('module'): name = name[:-6] yield name def handle_display_options(self, option_order): """If there were any non-global "display-only" options (--help-commands or the metadata display options) on the command line, display the requested info and return true; else return false. """ import sys if self.help_commands: return _Distribution.handle_display_options(self, option_order) # Stdout may be StringIO (e.g. in tests) if not isinstance(sys.stdout, io.TextIOWrapper): return _Distribution.handle_display_options(self, option_order) # Don't wrap stdout if utf-8 is already the encoding. Provides # workaround for #334. if sys.stdout.encoding.lower() in ('utf-8', 'utf8'): return _Distribution.handle_display_options(self, option_order) # Print metadata in UTF-8 no matter the platform encoding = sys.stdout.encoding errors = sys.stdout.errors newline = sys.platform != 'win32' and '\n' or None line_buffering = sys.stdout.line_buffering sys.stdout = io.TextIOWrapper( sys.stdout.detach(), 'utf-8', errors, newline, line_buffering ) try: return _Distribution.handle_display_options(self, option_order) finally: sys.stdout = io.TextIOWrapper( sys.stdout.detach(), encoding, errors, newline, line_buffering ) def run_command(self, command): self.set_defaults() # Postpone defaults until all explicit configuration is considered # (setup() args, config files, command line and plugins) super().run_command(command) class DistDeprecationWarning(SetuptoolsDeprecationWarning): """Class for warning about deprecations in dist in setuptools. Not ignored by default, unlike DeprecationWarning."""
castiel248/Convert
Lib/site-packages/setuptools/dist.py
Python
mit
45,578
"""setuptools.errors Provides exceptions used by setuptools modules. """ from distutils import errors as _distutils_errors # Re-export errors from distutils to facilitate the migration to PEP632 ByteCompileError = _distutils_errors.DistutilsByteCompileError CCompilerError = _distutils_errors.CCompilerError ClassError = _distutils_errors.DistutilsClassError CompileError = _distutils_errors.CompileError ExecError = _distutils_errors.DistutilsExecError FileError = _distutils_errors.DistutilsFileError InternalError = _distutils_errors.DistutilsInternalError LibError = _distutils_errors.LibError LinkError = _distutils_errors.LinkError ModuleError = _distutils_errors.DistutilsModuleError OptionError = _distutils_errors.DistutilsOptionError PlatformError = _distutils_errors.DistutilsPlatformError PreprocessError = _distutils_errors.PreprocessError SetupError = _distutils_errors.DistutilsSetupError TemplateError = _distutils_errors.DistutilsTemplateError UnknownFileError = _distutils_errors.UnknownFileError # The root error class in the hierarchy BaseError = _distutils_errors.DistutilsError class RemovedCommandError(BaseError, RuntimeError): """Error used for commands that have been removed in setuptools. Since ``setuptools`` is built on ``distutils``, simply removing a command from ``setuptools`` will make the behavior fall back to ``distutils``; this error is raised if a command exists in ``distutils`` but has been actively removed in ``setuptools``. """ class PackageDiscoveryError(BaseError, RuntimeError): """Impossible to perform automatic discovery of packages and/or modules. The current project layout or given discovery options can lead to problems when scanning the project directory. Setuptools might also refuse to complete auto-discovery if an error prone condition is detected (e.g. when a project is organised as a flat-layout but contains multiple directories that can be taken as top-level packages inside a single distribution [*]_). In these situations the users are encouraged to be explicit about which packages to include or to make the discovery parameters more specific. .. [*] Since multi-package distributions are uncommon it is very likely that the developers did not intend for all the directories to be packaged, and are just leaving auxiliary code in the repository top-level, such as maintenance-related scripts. """
castiel248/Convert
Lib/site-packages/setuptools/errors.py
Python
mit
2,464
import re import functools import distutils.core import distutils.errors import distutils.extension from .monkey import get_unpatched def _have_cython(): """ Return True if Cython can be imported. """ cython_impl = 'Cython.Distutils.build_ext' try: # from (cython_impl) import build_ext __import__(cython_impl, fromlist=['build_ext']).build_ext return True except Exception: pass return False # for compatibility have_pyrex = _have_cython _Extension = get_unpatched(distutils.core.Extension) class Extension(_Extension): """ Describes a single extension module. This means that all source files will be compiled into a single binary file ``<module path>.<suffix>`` (with ``<module path>`` derived from ``name`` and ``<suffix>`` defined by one of the values in ``importlib.machinery.EXTENSION_SUFFIXES``). In the case ``.pyx`` files are passed as ``sources and`` ``Cython`` is **not** installed in the build environment, ``setuptools`` may also try to look for the equivalent ``.cpp`` or ``.c`` files. :arg str name: the full name of the extension, including any packages -- ie. *not* a filename or pathname, but Python dotted name :arg list[str] sources: list of source filenames, relative to the distribution root (where the setup script lives), in Unix form (slash-separated) for portability. Source files may be C, C++, SWIG (.i), platform-specific resource files, or whatever else is recognized by the "build_ext" command as source for a Python extension. :keyword list[str] include_dirs: list of directories to search for C/C++ header files (in Unix form for portability) :keyword list[tuple[str, str|None]] define_macros: list of macros to define; each macro is defined using a 2-tuple: the first item corresponding to the name of the macro and the second item either a string with its value or None to define it without a particular value (equivalent of "#define FOO" in source or -DFOO on Unix C compiler command line) :keyword list[str] undef_macros: list of macros to undefine explicitly :keyword list[str] library_dirs: list of directories to search for C/C++ libraries at link time :keyword list[str] libraries: list of library names (not filenames or paths) to link against :keyword list[str] runtime_library_dirs: list of directories to search for C/C++ libraries at run time (for shared extensions, this is when the extension is loaded). Setting this will cause an exception during build on Windows platforms. :keyword list[str] extra_objects: list of extra files to link with (eg. object files not implied by 'sources', static library that must be explicitly specified, binary resource files, etc.) :keyword list[str] extra_compile_args: any extra platform- and compiler-specific information to use when compiling the source files in 'sources'. For platforms and compilers where "command line" makes sense, this is typically a list of command-line arguments, but for other platforms it could be anything. :keyword list[str] extra_link_args: any extra platform- and compiler-specific information to use when linking object files together to create the extension (or to create a new static Python interpreter). Similar interpretation as for 'extra_compile_args'. :keyword list[str] export_symbols: list of symbols to be exported from a shared extension. Not used on all platforms, and not generally necessary for Python extensions, which typically export exactly one symbol: "init" + extension_name. :keyword list[str] swig_opts: any extra options to pass to SWIG if a source file has the .i extension. :keyword list[str] depends: list of files that the extension depends on :keyword str language: extension language (i.e. "c", "c++", "objc"). Will be detected from the source extensions if not provided. :keyword bool optional: specifies that a build failure in the extension should not abort the build process, but simply not install the failing extension. :keyword bool py_limited_api: opt-in flag for the usage of :doc:`Python's limited API <python:c-api/stable>`. :raises setuptools.errors.PlatformError: if 'runtime_library_dirs' is specified on Windows. (since v63) """ def __init__(self, name, sources, *args, **kw): # The *args is needed for compatibility as calls may use positional # arguments. py_limited_api may be set only via keyword. self.py_limited_api = kw.pop("py_limited_api", False) super().__init__(name, sources, *args, **kw) def _convert_pyx_sources_to_lang(self): """ Replace sources with .pyx extensions to sources with the target language extension. This mechanism allows language authors to supply pre-converted sources but to prefer the .pyx sources. """ if _have_cython(): # the build has Cython, so allow it to compile the .pyx files return lang = self.language or '' target_ext = '.cpp' if lang.lower() == 'c++' else '.c' sub = functools.partial(re.sub, '.pyx$', target_ext) self.sources = list(map(sub, self.sources)) class Library(Extension): """Just like a regular Extension, but built as a library instead"""
castiel248/Convert
Lib/site-packages/setuptools/extension.py
Python
mit
5,591
import importlib.util import sys class VendorImporter: """ A PEP 302 meta path importer for finding optionally-vendored or otherwise naturally-installed packages from root_name. """ def __init__(self, root_name, vendored_names=(), vendor_pkg=None): self.root_name = root_name self.vendored_names = set(vendored_names) self.vendor_pkg = vendor_pkg or root_name.replace('extern', '_vendor') @property def search_path(self): """ Search first the vendor package then as a natural package. """ yield self.vendor_pkg + '.' yield '' def _module_matches_namespace(self, fullname): """Figure out if the target module is vendored.""" root, base, target = fullname.partition(self.root_name + '.') return not root and any(map(target.startswith, self.vendored_names)) def load_module(self, fullname): """ Iterate over the search path to locate and load fullname. """ root, base, target = fullname.partition(self.root_name + '.') for prefix in self.search_path: try: extant = prefix + target __import__(extant) mod = sys.modules[extant] sys.modules[fullname] = mod return mod except ImportError: pass else: raise ImportError( "The '{target}' package is required; " "normally this is bundled with this package so if you get " "this warning, consult the packager of your " "distribution.".format(**locals()) ) def create_module(self, spec): return self.load_module(spec.name) def exec_module(self, module): pass def find_spec(self, fullname, path=None, target=None): """Return a module spec for vendored names.""" return ( importlib.util.spec_from_loader(fullname, self) if self._module_matches_namespace(fullname) else None ) def install(self): """ Install this importer into sys.meta_path if not already present. """ if self not in sys.meta_path: sys.meta_path.append(self) names = ( 'packaging', 'pyparsing', 'ordered_set', 'more_itertools', 'importlib_metadata', 'zipp', 'importlib_resources', 'jaraco', 'typing_extensions', 'tomli', ) VendorImporter(__name__, names, 'setuptools._vendor').install()
castiel248/Convert
Lib/site-packages/setuptools/extern/__init__.py
Python
mit
2,512
""" Filename globbing utility. Mostly a copy of `glob` from Python 3.5. Changes include: * `yield from` and PEP3102 `*` removed. * Hidden files are not ignored. """ import os import re import fnmatch __all__ = ["glob", "iglob", "escape"] def glob(pathname, recursive=False): """Return a list of paths matching a pathname pattern. The pattern may contain simple shell-style wildcards a la fnmatch. However, unlike fnmatch, filenames starting with a dot are special cases that are not matched by '*' and '?' patterns. If recursive is true, the pattern '**' will match any files and zero or more directories and subdirectories. """ return list(iglob(pathname, recursive=recursive)) def iglob(pathname, recursive=False): """Return an iterator which yields the paths matching a pathname pattern. The pattern may contain simple shell-style wildcards a la fnmatch. However, unlike fnmatch, filenames starting with a dot are special cases that are not matched by '*' and '?' patterns. If recursive is true, the pattern '**' will match any files and zero or more directories and subdirectories. """ it = _iglob(pathname, recursive) if recursive and _isrecursive(pathname): s = next(it) # skip empty string assert not s return it def _iglob(pathname, recursive): dirname, basename = os.path.split(pathname) glob_in_dir = glob2 if recursive and _isrecursive(basename) else glob1 if not has_magic(pathname): if basename: if os.path.lexists(pathname): yield pathname else: # Patterns ending with a slash should match only directories if os.path.isdir(dirname): yield pathname return if not dirname: yield from glob_in_dir(dirname, basename) return # `os.path.split()` returns the argument itself as a dirname if it is a # drive or UNC path. Prevent an infinite recursion if a drive or UNC path # contains magic characters (i.e. r'\\?\C:'). if dirname != pathname and has_magic(dirname): dirs = _iglob(dirname, recursive) else: dirs = [dirname] if not has_magic(basename): glob_in_dir = glob0 for dirname in dirs: for name in glob_in_dir(dirname, basename): yield os.path.join(dirname, name) # These 2 helper functions non-recursively glob inside a literal directory. # They return a list of basenames. `glob1` accepts a pattern while `glob0` # takes a literal basename (so it only has to check for its existence). def glob1(dirname, pattern): if not dirname: if isinstance(pattern, bytes): dirname = os.curdir.encode('ASCII') else: dirname = os.curdir try: names = os.listdir(dirname) except OSError: return [] return fnmatch.filter(names, pattern) def glob0(dirname, basename): if not basename: # `os.path.split()` returns an empty basename for paths ending with a # directory separator. 'q*x/' should match only directories. if os.path.isdir(dirname): return [basename] else: if os.path.lexists(os.path.join(dirname, basename)): return [basename] return [] # This helper function recursively yields relative pathnames inside a literal # directory. def glob2(dirname, pattern): assert _isrecursive(pattern) yield pattern[:0] for x in _rlistdir(dirname): yield x # Recursively yields relative pathnames inside a literal directory. def _rlistdir(dirname): if not dirname: if isinstance(dirname, bytes): dirname = os.curdir.encode('ASCII') else: dirname = os.curdir try: names = os.listdir(dirname) except os.error: return for x in names: yield x path = os.path.join(dirname, x) if dirname else x for y in _rlistdir(path): yield os.path.join(x, y) magic_check = re.compile('([*?[])') magic_check_bytes = re.compile(b'([*?[])') def has_magic(s): if isinstance(s, bytes): match = magic_check_bytes.search(s) else: match = magic_check.search(s) return match is not None def _isrecursive(pattern): if isinstance(pattern, bytes): return pattern == b'**' else: return pattern == '**' def escape(pathname): """Escape all special characters. """ # Escaping is done by wrapping any of "*?[" between square brackets. # Metacharacters do not work in the drive part and shouldn't be escaped. drive, pathname = os.path.splitdrive(pathname) if isinstance(pathname, bytes): pathname = magic_check_bytes.sub(br'[\1]', pathname) else: pathname = magic_check.sub(r'[\1]', pathname) return drive + pathname
castiel248/Convert
Lib/site-packages/setuptools/glob.py
Python
mit
4,873
import glob import os import subprocess import sys import tempfile import warnings from distutils import log from distutils.errors import DistutilsError import pkg_resources from setuptools.wheel import Wheel from ._deprecation_warning import SetuptoolsDeprecationWarning def _fixup_find_links(find_links): """Ensure find-links option end-up being a list of strings.""" if isinstance(find_links, str): return find_links.split() assert isinstance(find_links, (tuple, list)) return find_links def fetch_build_egg(dist, req): # noqa: C901 # is too complex (16) # FIXME """Fetch an egg needed for building. Use pip/wheel to fetch/build a wheel.""" warnings.warn( "setuptools.installer is deprecated. Requirements should " "be satisfied by a PEP 517 installer.", SetuptoolsDeprecationWarning, ) # Warn if wheel is not available try: pkg_resources.get_distribution('wheel') except pkg_resources.DistributionNotFound: dist.announce('WARNING: The wheel package is not available.', log.WARN) # Ignore environment markers; if supplied, it is required. req = strip_marker(req) # Take easy_install options into account, but do not override relevant # pip environment variables (like PIP_INDEX_URL or PIP_QUIET); they'll # take precedence. opts = dist.get_option_dict('easy_install') if 'allow_hosts' in opts: raise DistutilsError('the `allow-hosts` option is not supported ' 'when using pip to install requirements.') quiet = 'PIP_QUIET' not in os.environ and 'PIP_VERBOSE' not in os.environ if 'PIP_INDEX_URL' in os.environ: index_url = None elif 'index_url' in opts: index_url = opts['index_url'][1] else: index_url = None find_links = ( _fixup_find_links(opts['find_links'][1])[:] if 'find_links' in opts else [] ) if dist.dependency_links: find_links.extend(dist.dependency_links) eggs_dir = os.path.realpath(dist.get_egg_cache_dir()) environment = pkg_resources.Environment() for egg_dist in pkg_resources.find_distributions(eggs_dir): if egg_dist in req and environment.can_add(egg_dist): return egg_dist with tempfile.TemporaryDirectory() as tmpdir: cmd = [ sys.executable, '-m', 'pip', '--disable-pip-version-check', 'wheel', '--no-deps', '-w', tmpdir, ] if quiet: cmd.append('--quiet') if index_url is not None: cmd.extend(('--index-url', index_url)) for link in find_links or []: cmd.extend(('--find-links', link)) # If requirement is a PEP 508 direct URL, directly pass # the URL to pip, as `req @ url` does not work on the # command line. cmd.append(req.url or str(req)) try: subprocess.check_call(cmd) except subprocess.CalledProcessError as e: raise DistutilsError(str(e)) from e wheel = Wheel(glob.glob(os.path.join(tmpdir, '*.whl'))[0]) dist_location = os.path.join(eggs_dir, wheel.egg_name()) wheel.install_as_egg(dist_location) dist_metadata = pkg_resources.PathMetadata( dist_location, os.path.join(dist_location, 'EGG-INFO')) dist = pkg_resources.Distribution.from_filename( dist_location, metadata=dist_metadata) return dist def strip_marker(req): """ Return a new requirement without the environment marker to avoid calling pip with something like `babel; extra == "i18n"`, which would always be ignored. """ # create a copy to avoid mutating the input req = pkg_resources.Requirement.parse(str(req)) req.marker = None return req
castiel248/Convert
Lib/site-packages/setuptools/installer.py
Python
mit
3,824
""" Launch the Python script on the command line after setuptools is bootstrapped via import. """ # Note that setuptools gets imported implicitly by the # invocation of this script using python -m setuptools.launch import tokenize import sys def run(): """ Run the script in sys.argv[1] as if it had been invoked naturally. """ __builtins__ script_name = sys.argv[1] namespace = dict( __file__=script_name, __name__='__main__', __doc__=None, ) sys.argv[:] = sys.argv[1:] open_ = getattr(tokenize, 'open', open) with open_(script_name) as fid: script = fid.read() norm_script = script.replace('\\r\\n', '\\n') code = compile(norm_script, script_name, 'exec') exec(code, namespace) if __name__ == '__main__': run()
castiel248/Convert
Lib/site-packages/setuptools/launch.py
Python
mit
812
import sys import logging import distutils.log from . import monkey def _not_warning(record): return record.levelno < logging.WARNING def configure(): """ Configure logging to emit warning and above to stderr and everything else to stdout. This behavior is provided for compatibility with distutils.log but may change in the future. """ err_handler = logging.StreamHandler() err_handler.setLevel(logging.WARNING) out_handler = logging.StreamHandler(sys.stdout) out_handler.addFilter(_not_warning) handlers = err_handler, out_handler logging.basicConfig( format="{message}", style='{', handlers=handlers, level=logging.DEBUG) if hasattr(distutils.log, 'Log'): monkey.patch_func(set_threshold, distutils.log, 'set_threshold') # For some reason `distutils.log` module is getting cached in `distutils.dist` # and then loaded again when patched, # implying: id(distutils.log) != id(distutils.dist.log). # Make sure the same module object is used everywhere: distutils.dist.log = distutils.log def set_threshold(level): logging.root.setLevel(level*10) return set_threshold.unpatched(level)
castiel248/Convert
Lib/site-packages/setuptools/logging.py
Python
mit
1,210
""" Monkey patching of distutils. """ import sys import distutils.filelist import platform import types import functools from importlib import import_module import inspect import setuptools __all__ = [] """ Everything is private. Contact the project team if you think you need this functionality. """ def _get_mro(cls): """ Returns the bases classes for cls sorted by the MRO. Works around an issue on Jython where inspect.getmro will not return all base classes if multiple classes share the same name. Instead, this function will return a tuple containing the class itself, and the contents of cls.__bases__. See https://github.com/pypa/setuptools/issues/1024. """ if platform.python_implementation() == "Jython": return (cls,) + cls.__bases__ return inspect.getmro(cls) def get_unpatched(item): lookup = ( get_unpatched_class if isinstance(item, type) else get_unpatched_function if isinstance(item, types.FunctionType) else lambda item: None ) return lookup(item) def get_unpatched_class(cls): """Protect against re-patching the distutils if reloaded Also ensures that no other distutils extension monkeypatched the distutils first. """ external_bases = ( cls for cls in _get_mro(cls) if not cls.__module__.startswith('setuptools') ) base = next(external_bases) if not base.__module__.startswith('distutils'): msg = "distutils has already been patched by %r" % cls raise AssertionError(msg) return base def patch_all(): # we can't patch distutils.cmd, alas distutils.core.Command = setuptools.Command has_issue_12885 = sys.version_info <= (3, 5, 3) if has_issue_12885: # fix findall bug in distutils (http://bugs.python.org/issue12885) distutils.filelist.findall = setuptools.findall needs_warehouse = ( (3, 4) < sys.version_info < (3, 4, 6) or (3, 5) < sys.version_info <= (3, 5, 3) ) if needs_warehouse: warehouse = 'https://upload.pypi.org/legacy/' distutils.config.PyPIRCCommand.DEFAULT_REPOSITORY = warehouse _patch_distribution_metadata() # Install Distribution throughout the distutils for module in distutils.dist, distutils.core, distutils.cmd: module.Distribution = setuptools.dist.Distribution # Install the patched Extension distutils.core.Extension = setuptools.extension.Extension distutils.extension.Extension = setuptools.extension.Extension if 'distutils.command.build_ext' in sys.modules: sys.modules['distutils.command.build_ext'].Extension = ( setuptools.extension.Extension ) patch_for_msvc_specialized_compiler() def _patch_distribution_metadata(): """Patch write_pkg_file and read_pkg_file for higher metadata standards""" for attr in ('write_pkg_file', 'read_pkg_file', 'get_metadata_version'): new_val = getattr(setuptools.dist, attr) setattr(distutils.dist.DistributionMetadata, attr, new_val) def patch_func(replacement, target_mod, func_name): """ Patch func_name in target_mod with replacement Important - original must be resolved by name to avoid patching an already patched function. """ original = getattr(target_mod, func_name) # set the 'unpatched' attribute on the replacement to # point to the original. vars(replacement).setdefault('unpatched', original) # replace the function in the original module setattr(target_mod, func_name, replacement) def get_unpatched_function(candidate): return getattr(candidate, 'unpatched') def patch_for_msvc_specialized_compiler(): """ Patch functions in distutils to use standalone Microsoft Visual C++ compilers. """ # import late to avoid circular imports on Python < 3.5 msvc = import_module('setuptools.msvc') if platform.system() != 'Windows': # Compilers only available on Microsoft Windows return def patch_params(mod_name, func_name): """ Prepare the parameters for patch_func to patch indicated function. """ repl_prefix = 'msvc14_' repl_name = repl_prefix + func_name.lstrip('_') repl = getattr(msvc, repl_name) mod = import_module(mod_name) if not hasattr(mod, func_name): raise ImportError(func_name) return repl, mod, func_name # Python 3.5+ msvc14 = functools.partial(patch_params, 'distutils._msvccompiler') try: # Patch distutils._msvccompiler._get_vc_env patch_func(*msvc14('_get_vc_env')) except ImportError: pass try: # Patch distutils._msvccompiler.gen_lib_options for Numpy patch_func(*msvc14('gen_lib_options')) except ImportError: pass
castiel248/Convert
Lib/site-packages/setuptools/monkey.py
Python
mit
4,857
""" Improved support for Microsoft Visual C++ compilers. Known supported compilers: -------------------------- Microsoft Visual C++ 14.X: Microsoft Visual C++ Build Tools 2015 (x86, x64, arm) Microsoft Visual Studio Build Tools 2017 (x86, x64, arm, arm64) Microsoft Visual Studio Build Tools 2019 (x86, x64, arm, arm64) This may also support compilers shipped with compatible Visual Studio versions. """ import json from io import open from os import listdir, pathsep from os.path import join, isfile, isdir, dirname import sys import contextlib import platform import itertools import subprocess import distutils.errors from setuptools.extern.packaging.version import LegacyVersion from setuptools.extern.more_itertools import unique_everseen from .monkey import get_unpatched if platform.system() == 'Windows': import winreg from os import environ else: # Mock winreg and environ so the module can be imported on this platform. class winreg: HKEY_USERS = None HKEY_CURRENT_USER = None HKEY_LOCAL_MACHINE = None HKEY_CLASSES_ROOT = None environ = dict() def _msvc14_find_vc2015(): """Python 3.8 "distutils/_msvccompiler.py" backport""" try: key = winreg.OpenKey( winreg.HKEY_LOCAL_MACHINE, r"Software\Microsoft\VisualStudio\SxS\VC7", 0, winreg.KEY_READ | winreg.KEY_WOW64_32KEY ) except OSError: return None, None best_version = 0 best_dir = None with key: for i in itertools.count(): try: v, vc_dir, vt = winreg.EnumValue(key, i) except OSError: break if v and vt == winreg.REG_SZ and isdir(vc_dir): try: version = int(float(v)) except (ValueError, TypeError): continue if version >= 14 and version > best_version: best_version, best_dir = version, vc_dir return best_version, best_dir def _msvc14_find_vc2017(): """Python 3.8 "distutils/_msvccompiler.py" backport Returns "15, path" based on the result of invoking vswhere.exe If no install is found, returns "None, None" The version is returned to avoid unnecessarily changing the function result. It may be ignored when the path is not None. If vswhere.exe is not available, by definition, VS 2017 is not installed. """ root = environ.get("ProgramFiles(x86)") or environ.get("ProgramFiles") if not root: return None, None try: path = subprocess.check_output([ join(root, "Microsoft Visual Studio", "Installer", "vswhere.exe"), "-latest", "-prerelease", "-requiresAny", "-requires", "Microsoft.VisualStudio.Component.VC.Tools.x86.x64", "-requires", "Microsoft.VisualStudio.Workload.WDExpress", "-property", "installationPath", "-products", "*", ]).decode(encoding="mbcs", errors="strict").strip() except (subprocess.CalledProcessError, OSError, UnicodeDecodeError): return None, None path = join(path, "VC", "Auxiliary", "Build") if isdir(path): return 15, path return None, None PLAT_SPEC_TO_RUNTIME = { 'x86': 'x86', 'x86_amd64': 'x64', 'x86_arm': 'arm', 'x86_arm64': 'arm64' } def _msvc14_find_vcvarsall(plat_spec): """Python 3.8 "distutils/_msvccompiler.py" backport""" _, best_dir = _msvc14_find_vc2017() vcruntime = None if plat_spec in PLAT_SPEC_TO_RUNTIME: vcruntime_plat = PLAT_SPEC_TO_RUNTIME[plat_spec] else: vcruntime_plat = 'x64' if 'amd64' in plat_spec else 'x86' if best_dir: vcredist = join(best_dir, "..", "..", "redist", "MSVC", "**", vcruntime_plat, "Microsoft.VC14*.CRT", "vcruntime140.dll") try: import glob vcruntime = glob.glob(vcredist, recursive=True)[-1] except (ImportError, OSError, LookupError): vcruntime = None if not best_dir: best_version, best_dir = _msvc14_find_vc2015() if best_version: vcruntime = join(best_dir, 'redist', vcruntime_plat, "Microsoft.VC140.CRT", "vcruntime140.dll") if not best_dir: return None, None vcvarsall = join(best_dir, "vcvarsall.bat") if not isfile(vcvarsall): return None, None if not vcruntime or not isfile(vcruntime): vcruntime = None return vcvarsall, vcruntime def _msvc14_get_vc_env(plat_spec): """Python 3.8 "distutils/_msvccompiler.py" backport""" if "DISTUTILS_USE_SDK" in environ: return { key.lower(): value for key, value in environ.items() } vcvarsall, vcruntime = _msvc14_find_vcvarsall(plat_spec) if not vcvarsall: raise distutils.errors.DistutilsPlatformError( "Unable to find vcvarsall.bat" ) try: out = subprocess.check_output( 'cmd /u /c "{}" {} && set'.format(vcvarsall, plat_spec), stderr=subprocess.STDOUT, ).decode('utf-16le', errors='replace') except subprocess.CalledProcessError as exc: raise distutils.errors.DistutilsPlatformError( "Error executing {}".format(exc.cmd) ) from exc env = { key.lower(): value for key, _, value in (line.partition('=') for line in out.splitlines()) if key and value } if vcruntime: env['py_vcruntime_redist'] = vcruntime return env def msvc14_get_vc_env(plat_spec): """ Patched "distutils._msvccompiler._get_vc_env" for support extra Microsoft Visual C++ 14.X compilers. Set environment without use of "vcvarsall.bat". Parameters ---------- plat_spec: str Target architecture. Return ------ dict environment """ # Always use backport from CPython 3.8 try: return _msvc14_get_vc_env(plat_spec) except distutils.errors.DistutilsPlatformError as exc: _augment_exception(exc, 14.0) raise def msvc14_gen_lib_options(*args, **kwargs): """ Patched "distutils._msvccompiler.gen_lib_options" for fix compatibility between "numpy.distutils" and "distutils._msvccompiler" (for Numpy < 1.11.2) """ if "numpy.distutils" in sys.modules: import numpy as np if LegacyVersion(np.__version__) < LegacyVersion('1.11.2'): return np.distutils.ccompiler.gen_lib_options(*args, **kwargs) return get_unpatched(msvc14_gen_lib_options)(*args, **kwargs) def _augment_exception(exc, version, arch=''): """ Add details to the exception message to help guide the user as to what action will resolve it. """ # Error if MSVC++ directory not found or environment not set message = exc.args[0] if "vcvarsall" in message.lower() or "visual c" in message.lower(): # Special error message if MSVC++ not installed tmpl = 'Microsoft Visual C++ {version:0.1f} or greater is required.' message = tmpl.format(**locals()) msdownload = 'www.microsoft.com/download/details.aspx?id=%d' if version == 9.0: if arch.lower().find('ia64') > -1: # For VC++ 9.0, if IA64 support is needed, redirect user # to Windows SDK 7.0. # Note: No download link available from Microsoft. message += ' Get it with "Microsoft Windows SDK 7.0"' else: # For VC++ 9.0 redirect user to Vc++ for Python 2.7 : # This redirection link is maintained by Microsoft. # Contact vspython@microsoft.com if it needs updating. message += ' Get it from http://aka.ms/vcpython27' elif version == 10.0: # For VC++ 10.0 Redirect user to Windows SDK 7.1 message += ' Get it with "Microsoft Windows SDK 7.1": ' message += msdownload % 8279 elif version >= 14.0: # For VC++ 14.X Redirect user to latest Visual C++ Build Tools message += (' Get it with "Microsoft C++ Build Tools": ' r'https://visualstudio.microsoft.com' r'/visual-cpp-build-tools/') exc.args = (message, ) class PlatformInfo: """ Current and Target Architectures information. Parameters ---------- arch: str Target architecture. """ current_cpu = environ.get('processor_architecture', '').lower() def __init__(self, arch): self.arch = arch.lower().replace('x64', 'amd64') @property def target_cpu(self): """ Return Target CPU architecture. Return ------ str Target CPU """ return self.arch[self.arch.find('_') + 1:] def target_is_x86(self): """ Return True if target CPU is x86 32 bits.. Return ------ bool CPU is x86 32 bits """ return self.target_cpu == 'x86' def current_is_x86(self): """ Return True if current CPU is x86 32 bits.. Return ------ bool CPU is x86 32 bits """ return self.current_cpu == 'x86' def current_dir(self, hidex86=False, x64=False): """ Current platform specific subfolder. Parameters ---------- hidex86: bool return '' and not '\x86' if architecture is x86. x64: bool return '\x64' and not '\amd64' if architecture is amd64. Return ------ str subfolder: '\target', or '' (see hidex86 parameter) """ return ( '' if (self.current_cpu == 'x86' and hidex86) else r'\x64' if (self.current_cpu == 'amd64' and x64) else r'\%s' % self.current_cpu ) def target_dir(self, hidex86=False, x64=False): r""" Target platform specific subfolder. Parameters ---------- hidex86: bool return '' and not '\x86' if architecture is x86. x64: bool return '\x64' and not '\amd64' if architecture is amd64. Return ------ str subfolder: '\current', or '' (see hidex86 parameter) """ return ( '' if (self.target_cpu == 'x86' and hidex86) else r'\x64' if (self.target_cpu == 'amd64' and x64) else r'\%s' % self.target_cpu ) def cross_dir(self, forcex86=False): r""" Cross platform specific subfolder. Parameters ---------- forcex86: bool Use 'x86' as current architecture even if current architecture is not x86. Return ------ str subfolder: '' if target architecture is current architecture, '\current_target' if not. """ current = 'x86' if forcex86 else self.current_cpu return ( '' if self.target_cpu == current else self.target_dir().replace('\\', '\\%s_' % current) ) class RegistryInfo: """ Microsoft Visual Studio related registry information. Parameters ---------- platform_info: PlatformInfo "PlatformInfo" instance. """ HKEYS = (winreg.HKEY_USERS, winreg.HKEY_CURRENT_USER, winreg.HKEY_LOCAL_MACHINE, winreg.HKEY_CLASSES_ROOT) def __init__(self, platform_info): self.pi = platform_info @property def visualstudio(self): """ Microsoft Visual Studio root registry key. Return ------ str Registry key """ return 'VisualStudio' @property def sxs(self): """ Microsoft Visual Studio SxS registry key. Return ------ str Registry key """ return join(self.visualstudio, 'SxS') @property def vc(self): """ Microsoft Visual C++ VC7 registry key. Return ------ str Registry key """ return join(self.sxs, 'VC7') @property def vs(self): """ Microsoft Visual Studio VS7 registry key. Return ------ str Registry key """ return join(self.sxs, 'VS7') @property def vc_for_python(self): """ Microsoft Visual C++ for Python registry key. Return ------ str Registry key """ return r'DevDiv\VCForPython' @property def microsoft_sdk(self): """ Microsoft SDK registry key. Return ------ str Registry key """ return 'Microsoft SDKs' @property def windows_sdk(self): """ Microsoft Windows/Platform SDK registry key. Return ------ str Registry key """ return join(self.microsoft_sdk, 'Windows') @property def netfx_sdk(self): """ Microsoft .NET Framework SDK registry key. Return ------ str Registry key """ return join(self.microsoft_sdk, 'NETFXSDK') @property def windows_kits_roots(self): """ Microsoft Windows Kits Roots registry key. Return ------ str Registry key """ return r'Windows Kits\Installed Roots' def microsoft(self, key, x86=False): """ Return key in Microsoft software registry. Parameters ---------- key: str Registry key path where look. x86: str Force x86 software registry. Return ------ str Registry key """ node64 = '' if self.pi.current_is_x86() or x86 else 'Wow6432Node' return join('Software', node64, 'Microsoft', key) def lookup(self, key, name): """ Look for values in registry in Microsoft software registry. Parameters ---------- key: str Registry key path where look. name: str Value name to find. Return ------ str value """ key_read = winreg.KEY_READ openkey = winreg.OpenKey closekey = winreg.CloseKey ms = self.microsoft for hkey in self.HKEYS: bkey = None try: bkey = openkey(hkey, ms(key), 0, key_read) except (OSError, IOError): if not self.pi.current_is_x86(): try: bkey = openkey(hkey, ms(key, True), 0, key_read) except (OSError, IOError): continue else: continue try: return winreg.QueryValueEx(bkey, name)[0] except (OSError, IOError): pass finally: if bkey: closekey(bkey) class SystemInfo: """ Microsoft Windows and Visual Studio related system information. Parameters ---------- registry_info: RegistryInfo "RegistryInfo" instance. vc_ver: float Required Microsoft Visual C++ version. """ # Variables and properties in this class use originals CamelCase variables # names from Microsoft source files for more easy comparison. WinDir = environ.get('WinDir', '') ProgramFiles = environ.get('ProgramFiles', '') ProgramFilesx86 = environ.get('ProgramFiles(x86)', ProgramFiles) def __init__(self, registry_info, vc_ver=None): self.ri = registry_info self.pi = self.ri.pi self.known_vs_paths = self.find_programdata_vs_vers() # Except for VS15+, VC version is aligned with VS version self.vs_ver = self.vc_ver = ( vc_ver or self._find_latest_available_vs_ver()) def _find_latest_available_vs_ver(self): """ Find the latest VC version Return ------ float version """ reg_vc_vers = self.find_reg_vs_vers() if not (reg_vc_vers or self.known_vs_paths): raise distutils.errors.DistutilsPlatformError( 'No Microsoft Visual C++ version found') vc_vers = set(reg_vc_vers) vc_vers.update(self.known_vs_paths) return sorted(vc_vers)[-1] def find_reg_vs_vers(self): """ Find Microsoft Visual Studio versions available in registry. Return ------ list of float Versions """ ms = self.ri.microsoft vckeys = (self.ri.vc, self.ri.vc_for_python, self.ri.vs) vs_vers = [] for hkey, key in itertools.product(self.ri.HKEYS, vckeys): try: bkey = winreg.OpenKey(hkey, ms(key), 0, winreg.KEY_READ) except (OSError, IOError): continue with bkey: subkeys, values, _ = winreg.QueryInfoKey(bkey) for i in range(values): with contextlib.suppress(ValueError): ver = float(winreg.EnumValue(bkey, i)[0]) if ver not in vs_vers: vs_vers.append(ver) for i in range(subkeys): with contextlib.suppress(ValueError): ver = float(winreg.EnumKey(bkey, i)) if ver not in vs_vers: vs_vers.append(ver) return sorted(vs_vers) def find_programdata_vs_vers(self): r""" Find Visual studio 2017+ versions from information in "C:\ProgramData\Microsoft\VisualStudio\Packages\_Instances". Return ------ dict float version as key, path as value. """ vs_versions = {} instances_dir = \ r'C:\ProgramData\Microsoft\VisualStudio\Packages\_Instances' try: hashed_names = listdir(instances_dir) except (OSError, IOError): # Directory not exists with all Visual Studio versions return vs_versions for name in hashed_names: try: # Get VS installation path from "state.json" file state_path = join(instances_dir, name, 'state.json') with open(state_path, 'rt', encoding='utf-8') as state_file: state = json.load(state_file) vs_path = state['installationPath'] # Raises OSError if this VS installation does not contain VC listdir(join(vs_path, r'VC\Tools\MSVC')) # Store version and path vs_versions[self._as_float_version( state['installationVersion'])] = vs_path except (OSError, IOError, KeyError): # Skip if "state.json" file is missing or bad format continue return vs_versions @staticmethod def _as_float_version(version): """ Return a string version as a simplified float version (major.minor) Parameters ---------- version: str Version. Return ------ float version """ return float('.'.join(version.split('.')[:2])) @property def VSInstallDir(self): """ Microsoft Visual Studio directory. Return ------ str path """ # Default path default = join(self.ProgramFilesx86, 'Microsoft Visual Studio %0.1f' % self.vs_ver) # Try to get path from registry, if fail use default path return self.ri.lookup(self.ri.vs, '%0.1f' % self.vs_ver) or default @property def VCInstallDir(self): """ Microsoft Visual C++ directory. Return ------ str path """ path = self._guess_vc() or self._guess_vc_legacy() if not isdir(path): msg = 'Microsoft Visual C++ directory not found' raise distutils.errors.DistutilsPlatformError(msg) return path def _guess_vc(self): """ Locate Visual C++ for VS2017+. Return ------ str path """ if self.vs_ver <= 14.0: return '' try: # First search in known VS paths vs_dir = self.known_vs_paths[self.vs_ver] except KeyError: # Else, search with path from registry vs_dir = self.VSInstallDir guess_vc = join(vs_dir, r'VC\Tools\MSVC') # Subdir with VC exact version as name try: # Update the VC version with real one instead of VS version vc_ver = listdir(guess_vc)[-1] self.vc_ver = self._as_float_version(vc_ver) return join(guess_vc, vc_ver) except (OSError, IOError, IndexError): return '' def _guess_vc_legacy(self): """ Locate Visual C++ for versions prior to 2017. Return ------ str path """ default = join(self.ProgramFilesx86, r'Microsoft Visual Studio %0.1f\VC' % self.vs_ver) # Try to get "VC++ for Python" path from registry as default path reg_path = join(self.ri.vc_for_python, '%0.1f' % self.vs_ver) python_vc = self.ri.lookup(reg_path, 'installdir') default_vc = join(python_vc, 'VC') if python_vc else default # Try to get path from registry, if fail use default path return self.ri.lookup(self.ri.vc, '%0.1f' % self.vs_ver) or default_vc @property def WindowsSdkVersion(self): """ Microsoft Windows SDK versions for specified MSVC++ version. Return ------ tuple of str versions """ if self.vs_ver <= 9.0: return '7.0', '6.1', '6.0a' elif self.vs_ver == 10.0: return '7.1', '7.0a' elif self.vs_ver == 11.0: return '8.0', '8.0a' elif self.vs_ver == 12.0: return '8.1', '8.1a' elif self.vs_ver >= 14.0: return '10.0', '8.1' @property def WindowsSdkLastVersion(self): """ Microsoft Windows SDK last version. Return ------ str version """ return self._use_last_dir_name(join(self.WindowsSdkDir, 'lib')) @property # noqa: C901 def WindowsSdkDir(self): # noqa: C901 # is too complex (12) # FIXME """ Microsoft Windows SDK directory. Return ------ str path """ sdkdir = '' for ver in self.WindowsSdkVersion: # Try to get it from registry loc = join(self.ri.windows_sdk, 'v%s' % ver) sdkdir = self.ri.lookup(loc, 'installationfolder') if sdkdir: break if not sdkdir or not isdir(sdkdir): # Try to get "VC++ for Python" version from registry path = join(self.ri.vc_for_python, '%0.1f' % self.vc_ver) install_base = self.ri.lookup(path, 'installdir') if install_base: sdkdir = join(install_base, 'WinSDK') if not sdkdir or not isdir(sdkdir): # If fail, use default new path for ver in self.WindowsSdkVersion: intver = ver[:ver.rfind('.')] path = r'Microsoft SDKs\Windows Kits\%s' % intver d = join(self.ProgramFiles, path) if isdir(d): sdkdir = d if not sdkdir or not isdir(sdkdir): # If fail, use default old path for ver in self.WindowsSdkVersion: path = r'Microsoft SDKs\Windows\v%s' % ver d = join(self.ProgramFiles, path) if isdir(d): sdkdir = d if not sdkdir: # If fail, use Platform SDK sdkdir = join(self.VCInstallDir, 'PlatformSDK') return sdkdir @property def WindowsSDKExecutablePath(self): """ Microsoft Windows SDK executable directory. Return ------ str path """ # Find WinSDK NetFx Tools registry dir name if self.vs_ver <= 11.0: netfxver = 35 arch = '' else: netfxver = 40 hidex86 = True if self.vs_ver <= 12.0 else False arch = self.pi.current_dir(x64=True, hidex86=hidex86) fx = 'WinSDK-NetFx%dTools%s' % (netfxver, arch.replace('\\', '-')) # list all possibles registry paths regpaths = [] if self.vs_ver >= 14.0: for ver in self.NetFxSdkVersion: regpaths += [join(self.ri.netfx_sdk, ver, fx)] for ver in self.WindowsSdkVersion: regpaths += [join(self.ri.windows_sdk, 'v%sA' % ver, fx)] # Return installation folder from the more recent path for path in regpaths: execpath = self.ri.lookup(path, 'installationfolder') if execpath: return execpath @property def FSharpInstallDir(self): """ Microsoft Visual F# directory. Return ------ str path """ path = join(self.ri.visualstudio, r'%0.1f\Setup\F#' % self.vs_ver) return self.ri.lookup(path, 'productdir') or '' @property def UniversalCRTSdkDir(self): """ Microsoft Universal CRT SDK directory. Return ------ str path """ # Set Kit Roots versions for specified MSVC++ version vers = ('10', '81') if self.vs_ver >= 14.0 else () # Find path of the more recent Kit for ver in vers: sdkdir = self.ri.lookup(self.ri.windows_kits_roots, 'kitsroot%s' % ver) if sdkdir: return sdkdir or '' @property def UniversalCRTSdkLastVersion(self): """ Microsoft Universal C Runtime SDK last version. Return ------ str version """ return self._use_last_dir_name(join(self.UniversalCRTSdkDir, 'lib')) @property def NetFxSdkVersion(self): """ Microsoft .NET Framework SDK versions. Return ------ tuple of str versions """ # Set FxSdk versions for specified VS version return (('4.7.2', '4.7.1', '4.7', '4.6.2', '4.6.1', '4.6', '4.5.2', '4.5.1', '4.5') if self.vs_ver >= 14.0 else ()) @property def NetFxSdkDir(self): """ Microsoft .NET Framework SDK directory. Return ------ str path """ sdkdir = '' for ver in self.NetFxSdkVersion: loc = join(self.ri.netfx_sdk, ver) sdkdir = self.ri.lookup(loc, 'kitsinstallationfolder') if sdkdir: break return sdkdir @property def FrameworkDir32(self): """ Microsoft .NET Framework 32bit directory. Return ------ str path """ # Default path guess_fw = join(self.WinDir, r'Microsoft.NET\Framework') # Try to get path from registry, if fail use default path return self.ri.lookup(self.ri.vc, 'frameworkdir32') or guess_fw @property def FrameworkDir64(self): """ Microsoft .NET Framework 64bit directory. Return ------ str path """ # Default path guess_fw = join(self.WinDir, r'Microsoft.NET\Framework64') # Try to get path from registry, if fail use default path return self.ri.lookup(self.ri.vc, 'frameworkdir64') or guess_fw @property def FrameworkVersion32(self): """ Microsoft .NET Framework 32bit versions. Return ------ tuple of str versions """ return self._find_dot_net_versions(32) @property def FrameworkVersion64(self): """ Microsoft .NET Framework 64bit versions. Return ------ tuple of str versions """ return self._find_dot_net_versions(64) def _find_dot_net_versions(self, bits): """ Find Microsoft .NET Framework versions. Parameters ---------- bits: int Platform number of bits: 32 or 64. Return ------ tuple of str versions """ # Find actual .NET version in registry reg_ver = self.ri.lookup(self.ri.vc, 'frameworkver%d' % bits) dot_net_dir = getattr(self, 'FrameworkDir%d' % bits) ver = reg_ver or self._use_last_dir_name(dot_net_dir, 'v') or '' # Set .NET versions for specified MSVC++ version if self.vs_ver >= 12.0: return ver, 'v4.0' elif self.vs_ver >= 10.0: return 'v4.0.30319' if ver.lower()[:2] != 'v4' else ver, 'v3.5' elif self.vs_ver == 9.0: return 'v3.5', 'v2.0.50727' elif self.vs_ver == 8.0: return 'v3.0', 'v2.0.50727' @staticmethod def _use_last_dir_name(path, prefix=''): """ Return name of the last dir in path or '' if no dir found. Parameters ---------- path: str Use dirs in this path prefix: str Use only dirs starting by this prefix Return ------ str name """ matching_dirs = ( dir_name for dir_name in reversed(listdir(path)) if isdir(join(path, dir_name)) and dir_name.startswith(prefix) ) return next(matching_dirs, None) or '' class EnvironmentInfo: """ Return environment variables for specified Microsoft Visual C++ version and platform : Lib, Include, Path and libpath. This function is compatible with Microsoft Visual C++ 9.0 to 14.X. Script created by analysing Microsoft environment configuration files like "vcvars[...].bat", "SetEnv.Cmd", "vcbuildtools.bat", ... Parameters ---------- arch: str Target architecture. vc_ver: float Required Microsoft Visual C++ version. If not set, autodetect the last version. vc_min_ver: float Minimum Microsoft Visual C++ version. """ # Variables and properties in this class use originals CamelCase variables # names from Microsoft source files for more easy comparison. def __init__(self, arch, vc_ver=None, vc_min_ver=0): self.pi = PlatformInfo(arch) self.ri = RegistryInfo(self.pi) self.si = SystemInfo(self.ri, vc_ver) if self.vc_ver < vc_min_ver: err = 'No suitable Microsoft Visual C++ version found' raise distutils.errors.DistutilsPlatformError(err) @property def vs_ver(self): """ Microsoft Visual Studio. Return ------ float version """ return self.si.vs_ver @property def vc_ver(self): """ Microsoft Visual C++ version. Return ------ float version """ return self.si.vc_ver @property def VSTools(self): """ Microsoft Visual Studio Tools. Return ------ list of str paths """ paths = [r'Common7\IDE', r'Common7\Tools'] if self.vs_ver >= 14.0: arch_subdir = self.pi.current_dir(hidex86=True, x64=True) paths += [r'Common7\IDE\CommonExtensions\Microsoft\TestWindow'] paths += [r'Team Tools\Performance Tools'] paths += [r'Team Tools\Performance Tools%s' % arch_subdir] return [join(self.si.VSInstallDir, path) for path in paths] @property def VCIncludes(self): """ Microsoft Visual C++ & Microsoft Foundation Class Includes. Return ------ list of str paths """ return [join(self.si.VCInstallDir, 'Include'), join(self.si.VCInstallDir, r'ATLMFC\Include')] @property def VCLibraries(self): """ Microsoft Visual C++ & Microsoft Foundation Class Libraries. Return ------ list of str paths """ if self.vs_ver >= 15.0: arch_subdir = self.pi.target_dir(x64=True) else: arch_subdir = self.pi.target_dir(hidex86=True) paths = ['Lib%s' % arch_subdir, r'ATLMFC\Lib%s' % arch_subdir] if self.vs_ver >= 14.0: paths += [r'Lib\store%s' % arch_subdir] return [join(self.si.VCInstallDir, path) for path in paths] @property def VCStoreRefs(self): """ Microsoft Visual C++ store references Libraries. Return ------ list of str paths """ if self.vs_ver < 14.0: return [] return [join(self.si.VCInstallDir, r'Lib\store\references')] @property def VCTools(self): """ Microsoft Visual C++ Tools. Return ------ list of str paths """ si = self.si tools = [join(si.VCInstallDir, 'VCPackages')] forcex86 = True if self.vs_ver <= 10.0 else False arch_subdir = self.pi.cross_dir(forcex86) if arch_subdir: tools += [join(si.VCInstallDir, 'Bin%s' % arch_subdir)] if self.vs_ver == 14.0: path = 'Bin%s' % self.pi.current_dir(hidex86=True) tools += [join(si.VCInstallDir, path)] elif self.vs_ver >= 15.0: host_dir = (r'bin\HostX86%s' if self.pi.current_is_x86() else r'bin\HostX64%s') tools += [join( si.VCInstallDir, host_dir % self.pi.target_dir(x64=True))] if self.pi.current_cpu != self.pi.target_cpu: tools += [join( si.VCInstallDir, host_dir % self.pi.current_dir(x64=True))] else: tools += [join(si.VCInstallDir, 'Bin')] return tools @property def OSLibraries(self): """ Microsoft Windows SDK Libraries. Return ------ list of str paths """ if self.vs_ver <= 10.0: arch_subdir = self.pi.target_dir(hidex86=True, x64=True) return [join(self.si.WindowsSdkDir, 'Lib%s' % arch_subdir)] else: arch_subdir = self.pi.target_dir(x64=True) lib = join(self.si.WindowsSdkDir, 'lib') libver = self._sdk_subdir return [join(lib, '%sum%s' % (libver, arch_subdir))] @property def OSIncludes(self): """ Microsoft Windows SDK Include. Return ------ list of str paths """ include = join(self.si.WindowsSdkDir, 'include') if self.vs_ver <= 10.0: return [include, join(include, 'gl')] else: if self.vs_ver >= 14.0: sdkver = self._sdk_subdir else: sdkver = '' return [join(include, '%sshared' % sdkver), join(include, '%sum' % sdkver), join(include, '%swinrt' % sdkver)] @property def OSLibpath(self): """ Microsoft Windows SDK Libraries Paths. Return ------ list of str paths """ ref = join(self.si.WindowsSdkDir, 'References') libpath = [] if self.vs_ver <= 9.0: libpath += self.OSLibraries if self.vs_ver >= 11.0: libpath += [join(ref, r'CommonConfiguration\Neutral')] if self.vs_ver >= 14.0: libpath += [ ref, join(self.si.WindowsSdkDir, 'UnionMetadata'), join( ref, 'Windows.Foundation.UniversalApiContract', '1.0.0.0'), join(ref, 'Windows.Foundation.FoundationContract', '1.0.0.0'), join( ref, 'Windows.Networking.Connectivity.WwanContract', '1.0.0.0'), join( self.si.WindowsSdkDir, 'ExtensionSDKs', 'Microsoft.VCLibs', '%0.1f' % self.vs_ver, 'References', 'CommonConfiguration', 'neutral'), ] return libpath @property def SdkTools(self): """ Microsoft Windows SDK Tools. Return ------ list of str paths """ return list(self._sdk_tools()) def _sdk_tools(self): """ Microsoft Windows SDK Tools paths generator. Return ------ generator of str paths """ if self.vs_ver < 15.0: bin_dir = 'Bin' if self.vs_ver <= 11.0 else r'Bin\x86' yield join(self.si.WindowsSdkDir, bin_dir) if not self.pi.current_is_x86(): arch_subdir = self.pi.current_dir(x64=True) path = 'Bin%s' % arch_subdir yield join(self.si.WindowsSdkDir, path) if self.vs_ver in (10.0, 11.0): if self.pi.target_is_x86(): arch_subdir = '' else: arch_subdir = self.pi.current_dir(hidex86=True, x64=True) path = r'Bin\NETFX 4.0 Tools%s' % arch_subdir yield join(self.si.WindowsSdkDir, path) elif self.vs_ver >= 15.0: path = join(self.si.WindowsSdkDir, 'Bin') arch_subdir = self.pi.current_dir(x64=True) sdkver = self.si.WindowsSdkLastVersion yield join(path, '%s%s' % (sdkver, arch_subdir)) if self.si.WindowsSDKExecutablePath: yield self.si.WindowsSDKExecutablePath @property def _sdk_subdir(self): """ Microsoft Windows SDK version subdir. Return ------ str subdir """ ucrtver = self.si.WindowsSdkLastVersion return ('%s\\' % ucrtver) if ucrtver else '' @property def SdkSetup(self): """ Microsoft Windows SDK Setup. Return ------ list of str paths """ if self.vs_ver > 9.0: return [] return [join(self.si.WindowsSdkDir, 'Setup')] @property def FxTools(self): """ Microsoft .NET Framework Tools. Return ------ list of str paths """ pi = self.pi si = self.si if self.vs_ver <= 10.0: include32 = True include64 = not pi.target_is_x86() and not pi.current_is_x86() else: include32 = pi.target_is_x86() or pi.current_is_x86() include64 = pi.current_cpu == 'amd64' or pi.target_cpu == 'amd64' tools = [] if include32: tools += [join(si.FrameworkDir32, ver) for ver in si.FrameworkVersion32] if include64: tools += [join(si.FrameworkDir64, ver) for ver in si.FrameworkVersion64] return tools @property def NetFxSDKLibraries(self): """ Microsoft .Net Framework SDK Libraries. Return ------ list of str paths """ if self.vs_ver < 14.0 or not self.si.NetFxSdkDir: return [] arch_subdir = self.pi.target_dir(x64=True) return [join(self.si.NetFxSdkDir, r'lib\um%s' % arch_subdir)] @property def NetFxSDKIncludes(self): """ Microsoft .Net Framework SDK Includes. Return ------ list of str paths """ if self.vs_ver < 14.0 or not self.si.NetFxSdkDir: return [] return [join(self.si.NetFxSdkDir, r'include\um')] @property def VsTDb(self): """ Microsoft Visual Studio Team System Database. Return ------ list of str paths """ return [join(self.si.VSInstallDir, r'VSTSDB\Deploy')] @property def MSBuild(self): """ Microsoft Build Engine. Return ------ list of str paths """ if self.vs_ver < 12.0: return [] elif self.vs_ver < 15.0: base_path = self.si.ProgramFilesx86 arch_subdir = self.pi.current_dir(hidex86=True) else: base_path = self.si.VSInstallDir arch_subdir = '' path = r'MSBuild\%0.1f\bin%s' % (self.vs_ver, arch_subdir) build = [join(base_path, path)] if self.vs_ver >= 15.0: # Add Roslyn C# & Visual Basic Compiler build += [join(base_path, path, 'Roslyn')] return build @property def HTMLHelpWorkshop(self): """ Microsoft HTML Help Workshop. Return ------ list of str paths """ if self.vs_ver < 11.0: return [] return [join(self.si.ProgramFilesx86, 'HTML Help Workshop')] @property def UCRTLibraries(self): """ Microsoft Universal C Runtime SDK Libraries. Return ------ list of str paths """ if self.vs_ver < 14.0: return [] arch_subdir = self.pi.target_dir(x64=True) lib = join(self.si.UniversalCRTSdkDir, 'lib') ucrtver = self._ucrt_subdir return [join(lib, '%sucrt%s' % (ucrtver, arch_subdir))] @property def UCRTIncludes(self): """ Microsoft Universal C Runtime SDK Include. Return ------ list of str paths """ if self.vs_ver < 14.0: return [] include = join(self.si.UniversalCRTSdkDir, 'include') return [join(include, '%sucrt' % self._ucrt_subdir)] @property def _ucrt_subdir(self): """ Microsoft Universal C Runtime SDK version subdir. Return ------ str subdir """ ucrtver = self.si.UniversalCRTSdkLastVersion return ('%s\\' % ucrtver) if ucrtver else '' @property def FSharp(self): """ Microsoft Visual F#. Return ------ list of str paths """ if 11.0 > self.vs_ver > 12.0: return [] return [self.si.FSharpInstallDir] @property def VCRuntimeRedist(self): """ Microsoft Visual C++ runtime redistributable dll. Return ------ str path """ vcruntime = 'vcruntime%d0.dll' % self.vc_ver arch_subdir = self.pi.target_dir(x64=True).strip('\\') # Installation prefixes candidates prefixes = [] tools_path = self.si.VCInstallDir redist_path = dirname(tools_path.replace(r'\Tools', r'\Redist')) if isdir(redist_path): # Redist version may not be exactly the same as tools redist_path = join(redist_path, listdir(redist_path)[-1]) prefixes += [redist_path, join(redist_path, 'onecore')] prefixes += [join(tools_path, 'redist')] # VS14 legacy path # CRT directory crt_dirs = ('Microsoft.VC%d.CRT' % (self.vc_ver * 10), # Sometime store in directory with VS version instead of VC 'Microsoft.VC%d.CRT' % (int(self.vs_ver) * 10)) # vcruntime path for prefix, crt_dir in itertools.product(prefixes, crt_dirs): path = join(prefix, arch_subdir, crt_dir, vcruntime) if isfile(path): return path def return_env(self, exists=True): """ Return environment dict. Parameters ---------- exists: bool It True, only return existing paths. Return ------ dict environment """ env = dict( include=self._build_paths('include', [self.VCIncludes, self.OSIncludes, self.UCRTIncludes, self.NetFxSDKIncludes], exists), lib=self._build_paths('lib', [self.VCLibraries, self.OSLibraries, self.FxTools, self.UCRTLibraries, self.NetFxSDKLibraries], exists), libpath=self._build_paths('libpath', [self.VCLibraries, self.FxTools, self.VCStoreRefs, self.OSLibpath], exists), path=self._build_paths('path', [self.VCTools, self.VSTools, self.VsTDb, self.SdkTools, self.SdkSetup, self.FxTools, self.MSBuild, self.HTMLHelpWorkshop, self.FSharp], exists), ) if self.vs_ver >= 14 and isfile(self.VCRuntimeRedist): env['py_vcruntime_redist'] = self.VCRuntimeRedist return env def _build_paths(self, name, spec_path_lists, exists): """ Given an environment variable name and specified paths, return a pathsep-separated string of paths containing unique, extant, directories from those paths and from the environment variable. Raise an error if no paths are resolved. Parameters ---------- name: str Environment variable name spec_path_lists: list of str Paths exists: bool It True, only return existing paths. Return ------ str Pathsep-separated paths """ # flatten spec_path_lists spec_paths = itertools.chain.from_iterable(spec_path_lists) env_paths = environ.get(name, '').split(pathsep) paths = itertools.chain(spec_paths, env_paths) extant_paths = list(filter(isdir, paths)) if exists else paths if not extant_paths: msg = "%s environment variable is empty" % name.upper() raise distutils.errors.DistutilsPlatformError(msg) unique_paths = unique_everseen(extant_paths) return pathsep.join(unique_paths)
castiel248/Convert
Lib/site-packages/setuptools/msvc.py
Python
mit
47,724
import os from distutils import log import itertools flatten = itertools.chain.from_iterable class Installer: nspkg_ext = '-nspkg.pth' def install_namespaces(self): nsp = self._get_all_ns_packages() if not nsp: return filename, ext = os.path.splitext(self._get_target()) filename += self.nspkg_ext self.outputs.append(filename) log.info("Installing %s", filename) lines = map(self._gen_nspkg_line, nsp) if self.dry_run: # always generate the lines, even in dry run list(lines) return with open(filename, 'wt') as f: f.writelines(lines) def uninstall_namespaces(self): filename, ext = os.path.splitext(self._get_target()) filename += self.nspkg_ext if not os.path.exists(filename): return log.info("Removing %s", filename) os.remove(filename) def _get_target(self): return self.target _nspkg_tmpl = ( "import sys, types, os", "has_mfs = sys.version_info > (3, 5)", "p = os.path.join(%(root)s, *%(pth)r)", "importlib = has_mfs and __import__('importlib.util')", "has_mfs and __import__('importlib.machinery')", ( "m = has_mfs and " "sys.modules.setdefault(%(pkg)r, " "importlib.util.module_from_spec(" "importlib.machinery.PathFinder.find_spec(%(pkg)r, " "[os.path.dirname(p)])))" ), ( "m = m or " "sys.modules.setdefault(%(pkg)r, types.ModuleType(%(pkg)r))" ), "mp = (m or []) and m.__dict__.setdefault('__path__',[])", "(p not in mp) and mp.append(p)", ) "lines for the namespace installer" _nspkg_tmpl_multi = ( 'm and setattr(sys.modules[%(parent)r], %(child)r, m)', ) "additional line(s) when a parent package is indicated" def _get_root(self): return "sys._getframe(1).f_locals['sitedir']" def _gen_nspkg_line(self, pkg): pth = tuple(pkg.split('.')) root = self._get_root() tmpl_lines = self._nspkg_tmpl parent, sep, child = pkg.rpartition('.') if parent: tmpl_lines += self._nspkg_tmpl_multi return ';'.join(tmpl_lines) % locals() + '\n' def _get_all_ns_packages(self): """Return sorted list of all package namespaces""" pkgs = self.distribution.namespace_packages or [] return sorted(flatten(map(self._pkg_names, pkgs))) @staticmethod def _pkg_names(pkg): """ Given a namespace package, yield the components of that package. >>> names = Installer._pkg_names('a.b.c') >>> set(names) == set(['a', 'a.b', 'a.b.c']) True """ parts = pkg.split('.') while parts: yield '.'.join(parts) parts.pop() class DevelopInstaller(Installer): def _get_root(self): return repr(str(self.egg_path)) def _get_target(self): return self.egg_link
castiel248/Convert
Lib/site-packages/setuptools/namespaces.py
Python
mit
3,093
"""PyPI and direct package downloading""" import sys import os import re import io import shutil import socket import base64 import hashlib import itertools import warnings import configparser import html import http.client import urllib.parse import urllib.request import urllib.error from functools import wraps import setuptools from pkg_resources import ( CHECKOUT_DIST, Distribution, BINARY_DIST, normalize_path, SOURCE_DIST, Environment, find_distributions, safe_name, safe_version, to_filename, Requirement, DEVELOP_DIST, EGG_DIST, parse_version, ) from distutils import log from distutils.errors import DistutilsError from fnmatch import translate from setuptools.wheel import Wheel from setuptools.extern.more_itertools import unique_everseen EGG_FRAGMENT = re.compile(r'^egg=([-A-Za-z0-9_.+!]+)$') HREF = re.compile(r"""href\s*=\s*['"]?([^'"> ]+)""", re.I) PYPI_MD5 = re.compile( r'<a href="([^"#]+)">([^<]+)</a>\n\s+\(<a (?:title="MD5 hash"\n\s+)' r'href="[^?]+\?:action=show_md5&amp;digest=([0-9a-f]{32})">md5</a>\)' ) URL_SCHEME = re.compile('([-+.a-z0-9]{2,}):', re.I).match EXTENSIONS = ".tar.gz .tar.bz2 .tar .zip .tgz".split() __all__ = [ 'PackageIndex', 'distros_for_url', 'parse_bdist_wininst', 'interpret_distro_name', ] _SOCKET_TIMEOUT = 15 _tmpl = "setuptools/{setuptools.__version__} Python-urllib/{py_major}" user_agent = _tmpl.format( py_major='{}.{}'.format(*sys.version_info), setuptools=setuptools) def parse_requirement_arg(spec): try: return Requirement.parse(spec) except ValueError as e: raise DistutilsError( "Not a URL, existing file, or requirement spec: %r" % (spec,) ) from e def parse_bdist_wininst(name): """Return (base,pyversion) or (None,None) for possible .exe name""" lower = name.lower() base, py_ver, plat = None, None, None if lower.endswith('.exe'): if lower.endswith('.win32.exe'): base = name[:-10] plat = 'win32' elif lower.startswith('.win32-py', -16): py_ver = name[-7:-4] base = name[:-16] plat = 'win32' elif lower.endswith('.win-amd64.exe'): base = name[:-14] plat = 'win-amd64' elif lower.startswith('.win-amd64-py', -20): py_ver = name[-7:-4] base = name[:-20] plat = 'win-amd64' return base, py_ver, plat def egg_info_for_url(url): parts = urllib.parse.urlparse(url) scheme, server, path, parameters, query, fragment = parts base = urllib.parse.unquote(path.split('/')[-1]) if server == 'sourceforge.net' and base == 'download': # XXX Yuck base = urllib.parse.unquote(path.split('/')[-2]) if '#' in base: base, fragment = base.split('#', 1) return base, fragment def distros_for_url(url, metadata=None): """Yield egg or source distribution objects that might be found at a URL""" base, fragment = egg_info_for_url(url) for dist in distros_for_location(url, base, metadata): yield dist if fragment: match = EGG_FRAGMENT.match(fragment) if match: for dist in interpret_distro_name( url, match.group(1), metadata, precedence=CHECKOUT_DIST ): yield dist def distros_for_location(location, basename, metadata=None): """Yield egg or source distribution objects based on basename""" if basename.endswith('.egg.zip'): basename = basename[:-4] # strip the .zip if basename.endswith('.egg') and '-' in basename: # only one, unambiguous interpretation return [Distribution.from_location(location, basename, metadata)] if basename.endswith('.whl') and '-' in basename: wheel = Wheel(basename) if not wheel.is_compatible(): return [] return [Distribution( location=location, project_name=wheel.project_name, version=wheel.version, # Increase priority over eggs. precedence=EGG_DIST + 1, )] if basename.endswith('.exe'): win_base, py_ver, platform = parse_bdist_wininst(basename) if win_base is not None: return interpret_distro_name( location, win_base, metadata, py_ver, BINARY_DIST, platform ) # Try source distro extensions (.zip, .tgz, etc.) # for ext in EXTENSIONS: if basename.endswith(ext): basename = basename[:-len(ext)] return interpret_distro_name(location, basename, metadata) return [] # no extension matched def distros_for_filename(filename, metadata=None): """Yield possible egg or source distribution objects based on a filename""" return distros_for_location( normalize_path(filename), os.path.basename(filename), metadata ) def interpret_distro_name( location, basename, metadata, py_version=None, precedence=SOURCE_DIST, platform=None ): """Generate alternative interpretations of a source distro name Note: if `location` is a filesystem filename, you should call ``pkg_resources.normalize_path()`` on it before passing it to this routine! """ # Generate alternative interpretations of a source distro name # Because some packages are ambiguous as to name/versions split # e.g. "adns-python-1.1.0", "egenix-mx-commercial", etc. # So, we generate each possible interpretation (e.g. "adns, python-1.1.0" # "adns-python, 1.1.0", and "adns-python-1.1.0, no version"). In practice, # the spurious interpretations should be ignored, because in the event # there's also an "adns" package, the spurious "python-1.1.0" version will # compare lower than any numeric version number, and is therefore unlikely # to match a request for it. It's still a potential problem, though, and # in the long run PyPI and the distutils should go for "safe" names and # versions in distribution archive names (sdist and bdist). parts = basename.split('-') if not py_version and any(re.match(r'py\d\.\d$', p) for p in parts[2:]): # it is a bdist_dumb, not an sdist -- bail out return for p in range(1, len(parts) + 1): yield Distribution( location, metadata, '-'.join(parts[:p]), '-'.join(parts[p:]), py_version=py_version, precedence=precedence, platform=platform ) def unique_values(func): """ Wrap a function returning an iterable such that the resulting iterable only ever yields unique items. """ @wraps(func) def wrapper(*args, **kwargs): return unique_everseen(func(*args, **kwargs)) return wrapper REL = re.compile(r"""<([^>]*\srel\s*=\s*['"]?([^'">]+)[^>]*)>""", re.I) # this line is here to fix emacs' cruddy broken syntax highlighting @unique_values def find_external_links(url, page): """Find rel="homepage" and rel="download" links in `page`, yielding URLs""" for match in REL.finditer(page): tag, rel = match.groups() rels = set(map(str.strip, rel.lower().split(','))) if 'homepage' in rels or 'download' in rels: for match in HREF.finditer(tag): yield urllib.parse.urljoin(url, htmldecode(match.group(1))) for tag in ("<th>Home Page", "<th>Download URL"): pos = page.find(tag) if pos != -1: match = HREF.search(page, pos) if match: yield urllib.parse.urljoin(url, htmldecode(match.group(1))) class ContentChecker: """ A null content checker that defines the interface for checking content """ def feed(self, block): """ Feed a block of data to the hash. """ return def is_valid(self): """ Check the hash. Return False if validation fails. """ return True def report(self, reporter, template): """ Call reporter with information about the checker (hash name) substituted into the template. """ return class HashChecker(ContentChecker): pattern = re.compile( r'(?P<hash_name>sha1|sha224|sha384|sha256|sha512|md5)=' r'(?P<expected>[a-f0-9]+)' ) def __init__(self, hash_name, expected): self.hash_name = hash_name self.hash = hashlib.new(hash_name) self.expected = expected @classmethod def from_url(cls, url): "Construct a (possibly null) ContentChecker from a URL" fragment = urllib.parse.urlparse(url)[-1] if not fragment: return ContentChecker() match = cls.pattern.search(fragment) if not match: return ContentChecker() return cls(**match.groupdict()) def feed(self, block): self.hash.update(block) def is_valid(self): return self.hash.hexdigest() == self.expected def report(self, reporter, template): msg = template % self.hash_name return reporter(msg) class PackageIndex(Environment): """A distribution index that scans web pages for download URLs""" def __init__( self, index_url="https://pypi.org/simple/", hosts=('*',), ca_bundle=None, verify_ssl=True, *args, **kw ): super().__init__(*args, **kw) self.index_url = index_url + "/" [:not index_url.endswith('/')] self.scanned_urls = {} self.fetched_urls = {} self.package_pages = {} self.allows = re.compile('|'.join(map(translate, hosts))).match self.to_scan = [] self.opener = urllib.request.urlopen def add(self, dist): # ignore invalid versions try: parse_version(dist.version) except Exception: return return super().add(dist) # FIXME: 'PackageIndex.process_url' is too complex (14) def process_url(self, url, retrieve=False): # noqa: C901 """Evaluate a URL as a possible download, and maybe retrieve it""" if url in self.scanned_urls and not retrieve: return self.scanned_urls[url] = True if not URL_SCHEME(url): self.process_filename(url) return else: dists = list(distros_for_url(url)) if dists: if not self.url_ok(url): return self.debug("Found link: %s", url) if dists or not retrieve or url in self.fetched_urls: list(map(self.add, dists)) return # don't need the actual page if not self.url_ok(url): self.fetched_urls[url] = True return self.info("Reading %s", url) self.fetched_urls[url] = True # prevent multiple fetch attempts tmpl = "Download error on %s: %%s -- Some packages may not be found!" f = self.open_url(url, tmpl % url) if f is None: return if isinstance(f, urllib.error.HTTPError) and f.code == 401: self.info("Authentication error: %s" % f.msg) self.fetched_urls[f.url] = True if 'html' not in f.headers.get('content-type', '').lower(): f.close() # not html, we can't process it return base = f.url # handle redirects page = f.read() if not isinstance(page, str): # In Python 3 and got bytes but want str. if isinstance(f, urllib.error.HTTPError): # Errors have no charset, assume latin1: charset = 'latin-1' else: charset = f.headers.get_param('charset') or 'latin-1' page = page.decode(charset, "ignore") f.close() for match in HREF.finditer(page): link = urllib.parse.urljoin(base, htmldecode(match.group(1))) self.process_url(link) if url.startswith(self.index_url) and getattr(f, 'code', None) != 404: page = self.process_index(url, page) def process_filename(self, fn, nested=False): # process filenames or directories if not os.path.exists(fn): self.warn("Not found: %s", fn) return if os.path.isdir(fn) and not nested: path = os.path.realpath(fn) for item in os.listdir(path): self.process_filename(os.path.join(path, item), True) dists = distros_for_filename(fn) if dists: self.debug("Found: %s", fn) list(map(self.add, dists)) def url_ok(self, url, fatal=False): s = URL_SCHEME(url) is_file = s and s.group(1).lower() == 'file' if is_file or self.allows(urllib.parse.urlparse(url)[1]): return True msg = ( "\nNote: Bypassing %s (disallowed host; see " "http://bit.ly/2hrImnY for details).\n") if fatal: raise DistutilsError(msg % url) else: self.warn(msg, url) def scan_egg_links(self, search_path): dirs = filter(os.path.isdir, search_path) egg_links = ( (path, entry) for path in dirs for entry in os.listdir(path) if entry.endswith('.egg-link') ) list(itertools.starmap(self.scan_egg_link, egg_links)) def scan_egg_link(self, path, entry): with open(os.path.join(path, entry)) as raw_lines: # filter non-empty lines lines = list(filter(None, map(str.strip, raw_lines))) if len(lines) != 2: # format is not recognized; punt return egg_path, setup_path = lines for dist in find_distributions(os.path.join(path, egg_path)): dist.location = os.path.join(path, *lines) dist.precedence = SOURCE_DIST self.add(dist) def _scan(self, link): # Process a URL to see if it's for a package page NO_MATCH_SENTINEL = None, None if not link.startswith(self.index_url): return NO_MATCH_SENTINEL parts = list(map( urllib.parse.unquote, link[len(self.index_url):].split('/') )) if len(parts) != 2 or '#' in parts[1]: return NO_MATCH_SENTINEL # it's a package page, sanitize and index it pkg = safe_name(parts[0]) ver = safe_version(parts[1]) self.package_pages.setdefault(pkg.lower(), {})[link] = True return to_filename(pkg), to_filename(ver) def process_index(self, url, page): """Process the contents of a PyPI page""" # process an index page into the package-page index for match in HREF.finditer(page): try: self._scan(urllib.parse.urljoin(url, htmldecode(match.group(1)))) except ValueError: pass pkg, ver = self._scan(url) # ensure this page is in the page index if not pkg: return "" # no sense double-scanning non-package pages # process individual package page for new_url in find_external_links(url, page): # Process the found URL base, frag = egg_info_for_url(new_url) if base.endswith('.py') and not frag: if ver: new_url += '#egg=%s-%s' % (pkg, ver) else: self.need_version_info(url) self.scan_url(new_url) return PYPI_MD5.sub( lambda m: '<a href="%s#md5=%s">%s</a>' % m.group(1, 3, 2), page ) def need_version_info(self, url): self.scan_all( "Page at %s links to .py file(s) without version info; an index " "scan is required.", url ) def scan_all(self, msg=None, *args): if self.index_url not in self.fetched_urls: if msg: self.warn(msg, *args) self.info( "Scanning index of all packages (this may take a while)" ) self.scan_url(self.index_url) def find_packages(self, requirement): self.scan_url(self.index_url + requirement.unsafe_name + '/') if not self.package_pages.get(requirement.key): # Fall back to safe version of the name self.scan_url(self.index_url + requirement.project_name + '/') if not self.package_pages.get(requirement.key): # We couldn't find the target package, so search the index page too self.not_found_in_index(requirement) for url in list(self.package_pages.get(requirement.key, ())): # scan each page that might be related to the desired package self.scan_url(url) def obtain(self, requirement, installer=None): self.prescan() self.find_packages(requirement) for dist in self[requirement.key]: if dist in requirement: return dist self.debug("%s does not match %s", requirement, dist) return super(PackageIndex, self).obtain(requirement, installer) def check_hash(self, checker, filename, tfp): """ checker is a ContentChecker """ checker.report( self.debug, "Validating %%s checksum for %s" % filename) if not checker.is_valid(): tfp.close() os.unlink(filename) raise DistutilsError( "%s validation failed for %s; " "possible download problem?" % (checker.hash.name, os.path.basename(filename)) ) def add_find_links(self, urls): """Add `urls` to the list that will be prescanned for searches""" for url in urls: if ( self.to_scan is None # if we have already "gone online" or not URL_SCHEME(url) # or it's a local file/directory or url.startswith('file:') or list(distros_for_url(url)) # or a direct package link ): # then go ahead and process it now self.scan_url(url) else: # otherwise, defer retrieval till later self.to_scan.append(url) def prescan(self): """Scan urls scheduled for prescanning (e.g. --find-links)""" if self.to_scan: list(map(self.scan_url, self.to_scan)) self.to_scan = None # from now on, go ahead and process immediately def not_found_in_index(self, requirement): if self[requirement.key]: # we've seen at least one distro meth, msg = self.info, "Couldn't retrieve index page for %r" else: # no distros seen for this name, might be misspelled meth, msg = ( self.warn, "Couldn't find index page for %r (maybe misspelled?)") meth(msg, requirement.unsafe_name) self.scan_all() def download(self, spec, tmpdir): """Locate and/or download `spec` to `tmpdir`, returning a local path `spec` may be a ``Requirement`` object, or a string containing a URL, an existing local filename, or a project/version requirement spec (i.e. the string form of a ``Requirement`` object). If it is the URL of a .py file with an unambiguous ``#egg=name-version`` tag (i.e., one that escapes ``-`` as ``_`` throughout), a trivial ``setup.py`` is automatically created alongside the downloaded file. If `spec` is a ``Requirement`` object or a string containing a project/version requirement spec, this method returns the location of a matching distribution (possibly after downloading it to `tmpdir`). If `spec` is a locally existing file or directory name, it is simply returned unchanged. If `spec` is a URL, it is downloaded to a subpath of `tmpdir`, and the local filename is returned. Various errors may be raised if a problem occurs during downloading. """ if not isinstance(spec, Requirement): scheme = URL_SCHEME(spec) if scheme: # It's a url, download it to tmpdir found = self._download_url(scheme.group(1), spec, tmpdir) base, fragment = egg_info_for_url(spec) if base.endswith('.py'): found = self.gen_setup(found, fragment, tmpdir) return found elif os.path.exists(spec): # Existing file or directory, just return it return spec else: spec = parse_requirement_arg(spec) return getattr(self.fetch_distribution(spec, tmpdir), 'location', None) def fetch_distribution( # noqa: C901 # is too complex (14) # FIXME self, requirement, tmpdir, force_scan=False, source=False, develop_ok=False, local_index=None): """Obtain a distribution suitable for fulfilling `requirement` `requirement` must be a ``pkg_resources.Requirement`` instance. If necessary, or if the `force_scan` flag is set, the requirement is searched for in the (online) package index as well as the locally installed packages. If a distribution matching `requirement` is found, the returned distribution's ``location`` is the value you would have gotten from calling the ``download()`` method with the matching distribution's URL or filename. If no matching distribution is found, ``None`` is returned. If the `source` flag is set, only source distributions and source checkout links will be considered. Unless the `develop_ok` flag is set, development and system eggs (i.e., those using the ``.egg-info`` format) will be ignored. """ # process a Requirement self.info("Searching for %s", requirement) skipped = {} dist = None def find(req, env=None): if env is None: env = self # Find a matching distribution; may be called more than once for dist in env[req.key]: if dist.precedence == DEVELOP_DIST and not develop_ok: if dist not in skipped: self.warn( "Skipping development or system egg: %s", dist, ) skipped[dist] = 1 continue test = ( dist in req and (dist.precedence <= SOURCE_DIST or not source) ) if test: loc = self.download(dist.location, tmpdir) dist.download_location = loc if os.path.exists(dist.download_location): return dist if force_scan: self.prescan() self.find_packages(requirement) dist = find(requirement) if not dist and local_index is not None: dist = find(requirement, local_index) if dist is None: if self.to_scan is not None: self.prescan() dist = find(requirement) if dist is None and not force_scan: self.find_packages(requirement) dist = find(requirement) if dist is None: self.warn( "No local packages or working download links found for %s%s", (source and "a source distribution of " or ""), requirement, ) else: self.info("Best match: %s", dist) return dist.clone(location=dist.download_location) def fetch(self, requirement, tmpdir, force_scan=False, source=False): """Obtain a file suitable for fulfilling `requirement` DEPRECATED; use the ``fetch_distribution()`` method now instead. For backward compatibility, this routine is identical but returns the ``location`` of the downloaded distribution instead of a distribution object. """ dist = self.fetch_distribution(requirement, tmpdir, force_scan, source) if dist is not None: return dist.location return None def gen_setup(self, filename, fragment, tmpdir): match = EGG_FRAGMENT.match(fragment) dists = match and [ d for d in interpret_distro_name(filename, match.group(1), None) if d.version ] or [] if len(dists) == 1: # unambiguous ``#egg`` fragment basename = os.path.basename(filename) # Make sure the file has been downloaded to the temp dir. if os.path.dirname(filename) != tmpdir: dst = os.path.join(tmpdir, basename) if not (os.path.exists(dst) and os.path.samefile(filename, dst)): shutil.copy2(filename, dst) filename = dst with open(os.path.join(tmpdir, 'setup.py'), 'w') as file: file.write( "from setuptools import setup\n" "setup(name=%r, version=%r, py_modules=[%r])\n" % ( dists[0].project_name, dists[0].version, os.path.splitext(basename)[0] ) ) return filename elif match: raise DistutilsError( "Can't unambiguously interpret project/version identifier %r; " "any dashes in the name or version should be escaped using " "underscores. %r" % (fragment, dists) ) else: raise DistutilsError( "Can't process plain .py files without an '#egg=name-version'" " suffix to enable automatic setup script generation." ) dl_blocksize = 8192 def _download_to(self, url, filename): self.info("Downloading %s", url) # Download the file fp = None try: checker = HashChecker.from_url(url) fp = self.open_url(url) if isinstance(fp, urllib.error.HTTPError): raise DistutilsError( "Can't download %s: %s %s" % (url, fp.code, fp.msg) ) headers = fp.info() blocknum = 0 bs = self.dl_blocksize size = -1 if "content-length" in headers: # Some servers return multiple Content-Length headers :( sizes = headers.get_all('Content-Length') size = max(map(int, sizes)) self.reporthook(url, filename, blocknum, bs, size) with open(filename, 'wb') as tfp: while True: block = fp.read(bs) if block: checker.feed(block) tfp.write(block) blocknum += 1 self.reporthook(url, filename, blocknum, bs, size) else: break self.check_hash(checker, filename, tfp) return headers finally: if fp: fp.close() def reporthook(self, url, filename, blocknum, blksize, size): pass # no-op # FIXME: def open_url(self, url, warning=None): # noqa: C901 # is too complex (12) if url.startswith('file:'): return local_open(url) try: return open_with_auth(url, self.opener) except (ValueError, http.client.InvalidURL) as v: msg = ' '.join([str(arg) for arg in v.args]) if warning: self.warn(warning, msg) else: raise DistutilsError('%s %s' % (url, msg)) from v except urllib.error.HTTPError as v: return v except urllib.error.URLError as v: if warning: self.warn(warning, v.reason) else: raise DistutilsError("Download error for %s: %s" % (url, v.reason)) from v except http.client.BadStatusLine as v: if warning: self.warn(warning, v.line) else: raise DistutilsError( '%s returned a bad status line. The server might be ' 'down, %s' % (url, v.line) ) from v except (http.client.HTTPException, socket.error) as v: if warning: self.warn(warning, v) else: raise DistutilsError("Download error for %s: %s" % (url, v)) from v def _download_url(self, scheme, url, tmpdir): # Determine download filename # name, fragment = egg_info_for_url(url) if name: while '..' in name: name = name.replace('..', '.').replace('\\', '_') else: name = "__downloaded__" # default if URL has no path contents if name.endswith('.egg.zip'): name = name[:-4] # strip the extra .zip before download filename = os.path.join(tmpdir, name) # Download the file # if scheme == 'svn' or scheme.startswith('svn+'): return self._download_svn(url, filename) elif scheme == 'git' or scheme.startswith('git+'): return self._download_git(url, filename) elif scheme.startswith('hg+'): return self._download_hg(url, filename) elif scheme == 'file': return urllib.request.url2pathname(urllib.parse.urlparse(url)[2]) else: self.url_ok(url, True) # raises error if not allowed return self._attempt_download(url, filename) def scan_url(self, url): self.process_url(url, True) def _attempt_download(self, url, filename): headers = self._download_to(url, filename) if 'html' in headers.get('content-type', '').lower(): return self._download_html(url, headers, filename) else: return filename def _download_html(self, url, headers, filename): file = open(filename) for line in file: if line.strip(): # Check for a subversion index page if re.search(r'<title>([^- ]+ - )?Revision \d+:', line): # it's a subversion index page: file.close() os.unlink(filename) return self._download_svn(url, filename) break # not an index page file.close() os.unlink(filename) raise DistutilsError("Unexpected HTML page found at " + url) def _download_svn(self, url, filename): warnings.warn("SVN download support is deprecated", UserWarning) url = url.split('#', 1)[0] # remove any fragment for svn's sake creds = '' if url.lower().startswith('svn:') and '@' in url: scheme, netloc, path, p, q, f = urllib.parse.urlparse(url) if not netloc and path.startswith('//') and '/' in path[2:]: netloc, path = path[2:].split('/', 1) auth, host = _splituser(netloc) if auth: if ':' in auth: user, pw = auth.split(':', 1) creds = " --username=%s --password=%s" % (user, pw) else: creds = " --username=" + auth netloc = host parts = scheme, netloc, url, p, q, f url = urllib.parse.urlunparse(parts) self.info("Doing subversion checkout from %s to %s", url, filename) os.system("svn checkout%s -q %s %s" % (creds, url, filename)) return filename @staticmethod def _vcs_split_rev_from_url(url, pop_prefix=False): scheme, netloc, path, query, frag = urllib.parse.urlsplit(url) scheme = scheme.split('+', 1)[-1] # Some fragment identification fails path = path.split('#', 1)[0] rev = None if '@' in path: path, rev = path.rsplit('@', 1) # Also, discard fragment url = urllib.parse.urlunsplit((scheme, netloc, path, query, '')) return url, rev def _download_git(self, url, filename): filename = filename.split('#', 1)[0] url, rev = self._vcs_split_rev_from_url(url, pop_prefix=True) self.info("Doing git clone from %s to %s", url, filename) os.system("git clone --quiet %s %s" % (url, filename)) if rev is not None: self.info("Checking out %s", rev) os.system("git -C %s checkout --quiet %s" % ( filename, rev, )) return filename def _download_hg(self, url, filename): filename = filename.split('#', 1)[0] url, rev = self._vcs_split_rev_from_url(url, pop_prefix=True) self.info("Doing hg clone from %s to %s", url, filename) os.system("hg clone --quiet %s %s" % (url, filename)) if rev is not None: self.info("Updating to %s", rev) os.system("hg --cwd %s up -C -r %s -q" % ( filename, rev, )) return filename def debug(self, msg, *args): log.debug(msg, *args) def info(self, msg, *args): log.info(msg, *args) def warn(self, msg, *args): log.warn(msg, *args) # This pattern matches a character entity reference (a decimal numeric # references, a hexadecimal numeric reference, or a named reference). entity_sub = re.compile(r'&(#(\d+|x[\da-fA-F]+)|[\w.:-]+);?').sub def decode_entity(match): what = match.group(0) return html.unescape(what) def htmldecode(text): """ Decode HTML entities in the given text. >>> htmldecode( ... 'https://../package_name-0.1.2.tar.gz' ... '?tokena=A&amp;tokenb=B">package_name-0.1.2.tar.gz') 'https://../package_name-0.1.2.tar.gz?tokena=A&tokenb=B">package_name-0.1.2.tar.gz' """ return entity_sub(decode_entity, text) def socket_timeout(timeout=15): def _socket_timeout(func): def _socket_timeout(*args, **kwargs): old_timeout = socket.getdefaulttimeout() socket.setdefaulttimeout(timeout) try: return func(*args, **kwargs) finally: socket.setdefaulttimeout(old_timeout) return _socket_timeout return _socket_timeout def _encode_auth(auth): """ Encode auth from a URL suitable for an HTTP header. >>> str(_encode_auth('username%3Apassword')) 'dXNlcm5hbWU6cGFzc3dvcmQ=' Long auth strings should not cause a newline to be inserted. >>> long_auth = 'username:' + 'password'*10 >>> chr(10) in str(_encode_auth(long_auth)) False """ auth_s = urllib.parse.unquote(auth) # convert to bytes auth_bytes = auth_s.encode() encoded_bytes = base64.b64encode(auth_bytes) # convert back to a string encoded = encoded_bytes.decode() # strip the trailing carriage return return encoded.replace('\n', '') class Credential: """ A username/password pair. Use like a namedtuple. """ def __init__(self, username, password): self.username = username self.password = password def __iter__(self): yield self.username yield self.password def __str__(self): return '%(username)s:%(password)s' % vars(self) class PyPIConfig(configparser.RawConfigParser): def __init__(self): """ Load from ~/.pypirc """ defaults = dict.fromkeys(['username', 'password', 'repository'], '') super().__init__(defaults) rc = os.path.join(os.path.expanduser('~'), '.pypirc') if os.path.exists(rc): self.read(rc) @property def creds_by_repository(self): sections_with_repositories = [ section for section in self.sections() if self.get(section, 'repository').strip() ] return dict(map(self._get_repo_cred, sections_with_repositories)) def _get_repo_cred(self, section): repo = self.get(section, 'repository').strip() return repo, Credential( self.get(section, 'username').strip(), self.get(section, 'password').strip(), ) def find_credential(self, url): """ If the URL indicated appears to be a repository defined in this config, return the credential for that repository. """ for repository, cred in self.creds_by_repository.items(): if url.startswith(repository): return cred def open_with_auth(url, opener=urllib.request.urlopen): """Open a urllib2 request, handling HTTP authentication""" parsed = urllib.parse.urlparse(url) scheme, netloc, path, params, query, frag = parsed # Double scheme does not raise on macOS as revealed by a # failing test. We would expect "nonnumeric port". Refs #20. if netloc.endswith(':'): raise http.client.InvalidURL("nonnumeric port: ''") if scheme in ('http', 'https'): auth, address = _splituser(netloc) else: auth = None if not auth: cred = PyPIConfig().find_credential(url) if cred: auth = str(cred) info = cred.username, url log.info('Authenticating as %s for %s (from .pypirc)', *info) if auth: auth = "Basic " + _encode_auth(auth) parts = scheme, address, path, params, query, frag new_url = urllib.parse.urlunparse(parts) request = urllib.request.Request(new_url) request.add_header("Authorization", auth) else: request = urllib.request.Request(url) request.add_header('User-Agent', user_agent) fp = opener(request) if auth: # Put authentication info back into request URL if same host, # so that links found on the page will work s2, h2, path2, param2, query2, frag2 = urllib.parse.urlparse(fp.url) if s2 == scheme and h2 == address: parts = s2, netloc, path2, param2, query2, frag2 fp.url = urllib.parse.urlunparse(parts) return fp # copy of urllib.parse._splituser from Python 3.8 def _splituser(host): """splituser('user[:passwd]@host[:port]') --> 'user[:passwd]', 'host[:port]'.""" user, delim, host = host.rpartition('@') return (user if delim else None), host # adding a timeout to avoid freezing package_index open_with_auth = socket_timeout(_SOCKET_TIMEOUT)(open_with_auth) def fix_sf_url(url): return url # backward compatibility def local_open(url): """Read a local path, with special support for directories""" scheme, server, path, param, query, frag = urllib.parse.urlparse(url) filename = urllib.request.url2pathname(path) if os.path.isfile(filename): return urllib.request.urlopen(url) elif path.endswith('/') and os.path.isdir(filename): files = [] for f in os.listdir(filename): filepath = os.path.join(filename, f) if f == 'index.html': with open(filepath, 'r') as fp: body = fp.read() break elif os.path.isdir(filepath): f += '/' files.append('<a href="{name}">{name}</a>'.format(name=f)) else: tmpl = ( "<html><head><title>{url}</title>" "</head><body>{files}</body></html>") body = tmpl.format(url=url, files='\n'.join(files)) status, message = 200, "OK" else: status, message, body = 404, "Path not found", "Not found" headers = {'content-type': 'text/html'} body_stream = io.StringIO(body) return urllib.error.HTTPError(url, status, message, headers, body_stream)
castiel248/Convert
Lib/site-packages/setuptools/package_index.py
Python
mit
40,020
import importlib try: import importlib.util except ImportError: pass try: module_from_spec = importlib.util.module_from_spec except AttributeError: def module_from_spec(spec): return spec.loader.load_module(spec.name)
castiel248/Convert
Lib/site-packages/setuptools/py34compat.py
Python
mit
245
import os import sys import tempfile import operator import functools import itertools import re import contextlib import pickle import textwrap import builtins import pkg_resources from distutils.errors import DistutilsError from pkg_resources import working_set if sys.platform.startswith('java'): import org.python.modules.posix.PosixModule as _os else: _os = sys.modules[os.name] try: _file = file except NameError: _file = None _open = open __all__ = [ "AbstractSandbox", "DirectorySandbox", "SandboxViolation", "run_setup", ] def _execfile(filename, globals, locals=None): """ Python 3 implementation of execfile. """ mode = 'rb' with open(filename, mode) as stream: script = stream.read() if locals is None: locals = globals code = compile(script, filename, 'exec') exec(code, globals, locals) @contextlib.contextmanager def save_argv(repl=None): saved = sys.argv[:] if repl is not None: sys.argv[:] = repl try: yield saved finally: sys.argv[:] = saved @contextlib.contextmanager def save_path(): saved = sys.path[:] try: yield saved finally: sys.path[:] = saved @contextlib.contextmanager def override_temp(replacement): """ Monkey-patch tempfile.tempdir with replacement, ensuring it exists """ os.makedirs(replacement, exist_ok=True) saved = tempfile.tempdir tempfile.tempdir = replacement try: yield finally: tempfile.tempdir = saved @contextlib.contextmanager def pushd(target): saved = os.getcwd() os.chdir(target) try: yield saved finally: os.chdir(saved) class UnpickleableException(Exception): """ An exception representing another Exception that could not be pickled. """ @staticmethod def dump(type, exc): """ Always return a dumped (pickled) type and exc. If exc can't be pickled, wrap it in UnpickleableException first. """ try: return pickle.dumps(type), pickle.dumps(exc) except Exception: # get UnpickleableException inside the sandbox from setuptools.sandbox import UnpickleableException as cls return cls.dump(cls, cls(repr(exc))) class ExceptionSaver: """ A Context Manager that will save an exception, serialized, and restore it later. """ def __enter__(self): return self def __exit__(self, type, exc, tb): if not exc: return # dump the exception self._saved = UnpickleableException.dump(type, exc) self._tb = tb # suppress the exception return True def resume(self): "restore and re-raise any exception" if '_saved' not in vars(self): return type, exc = map(pickle.loads, self._saved) raise exc.with_traceback(self._tb) @contextlib.contextmanager def save_modules(): """ Context in which imported modules are saved. Translates exceptions internal to the context into the equivalent exception outside the context. """ saved = sys.modules.copy() with ExceptionSaver() as saved_exc: yield saved sys.modules.update(saved) # remove any modules imported since del_modules = ( mod_name for mod_name in sys.modules if mod_name not in saved # exclude any encodings modules. See #285 and not mod_name.startswith('encodings.') ) _clear_modules(del_modules) saved_exc.resume() def _clear_modules(module_names): for mod_name in list(module_names): del sys.modules[mod_name] @contextlib.contextmanager def save_pkg_resources_state(): saved = pkg_resources.__getstate__() try: yield saved finally: pkg_resources.__setstate__(saved) @contextlib.contextmanager def setup_context(setup_dir): temp_dir = os.path.join(setup_dir, 'temp') with save_pkg_resources_state(): with save_modules(): with save_path(): hide_setuptools() with save_argv(): with override_temp(temp_dir): with pushd(setup_dir): # ensure setuptools commands are available __import__('setuptools') yield _MODULES_TO_HIDE = { 'setuptools', 'distutils', 'pkg_resources', 'Cython', '_distutils_hack', } def _needs_hiding(mod_name): """ >>> _needs_hiding('setuptools') True >>> _needs_hiding('pkg_resources') True >>> _needs_hiding('setuptools_plugin') False >>> _needs_hiding('setuptools.__init__') True >>> _needs_hiding('distutils') True >>> _needs_hiding('os') False >>> _needs_hiding('Cython') True """ base_module = mod_name.split('.', 1)[0] return base_module in _MODULES_TO_HIDE def hide_setuptools(): """ Remove references to setuptools' modules from sys.modules to allow the invocation to import the most appropriate setuptools. This technique is necessary to avoid issues such as #315 where setuptools upgrading itself would fail to find a function declared in the metadata. """ _distutils_hack = sys.modules.get('_distutils_hack', None) if _distutils_hack is not None: _distutils_hack.remove_shim() modules = filter(_needs_hiding, sys.modules) _clear_modules(modules) def run_setup(setup_script, args): """Run a distutils setup script, sandboxed in its directory""" setup_dir = os.path.abspath(os.path.dirname(setup_script)) with setup_context(setup_dir): try: sys.argv[:] = [setup_script] + list(args) sys.path.insert(0, setup_dir) # reset to include setup dir, w/clean callback list working_set.__init__() working_set.callbacks.append(lambda dist: dist.activate()) with DirectorySandbox(setup_dir): ns = dict(__file__=setup_script, __name__='__main__') _execfile(setup_script, ns) except SystemExit as v: if v.args and v.args[0]: raise # Normal exit, just return class AbstractSandbox: """Wrap 'os' module and 'open()' builtin for virtualizing setup scripts""" _active = False def __init__(self): self._attrs = [ name for name in dir(_os) if not name.startswith('_') and hasattr(self, name) ] def _copy(self, source): for name in self._attrs: setattr(os, name, getattr(source, name)) def __enter__(self): self._copy(self) if _file: builtins.file = self._file builtins.open = self._open self._active = True def __exit__(self, exc_type, exc_value, traceback): self._active = False if _file: builtins.file = _file builtins.open = _open self._copy(_os) def run(self, func): """Run 'func' under os sandboxing""" with self: return func() def _mk_dual_path_wrapper(name): original = getattr(_os, name) def wrap(self, src, dst, *args, **kw): if self._active: src, dst = self._remap_pair(name, src, dst, *args, **kw) return original(src, dst, *args, **kw) return wrap for name in ["rename", "link", "symlink"]: if hasattr(_os, name): locals()[name] = _mk_dual_path_wrapper(name) def _mk_single_path_wrapper(name, original=None): original = original or getattr(_os, name) def wrap(self, path, *args, **kw): if self._active: path = self._remap_input(name, path, *args, **kw) return original(path, *args, **kw) return wrap if _file: _file = _mk_single_path_wrapper('file', _file) _open = _mk_single_path_wrapper('open', _open) for name in [ "stat", "listdir", "chdir", "open", "chmod", "chown", "mkdir", "remove", "unlink", "rmdir", "utime", "lchown", "chroot", "lstat", "startfile", "mkfifo", "mknod", "pathconf", "access", ]: if hasattr(_os, name): locals()[name] = _mk_single_path_wrapper(name) def _mk_single_with_return(name): original = getattr(_os, name) def wrap(self, path, *args, **kw): if self._active: path = self._remap_input(name, path, *args, **kw) return self._remap_output(name, original(path, *args, **kw)) return original(path, *args, **kw) return wrap for name in ['readlink', 'tempnam']: if hasattr(_os, name): locals()[name] = _mk_single_with_return(name) def _mk_query(name): original = getattr(_os, name) def wrap(self, *args, **kw): retval = original(*args, **kw) if self._active: return self._remap_output(name, retval) return retval return wrap for name in ['getcwd', 'tmpnam']: if hasattr(_os, name): locals()[name] = _mk_query(name) def _validate_path(self, path): """Called to remap or validate any path, whether input or output""" return path def _remap_input(self, operation, path, *args, **kw): """Called for path inputs""" return self._validate_path(path) def _remap_output(self, operation, path): """Called for path outputs""" return self._validate_path(path) def _remap_pair(self, operation, src, dst, *args, **kw): """Called for path pairs like rename, link, and symlink operations""" return ( self._remap_input(operation + '-from', src, *args, **kw), self._remap_input(operation + '-to', dst, *args, **kw), ) if hasattr(os, 'devnull'): _EXCEPTIONS = [os.devnull] else: _EXCEPTIONS = [] class DirectorySandbox(AbstractSandbox): """Restrict operations to a single subdirectory - pseudo-chroot""" write_ops = dict.fromkeys( [ "open", "chmod", "chown", "mkdir", "remove", "unlink", "rmdir", "utime", "lchown", "chroot", "mkfifo", "mknod", "tempnam", ] ) _exception_patterns = [] "exempt writing to paths that match the pattern" def __init__(self, sandbox, exceptions=_EXCEPTIONS): self._sandbox = os.path.normcase(os.path.realpath(sandbox)) self._prefix = os.path.join(self._sandbox, '') self._exceptions = [ os.path.normcase(os.path.realpath(path)) for path in exceptions ] AbstractSandbox.__init__(self) def _violation(self, operation, *args, **kw): from setuptools.sandbox import SandboxViolation raise SandboxViolation(operation, args, kw) if _file: def _file(self, path, mode='r', *args, **kw): if mode not in ('r', 'rt', 'rb', 'rU', 'U') and not self._ok(path): self._violation("file", path, mode, *args, **kw) return _file(path, mode, *args, **kw) def _open(self, path, mode='r', *args, **kw): if mode not in ('r', 'rt', 'rb', 'rU', 'U') and not self._ok(path): self._violation("open", path, mode, *args, **kw) return _open(path, mode, *args, **kw) def tmpnam(self): self._violation("tmpnam") def _ok(self, path): active = self._active try: self._active = False realpath = os.path.normcase(os.path.realpath(path)) return ( self._exempted(realpath) or realpath == self._sandbox or realpath.startswith(self._prefix) ) finally: self._active = active def _exempted(self, filepath): start_matches = ( filepath.startswith(exception) for exception in self._exceptions ) pattern_matches = ( re.match(pattern, filepath) for pattern in self._exception_patterns ) candidates = itertools.chain(start_matches, pattern_matches) return any(candidates) def _remap_input(self, operation, path, *args, **kw): """Called for path inputs""" if operation in self.write_ops and not self._ok(path): self._violation(operation, os.path.realpath(path), *args, **kw) return path def _remap_pair(self, operation, src, dst, *args, **kw): """Called for path pairs like rename, link, and symlink operations""" if not self._ok(src) or not self._ok(dst): self._violation(operation, src, dst, *args, **kw) return (src, dst) def open(self, file, flags, mode=0o777, *args, **kw): """Called for low-level os.open()""" if flags & WRITE_FLAGS and not self._ok(file): self._violation("os.open", file, flags, mode, *args, **kw) return _os.open(file, flags, mode, *args, **kw) WRITE_FLAGS = functools.reduce( operator.or_, [ getattr(_os, a, 0) for a in "O_WRONLY O_RDWR O_APPEND O_CREAT O_TRUNC O_TEMPORARY".split() ], ) class SandboxViolation(DistutilsError): """A setup script attempted to modify the filesystem outside the sandbox""" tmpl = textwrap.dedent( """ SandboxViolation: {cmd}{args!r} {kwargs} The package setup script has attempted to modify files on your system that are not within the EasyInstall build area, and has been aborted. This package cannot be safely installed by EasyInstall, and may not support alternate installation locations even if you run its setup script by hand. Please inform the package's author and the EasyInstall maintainers to find out if a fix or workaround is available. """ ).lstrip() def __str__(self): cmd, args, kwargs = self.args return self.tmpl.format(**locals())
castiel248/Convert
Lib/site-packages/setuptools/sandbox.py
Python
mit
14,348
# EASY-INSTALL-DEV-SCRIPT: %(spec)r,%(script_name)r __requires__ = %(spec)r __import__('pkg_resources').require(%(spec)r) __file__ = %(dev_path)r with open(__file__) as f: exec(compile(f.read(), __file__, 'exec'))
castiel248/Convert
Lib/site-packages/setuptools/script (dev).tmpl
tmpl
mit
218
# EASY-INSTALL-SCRIPT: %(spec)r,%(script_name)r __requires__ = %(spec)r __import__('pkg_resources').run_script(%(spec)r, %(script_name)r)
castiel248/Convert
Lib/site-packages/setuptools/script.tmpl
tmpl
mit
138
import unicodedata import sys # HFS Plus uses decomposed UTF-8 def decompose(path): if isinstance(path, str): return unicodedata.normalize('NFD', path) try: path = path.decode('utf-8') path = unicodedata.normalize('NFD', path) path = path.encode('utf-8') except UnicodeError: pass # Not UTF-8 return path def filesys_decode(path): """ Ensure that the given path is decoded, NONE when no expected encoding works """ if isinstance(path, str): return path fs_enc = sys.getfilesystemencoding() or 'utf-8' candidates = fs_enc, 'utf-8' for enc in candidates: try: return path.decode(enc) except UnicodeDecodeError: continue def try_encode(string, enc): "turn unicode encoding into a functional routine" try: return string.encode(enc) except UnicodeEncodeError: return None
castiel248/Convert
Lib/site-packages/setuptools/unicode_utils.py
Python
mit
941
import pkg_resources try: __version__ = pkg_resources.get_distribution('setuptools').version except Exception: __version__ = 'unknown'
castiel248/Convert
Lib/site-packages/setuptools/version.py
Python
mit
144
"""Wheels support.""" import email import itertools import os import posixpath import re import zipfile import contextlib from distutils.util import get_platform import pkg_resources import setuptools from pkg_resources import parse_version from setuptools.extern.packaging.tags import sys_tags from setuptools.extern.packaging.utils import canonicalize_name from setuptools.command.egg_info import write_requirements from setuptools.archive_util import _unpack_zipfile_obj WHEEL_NAME = re.compile( r"""^(?P<project_name>.+?)-(?P<version>\d.*?) ((-(?P<build>\d.*?))?-(?P<py_version>.+?)-(?P<abi>.+?)-(?P<platform>.+?) )\.whl$""", re.VERBOSE).match NAMESPACE_PACKAGE_INIT = \ "__import__('pkg_resources').declare_namespace(__name__)\n" def unpack(src_dir, dst_dir): '''Move everything under `src_dir` to `dst_dir`, and delete the former.''' for dirpath, dirnames, filenames in os.walk(src_dir): subdir = os.path.relpath(dirpath, src_dir) for f in filenames: src = os.path.join(dirpath, f) dst = os.path.join(dst_dir, subdir, f) os.renames(src, dst) for n, d in reversed(list(enumerate(dirnames))): src = os.path.join(dirpath, d) dst = os.path.join(dst_dir, subdir, d) if not os.path.exists(dst): # Directory does not exist in destination, # rename it and prune it from os.walk list. os.renames(src, dst) del dirnames[n] # Cleanup. for dirpath, dirnames, filenames in os.walk(src_dir, topdown=True): assert not filenames os.rmdir(dirpath) @contextlib.contextmanager def disable_info_traces(): """ Temporarily disable info traces. """ from distutils import log saved = log.set_threshold(log.WARN) try: yield finally: log.set_threshold(saved) class Wheel: def __init__(self, filename): match = WHEEL_NAME(os.path.basename(filename)) if match is None: raise ValueError('invalid wheel name: %r' % filename) self.filename = filename for k, v in match.groupdict().items(): setattr(self, k, v) def tags(self): '''List tags (py_version, abi, platform) supported by this wheel.''' return itertools.product( self.py_version.split('.'), self.abi.split('.'), self.platform.split('.'), ) def is_compatible(self): '''Is the wheel is compatible with the current platform?''' supported_tags = set( (t.interpreter, t.abi, t.platform) for t in sys_tags()) return next((True for t in self.tags() if t in supported_tags), False) def egg_name(self): return pkg_resources.Distribution( project_name=self.project_name, version=self.version, platform=(None if self.platform == 'any' else get_platform()), ).egg_name() + '.egg' def get_dist_info(self, zf): # find the correct name of the .dist-info dir in the wheel file for member in zf.namelist(): dirname = posixpath.dirname(member) if (dirname.endswith('.dist-info') and canonicalize_name(dirname).startswith( canonicalize_name(self.project_name))): return dirname raise ValueError("unsupported wheel format. .dist-info not found") def install_as_egg(self, destination_eggdir): '''Install wheel as an egg directory.''' with zipfile.ZipFile(self.filename) as zf: self._install_as_egg(destination_eggdir, zf) def _install_as_egg(self, destination_eggdir, zf): dist_basename = '%s-%s' % (self.project_name, self.version) dist_info = self.get_dist_info(zf) dist_data = '%s.data' % dist_basename egg_info = os.path.join(destination_eggdir, 'EGG-INFO') self._convert_metadata(zf, destination_eggdir, dist_info, egg_info) self._move_data_entries(destination_eggdir, dist_data) self._fix_namespace_packages(egg_info, destination_eggdir) @staticmethod def _convert_metadata(zf, destination_eggdir, dist_info, egg_info): def get_metadata(name): with zf.open(posixpath.join(dist_info, name)) as fp: value = fp.read().decode('utf-8') return email.parser.Parser().parsestr(value) wheel_metadata = get_metadata('WHEEL') # Check wheel format version is supported. wheel_version = parse_version(wheel_metadata.get('Wheel-Version')) wheel_v1 = ( parse_version('1.0') <= wheel_version < parse_version('2.0dev0') ) if not wheel_v1: raise ValueError( 'unsupported wheel format version: %s' % wheel_version) # Extract to target directory. _unpack_zipfile_obj(zf, destination_eggdir) # Convert metadata. dist_info = os.path.join(destination_eggdir, dist_info) dist = pkg_resources.Distribution.from_location( destination_eggdir, dist_info, metadata=pkg_resources.PathMetadata(destination_eggdir, dist_info), ) # Note: Evaluate and strip markers now, # as it's difficult to convert back from the syntax: # foobar; "linux" in sys_platform and extra == 'test' def raw_req(req): req.marker = None return str(req) install_requires = list(map(raw_req, dist.requires())) extras_require = { extra: [ req for req in map(raw_req, dist.requires((extra,))) if req not in install_requires ] for extra in dist.extras } os.rename(dist_info, egg_info) os.rename( os.path.join(egg_info, 'METADATA'), os.path.join(egg_info, 'PKG-INFO'), ) setup_dist = setuptools.Distribution( attrs=dict( install_requires=install_requires, extras_require=extras_require, ), ) with disable_info_traces(): write_requirements( setup_dist.get_command_obj('egg_info'), None, os.path.join(egg_info, 'requires.txt'), ) @staticmethod def _move_data_entries(destination_eggdir, dist_data): """Move data entries to their correct location.""" dist_data = os.path.join(destination_eggdir, dist_data) dist_data_scripts = os.path.join(dist_data, 'scripts') if os.path.exists(dist_data_scripts): egg_info_scripts = os.path.join( destination_eggdir, 'EGG-INFO', 'scripts') os.mkdir(egg_info_scripts) for entry in os.listdir(dist_data_scripts): # Remove bytecode, as it's not properly handled # during easy_install scripts install phase. if entry.endswith('.pyc'): os.unlink(os.path.join(dist_data_scripts, entry)) else: os.rename( os.path.join(dist_data_scripts, entry), os.path.join(egg_info_scripts, entry), ) os.rmdir(dist_data_scripts) for subdir in filter(os.path.exists, ( os.path.join(dist_data, d) for d in ('data', 'headers', 'purelib', 'platlib') )): unpack(subdir, destination_eggdir) if os.path.exists(dist_data): os.rmdir(dist_data) @staticmethod def _fix_namespace_packages(egg_info, destination_eggdir): namespace_packages = os.path.join( egg_info, 'namespace_packages.txt') if os.path.exists(namespace_packages): with open(namespace_packages) as fp: namespace_packages = fp.read().split() for mod in namespace_packages: mod_dir = os.path.join(destination_eggdir, *mod.split('.')) mod_init = os.path.join(mod_dir, '__init__.py') if not os.path.exists(mod_dir): os.mkdir(mod_dir) if not os.path.exists(mod_init): with open(mod_init, 'w') as fp: fp.write(NAMESPACE_PACKAGE_INIT)
castiel248/Convert
Lib/site-packages/setuptools/wheel.py
Python
mit
8,376
import platform def windows_only(func): if platform.system() != 'Windows': return lambda *args, **kwargs: None return func @windows_only def hide_file(path): """ Set the hidden attribute on a file or directory. From http://stackoverflow.com/questions/19622133/ `path` must be text. """ import ctypes __import__('ctypes.wintypes') SetFileAttributes = ctypes.windll.kernel32.SetFileAttributesW SetFileAttributes.argtypes = ctypes.wintypes.LPWSTR, ctypes.wintypes.DWORD SetFileAttributes.restype = ctypes.wintypes.BOOL FILE_ATTRIBUTE_HIDDEN = 0x02 ret = SetFileAttributes(path, FILE_ATTRIBUTE_HIDDEN) if not ret: raise ctypes.WinError()
castiel248/Convert
Lib/site-packages/setuptools/windows_support.py
Python
mit
718
pip
castiel248/Convert
Lib/site-packages/sqlparse-0.4.4.dist-info/INSTALLER
none
mit
4
Metadata-Version: 2.1 Name: sqlparse Version: 0.4.4 Summary: A non-validating SQL parser. Author-email: Andi Albrecht <albrecht.andi@gmail.com> Requires-Python: >=3.5 Description-Content-Type: text/x-rst Classifier: Development Status :: 5 - Production/Stable Classifier: Intended Audience :: Developers Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python Classifier: Programming Language :: Python :: 3 Classifier: Programming Language :: Python :: 3 :: Only Classifier: Programming Language :: Python :: 3.5 Classifier: Programming Language :: Python :: 3.6 Classifier: Programming Language :: Python :: 3.7 Classifier: Programming Language :: Python :: 3.8 Classifier: Programming Language :: Python :: 3.9 Classifier: Programming Language :: Python :: 3.10 Classifier: Programming Language :: Python :: Implementation :: CPython Classifier: Programming Language :: Python :: Implementation :: PyPy Classifier: Topic :: Database Classifier: Topic :: Software Development Requires-Dist: flake8 ; extra == "dev" Requires-Dist: build ; extra == "dev" Requires-Dist: sphinx ; extra == "doc" Requires-Dist: pytest ; extra == "test" Requires-Dist: pytest-cov ; extra == "test" Project-URL: Documentation, https://sqlparse.readthedocs.io/ Project-URL: Home, https://github.com/andialbrecht/sqlparse Project-URL: Release Notes, https://sqlparse.readthedocs.io/en/latest/changes/ Project-URL: Source, https://github.com/andialbrecht/sqlparse Project-URL: Tracker, https://github.com/andialbrecht/sqlparse/issues Provides-Extra: dev Provides-Extra: doc Provides-Extra: test python-sqlparse - Parse SQL statements ====================================== |buildstatus|_ |coverage|_ |docs|_ |packageversion|_ .. docincludebegin sqlparse is a non-validating SQL parser for Python. It provides support for parsing, splitting and formatting SQL statements. The module is compatible with Python 3.5+ and released under the terms of the `New BSD license <https://opensource.org/licenses/BSD-3-Clause>`_. Visit the project page at https://github.com/andialbrecht/sqlparse for further information about this project. Quick Start ----------- .. code-block:: sh $ pip install sqlparse .. code-block:: python >>> import sqlparse >>> # Split a string containing two SQL statements: >>> raw = 'select * from foo; select * from bar;' >>> statements = sqlparse.split(raw) >>> statements ['select * from foo;', 'select * from bar;'] >>> # Format the first statement and print it out: >>> first = statements[0] >>> print(sqlparse.format(first, reindent=True, keyword_case='upper')) SELECT * FROM foo; >>> # Parsing a SQL statement: >>> parsed = sqlparse.parse('select * from foo')[0] >>> parsed.tokens [<DML 'select' at 0x7f22c5e15368>, <Whitespace ' ' at 0x7f22c5e153b0>, <Wildcard '*' … ] >>> Links ----- Project page https://github.com/andialbrecht/sqlparse Bug tracker https://github.com/andialbrecht/sqlparse/issues Documentation https://sqlparse.readthedocs.io/ Online Demo https://sqlformat.org/ sqlparse is licensed under the BSD license. Parts of the code are based on pygments written by Georg Brandl and others. pygments-Homepage: http://pygments.org/ .. |buildstatus| image:: https://github.com/andialbrecht/sqlparse/actions/workflows/python-app.yml/badge.svg .. _buildstatus: https://github.com/andialbrecht/sqlparse/actions/workflows/python-app.yml .. |coverage| image:: https://codecov.io/gh/andialbrecht/sqlparse/branch/master/graph/badge.svg .. _coverage: https://codecov.io/gh/andialbrecht/sqlparse .. |docs| image:: https://readthedocs.org/projects/sqlparse/badge/?version=latest .. _docs: https://sqlparse.readthedocs.io/en/latest/?badge=latest .. |packageversion| image:: https://img.shields.io/pypi/v/sqlparse?color=%2334D058&label=pypi%20package .. _packageversion: https://pypi.org/project/sqlparse
castiel248/Convert
Lib/site-packages/sqlparse-0.4.4.dist-info/METADATA
none
mit
3,975
../../Scripts/sqlformat.exe,sha256=4Ai8C2c6eJK-Z107wc4n1ADc0MIbfF-LE0bAKykWc1g,108436 sqlparse-0.4.4.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 sqlparse-0.4.4.dist-info/LICENSE,sha256=wZOCNbgNOekxOOrontw69n4Y7LxA0mZSn6V7Lc5CYxA,1537 sqlparse-0.4.4.dist-info/METADATA,sha256=3ddYXNmq5A2vauTq6QBwIcXiGFfFdHt19lZ0AhMgIHw,3975 sqlparse-0.4.4.dist-info/RECORD,, sqlparse-0.4.4.dist-info/WHEEL,sha256=rSgq_JpHF9fHR1lx53qwg_1-2LypZE_qmcuXbVUq948,81 sqlparse-0.4.4.dist-info/entry_points.txt,sha256=52MfRiHGE-AZj8HdMu4Z5erM9wEgUbFfzzYETOicUA0,52 sqlparse/__init__.py,sha256=DIbMPyqkC8hKdtNU6aX_FG5ScYNzX4F2Z-NggFN5jBk,2180 sqlparse/__main__.py,sha256=1jhVFLHlZs4NUJoAuHvQQKWgykPVTdgeE8V4XB5WQzw,610 sqlparse/__pycache__/__init__.cpython-311.pyc,, sqlparse/__pycache__/__main__.cpython-311.pyc,, sqlparse/__pycache__/cli.cpython-311.pyc,, sqlparse/__pycache__/exceptions.cpython-311.pyc,, sqlparse/__pycache__/formatter.cpython-311.pyc,, sqlparse/__pycache__/keywords.cpython-311.pyc,, sqlparse/__pycache__/lexer.cpython-311.pyc,, sqlparse/__pycache__/sql.cpython-311.pyc,, sqlparse/__pycache__/tokens.cpython-311.pyc,, sqlparse/__pycache__/utils.cpython-311.pyc,, sqlparse/cli.py,sha256=83gHgW0mTQXJbv-ItpAEZaq7-2lvWij0mg2cVmG67KA,5712 sqlparse/engine/__init__.py,sha256=i9kh0USMjk1bwKPFTn6K0PKC55HOqvnkoxHi1t7YccE,447 sqlparse/engine/__pycache__/__init__.cpython-311.pyc,, sqlparse/engine/__pycache__/filter_stack.cpython-311.pyc,, sqlparse/engine/__pycache__/grouping.cpython-311.pyc,, sqlparse/engine/__pycache__/statement_splitter.cpython-311.pyc,, sqlparse/engine/filter_stack.py,sha256=cId9vnz0Kpthg3ljdnX2Id6-vz0zpKHoMV_FqEYEsYU,1193 sqlparse/engine/grouping.py,sha256=3FCwNix0loFk2NYXHUM2Puqr-0aEDLLquV5Tydglhg0,13826 sqlparse/engine/statement_splitter.py,sha256=-injFkTCUKQth2I3K1PguFkEkPCiAlxkzZV64_CMl0A,3758 sqlparse/exceptions.py,sha256=QyZ9TKTvzgcmuQ1cJkxAj9SoAw4M02-Bf0CSUNWNDKM,342 sqlparse/filters/__init__.py,sha256=PcS7CklN-qpmfYhId4oGTyUb7au1A0aD-21RP_bsfQY,1242 sqlparse/filters/__pycache__/__init__.cpython-311.pyc,, sqlparse/filters/__pycache__/aligned_indent.cpython-311.pyc,, sqlparse/filters/__pycache__/others.cpython-311.pyc,, sqlparse/filters/__pycache__/output.cpython-311.pyc,, sqlparse/filters/__pycache__/reindent.cpython-311.pyc,, sqlparse/filters/__pycache__/right_margin.cpython-311.pyc,, sqlparse/filters/__pycache__/tokens.cpython-311.pyc,, sqlparse/filters/aligned_indent.py,sha256=kvN5TVMxovyX6cDnmxF-t-KUz2RnzbQ1fIQzdIxYY2g,5110 sqlparse/filters/others.py,sha256=No8RhdUT8td6I0r9uxM6GuI_alDsE9FhFftcZpq856c,5180 sqlparse/filters/output.py,sha256=OMSalSPvq3s3-r268Tjv-AmtjTNCfhLayWtQFO5oyVE,4001 sqlparse/filters/reindent.py,sha256=y090sT7Mc44Bw9InKqJ1u_BzUTc81W0L1N-BVLVpq8o,9549 sqlparse/filters/right_margin.py,sha256=Hil692JB3ZkiMPpPPZcMUiRUjDpmhFiuARUu5_imym8,1543 sqlparse/filters/tokens.py,sha256=CZwDwMzzOdq0qvTRIIic7w59g54QhwFgM2Op9932Zvk,1553 sqlparse/formatter.py,sha256=iWDPQhD4JqbiA4jZpK2QBZzEqVACw3bRwdLgPIma4lE,7566 sqlparse/keywords.py,sha256=6ODDvyPvRpt9QztyN396R925WdvovikFLhs2DqRn1Qo,29445 sqlparse/lexer.py,sha256=Gqebv66Wu8GQlQYF_NkLoIZYDufhibBjYJHzRNEyffg,5786 sqlparse/sql.py,sha256=UTEij071iIjtuYntsxqWgbKGCYW3AFMB2yJBuBoPjkw,20401 sqlparse/tokens.py,sha256=NMUdBh3XPKk-D-uYn_tqKqdsD_uXVZWzkoHIy0vEEpA,1661 sqlparse/utils.py,sha256=VO2icS0t4vqg9mpZJUUrmP0RqfIrC-QRWoRgoEey9r8,3446
castiel248/Convert
Lib/site-packages/sqlparse-0.4.4.dist-info/RECORD
none
mit
3,367
Wheel-Version: 1.0 Generator: flit 3.8.0 Root-Is-Purelib: true Tag: py3-none-any
castiel248/Convert
Lib/site-packages/sqlparse-0.4.4.dist-info/WHEEL
none
mit
81
[console_scripts] sqlformat=sqlparse.__main__:main
castiel248/Convert
Lib/site-packages/sqlparse-0.4.4.dist-info/entry_points.txt
Text
mit
52
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """Parse SQL statements.""" # Setup namespace from sqlparse import sql from sqlparse import cli from sqlparse import engine from sqlparse import tokens from sqlparse import filters from sqlparse import formatter __version__ = '0.4.4' __all__ = ['engine', 'filters', 'formatter', 'sql', 'tokens', 'cli'] def parse(sql, encoding=None): """Parse sql and return a list of statements. :param sql: A string containing one or more SQL statements. :param encoding: The encoding of the statement (optional). :returns: A tuple of :class:`~sqlparse.sql.Statement` instances. """ return tuple(parsestream(sql, encoding)) def parsestream(stream, encoding=None): """Parses sql statements from file-like object. :param stream: A file-like object. :param encoding: The encoding of the stream contents (optional). :returns: A generator of :class:`~sqlparse.sql.Statement` instances. """ stack = engine.FilterStack() stack.enable_grouping() return stack.run(stream, encoding) def format(sql, encoding=None, **options): """Format *sql* according to *options*. Available options are documented in :ref:`formatting`. In addition to the formatting options this function accepts the keyword "encoding" which determines the encoding of the statement. :returns: The formatted SQL statement as string. """ stack = engine.FilterStack() options = formatter.validate_options(options) stack = formatter.build_filter_stack(stack, options) stack.postprocess.append(filters.SerializerUnicode()) return ''.join(stack.run(sql, encoding)) def split(sql, encoding=None): """Split *sql* into single statements. :param sql: A string containing one or more SQL statements. :param encoding: The encoding of the statement (optional). :returns: A list of strings. """ stack = engine.FilterStack() return [str(stmt).strip() for stmt in stack.run(sql, encoding)]
castiel248/Convert
Lib/site-packages/sqlparse/__init__.py
Python
mit
2,180
#!/usr/bin/env python # # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """Entrypoint module for `python -m sqlparse`. Why does this file exist, and why __main__? For more info, read: - https://www.python.org/dev/peps/pep-0338/ - https://docs.python.org/2/using/cmdline.html#cmdoption-m - https://docs.python.org/3/using/cmdline.html#cmdoption-m """ import sys from sqlparse.cli import main if __name__ == '__main__': sys.exit(main())
castiel248/Convert
Lib/site-packages/sqlparse/__main__.py
Python
mit
610
#!/usr/bin/env python # # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """Module that contains the command line app. Why does this file exist, and why not put this in __main__? You might be tempted to import things from __main__ later, but that will cause problems: the code will get executed twice: - When you run `python -m sqlparse` python will execute ``__main__.py`` as a script. That means there won't be any ``sqlparse.__main__`` in ``sys.modules``. - When you import __main__ it will get executed again (as a module) because there's no ``sqlparse.__main__`` in ``sys.modules``. Also see (1) from http://click.pocoo.org/5/setuptools/#setuptools-integration """ import argparse import sys from io import TextIOWrapper import sqlparse from sqlparse.exceptions import SQLParseError # TODO: Add CLI Tests # TODO: Simplify formatter by using argparse `type` arguments def create_parser(): _CASE_CHOICES = ['upper', 'lower', 'capitalize'] parser = argparse.ArgumentParser( prog='sqlformat', description='Format FILE according to OPTIONS. Use "-" as FILE ' 'to read from stdin.', usage='%(prog)s [OPTIONS] FILE, ...', ) parser.add_argument('filename') parser.add_argument( '-o', '--outfile', dest='outfile', metavar='FILE', help='write output to FILE (defaults to stdout)') parser.add_argument( '--version', action='version', version=sqlparse.__version__) group = parser.add_argument_group('Formatting Options') group.add_argument( '-k', '--keywords', metavar='CHOICE', dest='keyword_case', choices=_CASE_CHOICES, help='change case of keywords, CHOICE is one of {}'.format( ', '.join('"{}"'.format(x) for x in _CASE_CHOICES))) group.add_argument( '-i', '--identifiers', metavar='CHOICE', dest='identifier_case', choices=_CASE_CHOICES, help='change case of identifiers, CHOICE is one of {}'.format( ', '.join('"{}"'.format(x) for x in _CASE_CHOICES))) group.add_argument( '-l', '--language', metavar='LANG', dest='output_format', choices=['python', 'php'], help='output a snippet in programming language LANG, ' 'choices are "python", "php"') group.add_argument( '--strip-comments', dest='strip_comments', action='store_true', default=False, help='remove comments') group.add_argument( '-r', '--reindent', dest='reindent', action='store_true', default=False, help='reindent statements') group.add_argument( '--indent_width', dest='indent_width', default=2, type=int, help='indentation width (defaults to 2 spaces)') group.add_argument( '--indent_after_first', dest='indent_after_first', action='store_true', default=False, help='indent after first line of statement (e.g. SELECT)') group.add_argument( '--indent_columns', dest='indent_columns', action='store_true', default=False, help='indent all columns by indent_width instead of keyword length') group.add_argument( '-a', '--reindent_aligned', action='store_true', default=False, help='reindent statements to aligned format') group.add_argument( '-s', '--use_space_around_operators', action='store_true', default=False, help='place spaces around mathematical operators') group.add_argument( '--wrap_after', dest='wrap_after', default=0, type=int, help='Column after which lists should be wrapped') group.add_argument( '--comma_first', dest='comma_first', default=False, type=bool, help='Insert linebreak before comma (default False)') group.add_argument( '--encoding', dest='encoding', default='utf-8', help='Specify the input encoding (default utf-8)') return parser def _error(msg): """Print msg and optionally exit with return code exit_.""" sys.stderr.write('[ERROR] {}\n'.format(msg)) return 1 def main(args=None): parser = create_parser() args = parser.parse_args(args) if args.filename == '-': # read from stdin wrapper = TextIOWrapper(sys.stdin.buffer, encoding=args.encoding) try: data = wrapper.read() finally: wrapper.detach() else: try: with open(args.filename, encoding=args.encoding) as f: data = ''.join(f.readlines()) except OSError as e: return _error( 'Failed to read {}: {}'.format(args.filename, e)) close_stream = False if args.outfile: try: stream = open(args.outfile, 'w', encoding=args.encoding) close_stream = True except OSError as e: return _error('Failed to open {}: {}'.format(args.outfile, e)) else: stream = sys.stdout formatter_opts = vars(args) try: formatter_opts = sqlparse.formatter.validate_options(formatter_opts) except SQLParseError as e: return _error('Invalid options: {}'.format(e)) s = sqlparse.format(data, **formatter_opts) stream.write(s) stream.flush() if close_stream: stream.close() return 0
castiel248/Convert
Lib/site-packages/sqlparse/cli.py
Python
mit
5,712
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse.engine import grouping from sqlparse.engine.filter_stack import FilterStack from sqlparse.engine.statement_splitter import StatementSplitter __all__ = [ 'grouping', 'FilterStack', 'StatementSplitter', ]
castiel248/Convert
Lib/site-packages/sqlparse/engine/__init__.py
Python
mit
447
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """filter""" from sqlparse import lexer from sqlparse.engine import grouping from sqlparse.engine.statement_splitter import StatementSplitter class FilterStack: def __init__(self): self.preprocess = [] self.stmtprocess = [] self.postprocess = [] self._grouping = False def enable_grouping(self): self._grouping = True def run(self, sql, encoding=None): stream = lexer.tokenize(sql, encoding) # Process token stream for filter_ in self.preprocess: stream = filter_.process(stream) stream = StatementSplitter().process(stream) # Output: Stream processed Statements for stmt in stream: if self._grouping: stmt = grouping.group(stmt) for filter_ in self.stmtprocess: filter_.process(stmt) for filter_ in self.postprocess: stmt = filter_.process(stmt) yield stmt
castiel248/Convert
Lib/site-packages/sqlparse/engine/filter_stack.py
Python
mit
1,193
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import sql from sqlparse import tokens as T from sqlparse.utils import recurse, imt T_NUMERICAL = (T.Number, T.Number.Integer, T.Number.Float) T_STRING = (T.String, T.String.Single, T.String.Symbol) T_NAME = (T.Name, T.Name.Placeholder) def _group_matching(tlist, cls): """Groups Tokens that have beginning and end.""" opens = [] tidx_offset = 0 for idx, token in enumerate(list(tlist)): tidx = idx - tidx_offset if token.is_whitespace: # ~50% of tokens will be whitespace. Will checking early # for them avoid 3 comparisons, but then add 1 more comparison # for the other ~50% of tokens... continue if token.is_group and not isinstance(token, cls): # Check inside previously grouped (i.e. parenthesis) if group # of different type is inside (i.e., case). though ideally should # should check for all open/close tokens at once to avoid recursion _group_matching(token, cls) continue if token.match(*cls.M_OPEN): opens.append(tidx) elif token.match(*cls.M_CLOSE): try: open_idx = opens.pop() except IndexError: # this indicates invalid sql and unbalanced tokens. # instead of break, continue in case other "valid" groups exist continue close_idx = tidx tlist.group_tokens(cls, open_idx, close_idx) tidx_offset += close_idx - open_idx def group_brackets(tlist): _group_matching(tlist, sql.SquareBrackets) def group_parenthesis(tlist): _group_matching(tlist, sql.Parenthesis) def group_case(tlist): _group_matching(tlist, sql.Case) def group_if(tlist): _group_matching(tlist, sql.If) def group_for(tlist): _group_matching(tlist, sql.For) def group_begin(tlist): _group_matching(tlist, sql.Begin) def group_typecasts(tlist): def match(token): return token.match(T.Punctuation, '::') def valid(token): return token is not None def post(tlist, pidx, tidx, nidx): return pidx, nidx valid_prev = valid_next = valid _group(tlist, sql.Identifier, match, valid_prev, valid_next, post) def group_tzcasts(tlist): def match(token): return token.ttype == T.Keyword.TZCast def valid_prev(token): return token is not None def valid_next(token): return token is not None and ( token.is_whitespace or token.match(T.Keyword, 'AS') or token.match(*sql.TypedLiteral.M_CLOSE) ) def post(tlist, pidx, tidx, nidx): return pidx, nidx _group(tlist, sql.Identifier, match, valid_prev, valid_next, post) def group_typed_literal(tlist): # definitely not complete, see e.g.: # https://docs.microsoft.com/en-us/sql/odbc/reference/appendixes/interval-literal-syntax # https://docs.microsoft.com/en-us/sql/odbc/reference/appendixes/interval-literals # https://www.postgresql.org/docs/9.1/datatype-datetime.html # https://www.postgresql.org/docs/9.1/functions-datetime.html def match(token): return imt(token, m=sql.TypedLiteral.M_OPEN) def match_to_extend(token): return isinstance(token, sql.TypedLiteral) def valid_prev(token): return token is not None def valid_next(token): return token is not None and token.match(*sql.TypedLiteral.M_CLOSE) def valid_final(token): return token is not None and token.match(*sql.TypedLiteral.M_EXTEND) def post(tlist, pidx, tidx, nidx): return tidx, nidx _group(tlist, sql.TypedLiteral, match, valid_prev, valid_next, post, extend=False) _group(tlist, sql.TypedLiteral, match_to_extend, valid_prev, valid_final, post, extend=True) def group_period(tlist): def match(token): return token.match(T.Punctuation, '.') def valid_prev(token): sqlcls = sql.SquareBrackets, sql.Identifier ttypes = T.Name, T.String.Symbol return imt(token, i=sqlcls, t=ttypes) def valid_next(token): # issue261, allow invalid next token return True def post(tlist, pidx, tidx, nidx): # next_ validation is being performed here. issue261 sqlcls = sql.SquareBrackets, sql.Function ttypes = T.Name, T.String.Symbol, T.Wildcard next_ = tlist[nidx] if nidx is not None else None valid_next = imt(next_, i=sqlcls, t=ttypes) return (pidx, nidx) if valid_next else (pidx, tidx) _group(tlist, sql.Identifier, match, valid_prev, valid_next, post) def group_as(tlist): def match(token): return token.is_keyword and token.normalized == 'AS' def valid_prev(token): return token.normalized == 'NULL' or not token.is_keyword def valid_next(token): ttypes = T.DML, T.DDL, T.CTE return not imt(token, t=ttypes) and token is not None def post(tlist, pidx, tidx, nidx): return pidx, nidx _group(tlist, sql.Identifier, match, valid_prev, valid_next, post) def group_assignment(tlist): def match(token): return token.match(T.Assignment, ':=') def valid(token): return token is not None and token.ttype not in (T.Keyword) def post(tlist, pidx, tidx, nidx): m_semicolon = T.Punctuation, ';' snidx, _ = tlist.token_next_by(m=m_semicolon, idx=nidx) nidx = snidx or nidx return pidx, nidx valid_prev = valid_next = valid _group(tlist, sql.Assignment, match, valid_prev, valid_next, post) def group_comparison(tlist): sqlcls = (sql.Parenthesis, sql.Function, sql.Identifier, sql.Operation, sql.TypedLiteral) ttypes = T_NUMERICAL + T_STRING + T_NAME def match(token): return token.ttype == T.Operator.Comparison def valid(token): if imt(token, t=ttypes, i=sqlcls): return True elif token and token.is_keyword and token.normalized == 'NULL': return True else: return False def post(tlist, pidx, tidx, nidx): return pidx, nidx valid_prev = valid_next = valid _group(tlist, sql.Comparison, match, valid_prev, valid_next, post, extend=False) @recurse(sql.Identifier) def group_identifier(tlist): ttypes = (T.String.Symbol, T.Name) tidx, token = tlist.token_next_by(t=ttypes) while token: tlist.group_tokens(sql.Identifier, tidx, tidx) tidx, token = tlist.token_next_by(t=ttypes, idx=tidx) def group_arrays(tlist): sqlcls = sql.SquareBrackets, sql.Identifier, sql.Function ttypes = T.Name, T.String.Symbol def match(token): return isinstance(token, sql.SquareBrackets) def valid_prev(token): return imt(token, i=sqlcls, t=ttypes) def valid_next(token): return True def post(tlist, pidx, tidx, nidx): return pidx, tidx _group(tlist, sql.Identifier, match, valid_prev, valid_next, post, extend=True, recurse=False) def group_operator(tlist): ttypes = T_NUMERICAL + T_STRING + T_NAME sqlcls = (sql.SquareBrackets, sql.Parenthesis, sql.Function, sql.Identifier, sql.Operation, sql.TypedLiteral) def match(token): return imt(token, t=(T.Operator, T.Wildcard)) def valid(token): return imt(token, i=sqlcls, t=ttypes) \ or (token and token.match( T.Keyword, ('CURRENT_DATE', 'CURRENT_TIME', 'CURRENT_TIMESTAMP'))) def post(tlist, pidx, tidx, nidx): tlist[tidx].ttype = T.Operator return pidx, nidx valid_prev = valid_next = valid _group(tlist, sql.Operation, match, valid_prev, valid_next, post, extend=False) def group_identifier_list(tlist): m_role = T.Keyword, ('null', 'role') sqlcls = (sql.Function, sql.Case, sql.Identifier, sql.Comparison, sql.IdentifierList, sql.Operation) ttypes = (T_NUMERICAL + T_STRING + T_NAME + (T.Keyword, T.Comment, T.Wildcard)) def match(token): return token.match(T.Punctuation, ',') def valid(token): return imt(token, i=sqlcls, m=m_role, t=ttypes) def post(tlist, pidx, tidx, nidx): return pidx, nidx valid_prev = valid_next = valid _group(tlist, sql.IdentifierList, match, valid_prev, valid_next, post, extend=True) @recurse(sql.Comment) def group_comments(tlist): tidx, token = tlist.token_next_by(t=T.Comment) while token: eidx, end = tlist.token_not_matching( lambda tk: imt(tk, t=T.Comment) or tk.is_whitespace, idx=tidx) if end is not None: eidx, end = tlist.token_prev(eidx, skip_ws=False) tlist.group_tokens(sql.Comment, tidx, eidx) tidx, token = tlist.token_next_by(t=T.Comment, idx=tidx) @recurse(sql.Where) def group_where(tlist): tidx, token = tlist.token_next_by(m=sql.Where.M_OPEN) while token: eidx, end = tlist.token_next_by(m=sql.Where.M_CLOSE, idx=tidx) if end is None: end = tlist._groupable_tokens[-1] else: end = tlist.tokens[eidx - 1] # TODO: convert this to eidx instead of end token. # i think above values are len(tlist) and eidx-1 eidx = tlist.token_index(end) tlist.group_tokens(sql.Where, tidx, eidx) tidx, token = tlist.token_next_by(m=sql.Where.M_OPEN, idx=tidx) @recurse() def group_aliased(tlist): I_ALIAS = (sql.Parenthesis, sql.Function, sql.Case, sql.Identifier, sql.Operation, sql.Comparison) tidx, token = tlist.token_next_by(i=I_ALIAS, t=T.Number) while token: nidx, next_ = tlist.token_next(tidx) if isinstance(next_, sql.Identifier): tlist.group_tokens(sql.Identifier, tidx, nidx, extend=True) tidx, token = tlist.token_next_by(i=I_ALIAS, t=T.Number, idx=tidx) @recurse(sql.Function) def group_functions(tlist): has_create = False has_table = False has_as = False for tmp_token in tlist.tokens: if tmp_token.value.upper() == 'CREATE': has_create = True if tmp_token.value.upper() == 'TABLE': has_table = True if tmp_token.value == 'AS': has_as = True if has_create and has_table and not has_as: return tidx, token = tlist.token_next_by(t=T.Name) while token: nidx, next_ = tlist.token_next(tidx) if isinstance(next_, sql.Parenthesis): tlist.group_tokens(sql.Function, tidx, nidx) tidx, token = tlist.token_next_by(t=T.Name, idx=tidx) def group_order(tlist): """Group together Identifier and Asc/Desc token""" tidx, token = tlist.token_next_by(t=T.Keyword.Order) while token: pidx, prev_ = tlist.token_prev(tidx) if imt(prev_, i=sql.Identifier, t=T.Number): tlist.group_tokens(sql.Identifier, pidx, tidx) tidx = pidx tidx, token = tlist.token_next_by(t=T.Keyword.Order, idx=tidx) @recurse() def align_comments(tlist): tidx, token = tlist.token_next_by(i=sql.Comment) while token: pidx, prev_ = tlist.token_prev(tidx) if isinstance(prev_, sql.TokenList): tlist.group_tokens(sql.TokenList, pidx, tidx, extend=True) tidx = pidx tidx, token = tlist.token_next_by(i=sql.Comment, idx=tidx) def group_values(tlist): tidx, token = tlist.token_next_by(m=(T.Keyword, 'VALUES')) start_idx = tidx end_idx = -1 while token: if isinstance(token, sql.Parenthesis): end_idx = tidx tidx, token = tlist.token_next(tidx) if end_idx != -1: tlist.group_tokens(sql.Values, start_idx, end_idx, extend=True) def group(stmt): for func in [ group_comments, # _group_matching group_brackets, group_parenthesis, group_case, group_if, group_for, group_begin, group_functions, group_where, group_period, group_arrays, group_identifier, group_order, group_typecasts, group_tzcasts, group_typed_literal, group_operator, group_comparison, group_as, group_aliased, group_assignment, align_comments, group_identifier_list, group_values, ]: func(stmt) return stmt def _group(tlist, cls, match, valid_prev=lambda t: True, valid_next=lambda t: True, post=None, extend=True, recurse=True ): """Groups together tokens that are joined by a middle token. i.e. x < y""" tidx_offset = 0 pidx, prev_ = None, None for idx, token in enumerate(list(tlist)): tidx = idx - tidx_offset if tidx < 0: # tidx shouldn't get negative continue if token.is_whitespace: continue if recurse and token.is_group and not isinstance(token, cls): _group(token, cls, match, valid_prev, valid_next, post, extend) if match(token): nidx, next_ = tlist.token_next(tidx) if prev_ and valid_prev(prev_) and valid_next(next_): from_idx, to_idx = post(tlist, pidx, tidx, nidx) grp = tlist.group_tokens(cls, from_idx, to_idx, extend=extend) tidx_offset += to_idx - from_idx pidx, prev_ = from_idx, grp continue pidx, prev_ = tidx, token
castiel248/Convert
Lib/site-packages/sqlparse/engine/grouping.py
Python
mit
13,826
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import sql, tokens as T class StatementSplitter: """Filter that split stream at individual statements""" def __init__(self): self._reset() def _reset(self): """Set the filter attributes to its default values""" self._in_declare = False self._is_create = False self._begin_depth = 0 self.consume_ws = False self.tokens = [] self.level = 0 def _change_splitlevel(self, ttype, value): """Get the new split level (increase, decrease or remain equal)""" # parenthesis increase/decrease a level if ttype is T.Punctuation and value == '(': return 1 elif ttype is T.Punctuation and value == ')': return -1 elif ttype not in T.Keyword: # if normal token return return 0 # Everything after here is ttype = T.Keyword # Also to note, once entered an If statement you are done and basically # returning unified = value.upper() # three keywords begin with CREATE, but only one of them is DDL # DDL Create though can contain more words such as "or replace" if ttype is T.Keyword.DDL and unified.startswith('CREATE'): self._is_create = True return 0 # can have nested declare inside of being... if unified == 'DECLARE' and self._is_create and self._begin_depth == 0: self._in_declare = True return 1 if unified == 'BEGIN': self._begin_depth += 1 if self._is_create: # FIXME(andi): This makes no sense. return 1 return 0 # Should this respect a preceding BEGIN? # In CASE ... WHEN ... END this results in a split level -1. # Would having multiple CASE WHEN END and a Assignment Operator # cause the statement to cut off prematurely? if unified == 'END': self._begin_depth = max(0, self._begin_depth - 1) return -1 if (unified in ('IF', 'FOR', 'WHILE', 'CASE') and self._is_create and self._begin_depth > 0): return 1 if unified in ('END IF', 'END FOR', 'END WHILE'): return -1 # Default return 0 def process(self, stream): """Process the stream""" EOS_TTYPE = T.Whitespace, T.Comment.Single # Run over all stream tokens for ttype, value in stream: # Yield token if we finished a statement and there's no whitespaces # It will count newline token as a non whitespace. In this context # whitespace ignores newlines. # why don't multi line comments also count? if self.consume_ws and ttype not in EOS_TTYPE: yield sql.Statement(self.tokens) # Reset filter and prepare to process next statement self._reset() # Change current split level (increase, decrease or remain equal) self.level += self._change_splitlevel(ttype, value) # Append the token to the current statement self.tokens.append(sql.Token(ttype, value)) # Check if we get the end of a statement if self.level <= 0 and ttype is T.Punctuation and value == ';': self.consume_ws = True # Yield pending statement (if any) if self.tokens and not all(t.is_whitespace for t in self.tokens): yield sql.Statement(self.tokens)
castiel248/Convert
Lib/site-packages/sqlparse/engine/statement_splitter.py
Python
mit
3,758
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """Exceptions used in this package.""" class SQLParseError(Exception): """Base class for exceptions in this module."""
castiel248/Convert
Lib/site-packages/sqlparse/exceptions.py
Python
mit
342
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse.filters.others import SerializerUnicode from sqlparse.filters.others import StripCommentsFilter from sqlparse.filters.others import StripWhitespaceFilter from sqlparse.filters.others import SpacesAroundOperatorsFilter from sqlparse.filters.output import OutputPHPFilter from sqlparse.filters.output import OutputPythonFilter from sqlparse.filters.tokens import KeywordCaseFilter from sqlparse.filters.tokens import IdentifierCaseFilter from sqlparse.filters.tokens import TruncateStringFilter from sqlparse.filters.reindent import ReindentFilter from sqlparse.filters.right_margin import RightMarginFilter from sqlparse.filters.aligned_indent import AlignedIndentFilter __all__ = [ 'SerializerUnicode', 'StripCommentsFilter', 'StripWhitespaceFilter', 'SpacesAroundOperatorsFilter', 'OutputPHPFilter', 'OutputPythonFilter', 'KeywordCaseFilter', 'IdentifierCaseFilter', 'TruncateStringFilter', 'ReindentFilter', 'RightMarginFilter', 'AlignedIndentFilter', ]
castiel248/Convert
Lib/site-packages/sqlparse/filters/__init__.py
Python
mit
1,242
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import sql, tokens as T from sqlparse.utils import offset, indent class AlignedIndentFilter: join_words = (r'((LEFT\s+|RIGHT\s+|FULL\s+)?' r'(INNER\s+|OUTER\s+|STRAIGHT\s+)?|' r'(CROSS\s+|NATURAL\s+)?)?JOIN\b') by_words = r'(GROUP|ORDER)\s+BY\b' split_words = ('FROM', join_words, 'ON', by_words, 'WHERE', 'AND', 'OR', 'HAVING', 'LIMIT', 'UNION', 'VALUES', 'SET', 'BETWEEN', 'EXCEPT') def __init__(self, char=' ', n='\n'): self.n = n self.offset = 0 self.indent = 0 self.char = char self._max_kwd_len = len('select') def nl(self, offset=1): # offset = 1 represent a single space after SELECT offset = -len(offset) if not isinstance(offset, int) else offset # add two for the space and parenthesis indent = self.indent * (2 + self._max_kwd_len) return sql.Token(T.Whitespace, self.n + self.char * ( self._max_kwd_len + offset + indent + self.offset)) def _process_statement(self, tlist): if len(tlist.tokens) > 0 and tlist.tokens[0].is_whitespace \ and self.indent == 0: tlist.tokens.pop(0) # process the main query body self._process(sql.TokenList(tlist.tokens)) def _process_parenthesis(self, tlist): # if this isn't a subquery, don't re-indent _, token = tlist.token_next_by(m=(T.DML, 'SELECT')) if token is not None: with indent(self): tlist.insert_after(tlist[0], self.nl('SELECT')) # process the inside of the parenthesis self._process_default(tlist) # de-indent last parenthesis tlist.insert_before(tlist[-1], self.nl()) def _process_identifierlist(self, tlist): # columns being selected identifiers = list(tlist.get_identifiers()) identifiers.pop(0) [tlist.insert_before(token, self.nl()) for token in identifiers] self._process_default(tlist) def _process_case(self, tlist): offset_ = len('case ') + len('when ') cases = tlist.get_cases(skip_ws=True) # align the end as well end_token = tlist.token_next_by(m=(T.Keyword, 'END'))[1] cases.append((None, [end_token])) condition_width = [len(' '.join(map(str, cond))) if cond else 0 for cond, _ in cases] max_cond_width = max(condition_width) for i, (cond, value) in enumerate(cases): # cond is None when 'else or end' stmt = cond[0] if cond else value[0] if i > 0: tlist.insert_before(stmt, self.nl(offset_ - len(str(stmt)))) if cond: ws = sql.Token(T.Whitespace, self.char * ( max_cond_width - condition_width[i])) tlist.insert_after(cond[-1], ws) def _next_token(self, tlist, idx=-1): split_words = T.Keyword, self.split_words, True tidx, token = tlist.token_next_by(m=split_words, idx=idx) # treat "BETWEEN x and y" as a single statement if token and token.normalized == 'BETWEEN': tidx, token = self._next_token(tlist, tidx) if token and token.normalized == 'AND': tidx, token = self._next_token(tlist, tidx) return tidx, token def _split_kwds(self, tlist): tidx, token = self._next_token(tlist) while token: # joins, group/order by are special case. only consider the first # word as aligner if ( token.match(T.Keyword, self.join_words, regex=True) or token.match(T.Keyword, self.by_words, regex=True) ): token_indent = token.value.split()[0] else: token_indent = str(token) tlist.insert_before(token, self.nl(token_indent)) tidx += 1 tidx, token = self._next_token(tlist, tidx) def _process_default(self, tlist): self._split_kwds(tlist) # process any sub-sub statements for sgroup in tlist.get_sublists(): idx = tlist.token_index(sgroup) pidx, prev_ = tlist.token_prev(idx) # HACK: make "group/order by" work. Longer than max_len. offset_ = 3 if ( prev_ and prev_.match(T.Keyword, self.by_words, regex=True) ) else 0 with offset(self, offset_): self._process(sgroup) def _process(self, tlist): func_name = '_process_{cls}'.format(cls=type(tlist).__name__) func = getattr(self, func_name.lower(), self._process_default) func(tlist) def process(self, stmt): self._process(stmt) return stmt
castiel248/Convert
Lib/site-packages/sqlparse/filters/aligned_indent.py
Python
mit
5,110
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause import re from sqlparse import sql, tokens as T from sqlparse.utils import split_unquoted_newlines class StripCommentsFilter: @staticmethod def _process(tlist): def get_next_comment(): # TODO(andi) Comment types should be unified, see related issue38 return tlist.token_next_by(i=sql.Comment, t=T.Comment) def _get_insert_token(token): """Returns either a whitespace or the line breaks from token.""" # See issue484 why line breaks should be preserved. # Note: The actual value for a line break is replaced by \n # in SerializerUnicode which will be executed in the # postprocessing state. m = re.search(r'((\r|\n)+) *$', token.value) if m is not None: return sql.Token(T.Whitespace.Newline, m.groups()[0]) else: return sql.Token(T.Whitespace, ' ') tidx, token = get_next_comment() while token: pidx, prev_ = tlist.token_prev(tidx, skip_ws=False) nidx, next_ = tlist.token_next(tidx, skip_ws=False) # Replace by whitespace if prev and next exist and if they're not # whitespaces. This doesn't apply if prev or next is a parenthesis. if (prev_ is None or next_ is None or prev_.is_whitespace or prev_.match(T.Punctuation, '(') or next_.is_whitespace or next_.match(T.Punctuation, ')')): # Insert a whitespace to ensure the following SQL produces # a valid SQL (see #425). if prev_ is not None and not prev_.match(T.Punctuation, '('): tlist.tokens.insert(tidx, _get_insert_token(token)) tlist.tokens.remove(token) else: tlist.tokens[tidx] = _get_insert_token(token) tidx, token = get_next_comment() def process(self, stmt): [self.process(sgroup) for sgroup in stmt.get_sublists()] StripCommentsFilter._process(stmt) return stmt class StripWhitespaceFilter: def _stripws(self, tlist): func_name = '_stripws_{cls}'.format(cls=type(tlist).__name__) func = getattr(self, func_name.lower(), self._stripws_default) func(tlist) @staticmethod def _stripws_default(tlist): last_was_ws = False is_first_char = True for token in tlist.tokens: if token.is_whitespace: token.value = '' if last_was_ws or is_first_char else ' ' last_was_ws = token.is_whitespace is_first_char = False def _stripws_identifierlist(self, tlist): # Removes newlines before commas, see issue140 last_nl = None for token in list(tlist.tokens): if last_nl and token.ttype is T.Punctuation and token.value == ',': tlist.tokens.remove(last_nl) last_nl = token if token.is_whitespace else None # next_ = tlist.token_next(token, skip_ws=False) # if (next_ and not next_.is_whitespace and # token.ttype is T.Punctuation and token.value == ','): # tlist.insert_after(token, sql.Token(T.Whitespace, ' ')) return self._stripws_default(tlist) def _stripws_parenthesis(self, tlist): while tlist.tokens[1].is_whitespace: tlist.tokens.pop(1) while tlist.tokens[-2].is_whitespace: tlist.tokens.pop(-2) self._stripws_default(tlist) def process(self, stmt, depth=0): [self.process(sgroup, depth + 1) for sgroup in stmt.get_sublists()] self._stripws(stmt) if depth == 0 and stmt.tokens and stmt.tokens[-1].is_whitespace: stmt.tokens.pop(-1) return stmt class SpacesAroundOperatorsFilter: @staticmethod def _process(tlist): ttypes = (T.Operator, T.Comparison) tidx, token = tlist.token_next_by(t=ttypes) while token: nidx, next_ = tlist.token_next(tidx, skip_ws=False) if next_ and next_.ttype != T.Whitespace: tlist.insert_after(tidx, sql.Token(T.Whitespace, ' ')) pidx, prev_ = tlist.token_prev(tidx, skip_ws=False) if prev_ and prev_.ttype != T.Whitespace: tlist.insert_before(tidx, sql.Token(T.Whitespace, ' ')) tidx += 1 # has to shift since token inserted before it # assert tlist.token_index(token) == tidx tidx, token = tlist.token_next_by(t=ttypes, idx=tidx) def process(self, stmt): [self.process(sgroup) for sgroup in stmt.get_sublists()] SpacesAroundOperatorsFilter._process(stmt) return stmt # --------------------------- # postprocess class SerializerUnicode: @staticmethod def process(stmt): lines = split_unquoted_newlines(stmt) return '\n'.join(line.rstrip() for line in lines)
castiel248/Convert
Lib/site-packages/sqlparse/filters/others.py
Python
mit
5,180
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import sql, tokens as T class OutputFilter: varname_prefix = '' def __init__(self, varname='sql'): self.varname = self.varname_prefix + varname self.count = 0 def _process(self, stream, varname, has_nl): raise NotImplementedError def process(self, stmt): self.count += 1 if self.count > 1: varname = '{f.varname}{f.count}'.format(f=self) else: varname = self.varname has_nl = len(str(stmt).strip().splitlines()) > 1 stmt.tokens = self._process(stmt.tokens, varname, has_nl) return stmt class OutputPythonFilter(OutputFilter): def _process(self, stream, varname, has_nl): # SQL query assignation to varname if self.count > 1: yield sql.Token(T.Whitespace, '\n') yield sql.Token(T.Name, varname) yield sql.Token(T.Whitespace, ' ') yield sql.Token(T.Operator, '=') yield sql.Token(T.Whitespace, ' ') if has_nl: yield sql.Token(T.Operator, '(') yield sql.Token(T.Text, "'") # Print the tokens on the quote for token in stream: # Token is a new line separator if token.is_whitespace and '\n' in token.value: # Close quote and add a new line yield sql.Token(T.Text, " '") yield sql.Token(T.Whitespace, '\n') # Quote header on secondary lines yield sql.Token(T.Whitespace, ' ' * (len(varname) + 4)) yield sql.Token(T.Text, "'") # Indentation after_lb = token.value.split('\n', 1)[1] if after_lb: yield sql.Token(T.Whitespace, after_lb) continue # Token has escape chars elif "'" in token.value: token.value = token.value.replace("'", "\\'") # Put the token yield sql.Token(T.Text, token.value) # Close quote yield sql.Token(T.Text, "'") if has_nl: yield sql.Token(T.Operator, ')') class OutputPHPFilter(OutputFilter): varname_prefix = '$' def _process(self, stream, varname, has_nl): # SQL query assignation to varname (quote header) if self.count > 1: yield sql.Token(T.Whitespace, '\n') yield sql.Token(T.Name, varname) yield sql.Token(T.Whitespace, ' ') if has_nl: yield sql.Token(T.Whitespace, ' ') yield sql.Token(T.Operator, '=') yield sql.Token(T.Whitespace, ' ') yield sql.Token(T.Text, '"') # Print the tokens on the quote for token in stream: # Token is a new line separator if token.is_whitespace and '\n' in token.value: # Close quote and add a new line yield sql.Token(T.Text, ' ";') yield sql.Token(T.Whitespace, '\n') # Quote header on secondary lines yield sql.Token(T.Name, varname) yield sql.Token(T.Whitespace, ' ') yield sql.Token(T.Operator, '.=') yield sql.Token(T.Whitespace, ' ') yield sql.Token(T.Text, '"') # Indentation after_lb = token.value.split('\n', 1)[1] if after_lb: yield sql.Token(T.Whitespace, after_lb) continue # Token has escape chars elif '"' in token.value: token.value = token.value.replace('"', '\\"') # Put the token yield sql.Token(T.Text, token.value) # Close quote yield sql.Token(T.Text, '"') yield sql.Token(T.Punctuation, ';')
castiel248/Convert
Lib/site-packages/sqlparse/filters/output.py
Python
mit
4,001
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import sql, tokens as T from sqlparse.utils import offset, indent class ReindentFilter: def __init__(self, width=2, char=' ', wrap_after=0, n='\n', comma_first=False, indent_after_first=False, indent_columns=False): self.n = n self.width = width self.char = char self.indent = 1 if indent_after_first else 0 self.offset = 0 self.wrap_after = wrap_after self.comma_first = comma_first self.indent_columns = indent_columns self._curr_stmt = None self._last_stmt = None self._last_func = None def _flatten_up_to_token(self, token): """Yields all tokens up to token but excluding current.""" if token.is_group: token = next(token.flatten()) for t in self._curr_stmt.flatten(): if t == token: break yield t @property def leading_ws(self): return self.offset + self.indent * self.width def _get_offset(self, token): raw = ''.join(map(str, self._flatten_up_to_token(token))) line = (raw or '\n').splitlines()[-1] # Now take current offset into account and return relative offset. return len(line) - len(self.char * self.leading_ws) def nl(self, offset=0): return sql.Token( T.Whitespace, self.n + self.char * max(0, self.leading_ws + offset)) def _next_token(self, tlist, idx=-1): split_words = ('FROM', 'STRAIGHT_JOIN$', 'JOIN$', 'AND', 'OR', 'GROUP BY', 'ORDER BY', 'UNION', 'VALUES', 'SET', 'BETWEEN', 'EXCEPT', 'HAVING', 'LIMIT') m_split = T.Keyword, split_words, True tidx, token = tlist.token_next_by(m=m_split, idx=idx) if token and token.normalized == 'BETWEEN': tidx, token = self._next_token(tlist, tidx) if token and token.normalized == 'AND': tidx, token = self._next_token(tlist, tidx) return tidx, token def _split_kwds(self, tlist): tidx, token = self._next_token(tlist) while token: pidx, prev_ = tlist.token_prev(tidx, skip_ws=False) uprev = str(prev_) if prev_ and prev_.is_whitespace: del tlist.tokens[pidx] tidx -= 1 if not (uprev.endswith('\n') or uprev.endswith('\r')): tlist.insert_before(tidx, self.nl()) tidx += 1 tidx, token = self._next_token(tlist, tidx) def _split_statements(self, tlist): ttypes = T.Keyword.DML, T.Keyword.DDL tidx, token = tlist.token_next_by(t=ttypes) while token: pidx, prev_ = tlist.token_prev(tidx, skip_ws=False) if prev_ and prev_.is_whitespace: del tlist.tokens[pidx] tidx -= 1 # only break if it's not the first token if prev_: tlist.insert_before(tidx, self.nl()) tidx += 1 tidx, token = tlist.token_next_by(t=ttypes, idx=tidx) def _process(self, tlist): func_name = '_process_{cls}'.format(cls=type(tlist).__name__) func = getattr(self, func_name.lower(), self._process_default) func(tlist) def _process_where(self, tlist): tidx, token = tlist.token_next_by(m=(T.Keyword, 'WHERE')) if not token: return # issue121, errors in statement fixed?? tlist.insert_before(tidx, self.nl()) with indent(self): self._process_default(tlist) def _process_parenthesis(self, tlist): ttypes = T.Keyword.DML, T.Keyword.DDL _, is_dml_dll = tlist.token_next_by(t=ttypes) fidx, first = tlist.token_next_by(m=sql.Parenthesis.M_OPEN) if first is None: return with indent(self, 1 if is_dml_dll else 0): tlist.tokens.insert(0, self.nl()) if is_dml_dll else None with offset(self, self._get_offset(first) + 1): self._process_default(tlist, not is_dml_dll) def _process_function(self, tlist): self._last_func = tlist[0] self._process_default(tlist) def _process_identifierlist(self, tlist): identifiers = list(tlist.get_identifiers()) if self.indent_columns: first = next(identifiers[0].flatten()) num_offset = 1 if self.char == '\t' else self.width else: first = next(identifiers.pop(0).flatten()) num_offset = 1 if self.char == '\t' else self._get_offset(first) if not tlist.within(sql.Function) and not tlist.within(sql.Values): with offset(self, num_offset): position = 0 for token in identifiers: # Add 1 for the "," separator position += len(token.value) + 1 if position > (self.wrap_after - self.offset): adjust = 0 if self.comma_first: adjust = -2 _, comma = tlist.token_prev( tlist.token_index(token)) if comma is None: continue token = comma tlist.insert_before(token, self.nl(offset=adjust)) if self.comma_first: _, ws = tlist.token_next( tlist.token_index(token), skip_ws=False) if (ws is not None and ws.ttype is not T.Text.Whitespace): tlist.insert_after( token, sql.Token(T.Whitespace, ' ')) position = 0 else: # ensure whitespace for token in tlist: _, next_ws = tlist.token_next( tlist.token_index(token), skip_ws=False) if token.value == ',' and not next_ws.is_whitespace: tlist.insert_after( token, sql.Token(T.Whitespace, ' ')) end_at = self.offset + sum(len(i.value) + 1 for i in identifiers) adjusted_offset = 0 if (self.wrap_after > 0 and end_at > (self.wrap_after - self.offset) and self._last_func): adjusted_offset = -len(self._last_func.value) - 1 with offset(self, adjusted_offset), indent(self): if adjusted_offset < 0: tlist.insert_before(identifiers[0], self.nl()) position = 0 for token in identifiers: # Add 1 for the "," separator position += len(token.value) + 1 if (self.wrap_after > 0 and position > (self.wrap_after - self.offset)): adjust = 0 tlist.insert_before(token, self.nl(offset=adjust)) position = 0 self._process_default(tlist) def _process_case(self, tlist): iterable = iter(tlist.get_cases()) cond, _ = next(iterable) first = next(cond[0].flatten()) with offset(self, self._get_offset(tlist[0])): with offset(self, self._get_offset(first)): for cond, value in iterable: token = value[0] if cond is None else cond[0] tlist.insert_before(token, self.nl()) # Line breaks on group level are done. let's add an offset of # len "when ", "then ", "else " with offset(self, len("WHEN ")): self._process_default(tlist) end_idx, end = tlist.token_next_by(m=sql.Case.M_CLOSE) if end_idx is not None: tlist.insert_before(end_idx, self.nl()) def _process_values(self, tlist): tlist.insert_before(0, self.nl()) tidx, token = tlist.token_next_by(i=sql.Parenthesis) first_token = token while token: ptidx, ptoken = tlist.token_next_by(m=(T.Punctuation, ','), idx=tidx) if ptoken: if self.comma_first: adjust = -2 offset = self._get_offset(first_token) + adjust tlist.insert_before(ptoken, self.nl(offset)) else: tlist.insert_after(ptoken, self.nl(self._get_offset(token))) tidx, token = tlist.token_next_by(i=sql.Parenthesis, idx=tidx) def _process_default(self, tlist, stmts=True): self._split_statements(tlist) if stmts else None self._split_kwds(tlist) for sgroup in tlist.get_sublists(): self._process(sgroup) def process(self, stmt): self._curr_stmt = stmt self._process(stmt) if self._last_stmt is not None: nl = '\n' if str(self._last_stmt).endswith('\n') else '\n\n' stmt.tokens.insert(0, sql.Token(T.Whitespace, nl)) self._last_stmt = stmt return stmt
castiel248/Convert
Lib/site-packages/sqlparse/filters/reindent.py
Python
mit
9,549
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause import re from sqlparse import sql, tokens as T # FIXME: Doesn't work class RightMarginFilter: keep_together = ( # sql.TypeCast, sql.Identifier, sql.Alias, ) def __init__(self, width=79): self.width = width self.line = '' def _process(self, group, stream): for token in stream: if token.is_whitespace and '\n' in token.value: if token.value.endswith('\n'): self.line = '' else: self.line = token.value.splitlines()[-1] elif token.is_group and type(token) not in self.keep_together: token.tokens = self._process(token, token.tokens) else: val = str(token) if len(self.line) + len(val) > self.width: match = re.search(r'^ +', self.line) if match is not None: indent = match.group() else: indent = '' yield sql.Token(T.Whitespace, '\n{}'.format(indent)) self.line = indent self.line += val yield token def process(self, group): # return # group.tokens = self._process(group, group.tokens) raise NotImplementedError
castiel248/Convert
Lib/site-packages/sqlparse/filters/right_margin.py
Python
mit
1,543
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import tokens as T class _CaseFilter: ttype = None def __init__(self, case=None): case = case or 'upper' self.convert = getattr(str, case) def process(self, stream): for ttype, value in stream: if ttype in self.ttype: value = self.convert(value) yield ttype, value class KeywordCaseFilter(_CaseFilter): ttype = T.Keyword class IdentifierCaseFilter(_CaseFilter): ttype = T.Name, T.String.Symbol def process(self, stream): for ttype, value in stream: if ttype in self.ttype and value.strip()[0] != '"': value = self.convert(value) yield ttype, value class TruncateStringFilter: def __init__(self, width, char): self.width = width self.char = char def process(self, stream): for ttype, value in stream: if ttype != T.Literal.String.Single: yield ttype, value continue if value[:2] == "''": inner = value[2:-2] quote = "''" else: inner = value[1:-1] quote = "'" if len(inner) > self.width: value = ''.join((quote, inner[:self.width], self.char, quote)) yield ttype, value
castiel248/Convert
Lib/site-packages/sqlparse/filters/tokens.py
Python
mit
1,553
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """SQL formatter""" from sqlparse import filters from sqlparse.exceptions import SQLParseError def validate_options(options): """Validates options.""" kwcase = options.get('keyword_case') if kwcase not in [None, 'upper', 'lower', 'capitalize']: raise SQLParseError('Invalid value for keyword_case: ' '{!r}'.format(kwcase)) idcase = options.get('identifier_case') if idcase not in [None, 'upper', 'lower', 'capitalize']: raise SQLParseError('Invalid value for identifier_case: ' '{!r}'.format(idcase)) ofrmt = options.get('output_format') if ofrmt not in [None, 'sql', 'python', 'php']: raise SQLParseError('Unknown output format: ' '{!r}'.format(ofrmt)) strip_comments = options.get('strip_comments', False) if strip_comments not in [True, False]: raise SQLParseError('Invalid value for strip_comments: ' '{!r}'.format(strip_comments)) space_around_operators = options.get('use_space_around_operators', False) if space_around_operators not in [True, False]: raise SQLParseError('Invalid value for use_space_around_operators: ' '{!r}'.format(space_around_operators)) strip_ws = options.get('strip_whitespace', False) if strip_ws not in [True, False]: raise SQLParseError('Invalid value for strip_whitespace: ' '{!r}'.format(strip_ws)) truncate_strings = options.get('truncate_strings') if truncate_strings is not None: try: truncate_strings = int(truncate_strings) except (ValueError, TypeError): raise SQLParseError('Invalid value for truncate_strings: ' '{!r}'.format(truncate_strings)) if truncate_strings <= 1: raise SQLParseError('Invalid value for truncate_strings: ' '{!r}'.format(truncate_strings)) options['truncate_strings'] = truncate_strings options['truncate_char'] = options.get('truncate_char', '[...]') indent_columns = options.get('indent_columns', False) if indent_columns not in [True, False]: raise SQLParseError('Invalid value for indent_columns: ' '{!r}'.format(indent_columns)) elif indent_columns: options['reindent'] = True # enforce reindent options['indent_columns'] = indent_columns reindent = options.get('reindent', False) if reindent not in [True, False]: raise SQLParseError('Invalid value for reindent: ' '{!r}'.format(reindent)) elif reindent: options['strip_whitespace'] = True reindent_aligned = options.get('reindent_aligned', False) if reindent_aligned not in [True, False]: raise SQLParseError('Invalid value for reindent_aligned: ' '{!r}'.format(reindent)) elif reindent_aligned: options['strip_whitespace'] = True indent_after_first = options.get('indent_after_first', False) if indent_after_first not in [True, False]: raise SQLParseError('Invalid value for indent_after_first: ' '{!r}'.format(indent_after_first)) options['indent_after_first'] = indent_after_first indent_tabs = options.get('indent_tabs', False) if indent_tabs not in [True, False]: raise SQLParseError('Invalid value for indent_tabs: ' '{!r}'.format(indent_tabs)) elif indent_tabs: options['indent_char'] = '\t' else: options['indent_char'] = ' ' indent_width = options.get('indent_width', 2) try: indent_width = int(indent_width) except (TypeError, ValueError): raise SQLParseError('indent_width requires an integer') if indent_width < 1: raise SQLParseError('indent_width requires a positive integer') options['indent_width'] = indent_width wrap_after = options.get('wrap_after', 0) try: wrap_after = int(wrap_after) except (TypeError, ValueError): raise SQLParseError('wrap_after requires an integer') if wrap_after < 0: raise SQLParseError('wrap_after requires a positive integer') options['wrap_after'] = wrap_after comma_first = options.get('comma_first', False) if comma_first not in [True, False]: raise SQLParseError('comma_first requires a boolean value') options['comma_first'] = comma_first right_margin = options.get('right_margin') if right_margin is not None: try: right_margin = int(right_margin) except (TypeError, ValueError): raise SQLParseError('right_margin requires an integer') if right_margin < 10: raise SQLParseError('right_margin requires an integer > 10') options['right_margin'] = right_margin return options def build_filter_stack(stack, options): """Setup and return a filter stack. Args: stack: :class:`~sqlparse.filters.FilterStack` instance options: Dictionary with options validated by validate_options. """ # Token filter if options.get('keyword_case'): stack.preprocess.append( filters.KeywordCaseFilter(options['keyword_case'])) if options.get('identifier_case'): stack.preprocess.append( filters.IdentifierCaseFilter(options['identifier_case'])) if options.get('truncate_strings'): stack.preprocess.append(filters.TruncateStringFilter( width=options['truncate_strings'], char=options['truncate_char'])) if options.get('use_space_around_operators', False): stack.enable_grouping() stack.stmtprocess.append(filters.SpacesAroundOperatorsFilter()) # After grouping if options.get('strip_comments'): stack.enable_grouping() stack.stmtprocess.append(filters.StripCommentsFilter()) if options.get('strip_whitespace') or options.get('reindent'): stack.enable_grouping() stack.stmtprocess.append(filters.StripWhitespaceFilter()) if options.get('reindent'): stack.enable_grouping() stack.stmtprocess.append( filters.ReindentFilter( char=options['indent_char'], width=options['indent_width'], indent_after_first=options['indent_after_first'], indent_columns=options['indent_columns'], wrap_after=options['wrap_after'], comma_first=options['comma_first'])) if options.get('reindent_aligned', False): stack.enable_grouping() stack.stmtprocess.append( filters.AlignedIndentFilter(char=options['indent_char'])) if options.get('right_margin'): stack.enable_grouping() stack.stmtprocess.append( filters.RightMarginFilter(width=options['right_margin'])) # Serializer if options.get('output_format'): frmt = options['output_format'] if frmt.lower() == 'php': fltr = filters.OutputPHPFilter() elif frmt.lower() == 'python': fltr = filters.OutputPythonFilter() else: fltr = None if fltr is not None: stack.postprocess.append(fltr) return stack
castiel248/Convert
Lib/site-packages/sqlparse/formatter.py
Python
mit
7,566
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause from sqlparse import tokens # object() only supports "is" and is useful as a marker # use this marker to specify that the given regex in SQL_REGEX # shall be processed further through a lookup in the KEYWORDS dictionaries PROCESS_AS_KEYWORD = object() SQL_REGEX = [ (r'(--|# )\+.*?(\r\n|\r|\n|$)', tokens.Comment.Single.Hint), (r'/\*\+[\s\S]*?\*/', tokens.Comment.Multiline.Hint), (r'(--|# ).*?(\r\n|\r|\n|$)', tokens.Comment.Single), (r'/\*[\s\S]*?\*/', tokens.Comment.Multiline), (r'(\r\n|\r|\n)', tokens.Newline), (r'\s+?', tokens.Whitespace), (r':=', tokens.Assignment), (r'::', tokens.Punctuation), (r'\*', tokens.Wildcard), (r"`(``|[^`])*`", tokens.Name), (r"´(´´|[^´])*´", tokens.Name), (r'((?<!\S)\$(?:[_A-ZÀ-Ü]\w*)?\$)[\s\S]*?\1', tokens.Literal), (r'\?', tokens.Name.Placeholder), (r'%(\(\w+\))?s', tokens.Name.Placeholder), (r'(?<!\w)[$:?]\w+', tokens.Name.Placeholder), (r'\\\w+', tokens.Command), # FIXME(andi): VALUES shouldn't be listed here # see https://github.com/andialbrecht/sqlparse/pull/64 # AS and IN are special, it may be followed by a parenthesis, but # are never functions, see issue183 and issue507 (r'(CASE|IN|VALUES|USING|FROM|AS)\b', tokens.Keyword), (r'(@|##|#)[A-ZÀ-Ü]\w+', tokens.Name), # see issue #39 # Spaces around period `schema . name` are valid identifier # TODO: Spaces before period not implemented (r'[A-ZÀ-Ü]\w*(?=\s*\.)', tokens.Name), # 'Name'. # FIXME(atronah): never match, # because `re.match` doesn't work with look-behind regexp feature (r'(?<=\.)[A-ZÀ-Ü]\w*', tokens.Name), # .'Name' (r'[A-ZÀ-Ü]\w*(?=\()', tokens.Name), # side effect: change kw to func (r'-?0x[\dA-F]+', tokens.Number.Hexadecimal), (r'-?\d+(\.\d+)?E-?\d+', tokens.Number.Float), (r'(?![_A-ZÀ-Ü])-?(\d+(\.\d*)|\.\d+)(?![_A-ZÀ-Ü])', tokens.Number.Float), (r'(?![_A-ZÀ-Ü])-?\d+(?![_A-ZÀ-Ü])', tokens.Number.Integer), (r"'(''|\\'|[^'])*'", tokens.String.Single), # not a real string literal in ANSI SQL: (r'"(""|\\"|[^"])*"', tokens.String.Symbol), (r'(""|".*?[^\\]")', tokens.String.Symbol), # sqlite names can be escaped with [square brackets]. left bracket # cannot be preceded by word character or a right bracket -- # otherwise it's probably an array index (r'(?<![\w\])])(\[[^\]\[]+\])', tokens.Name), (r'((LEFT\s+|RIGHT\s+|FULL\s+)?(INNER\s+|OUTER\s+|STRAIGHT\s+)?' r'|(CROSS\s+|NATURAL\s+)?)?JOIN\b', tokens.Keyword), (r'END(\s+IF|\s+LOOP|\s+WHILE)?\b', tokens.Keyword), (r'NOT\s+NULL\b', tokens.Keyword), (r'NULLS\s+(FIRST|LAST)\b', tokens.Keyword), (r'UNION\s+ALL\b', tokens.Keyword), (r'CREATE(\s+OR\s+REPLACE)?\b', tokens.Keyword.DDL), (r'DOUBLE\s+PRECISION\b', tokens.Name.Builtin), (r'GROUP\s+BY\b', tokens.Keyword), (r'ORDER\s+BY\b', tokens.Keyword), (r'HANDLER\s+FOR\b', tokens.Keyword), (r'(LATERAL\s+VIEW\s+)' r'(EXPLODE|INLINE|PARSE_URL_TUPLE|POSEXPLODE|STACK)\b', tokens.Keyword), (r"(AT|WITH')\s+TIME\s+ZONE\s+'[^']+'", tokens.Keyword.TZCast), (r'(NOT\s+)?(LIKE|ILIKE|RLIKE)\b', tokens.Operator.Comparison), (r'(NOT\s+)?(REGEXP)\b', tokens.Operator.Comparison), # Check for keywords, also returns tokens.Name if regex matches # but the match isn't a keyword. (r'\w[$#\w]*', PROCESS_AS_KEYWORD), (r'[;:()\[\],\.]', tokens.Punctuation), (r'[<>=~!]+', tokens.Operator.Comparison), (r'[+/@#%^&|^-]+', tokens.Operator), ] KEYWORDS = { 'ABORT': tokens.Keyword, 'ABS': tokens.Keyword, 'ABSOLUTE': tokens.Keyword, 'ACCESS': tokens.Keyword, 'ADA': tokens.Keyword, 'ADD': tokens.Keyword, 'ADMIN': tokens.Keyword, 'AFTER': tokens.Keyword, 'AGGREGATE': tokens.Keyword, 'ALIAS': tokens.Keyword, 'ALL': tokens.Keyword, 'ALLOCATE': tokens.Keyword, 'ANALYSE': tokens.Keyword, 'ANALYZE': tokens.Keyword, 'ANY': tokens.Keyword, 'ARRAYLEN': tokens.Keyword, 'ARE': tokens.Keyword, 'ASC': tokens.Keyword.Order, 'ASENSITIVE': tokens.Keyword, 'ASSERTION': tokens.Keyword, 'ASSIGNMENT': tokens.Keyword, 'ASYMMETRIC': tokens.Keyword, 'AT': tokens.Keyword, 'ATOMIC': tokens.Keyword, 'AUDIT': tokens.Keyword, 'AUTHORIZATION': tokens.Keyword, 'AUTO_INCREMENT': tokens.Keyword, 'AVG': tokens.Keyword, 'BACKWARD': tokens.Keyword, 'BEFORE': tokens.Keyword, 'BEGIN': tokens.Keyword, 'BETWEEN': tokens.Keyword, 'BITVAR': tokens.Keyword, 'BIT_LENGTH': tokens.Keyword, 'BOTH': tokens.Keyword, 'BREADTH': tokens.Keyword, # 'C': tokens.Keyword, # most likely this is an alias 'CACHE': tokens.Keyword, 'CALL': tokens.Keyword, 'CALLED': tokens.Keyword, 'CARDINALITY': tokens.Keyword, 'CASCADE': tokens.Keyword, 'CASCADED': tokens.Keyword, 'CAST': tokens.Keyword, 'CATALOG': tokens.Keyword, 'CATALOG_NAME': tokens.Keyword, 'CHAIN': tokens.Keyword, 'CHARACTERISTICS': tokens.Keyword, 'CHARACTER_LENGTH': tokens.Keyword, 'CHARACTER_SET_CATALOG': tokens.Keyword, 'CHARACTER_SET_NAME': tokens.Keyword, 'CHARACTER_SET_SCHEMA': tokens.Keyword, 'CHAR_LENGTH': tokens.Keyword, 'CHARSET': tokens.Keyword, 'CHECK': tokens.Keyword, 'CHECKED': tokens.Keyword, 'CHECKPOINT': tokens.Keyword, 'CLASS': tokens.Keyword, 'CLASS_ORIGIN': tokens.Keyword, 'CLOB': tokens.Keyword, 'CLOSE': tokens.Keyword, 'CLUSTER': tokens.Keyword, 'COALESCE': tokens.Keyword, 'COBOL': tokens.Keyword, 'COLLATE': tokens.Keyword, 'COLLATION': tokens.Keyword, 'COLLATION_CATALOG': tokens.Keyword, 'COLLATION_NAME': tokens.Keyword, 'COLLATION_SCHEMA': tokens.Keyword, 'COLLECT': tokens.Keyword, 'COLUMN': tokens.Keyword, 'COLUMN_NAME': tokens.Keyword, 'COMPRESS': tokens.Keyword, 'COMMAND_FUNCTION': tokens.Keyword, 'COMMAND_FUNCTION_CODE': tokens.Keyword, 'COMMENT': tokens.Keyword, 'COMMIT': tokens.Keyword.DML, 'COMMITTED': tokens.Keyword, 'COMPLETION': tokens.Keyword, 'CONCURRENTLY': tokens.Keyword, 'CONDITION_NUMBER': tokens.Keyword, 'CONNECT': tokens.Keyword, 'CONNECTION': tokens.Keyword, 'CONNECTION_NAME': tokens.Keyword, 'CONSTRAINT': tokens.Keyword, 'CONSTRAINTS': tokens.Keyword, 'CONSTRAINT_CATALOG': tokens.Keyword, 'CONSTRAINT_NAME': tokens.Keyword, 'CONSTRAINT_SCHEMA': tokens.Keyword, 'CONSTRUCTOR': tokens.Keyword, 'CONTAINS': tokens.Keyword, 'CONTINUE': tokens.Keyword, 'CONVERSION': tokens.Keyword, 'CONVERT': tokens.Keyword, 'COPY': tokens.Keyword, 'CORRESPONDING': tokens.Keyword, 'COUNT': tokens.Keyword, 'CREATEDB': tokens.Keyword, 'CREATEUSER': tokens.Keyword, 'CROSS': tokens.Keyword, 'CUBE': tokens.Keyword, 'CURRENT': tokens.Keyword, 'CURRENT_DATE': tokens.Keyword, 'CURRENT_PATH': tokens.Keyword, 'CURRENT_ROLE': tokens.Keyword, 'CURRENT_TIME': tokens.Keyword, 'CURRENT_TIMESTAMP': tokens.Keyword, 'CURRENT_USER': tokens.Keyword, 'CURSOR': tokens.Keyword, 'CURSOR_NAME': tokens.Keyword, 'CYCLE': tokens.Keyword, 'DATA': tokens.Keyword, 'DATABASE': tokens.Keyword, 'DATETIME_INTERVAL_CODE': tokens.Keyword, 'DATETIME_INTERVAL_PRECISION': tokens.Keyword, 'DAY': tokens.Keyword, 'DEALLOCATE': tokens.Keyword, 'DECLARE': tokens.Keyword, 'DEFAULT': tokens.Keyword, 'DEFAULTS': tokens.Keyword, 'DEFERRABLE': tokens.Keyword, 'DEFERRED': tokens.Keyword, 'DEFINED': tokens.Keyword, 'DEFINER': tokens.Keyword, 'DELIMITER': tokens.Keyword, 'DELIMITERS': tokens.Keyword, 'DEREF': tokens.Keyword, 'DESC': tokens.Keyword.Order, 'DESCRIBE': tokens.Keyword, 'DESCRIPTOR': tokens.Keyword, 'DESTROY': tokens.Keyword, 'DESTRUCTOR': tokens.Keyword, 'DETERMINISTIC': tokens.Keyword, 'DIAGNOSTICS': tokens.Keyword, 'DICTIONARY': tokens.Keyword, 'DISABLE': tokens.Keyword, 'DISCONNECT': tokens.Keyword, 'DISPATCH': tokens.Keyword, 'DIV': tokens.Operator, 'DO': tokens.Keyword, 'DOMAIN': tokens.Keyword, 'DYNAMIC': tokens.Keyword, 'DYNAMIC_FUNCTION': tokens.Keyword, 'DYNAMIC_FUNCTION_CODE': tokens.Keyword, 'EACH': tokens.Keyword, 'ENABLE': tokens.Keyword, 'ENCODING': tokens.Keyword, 'ENCRYPTED': tokens.Keyword, 'END-EXEC': tokens.Keyword, 'ENGINE': tokens.Keyword, 'EQUALS': tokens.Keyword, 'ESCAPE': tokens.Keyword, 'EVERY': tokens.Keyword, 'EXCEPT': tokens.Keyword, 'EXCEPTION': tokens.Keyword, 'EXCLUDING': tokens.Keyword, 'EXCLUSIVE': tokens.Keyword, 'EXEC': tokens.Keyword, 'EXECUTE': tokens.Keyword, 'EXISTING': tokens.Keyword, 'EXISTS': tokens.Keyword, 'EXPLAIN': tokens.Keyword, 'EXTERNAL': tokens.Keyword, 'EXTRACT': tokens.Keyword, 'FALSE': tokens.Keyword, 'FETCH': tokens.Keyword, 'FILE': tokens.Keyword, 'FINAL': tokens.Keyword, 'FIRST': tokens.Keyword, 'FORCE': tokens.Keyword, 'FOREACH': tokens.Keyword, 'FOREIGN': tokens.Keyword, 'FORTRAN': tokens.Keyword, 'FORWARD': tokens.Keyword, 'FOUND': tokens.Keyword, 'FREE': tokens.Keyword, 'FREEZE': tokens.Keyword, 'FULL': tokens.Keyword, 'FUNCTION': tokens.Keyword, # 'G': tokens.Keyword, 'GENERAL': tokens.Keyword, 'GENERATED': tokens.Keyword, 'GET': tokens.Keyword, 'GLOBAL': tokens.Keyword, 'GO': tokens.Keyword, 'GOTO': tokens.Keyword, 'GRANT': tokens.Keyword, 'GRANTED': tokens.Keyword, 'GROUPING': tokens.Keyword, 'HAVING': tokens.Keyword, 'HIERARCHY': tokens.Keyword, 'HOLD': tokens.Keyword, 'HOUR': tokens.Keyword, 'HOST': tokens.Keyword, 'IDENTIFIED': tokens.Keyword, 'IDENTITY': tokens.Keyword, 'IGNORE': tokens.Keyword, 'ILIKE': tokens.Keyword, 'IMMEDIATE': tokens.Keyword, 'IMMUTABLE': tokens.Keyword, 'IMPLEMENTATION': tokens.Keyword, 'IMPLICIT': tokens.Keyword, 'INCLUDING': tokens.Keyword, 'INCREMENT': tokens.Keyword, 'INDEX': tokens.Keyword, 'INDICATOR': tokens.Keyword, 'INFIX': tokens.Keyword, 'INHERITS': tokens.Keyword, 'INITIAL': tokens.Keyword, 'INITIALIZE': tokens.Keyword, 'INITIALLY': tokens.Keyword, 'INOUT': tokens.Keyword, 'INPUT': tokens.Keyword, 'INSENSITIVE': tokens.Keyword, 'INSTANTIABLE': tokens.Keyword, 'INSTEAD': tokens.Keyword, 'INTERSECT': tokens.Keyword, 'INTO': tokens.Keyword, 'INVOKER': tokens.Keyword, 'IS': tokens.Keyword, 'ISNULL': tokens.Keyword, 'ISOLATION': tokens.Keyword, 'ITERATE': tokens.Keyword, # 'K': tokens.Keyword, 'KEY': tokens.Keyword, 'KEY_MEMBER': tokens.Keyword, 'KEY_TYPE': tokens.Keyword, 'LANCOMPILER': tokens.Keyword, 'LANGUAGE': tokens.Keyword, 'LARGE': tokens.Keyword, 'LAST': tokens.Keyword, 'LATERAL': tokens.Keyword, 'LEADING': tokens.Keyword, 'LENGTH': tokens.Keyword, 'LESS': tokens.Keyword, 'LEVEL': tokens.Keyword, 'LIMIT': tokens.Keyword, 'LISTEN': tokens.Keyword, 'LOAD': tokens.Keyword, 'LOCAL': tokens.Keyword, 'LOCALTIME': tokens.Keyword, 'LOCALTIMESTAMP': tokens.Keyword, 'LOCATION': tokens.Keyword, 'LOCATOR': tokens.Keyword, 'LOCK': tokens.Keyword, 'LOWER': tokens.Keyword, # 'M': tokens.Keyword, 'MAP': tokens.Keyword, 'MATCH': tokens.Keyword, 'MAXEXTENTS': tokens.Keyword, 'MAXVALUE': tokens.Keyword, 'MESSAGE_LENGTH': tokens.Keyword, 'MESSAGE_OCTET_LENGTH': tokens.Keyword, 'MESSAGE_TEXT': tokens.Keyword, 'METHOD': tokens.Keyword, 'MINUTE': tokens.Keyword, 'MINUS': tokens.Keyword, 'MINVALUE': tokens.Keyword, 'MOD': tokens.Keyword, 'MODE': tokens.Keyword, 'MODIFIES': tokens.Keyword, 'MODIFY': tokens.Keyword, 'MONTH': tokens.Keyword, 'MORE': tokens.Keyword, 'MOVE': tokens.Keyword, 'MUMPS': tokens.Keyword, 'NAMES': tokens.Keyword, 'NATIONAL': tokens.Keyword, 'NATURAL': tokens.Keyword, 'NCHAR': tokens.Keyword, 'NCLOB': tokens.Keyword, 'NEW': tokens.Keyword, 'NEXT': tokens.Keyword, 'NO': tokens.Keyword, 'NOAUDIT': tokens.Keyword, 'NOCOMPRESS': tokens.Keyword, 'NOCREATEDB': tokens.Keyword, 'NOCREATEUSER': tokens.Keyword, 'NONE': tokens.Keyword, 'NOT': tokens.Keyword, 'NOTFOUND': tokens.Keyword, 'NOTHING': tokens.Keyword, 'NOTIFY': tokens.Keyword, 'NOTNULL': tokens.Keyword, 'NOWAIT': tokens.Keyword, 'NULL': tokens.Keyword, 'NULLABLE': tokens.Keyword, 'NULLIF': tokens.Keyword, 'OBJECT': tokens.Keyword, 'OCTET_LENGTH': tokens.Keyword, 'OF': tokens.Keyword, 'OFF': tokens.Keyword, 'OFFLINE': tokens.Keyword, 'OFFSET': tokens.Keyword, 'OIDS': tokens.Keyword, 'OLD': tokens.Keyword, 'ONLINE': tokens.Keyword, 'ONLY': tokens.Keyword, 'OPEN': tokens.Keyword, 'OPERATION': tokens.Keyword, 'OPERATOR': tokens.Keyword, 'OPTION': tokens.Keyword, 'OPTIONS': tokens.Keyword, 'ORDINALITY': tokens.Keyword, 'OUT': tokens.Keyword, 'OUTPUT': tokens.Keyword, 'OVERLAPS': tokens.Keyword, 'OVERLAY': tokens.Keyword, 'OVERRIDING': tokens.Keyword, 'OWNER': tokens.Keyword, 'QUARTER': tokens.Keyword, 'PAD': tokens.Keyword, 'PARAMETER': tokens.Keyword, 'PARAMETERS': tokens.Keyword, 'PARAMETER_MODE': tokens.Keyword, 'PARAMETER_NAME': tokens.Keyword, 'PARAMETER_ORDINAL_POSITION': tokens.Keyword, 'PARAMETER_SPECIFIC_CATALOG': tokens.Keyword, 'PARAMETER_SPECIFIC_NAME': tokens.Keyword, 'PARAMETER_SPECIFIC_SCHEMA': tokens.Keyword, 'PARTIAL': tokens.Keyword, 'PASCAL': tokens.Keyword, 'PCTFREE': tokens.Keyword, 'PENDANT': tokens.Keyword, 'PLACING': tokens.Keyword, 'PLI': tokens.Keyword, 'POSITION': tokens.Keyword, 'POSTFIX': tokens.Keyword, 'PRECISION': tokens.Keyword, 'PREFIX': tokens.Keyword, 'PREORDER': tokens.Keyword, 'PREPARE': tokens.Keyword, 'PRESERVE': tokens.Keyword, 'PRIMARY': tokens.Keyword, 'PRIOR': tokens.Keyword, 'PRIVILEGES': tokens.Keyword, 'PROCEDURAL': tokens.Keyword, 'PROCEDURE': tokens.Keyword, 'PUBLIC': tokens.Keyword, 'RAISE': tokens.Keyword, 'RAW': tokens.Keyword, 'READ': tokens.Keyword, 'READS': tokens.Keyword, 'RECHECK': tokens.Keyword, 'RECURSIVE': tokens.Keyword, 'REF': tokens.Keyword, 'REFERENCES': tokens.Keyword, 'REFERENCING': tokens.Keyword, 'REINDEX': tokens.Keyword, 'RELATIVE': tokens.Keyword, 'RENAME': tokens.Keyword, 'REPEATABLE': tokens.Keyword, 'RESET': tokens.Keyword, 'RESOURCE': tokens.Keyword, 'RESTART': tokens.Keyword, 'RESTRICT': tokens.Keyword, 'RESULT': tokens.Keyword, 'RETURN': tokens.Keyword, 'RETURNED_LENGTH': tokens.Keyword, 'RETURNED_OCTET_LENGTH': tokens.Keyword, 'RETURNED_SQLSTATE': tokens.Keyword, 'RETURNING': tokens.Keyword, 'RETURNS': tokens.Keyword, 'REVOKE': tokens.Keyword, 'RIGHT': tokens.Keyword, 'ROLE': tokens.Keyword, 'ROLLBACK': tokens.Keyword.DML, 'ROLLUP': tokens.Keyword, 'ROUTINE': tokens.Keyword, 'ROUTINE_CATALOG': tokens.Keyword, 'ROUTINE_NAME': tokens.Keyword, 'ROUTINE_SCHEMA': tokens.Keyword, 'ROW': tokens.Keyword, 'ROWS': tokens.Keyword, 'ROW_COUNT': tokens.Keyword, 'RULE': tokens.Keyword, 'SAVE_POINT': tokens.Keyword, 'SCALE': tokens.Keyword, 'SCHEMA': tokens.Keyword, 'SCHEMA_NAME': tokens.Keyword, 'SCOPE': tokens.Keyword, 'SCROLL': tokens.Keyword, 'SEARCH': tokens.Keyword, 'SECOND': tokens.Keyword, 'SECURITY': tokens.Keyword, 'SELF': tokens.Keyword, 'SENSITIVE': tokens.Keyword, 'SEQUENCE': tokens.Keyword, 'SERIALIZABLE': tokens.Keyword, 'SERVER_NAME': tokens.Keyword, 'SESSION': tokens.Keyword, 'SESSION_USER': tokens.Keyword, 'SETOF': tokens.Keyword, 'SETS': tokens.Keyword, 'SHARE': tokens.Keyword, 'SHOW': tokens.Keyword, 'SIMILAR': tokens.Keyword, 'SIMPLE': tokens.Keyword, 'SIZE': tokens.Keyword, 'SOME': tokens.Keyword, 'SOURCE': tokens.Keyword, 'SPACE': tokens.Keyword, 'SPECIFIC': tokens.Keyword, 'SPECIFICTYPE': tokens.Keyword, 'SPECIFIC_NAME': tokens.Keyword, 'SQL': tokens.Keyword, 'SQLBUF': tokens.Keyword, 'SQLCODE': tokens.Keyword, 'SQLERROR': tokens.Keyword, 'SQLEXCEPTION': tokens.Keyword, 'SQLSTATE': tokens.Keyword, 'SQLWARNING': tokens.Keyword, 'STABLE': tokens.Keyword, 'START': tokens.Keyword.DML, # 'STATE': tokens.Keyword, 'STATEMENT': tokens.Keyword, 'STATIC': tokens.Keyword, 'STATISTICS': tokens.Keyword, 'STDIN': tokens.Keyword, 'STDOUT': tokens.Keyword, 'STORAGE': tokens.Keyword, 'STRICT': tokens.Keyword, 'STRUCTURE': tokens.Keyword, 'STYPE': tokens.Keyword, 'SUBCLASS_ORIGIN': tokens.Keyword, 'SUBLIST': tokens.Keyword, 'SUBSTRING': tokens.Keyword, 'SUCCESSFUL': tokens.Keyword, 'SUM': tokens.Keyword, 'SYMMETRIC': tokens.Keyword, 'SYNONYM': tokens.Keyword, 'SYSID': tokens.Keyword, 'SYSTEM': tokens.Keyword, 'SYSTEM_USER': tokens.Keyword, 'TABLE': tokens.Keyword, 'TABLE_NAME': tokens.Keyword, 'TEMP': tokens.Keyword, 'TEMPLATE': tokens.Keyword, 'TEMPORARY': tokens.Keyword, 'TERMINATE': tokens.Keyword, 'THAN': tokens.Keyword, 'TIMESTAMP': tokens.Keyword, 'TIMEZONE_HOUR': tokens.Keyword, 'TIMEZONE_MINUTE': tokens.Keyword, 'TO': tokens.Keyword, 'TOAST': tokens.Keyword, 'TRAILING': tokens.Keyword, 'TRANSATION': tokens.Keyword, 'TRANSACTIONS_COMMITTED': tokens.Keyword, 'TRANSACTIONS_ROLLED_BACK': tokens.Keyword, 'TRANSATION_ACTIVE': tokens.Keyword, 'TRANSFORM': tokens.Keyword, 'TRANSFORMS': tokens.Keyword, 'TRANSLATE': tokens.Keyword, 'TRANSLATION': tokens.Keyword, 'TREAT': tokens.Keyword, 'TRIGGER': tokens.Keyword, 'TRIGGER_CATALOG': tokens.Keyword, 'TRIGGER_NAME': tokens.Keyword, 'TRIGGER_SCHEMA': tokens.Keyword, 'TRIM': tokens.Keyword, 'TRUE': tokens.Keyword, 'TRUNCATE': tokens.Keyword, 'TRUSTED': tokens.Keyword, 'TYPE': tokens.Keyword, 'UID': tokens.Keyword, 'UNCOMMITTED': tokens.Keyword, 'UNDER': tokens.Keyword, 'UNENCRYPTED': tokens.Keyword, 'UNION': tokens.Keyword, 'UNIQUE': tokens.Keyword, 'UNKNOWN': tokens.Keyword, 'UNLISTEN': tokens.Keyword, 'UNNAMED': tokens.Keyword, 'UNNEST': tokens.Keyword, 'UNTIL': tokens.Keyword, 'UPPER': tokens.Keyword, 'USAGE': tokens.Keyword, 'USE': tokens.Keyword, 'USER': tokens.Keyword, 'USER_DEFINED_TYPE_CATALOG': tokens.Keyword, 'USER_DEFINED_TYPE_NAME': tokens.Keyword, 'USER_DEFINED_TYPE_SCHEMA': tokens.Keyword, 'USING': tokens.Keyword, 'VACUUM': tokens.Keyword, 'VALID': tokens.Keyword, 'VALIDATE': tokens.Keyword, 'VALIDATOR': tokens.Keyword, 'VALUES': tokens.Keyword, 'VARIABLE': tokens.Keyword, 'VERBOSE': tokens.Keyword, 'VERSION': tokens.Keyword, 'VIEW': tokens.Keyword, 'VOLATILE': tokens.Keyword, 'WEEK': tokens.Keyword, 'WHENEVER': tokens.Keyword, 'WITH': tokens.Keyword.CTE, 'WITHOUT': tokens.Keyword, 'WORK': tokens.Keyword, 'WRITE': tokens.Keyword, 'YEAR': tokens.Keyword, 'ZONE': tokens.Keyword, # Name.Builtin 'ARRAY': tokens.Name.Builtin, 'BIGINT': tokens.Name.Builtin, 'BINARY': tokens.Name.Builtin, 'BIT': tokens.Name.Builtin, 'BLOB': tokens.Name.Builtin, 'BOOLEAN': tokens.Name.Builtin, 'CHAR': tokens.Name.Builtin, 'CHARACTER': tokens.Name.Builtin, 'DATE': tokens.Name.Builtin, 'DEC': tokens.Name.Builtin, 'DECIMAL': tokens.Name.Builtin, 'FILE_TYPE': tokens.Name.Builtin, 'FLOAT': tokens.Name.Builtin, 'INT': tokens.Name.Builtin, 'INT8': tokens.Name.Builtin, 'INTEGER': tokens.Name.Builtin, 'INTERVAL': tokens.Name.Builtin, 'LONG': tokens.Name.Builtin, 'NATURALN': tokens.Name.Builtin, 'NVARCHAR': tokens.Name.Builtin, 'NUMBER': tokens.Name.Builtin, 'NUMERIC': tokens.Name.Builtin, 'PLS_INTEGER': tokens.Name.Builtin, 'POSITIVE': tokens.Name.Builtin, 'POSITIVEN': tokens.Name.Builtin, 'REAL': tokens.Name.Builtin, 'ROWID': tokens.Name.Builtin, 'ROWLABEL': tokens.Name.Builtin, 'ROWNUM': tokens.Name.Builtin, 'SERIAL': tokens.Name.Builtin, 'SERIAL8': tokens.Name.Builtin, 'SIGNED': tokens.Name.Builtin, 'SIGNTYPE': tokens.Name.Builtin, 'SIMPLE_DOUBLE': tokens.Name.Builtin, 'SIMPLE_FLOAT': tokens.Name.Builtin, 'SIMPLE_INTEGER': tokens.Name.Builtin, 'SMALLINT': tokens.Name.Builtin, 'SYS_REFCURSOR': tokens.Name.Builtin, 'SYSDATE': tokens.Name, 'TEXT': tokens.Name.Builtin, 'TINYINT': tokens.Name.Builtin, 'UNSIGNED': tokens.Name.Builtin, 'UROWID': tokens.Name.Builtin, 'UTL_FILE': tokens.Name.Builtin, 'VARCHAR': tokens.Name.Builtin, 'VARCHAR2': tokens.Name.Builtin, 'VARYING': tokens.Name.Builtin, } KEYWORDS_COMMON = { 'SELECT': tokens.Keyword.DML, 'INSERT': tokens.Keyword.DML, 'DELETE': tokens.Keyword.DML, 'UPDATE': tokens.Keyword.DML, 'UPSERT': tokens.Keyword.DML, 'REPLACE': tokens.Keyword.DML, 'MERGE': tokens.Keyword.DML, 'DROP': tokens.Keyword.DDL, 'CREATE': tokens.Keyword.DDL, 'ALTER': tokens.Keyword.DDL, 'WHERE': tokens.Keyword, 'FROM': tokens.Keyword, 'INNER': tokens.Keyword, 'JOIN': tokens.Keyword, 'STRAIGHT_JOIN': tokens.Keyword, 'AND': tokens.Keyword, 'OR': tokens.Keyword, 'LIKE': tokens.Keyword, 'ON': tokens.Keyword, 'IN': tokens.Keyword, 'SET': tokens.Keyword, 'BY': tokens.Keyword, 'GROUP': tokens.Keyword, 'ORDER': tokens.Keyword, 'LEFT': tokens.Keyword, 'OUTER': tokens.Keyword, 'FULL': tokens.Keyword, 'IF': tokens.Keyword, 'END': tokens.Keyword, 'THEN': tokens.Keyword, 'LOOP': tokens.Keyword, 'AS': tokens.Keyword, 'ELSE': tokens.Keyword, 'FOR': tokens.Keyword, 'WHILE': tokens.Keyword, 'CASE': tokens.Keyword, 'WHEN': tokens.Keyword, 'MIN': tokens.Keyword, 'MAX': tokens.Keyword, 'DISTINCT': tokens.Keyword, } KEYWORDS_ORACLE = { 'ARCHIVE': tokens.Keyword, 'ARCHIVELOG': tokens.Keyword, 'BACKUP': tokens.Keyword, 'BECOME': tokens.Keyword, 'BLOCK': tokens.Keyword, 'BODY': tokens.Keyword, 'CANCEL': tokens.Keyword, 'CHANGE': tokens.Keyword, 'COMPILE': tokens.Keyword, 'CONTENTS': tokens.Keyword, 'CONTROLFILE': tokens.Keyword, 'DATAFILE': tokens.Keyword, 'DBA': tokens.Keyword, 'DISMOUNT': tokens.Keyword, 'DOUBLE': tokens.Keyword, 'DUMP': tokens.Keyword, 'ELSIF': tokens.Keyword, 'EVENTS': tokens.Keyword, 'EXCEPTIONS': tokens.Keyword, 'EXPLAIN': tokens.Keyword, 'EXTENT': tokens.Keyword, 'EXTERNALLY': tokens.Keyword, 'FLUSH': tokens.Keyword, 'FREELIST': tokens.Keyword, 'FREELISTS': tokens.Keyword, # groups seems too common as table name # 'GROUPS': tokens.Keyword, 'INDICATOR': tokens.Keyword, 'INITRANS': tokens.Keyword, 'INSTANCE': tokens.Keyword, 'LAYER': tokens.Keyword, 'LINK': tokens.Keyword, 'LISTS': tokens.Keyword, 'LOGFILE': tokens.Keyword, 'MANAGE': tokens.Keyword, 'MANUAL': tokens.Keyword, 'MAXDATAFILES': tokens.Keyword, 'MAXINSTANCES': tokens.Keyword, 'MAXLOGFILES': tokens.Keyword, 'MAXLOGHISTORY': tokens.Keyword, 'MAXLOGMEMBERS': tokens.Keyword, 'MAXTRANS': tokens.Keyword, 'MINEXTENTS': tokens.Keyword, 'MODULE': tokens.Keyword, 'MOUNT': tokens.Keyword, 'NOARCHIVELOG': tokens.Keyword, 'NOCACHE': tokens.Keyword, 'NOCYCLE': tokens.Keyword, 'NOMAXVALUE': tokens.Keyword, 'NOMINVALUE': tokens.Keyword, 'NOORDER': tokens.Keyword, 'NORESETLOGS': tokens.Keyword, 'NORMAL': tokens.Keyword, 'NOSORT': tokens.Keyword, 'OPTIMAL': tokens.Keyword, 'OWN': tokens.Keyword, 'PACKAGE': tokens.Keyword, 'PARALLEL': tokens.Keyword, 'PCTINCREASE': tokens.Keyword, 'PCTUSED': tokens.Keyword, 'PLAN': tokens.Keyword, 'PRIVATE': tokens.Keyword, 'PROFILE': tokens.Keyword, 'QUOTA': tokens.Keyword, 'RECOVER': tokens.Keyword, 'RESETLOGS': tokens.Keyword, 'RESTRICTED': tokens.Keyword, 'REUSE': tokens.Keyword, 'ROLES': tokens.Keyword, 'SAVEPOINT': tokens.Keyword, 'SCN': tokens.Keyword, 'SECTION': tokens.Keyword, 'SEGMENT': tokens.Keyword, 'SHARED': tokens.Keyword, 'SNAPSHOT': tokens.Keyword, 'SORT': tokens.Keyword, 'STATEMENT_ID': tokens.Keyword, 'STOP': tokens.Keyword, 'SWITCH': tokens.Keyword, 'TABLES': tokens.Keyword, 'TABLESPACE': tokens.Keyword, 'THREAD': tokens.Keyword, 'TIME': tokens.Keyword, 'TRACING': tokens.Keyword, 'TRANSACTION': tokens.Keyword, 'TRIGGERS': tokens.Keyword, 'UNLIMITED': tokens.Keyword, 'UNLOCK': tokens.Keyword, } # PostgreSQL Syntax KEYWORDS_PLPGSQL = { 'CONFLICT': tokens.Keyword, 'WINDOW': tokens.Keyword, 'PARTITION': tokens.Keyword, 'OVER': tokens.Keyword, 'PERFORM': tokens.Keyword, 'NOTICE': tokens.Keyword, 'PLPGSQL': tokens.Keyword, 'INHERIT': tokens.Keyword, 'INDEXES': tokens.Keyword, 'ON_ERROR_STOP': tokens.Keyword, 'BYTEA': tokens.Keyword, 'BIGSERIAL': tokens.Keyword, 'BIT VARYING': tokens.Keyword, 'BOX': tokens.Keyword, 'CHARACTER': tokens.Keyword, 'CHARACTER VARYING': tokens.Keyword, 'CIDR': tokens.Keyword, 'CIRCLE': tokens.Keyword, 'DOUBLE PRECISION': tokens.Keyword, 'INET': tokens.Keyword, 'JSON': tokens.Keyword, 'JSONB': tokens.Keyword, 'LINE': tokens.Keyword, 'LSEG': tokens.Keyword, 'MACADDR': tokens.Keyword, 'MONEY': tokens.Keyword, 'PATH': tokens.Keyword, 'PG_LSN': tokens.Keyword, 'POINT': tokens.Keyword, 'POLYGON': tokens.Keyword, 'SMALLSERIAL': tokens.Keyword, 'TSQUERY': tokens.Keyword, 'TSVECTOR': tokens.Keyword, 'TXID_SNAPSHOT': tokens.Keyword, 'UUID': tokens.Keyword, 'XML': tokens.Keyword, 'FOR': tokens.Keyword, 'IN': tokens.Keyword, 'LOOP': tokens.Keyword, } # Hive Syntax KEYWORDS_HQL = { 'EXPLODE': tokens.Keyword, 'DIRECTORY': tokens.Keyword, 'DISTRIBUTE': tokens.Keyword, 'INCLUDE': tokens.Keyword, 'LOCATE': tokens.Keyword, 'OVERWRITE': tokens.Keyword, 'POSEXPLODE': tokens.Keyword, 'ARRAY_CONTAINS': tokens.Keyword, 'CMP': tokens.Keyword, 'COLLECT_LIST': tokens.Keyword, 'CONCAT': tokens.Keyword, 'CONDITION': tokens.Keyword, 'DATE_ADD': tokens.Keyword, 'DATE_SUB': tokens.Keyword, 'DECODE': tokens.Keyword, 'DBMS_OUTPUT': tokens.Keyword, 'ELEMENTS': tokens.Keyword, 'EXCHANGE': tokens.Keyword, 'EXTENDED': tokens.Keyword, 'FLOOR': tokens.Keyword, 'FOLLOWING': tokens.Keyword, 'FROM_UNIXTIME': tokens.Keyword, 'FTP': tokens.Keyword, 'HOUR': tokens.Keyword, 'INLINE': tokens.Keyword, 'INSTR': tokens.Keyword, 'LEN': tokens.Keyword, 'MAP': tokens.Name.Builtin, 'MAXELEMENT': tokens.Keyword, 'MAXINDEX': tokens.Keyword, 'MAX_PART_DATE': tokens.Keyword, 'MAX_PART_INT': tokens.Keyword, 'MAX_PART_STRING': tokens.Keyword, 'MINELEMENT': tokens.Keyword, 'MININDEX': tokens.Keyword, 'MIN_PART_DATE': tokens.Keyword, 'MIN_PART_INT': tokens.Keyword, 'MIN_PART_STRING': tokens.Keyword, 'NOW': tokens.Keyword, 'NVL': tokens.Keyword, 'NVL2': tokens.Keyword, 'PARSE_URL_TUPLE': tokens.Keyword, 'PART_LOC': tokens.Keyword, 'PART_COUNT': tokens.Keyword, 'PART_COUNT_BY': tokens.Keyword, 'PRINT': tokens.Keyword, 'PUT_LINE': tokens.Keyword, 'RANGE': tokens.Keyword, 'REDUCE': tokens.Keyword, 'REGEXP_REPLACE': tokens.Keyword, 'RESIGNAL': tokens.Keyword, 'RTRIM': tokens.Keyword, 'SIGN': tokens.Keyword, 'SIGNAL': tokens.Keyword, 'SIN': tokens.Keyword, 'SPLIT': tokens.Keyword, 'SQRT': tokens.Keyword, 'STACK': tokens.Keyword, 'STR': tokens.Keyword, 'STRING': tokens.Name.Builtin, 'STRUCT': tokens.Name.Builtin, 'SUBSTR': tokens.Keyword, 'SUMMARY': tokens.Keyword, 'TBLPROPERTIES': tokens.Keyword, 'TIMESTAMP': tokens.Name.Builtin, 'TIMESTAMP_ISO': tokens.Keyword, 'TO_CHAR': tokens.Keyword, 'TO_DATE': tokens.Keyword, 'TO_TIMESTAMP': tokens.Keyword, 'TRUNC': tokens.Keyword, 'UNBOUNDED': tokens.Keyword, 'UNIQUEJOIN': tokens.Keyword, 'UNIX_TIMESTAMP': tokens.Keyword, 'UTC_TIMESTAMP': tokens.Keyword, 'VIEWS': tokens.Keyword, 'EXIT': tokens.Keyword, 'BREAK': tokens.Keyword, 'LEAVE': tokens.Keyword, } KEYWORDS_MSACCESS = { 'DISTINCTROW': tokens.Keyword, }
castiel248/Convert
Lib/site-packages/sqlparse/keywords.py
Python
mit
29,445
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """SQL Lexer""" import re # This code is based on the SqlLexer in pygments. # http://pygments.org/ # It's separated from the rest of pygments to increase performance # and to allow some customizations. from io import TextIOBase from sqlparse import tokens, keywords from sqlparse.utils import consume class Lexer: """The Lexer supports configurable syntax. To add support for additional keywords, use the `add_keywords` method.""" _default_intance = None # Development notes: # - This class is prepared to be able to support additional SQL dialects # in the future by adding additional functions that take the place of # the function default_initialization() # - The lexer class uses an explicit singleton behavior with the # instance-getter method get_default_instance(). This mechanism has # the advantage that the call signature of the entry-points to the # sqlparse library are not affected. Also, usage of sqlparse in third # party code does not need to be adapted. On the other hand, singleton # behavior is not thread safe, and the current implementation does not # easily allow for multiple SQL dialects to be parsed in the same # process. Such behavior can be supported in the future by passing a # suitably initialized lexer object as an additional parameter to the # entry-point functions (such as `parse`). Code will need to be written # to pass down and utilize such an object. The current implementation # is prepared to support this thread safe approach without the # default_instance part needing to change interface. @classmethod def get_default_instance(cls): """Returns the lexer instance used internally by the sqlparse core functions.""" if cls._default_intance is None: cls._default_intance = cls() cls._default_intance.default_initialization() return cls._default_intance def default_initialization(self): """Initialize the lexer with default dictionaries. Useful if you need to revert custom syntax settings.""" self.clear() self.set_SQL_REGEX(keywords.SQL_REGEX) self.add_keywords(keywords.KEYWORDS_COMMON) self.add_keywords(keywords.KEYWORDS_ORACLE) self.add_keywords(keywords.KEYWORDS_PLPGSQL) self.add_keywords(keywords.KEYWORDS_HQL) self.add_keywords(keywords.KEYWORDS_MSACCESS) self.add_keywords(keywords.KEYWORDS) def clear(self): """Clear all syntax configurations. Useful if you want to load a reduced set of syntax configurations. After this call, regexps and keyword dictionaries need to be loaded to make the lexer functional again.""" self._SQL_REGEX = [] self._keywords = [] def set_SQL_REGEX(self, SQL_REGEX): """Set the list of regex that will parse the SQL.""" FLAGS = re.IGNORECASE | re.UNICODE self._SQL_REGEX = [ (re.compile(rx, FLAGS).match, tt) for rx, tt in SQL_REGEX ] def add_keywords(self, keywords): """Add keyword dictionaries. Keywords are looked up in the same order that dictionaries were added.""" self._keywords.append(keywords) def is_keyword(self, value): """Checks for a keyword. If the given value is in one of the KEYWORDS_* dictionary it's considered a keyword. Otherwise, tokens.Name is returned. """ val = value.upper() for kwdict in self._keywords: if val in kwdict: return kwdict[val], value else: return tokens.Name, value def get_tokens(self, text, encoding=None): """ Return an iterable of (tokentype, value) pairs generated from `text`. If `unfiltered` is set to `True`, the filtering mechanism is bypassed even if filters are defined. Also preprocess the text, i.e. expand tabs and strip it if wanted and applies registered filters. Split ``text`` into (tokentype, text) pairs. ``stack`` is the initial stack (default: ``['root']``) """ if isinstance(text, TextIOBase): text = text.read() if isinstance(text, str): pass elif isinstance(text, bytes): if encoding: text = text.decode(encoding) else: try: text = text.decode('utf-8') except UnicodeDecodeError: text = text.decode('unicode-escape') else: raise TypeError("Expected text or file-like object, got {!r}". format(type(text))) iterable = enumerate(text) for pos, char in iterable: for rexmatch, action in self._SQL_REGEX: m = rexmatch(text, pos) if not m: continue elif isinstance(action, tokens._TokenType): yield action, m.group() elif action is keywords.PROCESS_AS_KEYWORD: yield self.is_keyword(m.group()) consume(iterable, m.end() - pos - 1) break else: yield tokens.Error, char def tokenize(sql, encoding=None): """Tokenize sql. Tokenize *sql* using the :class:`Lexer` and return a 2-tuple stream of ``(token type, value)`` items. """ return Lexer.get_default_instance().get_tokens(sql, encoding)
castiel248/Convert
Lib/site-packages/sqlparse/lexer.py
Python
mit
5,786
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause """This module contains classes representing syntactical elements of SQL.""" import re from sqlparse import tokens as T from sqlparse.utils import imt, remove_quotes class NameAliasMixin: """Implements get_real_name and get_alias.""" def get_real_name(self): """Returns the real name (object name) of this identifier.""" # a.b dot_idx, _ = self.token_next_by(m=(T.Punctuation, '.')) return self._get_first_name(dot_idx, real_name=True) def get_alias(self): """Returns the alias for this identifier or ``None``.""" # "name AS alias" kw_idx, kw = self.token_next_by(m=(T.Keyword, 'AS')) if kw is not None: return self._get_first_name(kw_idx + 1, keywords=True) # "name alias" or "complicated column expression alias" _, ws = self.token_next_by(t=T.Whitespace) if len(self.tokens) > 2 and ws is not None: return self._get_first_name(reverse=True) class Token: """Base class for all other classes in this module. It represents a single token and has two instance attributes: ``value`` is the unchanged value of the token and ``ttype`` is the type of the token. """ __slots__ = ('value', 'ttype', 'parent', 'normalized', 'is_keyword', 'is_group', 'is_whitespace') def __init__(self, ttype, value): value = str(value) self.value = value self.ttype = ttype self.parent = None self.is_group = False self.is_keyword = ttype in T.Keyword self.is_whitespace = self.ttype in T.Whitespace self.normalized = value.upper() if self.is_keyword else value def __str__(self): return self.value # Pending tokenlist __len__ bug fix # def __len__(self): # return len(self.value) def __repr__(self): cls = self._get_repr_name() value = self._get_repr_value() q = '"' if value.startswith("'") and value.endswith("'") else "'" return "<{cls} {q}{value}{q} at 0x{id:2X}>".format( id=id(self), **locals()) def _get_repr_name(self): return str(self.ttype).split('.')[-1] def _get_repr_value(self): raw = str(self) if len(raw) > 7: raw = raw[:6] + '...' return re.sub(r'\s+', ' ', raw) def flatten(self): """Resolve subgroups.""" yield self def match(self, ttype, values, regex=False): """Checks whether the token matches the given arguments. *ttype* is a token type. If this token doesn't match the given token type. *values* is a list of possible values for this token. The values are OR'ed together so if only one of the values matches ``True`` is returned. Except for keyword tokens the comparison is case-sensitive. For convenience it's OK to pass in a single string. If *regex* is ``True`` (default is ``False``) the given values are treated as regular expressions. """ type_matched = self.ttype is ttype if not type_matched or values is None: return type_matched if isinstance(values, str): values = (values,) if regex: # TODO: Add test for regex with is_keyboard = false flag = re.IGNORECASE if self.is_keyword else 0 values = (re.compile(v, flag) for v in values) for pattern in values: if pattern.search(self.normalized): return True return False if self.is_keyword: values = (v.upper() for v in values) return self.normalized in values def within(self, group_cls): """Returns ``True`` if this token is within *group_cls*. Use this method for example to check if an identifier is within a function: ``t.within(sql.Function)``. """ parent = self.parent while parent: if isinstance(parent, group_cls): return True parent = parent.parent return False def is_child_of(self, other): """Returns ``True`` if this token is a direct child of *other*.""" return self.parent == other def has_ancestor(self, other): """Returns ``True`` if *other* is in this tokens ancestry.""" parent = self.parent while parent: if parent == other: return True parent = parent.parent return False class TokenList(Token): """A group of tokens. It has an additional instance attribute ``tokens`` which holds a list of child-tokens. """ __slots__ = 'tokens' def __init__(self, tokens=None): self.tokens = tokens or [] [setattr(token, 'parent', self) for token in self.tokens] super().__init__(None, str(self)) self.is_group = True def __str__(self): return ''.join(token.value for token in self.flatten()) # weird bug # def __len__(self): # return len(self.tokens) def __iter__(self): return iter(self.tokens) def __getitem__(self, item): return self.tokens[item] def _get_repr_name(self): return type(self).__name__ def _pprint_tree(self, max_depth=None, depth=0, f=None, _pre=''): """Pretty-print the object tree.""" token_count = len(self.tokens) for idx, token in enumerate(self.tokens): cls = token._get_repr_name() value = token._get_repr_value() last = idx == (token_count - 1) pre = '`- ' if last else '|- ' q = '"' if value.startswith("'") and value.endswith("'") else "'" print("{_pre}{pre}{idx} {cls} {q}{value}{q}" .format(**locals()), file=f) if token.is_group and (max_depth is None or depth < max_depth): parent_pre = ' ' if last else '| ' token._pprint_tree(max_depth, depth + 1, f, _pre + parent_pre) def get_token_at_offset(self, offset): """Returns the token that is on position offset.""" idx = 0 for token in self.flatten(): end = idx + len(token.value) if idx <= offset < end: return token idx = end def flatten(self): """Generator yielding ungrouped tokens. This method is recursively called for all child tokens. """ for token in self.tokens: if token.is_group: yield from token.flatten() else: yield token def get_sublists(self): for token in self.tokens: if token.is_group: yield token @property def _groupable_tokens(self): return self.tokens def _token_matching(self, funcs, start=0, end=None, reverse=False): """next token that match functions""" if start is None: return None if not isinstance(funcs, (list, tuple)): funcs = (funcs,) if reverse: assert end is None indexes = range(start - 2, -1, -1) else: if end is None: end = len(self.tokens) indexes = range(start, end) for idx in indexes: token = self.tokens[idx] for func in funcs: if func(token): return idx, token return None, None def token_first(self, skip_ws=True, skip_cm=False): """Returns the first child token. If *skip_ws* is ``True`` (the default), whitespace tokens are ignored. if *skip_cm* is ``True`` (default: ``False``), comments are ignored too. """ # this on is inconsistent, using Comment instead of T.Comment... def matcher(tk): return not ((skip_ws and tk.is_whitespace) or (skip_cm and imt(tk, t=T.Comment, i=Comment))) return self._token_matching(matcher)[1] def token_next_by(self, i=None, m=None, t=None, idx=-1, end=None): idx += 1 return self._token_matching(lambda tk: imt(tk, i, m, t), idx, end) def token_not_matching(self, funcs, idx): funcs = (funcs,) if not isinstance(funcs, (list, tuple)) else funcs funcs = [lambda tk: not func(tk) for func in funcs] return self._token_matching(funcs, idx) def token_matching(self, funcs, idx): return self._token_matching(funcs, idx)[1] def token_prev(self, idx, skip_ws=True, skip_cm=False): """Returns the previous token relative to *idx*. If *skip_ws* is ``True`` (the default) whitespace tokens are ignored. If *skip_cm* is ``True`` comments are ignored. ``None`` is returned if there's no previous token. """ return self.token_next(idx, skip_ws, skip_cm, _reverse=True) # TODO: May need to re-add default value to idx def token_next(self, idx, skip_ws=True, skip_cm=False, _reverse=False): """Returns the next token relative to *idx*. If *skip_ws* is ``True`` (the default) whitespace tokens are ignored. If *skip_cm* is ``True`` comments are ignored. ``None`` is returned if there's no next token. """ if idx is None: return None, None idx += 1 # alot of code usage current pre-compensates for this def matcher(tk): return not ((skip_ws and tk.is_whitespace) or (skip_cm and imt(tk, t=T.Comment, i=Comment))) return self._token_matching(matcher, idx, reverse=_reverse) def token_index(self, token, start=0): """Return list index of token.""" start = start if isinstance(start, int) else self.token_index(start) return start + self.tokens[start:].index(token) def group_tokens(self, grp_cls, start, end, include_end=True, extend=False): """Replace tokens by an instance of *grp_cls*.""" start_idx = start start = self.tokens[start_idx] end_idx = end + include_end # will be needed later for new group_clauses # while skip_ws and tokens and tokens[-1].is_whitespace: # tokens = tokens[:-1] if extend and isinstance(start, grp_cls): subtokens = self.tokens[start_idx + 1:end_idx] grp = start grp.tokens.extend(subtokens) del self.tokens[start_idx + 1:end_idx] grp.value = str(start) else: subtokens = self.tokens[start_idx:end_idx] grp = grp_cls(subtokens) self.tokens[start_idx:end_idx] = [grp] grp.parent = self for token in subtokens: token.parent = grp return grp def insert_before(self, where, token): """Inserts *token* before *where*.""" if not isinstance(where, int): where = self.token_index(where) token.parent = self self.tokens.insert(where, token) def insert_after(self, where, token, skip_ws=True): """Inserts *token* after *where*.""" if not isinstance(where, int): where = self.token_index(where) nidx, next_ = self.token_next(where, skip_ws=skip_ws) token.parent = self if next_ is None: self.tokens.append(token) else: self.tokens.insert(nidx, token) def has_alias(self): """Returns ``True`` if an alias is present.""" return self.get_alias() is not None def get_alias(self): """Returns the alias for this identifier or ``None``.""" return None def get_name(self): """Returns the name of this identifier. This is either it's alias or it's real name. The returned valued can be considered as the name under which the object corresponding to this identifier is known within the current statement. """ return self.get_alias() or self.get_real_name() def get_real_name(self): """Returns the real name (object name) of this identifier.""" return None def get_parent_name(self): """Return name of the parent object if any. A parent object is identified by the first occurring dot. """ dot_idx, _ = self.token_next_by(m=(T.Punctuation, '.')) _, prev_ = self.token_prev(dot_idx) return remove_quotes(prev_.value) if prev_ is not None else None def _get_first_name(self, idx=None, reverse=False, keywords=False, real_name=False): """Returns the name of the first token with a name""" tokens = self.tokens[idx:] if idx else self.tokens tokens = reversed(tokens) if reverse else tokens types = [T.Name, T.Wildcard, T.String.Symbol] if keywords: types.append(T.Keyword) for token in tokens: if token.ttype in types: return remove_quotes(token.value) elif isinstance(token, (Identifier, Function)): return token.get_real_name() if real_name else token.get_name() class Statement(TokenList): """Represents a SQL statement.""" def get_type(self): """Returns the type of a statement. The returned value is a string holding an upper-cased reprint of the first DML or DDL keyword. If the first token in this group isn't a DML or DDL keyword "UNKNOWN" is returned. Whitespaces and comments at the beginning of the statement are ignored. """ token = self.token_first(skip_cm=True) if token is None: # An "empty" statement that either has not tokens at all # or only whitespace tokens. return 'UNKNOWN' elif token.ttype in (T.Keyword.DML, T.Keyword.DDL): return token.normalized elif token.ttype == T.Keyword.CTE: # The WITH keyword should be followed by either an Identifier or # an IdentifierList containing the CTE definitions; the actual # DML keyword (e.g. SELECT, INSERT) will follow next. tidx = self.token_index(token) while tidx is not None: tidx, token = self.token_next(tidx, skip_ws=True) if isinstance(token, (Identifier, IdentifierList)): tidx, token = self.token_next(tidx, skip_ws=True) if token is not None \ and token.ttype == T.Keyword.DML: return token.normalized # Hmm, probably invalid syntax, so return unknown. return 'UNKNOWN' class Identifier(NameAliasMixin, TokenList): """Represents an identifier. Identifiers may have aliases or typecasts. """ def is_wildcard(self): """Return ``True`` if this identifier contains a wildcard.""" _, token = self.token_next_by(t=T.Wildcard) return token is not None def get_typecast(self): """Returns the typecast or ``None`` of this object as a string.""" midx, marker = self.token_next_by(m=(T.Punctuation, '::')) nidx, next_ = self.token_next(midx, skip_ws=False) return next_.value if next_ else None def get_ordering(self): """Returns the ordering or ``None`` as uppercase string.""" _, ordering = self.token_next_by(t=T.Keyword.Order) return ordering.normalized if ordering else None def get_array_indices(self): """Returns an iterator of index token lists""" for token in self.tokens: if isinstance(token, SquareBrackets): # Use [1:-1] index to discard the square brackets yield token.tokens[1:-1] class IdentifierList(TokenList): """A list of :class:`~sqlparse.sql.Identifier`\'s.""" def get_identifiers(self): """Returns the identifiers. Whitespaces and punctuations are not included in this generator. """ for token in self.tokens: if not (token.is_whitespace or token.match(T.Punctuation, ',')): yield token class TypedLiteral(TokenList): """A typed literal, such as "date '2001-09-28'" or "interval '2 hours'".""" M_OPEN = [(T.Name.Builtin, None), (T.Keyword, "TIMESTAMP")] M_CLOSE = T.String.Single, None M_EXTEND = T.Keyword, ("DAY", "HOUR", "MINUTE", "MONTH", "SECOND", "YEAR") class Parenthesis(TokenList): """Tokens between parenthesis.""" M_OPEN = T.Punctuation, '(' M_CLOSE = T.Punctuation, ')' @property def _groupable_tokens(self): return self.tokens[1:-1] class SquareBrackets(TokenList): """Tokens between square brackets""" M_OPEN = T.Punctuation, '[' M_CLOSE = T.Punctuation, ']' @property def _groupable_tokens(self): return self.tokens[1:-1] class Assignment(TokenList): """An assignment like 'var := val;'""" class If(TokenList): """An 'if' clause with possible 'else if' or 'else' parts.""" M_OPEN = T.Keyword, 'IF' M_CLOSE = T.Keyword, 'END IF' class For(TokenList): """A 'FOR' loop.""" M_OPEN = T.Keyword, ('FOR', 'FOREACH') M_CLOSE = T.Keyword, 'END LOOP' class Comparison(TokenList): """A comparison used for example in WHERE clauses.""" @property def left(self): return self.tokens[0] @property def right(self): return self.tokens[-1] class Comment(TokenList): """A comment.""" def is_multiline(self): return self.tokens and self.tokens[0].ttype == T.Comment.Multiline class Where(TokenList): """A WHERE clause.""" M_OPEN = T.Keyword, 'WHERE' M_CLOSE = T.Keyword, ( 'ORDER BY', 'GROUP BY', 'LIMIT', 'UNION', 'UNION ALL', 'EXCEPT', 'HAVING', 'RETURNING', 'INTO') class Having(TokenList): """A HAVING clause.""" M_OPEN = T.Keyword, 'HAVING' M_CLOSE = T.Keyword, ('ORDER BY', 'LIMIT') class Case(TokenList): """A CASE statement with one or more WHEN and possibly an ELSE part.""" M_OPEN = T.Keyword, 'CASE' M_CLOSE = T.Keyword, 'END' def get_cases(self, skip_ws=False): """Returns a list of 2-tuples (condition, value). If an ELSE exists condition is None. """ CONDITION = 1 VALUE = 2 ret = [] mode = CONDITION for token in self.tokens: # Set mode from the current statement if token.match(T.Keyword, 'CASE'): continue elif skip_ws and token.ttype in T.Whitespace: continue elif token.match(T.Keyword, 'WHEN'): ret.append(([], [])) mode = CONDITION elif token.match(T.Keyword, 'THEN'): mode = VALUE elif token.match(T.Keyword, 'ELSE'): ret.append((None, [])) mode = VALUE elif token.match(T.Keyword, 'END'): mode = None # First condition without preceding WHEN if mode and not ret: ret.append(([], [])) # Append token depending of the current mode if mode == CONDITION: ret[-1][0].append(token) elif mode == VALUE: ret[-1][1].append(token) # Return cases list return ret class Function(NameAliasMixin, TokenList): """A function or procedure call.""" def get_parameters(self): """Return a list of parameters.""" parenthesis = self.tokens[-1] for token in parenthesis.tokens: if isinstance(token, IdentifierList): return token.get_identifiers() elif imt(token, i=(Function, Identifier), t=T.Literal): return [token, ] return [] class Begin(TokenList): """A BEGIN/END block.""" M_OPEN = T.Keyword, 'BEGIN' M_CLOSE = T.Keyword, 'END' class Operation(TokenList): """Grouping of operations""" class Values(TokenList): """Grouping of values""" class Command(TokenList): """Grouping of CLI commands."""
castiel248/Convert
Lib/site-packages/sqlparse/sql.py
Python
mit
20,401
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause # # The Token implementation is based on pygment's token system written # by Georg Brandl. # http://pygments.org/ """Tokens""" class _TokenType(tuple): parent = None def __contains__(self, item): return item is not None and (self is item or item[:len(self)] == self) def __getattr__(self, name): new = _TokenType(self + (name,)) setattr(self, name, new) new.parent = self return new def __repr__(self): # self can be False only if its the `root` i.e. Token itself return 'Token' + ('.' if self else '') + '.'.join(self) Token = _TokenType() # Special token types Text = Token.Text Whitespace = Text.Whitespace Newline = Whitespace.Newline Error = Token.Error # Text that doesn't belong to this lexer (e.g. HTML in PHP) Other = Token.Other # Common token types for source code Keyword = Token.Keyword Name = Token.Name Literal = Token.Literal String = Literal.String Number = Literal.Number Punctuation = Token.Punctuation Operator = Token.Operator Comparison = Operator.Comparison Wildcard = Token.Wildcard Comment = Token.Comment Assignment = Token.Assignment # Generic types for non-source code Generic = Token.Generic Command = Generic.Command # String and some others are not direct children of Token. # alias them: Token.Token = Token Token.String = String Token.Number = Number # SQL specific tokens DML = Keyword.DML DDL = Keyword.DDL CTE = Keyword.CTE
castiel248/Convert
Lib/site-packages/sqlparse/tokens.py
Python
mit
1,661
# # Copyright (C) 2009-2020 the sqlparse authors and contributors # <see AUTHORS file> # # This module is part of python-sqlparse and is released under # the BSD License: https://opensource.org/licenses/BSD-3-Clause import itertools import re from collections import deque from contextlib import contextmanager # This regular expression replaces the home-cooked parser that was here before. # It is much faster, but requires an extra post-processing step to get the # desired results (that are compatible with what you would expect from the # str.splitlines() method). # # It matches groups of characters: newlines, quoted strings, or unquoted text, # and splits on that basis. The post-processing step puts those back together # into the actual lines of SQL. SPLIT_REGEX = re.compile(r""" ( (?: # Start of non-capturing group (?:\r\n|\r|\n) | # Match any single newline, or [^\r\n'"]+ | # Match any character series without quotes or # newlines, or "(?:[^"\\]|\\.)*" | # Match double-quoted strings, or '(?:[^'\\]|\\.)*' # Match single quoted strings ) ) """, re.VERBOSE) LINE_MATCH = re.compile(r'(\r\n|\r|\n)') def split_unquoted_newlines(stmt): """Split a string on all unquoted newlines. Unlike str.splitlines(), this will ignore CR/LF/CR+LF if the requisite character is inside of a string.""" text = str(stmt) lines = SPLIT_REGEX.split(text) outputlines = [''] for line in lines: if not line: continue elif LINE_MATCH.match(line): outputlines.append('') else: outputlines[-1] += line return outputlines def remove_quotes(val): """Helper that removes surrounding quotes from strings.""" if val is None: return if val[0] in ('"', "'", '`') and val[0] == val[-1]: val = val[1:-1] return val def recurse(*cls): """Function decorator to help with recursion :param cls: Classes to not recurse over :return: function """ def wrap(f): def wrapped_f(tlist): for sgroup in tlist.get_sublists(): if not isinstance(sgroup, cls): wrapped_f(sgroup) f(tlist) return wrapped_f return wrap def imt(token, i=None, m=None, t=None): """Helper function to simplify comparisons Instance, Match and TokenType :param token: :param i: Class or Tuple/List of Classes :param m: Tuple of TokenType & Value. Can be list of Tuple for multiple :param t: TokenType or Tuple/List of TokenTypes :return: bool """ clss = i types = [t, ] if t and not isinstance(t, list) else t mpatterns = [m, ] if m and not isinstance(m, list) else m if token is None: return False elif clss and isinstance(token, clss): return True elif mpatterns and any(token.match(*pattern) for pattern in mpatterns): return True elif types and any(token.ttype in ttype for ttype in types): return True else: return False def consume(iterator, n): """Advance the iterator n-steps ahead. If n is none, consume entirely.""" deque(itertools.islice(iterator, n), maxlen=0) @contextmanager def offset(filter_, n=0): filter_.offset += n yield filter_.offset -= n @contextmanager def indent(filter_, n=1): filter_.indent += n yield filter_.indent -= n
castiel248/Convert
Lib/site-packages/sqlparse/utils.py
Python
mit
3,446
pip
castiel248/Convert
Lib/site-packages/tzdata-2023.3.dist-info/INSTALLER
none
mit
4
Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
castiel248/Convert
Lib/site-packages/tzdata-2023.3.dist-info/LICENSE_APACHE
none
mit
11,357
Metadata-Version: 2.1 Name: tzdata Version: 2023.3 Summary: Provider of IANA time zone data Home-page: https://github.com/python/tzdata Author: Python Software Foundation Author-email: datetime-sig@python.org License: Apache-2.0 Project-URL: Bug Reports, https://github.com/python/tzdata/issues Project-URL: Source, https://github.com/python/tzdata Project-URL: Documentation, https://tzdata.readthedocs.io Classifier: Development Status :: 4 - Beta Classifier: Intended Audience :: Developers Classifier: License :: OSI Approved :: Apache Software License Classifier: Programming Language :: Python :: 2 Classifier: Programming Language :: Python :: 3 Requires-Python: >=2 Description-Content-Type: text/x-rst License-File: LICENSE License-File: licenses/LICENSE_APACHE tzdata: Python package providing IANA time zone data ==================================================== This is a Python package containing ``zic``-compiled binaries for the IANA time zone database. It is intended to be a fallback for systems that do not have system time zone data installed (or don't have it installed in a standard location), as a part of `PEP 615 <https://www.python.org/dev/peps/pep-0615/>`_ This repository generates a ``pip``-installable package, published on PyPI as `tzdata <https://pypi.org/project/tzdata>`_. For more information, see `the documentation <https://tzdata.readthedocs.io>`_.
castiel248/Convert
Lib/site-packages/tzdata-2023.3.dist-info/METADATA
none
mit
1,393
tzdata-2023.3.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 tzdata-2023.3.dist-info/LICENSE,sha256=M-jlAC01EtP8wigrmV5rrZ0zR4G5xawxhD9ASQDh87Q,592 tzdata-2023.3.dist-info/LICENSE_APACHE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357 tzdata-2023.3.dist-info/METADATA,sha256=BB4RrjGT8Mtn6W63QcGEsYZDsAbbJqh3YitWV7hhZ78,1393 tzdata-2023.3.dist-info/RECORD,, tzdata-2023.3.dist-info/WHEEL,sha256=a-zpFRIJzOq5QfuhBzbhiA1eHTzNCJn8OdRvhdNX0Rk,110 tzdata-2023.3.dist-info/top_level.txt,sha256=MO6QqC0xRrN67Gh9xU_nMmadwBVlYzPNkq_h4gYuzaQ,7 tzdata/__init__.py,sha256=ejUiZSlnEtFPRNzBFzUfXL0fHDenin8X5DEKhw09rYU,252 tzdata/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Africa/Abidjan,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Accra,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Addis_Ababa,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Algiers,sha256=L2nS4gLNFvuo89p3YtB-lSDYY2284SqkGH9pQQI8uwc,470 tzdata/zoneinfo/Africa/Asmara,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Asmera,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Bamako,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Bangui,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Banjul,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Bissau,sha256=wa3uva129dJHRCi7tYt04kFOn1-osMS2afMjleO9mDw,149 tzdata/zoneinfo/Africa/Blantyre,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Brazzaville,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Bujumbura,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Cairo,sha256=icuaNiEvuC6TPc2fqhDv36lpop7IDDIGO7tFGMAz0b4,1309 tzdata/zoneinfo/Africa/Casablanca,sha256=MMps8T4AwqbEN6PIN_pkNiPMBEBqtRZRZceLN-9rxMM,1919 tzdata/zoneinfo/Africa/Ceuta,sha256=oEIgK53afz1SYxYB_D0jR98Ss3g581yb8TnLppPaYcY,562 tzdata/zoneinfo/Africa/Conakry,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Dakar,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Dar_es_Salaam,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Djibouti,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Douala,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/El_Aaiun,sha256=6hfLbLfrD1Qy9ZZqLXr1Xw7fzeEs_FqeHN2zZJZUVJI,1830 tzdata/zoneinfo/Africa/Freetown,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Gaborone,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Harare,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Johannesburg,sha256=0Zrr4kNcToS_euZVM9I6nUQPmBYuW01pxz94PgIpnsg,190 tzdata/zoneinfo/Africa/Juba,sha256=VTpoMAP-jJ6cKsDeNVr7l3LKGoKDUxGU2b1gqvDPz34,458 tzdata/zoneinfo/Africa/Kampala,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Khartoum,sha256=NRwOwIg4SR6XuD11k3hxBz77uoBpzejXq7vxtq2Xys8,458 tzdata/zoneinfo/Africa/Kigali,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Kinshasa,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Lagos,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Libreville,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Lome,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Luanda,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Lubumbashi,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Lusaka,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Malabo,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Maputo,sha256=_UqXNoIwqJZ2yYd3lRCpkg_o2RH6BlSBU20QSM0PUp4,131 tzdata/zoneinfo/Africa/Maseru,sha256=0Zrr4kNcToS_euZVM9I6nUQPmBYuW01pxz94PgIpnsg,190 tzdata/zoneinfo/Africa/Mbabane,sha256=0Zrr4kNcToS_euZVM9I6nUQPmBYuW01pxz94PgIpnsg,190 tzdata/zoneinfo/Africa/Mogadishu,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Monrovia,sha256=WM-JVfr502Vgy18Fe6iAJ2yMgOWbwwumIQh_yp53eKM,164 tzdata/zoneinfo/Africa/Nairobi,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Africa/Ndjamena,sha256=Tlj4ZUUNJxEhvAoo7TJKqWv1J7tEYaf1FEMez-K9xEg,160 tzdata/zoneinfo/Africa/Niamey,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Nouakchott,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Ouagadougou,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Porto-Novo,sha256=5e8SiFccxWxSdsqWbhyKZ1xnR3JtdY7K_n7_zm7Ke-Q,180 tzdata/zoneinfo/Africa/Sao_Tome,sha256=Pfiutakw5B5xr1OSg1uFvT0GwC6jVOqqxnx69GEJu50,173 tzdata/zoneinfo/Africa/Timbuktu,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Africa/Tripoli,sha256=zzMBLZZh4VQ4_ARe5k4L_rsuqKP7edKvVt8F6kvj5FM,431 tzdata/zoneinfo/Africa/Tunis,sha256=uoAEER48RJqNeGoYBuk5IeYqjc8sHvWLvKssuVCd18g,449 tzdata/zoneinfo/Africa/Windhoek,sha256=g1jLRko_2peGsUTg0_wZycOC4gxTAHwfV2SO9I3KdCM,638 tzdata/zoneinfo/Africa/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Africa/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/America/Adak,sha256=q_sZgOINX4TsX9iBx1gNd6XGwBnzCjg6qpdAQhK0ieA,969 tzdata/zoneinfo/America/Anchorage,sha256=d8oMIpYvBpmLzl5I2By4ZaFEZsg_9dxgfqpIM0QFi_Y,977 tzdata/zoneinfo/America/Anguilla,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Antigua,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Araguaina,sha256=TawYX4lVAxq0BxUGhTDx4C8vtBRnLuWi8qLV_oXDiUo,592 tzdata/zoneinfo/America/Argentina/Buenos_Aires,sha256=IEVOpSfI6oiJJmFNIb9Vb0bOOMIgxO5bghFw7vkHFGk,708 tzdata/zoneinfo/America/Argentina/Catamarca,sha256=UC0fxx7ZPmjPw3D0BK-5vap-c1cBzbgR293MdmEfOx0,708 tzdata/zoneinfo/America/Argentina/ComodRivadavia,sha256=UC0fxx7ZPmjPw3D0BK-5vap-c1cBzbgR293MdmEfOx0,708 tzdata/zoneinfo/America/Argentina/Cordoba,sha256=9Ij3WjT9mWMKQ43LeSUIqQuDb9zS3FSlHYPVNQJTFf0,708 tzdata/zoneinfo/America/Argentina/Jujuy,sha256=7YpjOcmVaKKpiq31rQe8TTDNExdH9jjZIhdcZv-ShUg,690 tzdata/zoneinfo/America/Argentina/La_Rioja,sha256=mUkRD5jaWJUy2f8vNFqOlMgKPptULOBn-vf_jMgF6x8,717 tzdata/zoneinfo/America/Argentina/Mendoza,sha256=dL4q0zgY2FKPbG8cC-Wknnpp8tF2Y7SWgWSC_G_WznI,708 tzdata/zoneinfo/America/Argentina/Rio_Gallegos,sha256=bCpWMlEI8KWe4c3n6fn8u6WCPnxjYtVy57ERtLTZaEs,708 tzdata/zoneinfo/America/Argentina/Salta,sha256=H_ybxVycfOe7LlUA3GngoS0jENHkQURIRhjfJQF2kfU,690 tzdata/zoneinfo/America/Argentina/San_Juan,sha256=Mj5vIUzQl5DtsPe3iMzS7rR-88U9HKW2csQqUda4JNM,717 tzdata/zoneinfo/America/Argentina/San_Luis,sha256=rka8BokogyvMRFH6jr8D6s1tFIpsUeqHJ_feLK5O6ds,717 tzdata/zoneinfo/America/Argentina/Tucuman,sha256=yv3aC-hALLio2yqneLIIylZhXKDlbPJGAd_abgsj9gg,726 tzdata/zoneinfo/America/Argentina/Ushuaia,sha256=mcmZgB1pEHX6i7nlyRzjLnG8bqAtAK1TwMdRD2pZqBE,708 tzdata/zoneinfo/America/Argentina/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/America/Argentina/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/America/Aruba,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Asuncion,sha256=PuuUl8VILSBeZWDyLkM67bWl47xPMcJ0fY-rAhvSFzc,884 tzdata/zoneinfo/America/Atikokan,sha256=p41zBnujy9lPiiPf3WqotoyzOxhIS8F7TiDqGuwvCoE,149 tzdata/zoneinfo/America/Atka,sha256=q_sZgOINX4TsX9iBx1gNd6XGwBnzCjg6qpdAQhK0ieA,969 tzdata/zoneinfo/America/Bahia,sha256=_-ZFw-HzXc7byacHW_NJHtJ03ADFdqt1kaYgyWYobYw,682 tzdata/zoneinfo/America/Bahia_Banderas,sha256=F2Tz2IIWs9nqdSb5sdKLrO6Cu0xiGLbQZ3TamKR4v5A,728 tzdata/zoneinfo/America/Barbados,sha256=gdiJf9ZKOMs9QB4ex0-crvdmhNfHpNzXTV2xTaNDCAg,278 tzdata/zoneinfo/America/Belem,sha256=w0jv-gdBbEBZQBF2z2liKpRM9CEOWA36O1qU1nJKeCs,394 tzdata/zoneinfo/America/Belize,sha256=uYBPJqnCGnOOeKnoz1IG9POWTvXD5kUirpFuB0PHjVo,1045 tzdata/zoneinfo/America/Blanc-Sablon,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Boa_Vista,sha256=hYTFFNNZJdl_nSYIdfI8SQhtmfiakjCDI_15TlB-xEw,430 tzdata/zoneinfo/America/Bogota,sha256=BqH6uClrrlT-VsBmke2Mh-IfA1R1l1h031CRUSLS1no,179 tzdata/zoneinfo/America/Boise,sha256=Jt3omyPSPRoKE-KXVd-wxVON-CDE5oGaJA7Ar90Q2OM,999 tzdata/zoneinfo/America/Buenos_Aires,sha256=IEVOpSfI6oiJJmFNIb9Vb0bOOMIgxO5bghFw7vkHFGk,708 tzdata/zoneinfo/America/Cambridge_Bay,sha256=NFwNVfgxb2YMLzc-42RA-SKtNcODpukEfYf_QWWYTsI,883 tzdata/zoneinfo/America/Campo_Grande,sha256=mngKYjaH_ENVmJ-mtURVjjFo5kHgLfYNPHZaCVSxQFE,952 tzdata/zoneinfo/America/Cancun,sha256=XOYTJdVeHFfKeSGxHcZ_stJ9_Vkqn0q0LmS1mhnGI8o,529 tzdata/zoneinfo/America/Caracas,sha256=UHmUwc0mFPoidR4UDCWb4T4w_mpCBsSb4BkW3SOKIVY,190 tzdata/zoneinfo/America/Catamarca,sha256=UC0fxx7ZPmjPw3D0BK-5vap-c1cBzbgR293MdmEfOx0,708 tzdata/zoneinfo/America/Cayenne,sha256=9URU4o1v5759UWuh8xI9vnaANOceOeRW67XoGQuuUa8,151 tzdata/zoneinfo/America/Cayman,sha256=p41zBnujy9lPiiPf3WqotoyzOxhIS8F7TiDqGuwvCoE,149 tzdata/zoneinfo/America/Chicago,sha256=wntzn_RqffBZThINcltDkhfhHkTqmlDNxJEwODtUguc,1754 tzdata/zoneinfo/America/Chihuahua,sha256=hHey29pNZGuKh_bTiluGQSOGAhiQuCG4VMNGlJCgxPs,691 tzdata/zoneinfo/America/Ciudad_Juarez,sha256=eJkqieD7ixtltRojAKRk4iNRk-bZZZDPQV2hyR1vMmI,718 tzdata/zoneinfo/America/Coral_Harbour,sha256=p41zBnujy9lPiiPf3WqotoyzOxhIS8F7TiDqGuwvCoE,149 tzdata/zoneinfo/America/Cordoba,sha256=9Ij3WjT9mWMKQ43LeSUIqQuDb9zS3FSlHYPVNQJTFf0,708 tzdata/zoneinfo/America/Costa_Rica,sha256=ihoqA_tHmYm0YjTRLZu3q8PqsqqOeb1CELjWhPf_HXE,232 tzdata/zoneinfo/America/Creston,sha256=rhFFPCHQiYTedfLv7ATckxeKe04jxeUvIJi4vUXMtUc,240 tzdata/zoneinfo/America/Cuiaba,sha256=OaIle0Cr-BKe0hOik5rwdcoCbQ5LSHkHqBS2cLoCqAU,934 tzdata/zoneinfo/America/Curacao,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Danmarkshavn,sha256=cQORuA8pR0vw3ZwYfeGkWaT1tPU66nMQ2xRKT1T1Yb4,447 tzdata/zoneinfo/America/Dawson,sha256=BlKV0U36jqnlxM5-Pxn8OIiY5kJEcLlt3QZo-GsMzlY,1029 tzdata/zoneinfo/America/Dawson_Creek,sha256=t4USMuIvq1VVL9gYCabraAYs31kmAqAnwf7GzEiJJNc,683 tzdata/zoneinfo/America/Denver,sha256=m7cDkg7KS2EZ6BoQVYOk9soiBlHxO0GEeat81WxBPz4,1042 tzdata/zoneinfo/America/Detroit,sha256=I4F8Mt9nx38AF6D-steYskBa_HHO6jKU1-W0yRFr50A,899 tzdata/zoneinfo/America/Dominica,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Edmonton,sha256=Dq2mxcSNWZhMWRqxwwtMcaqwAIGMwkOzz-mW8fJscV8,970 tzdata/zoneinfo/America/Eirunepe,sha256=6tKYaRpnbBSmXiwXy7_m4WW_rbVfn5LUec0keC3J7Iw,436 tzdata/zoneinfo/America/El_Salvador,sha256=4wjsCpRH9AFk5abLAbnuv-zouhRKcwb0aenk-nWtmz0,176 tzdata/zoneinfo/America/Ensenada,sha256=8fnbxtJqQnP6myWWVdev2eI1O5yBc8P5hLU9fskYMF4,1025 tzdata/zoneinfo/America/Fort_Nelson,sha256=_j7IJ-hXHtV_7dSMg6pxGQLb6z_IaUMj3aJde_F49QQ,1448 tzdata/zoneinfo/America/Fort_Wayne,sha256=5nj0KhPvvXvg8mqc5T4EscKKWC6rBWEcsBwWg2Qy8Hs,531 tzdata/zoneinfo/America/Fortaleza,sha256=ugF4DWO3j_khONebf7CLsT9ldL-JOWey_69S0jl2LIA,484 tzdata/zoneinfo/America/Glace_Bay,sha256=I1posPHAEfg_Lc_FQdX1B8F8_A0NeJnK72p36PE7pKM,880 tzdata/zoneinfo/America/Godthab,sha256=v6AuVn_vGXOCnQKIahnqrzNZg0Djx2dhy3FwTd5BHjM,965 tzdata/zoneinfo/America/Goose_Bay,sha256=kB975nprE5Sr_vb244223YBWJnnZmu3FkhYIOqAZB5Y,1580 tzdata/zoneinfo/America/Grand_Turk,sha256=Gp8hpMt9P3QoEHmsIX2bqGNMkUSvlwZqqNzccR-cbe8,853 tzdata/zoneinfo/America/Grenada,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Guadeloupe,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Guatemala,sha256=BGPGI4lyN6IFF_T0kx1q2lh3U5SEhbyDqLFuW8EFCaU,212 tzdata/zoneinfo/America/Guayaquil,sha256=8OIaCy-SirKKz4I77l6MQFDgSLHtjN0TvklLVEZ_008,179 tzdata/zoneinfo/America/Guyana,sha256=PmnEtWtOTamsPJXEo7PcNQCy2Rp-evGyJh4cf0pjAR4,181 tzdata/zoneinfo/America/Halifax,sha256=kO5ahBM2oTLfWS4KX15FbKXfo5wg-f9vw1_hMOISGig,1672 tzdata/zoneinfo/America/Havana,sha256=ms5rCuq2yBM49VmTymMtFQN3c5aBN1lkd8jjzKdnNm8,1117 tzdata/zoneinfo/America/Hermosillo,sha256=W-QiSzPq2J-hWWQ-uzD6McLKzG8XPEawbJpnXlNp3-Q,286 tzdata/zoneinfo/America/Indiana/Indianapolis,sha256=5nj0KhPvvXvg8mqc5T4EscKKWC6rBWEcsBwWg2Qy8Hs,531 tzdata/zoneinfo/America/Indiana/Knox,sha256=KJCzXct8CTMItVLYLYeBqM6aT6b53gWCg6aDbsH58oI,1016 tzdata/zoneinfo/America/Indiana/Marengo,sha256=ygWmq8sYee8NFwlSZyQ_tsKopFQMp9Ne557zGGbyF2Y,567 tzdata/zoneinfo/America/Indiana/Petersburg,sha256=BIrubzHEp5QoyMaPgYbC1zSa_F3LwpXzKM8xH3rHspI,683 tzdata/zoneinfo/America/Indiana/Tell_City,sha256=em2YMHDWEFXdZH0BKi5bLRAQ8bYDfop2T0Q8SqDh0B8,522 tzdata/zoneinfo/America/Indiana/Vevay,sha256=dPk334e7MQwl71-avNyREBYVWuFTQcVKfltlRhrlRpw,369 tzdata/zoneinfo/America/Indiana/Vincennes,sha256=jiODDXepmLP3gvCkBufdE3rp5cEXftBHnKne8_XOOCg,558 tzdata/zoneinfo/America/Indiana/Winamac,sha256=R8Em7dmolgP711usASyUGzhC_NL5PdNmSah39w9KoTM,612 tzdata/zoneinfo/America/Indiana/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/America/Indiana/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/America/Indianapolis,sha256=5nj0KhPvvXvg8mqc5T4EscKKWC6rBWEcsBwWg2Qy8Hs,531 tzdata/zoneinfo/America/Inuvik,sha256=d_ZX-USS70HIT-_PRJKMY6mbQRvbKLvsy9ar7uL2M40,817 tzdata/zoneinfo/America/Iqaluit,sha256=nONS7zksGHTrbEJj73LYRZW964OncQuj_V6fNjpDoQ0,855 tzdata/zoneinfo/America/Jamaica,sha256=pDexcAMzrv9TqLWGjVOHwIDcFMLT6Vqlzjb5AbNmkoQ,339 tzdata/zoneinfo/America/Jujuy,sha256=7YpjOcmVaKKpiq31rQe8TTDNExdH9jjZIhdcZv-ShUg,690 tzdata/zoneinfo/America/Juneau,sha256=V8IqRaJHSH7onK1gu3YYtW_a4VkNwjx5DCvQXpFdYAo,966 tzdata/zoneinfo/America/Kentucky/Louisville,sha256=zS2SS573D9TmQZFWtSyRIVN3ZXVN_2FpVBbtqQFMzKU,1242 tzdata/zoneinfo/America/Kentucky/Monticello,sha256=54or2oQ9bSbM9ifRoOjV7UjRF83jSSPuxfGeXH0nIqk,972 tzdata/zoneinfo/America/Kentucky/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/America/Kentucky/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/America/Knox_IN,sha256=KJCzXct8CTMItVLYLYeBqM6aT6b53gWCg6aDbsH58oI,1016 tzdata/zoneinfo/America/Kralendijk,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/La_Paz,sha256=2iYBxnc0HIwAzlx-Q3AI9Lb0GI87VY279oGcroBZSVs,170 tzdata/zoneinfo/America/Lima,sha256=7vNjRhxzL-X4kyba-NkzXYNAOE-cqqcXvzXTqcTXBhY,283 tzdata/zoneinfo/America/Los_Angeles,sha256=IA0FdU9tg6Nxz0CNcIUSV5dlezsL6-uh5QjP_oaj5cg,1294 tzdata/zoneinfo/America/Louisville,sha256=zS2SS573D9TmQZFWtSyRIVN3ZXVN_2FpVBbtqQFMzKU,1242 tzdata/zoneinfo/America/Lower_Princes,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Maceio,sha256=dSVg0dHedT9w1QO2F1AvWoel4_h8wmuYS4guEaL-5Kk,502 tzdata/zoneinfo/America/Managua,sha256=ZYsoyN_GIlwAIpIj1spjQDPWGQ9kFZSipjUbO8caGfw,295 tzdata/zoneinfo/America/Manaus,sha256=9kgrhpryB94YOVoshJliiiDSf9mwjb3OZwX0HusNRrk,412 tzdata/zoneinfo/America/Marigot,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Martinique,sha256=m3rC6Mogc6cc1a9XJ8FPIYhZaSFNdYkxaZ-pfHhG3X4,178 tzdata/zoneinfo/America/Matamoros,sha256=73sQpcZ-qYCPalWxd0_R2jH5MwYGTT4sRW0bNkBkR-8,437 tzdata/zoneinfo/America/Mazatlan,sha256=C5CBj73KgB8vbDbDEgqMHfPeMeglQj156WNbwYSxux8,718 tzdata/zoneinfo/America/Mendoza,sha256=dL4q0zgY2FKPbG8cC-Wknnpp8tF2Y7SWgWSC_G_WznI,708 tzdata/zoneinfo/America/Menominee,sha256=oUmJmzOZtChYrB9In-E1GqEVi2ogKjPESXlUySUGs94,917 tzdata/zoneinfo/America/Merida,sha256=KTdHMhhdhJtTg40KW2qSfd6N9PAQ50d_ektYDt2ouy0,654 tzdata/zoneinfo/America/Metlakatla,sha256=-SGuCUejuefFzayhzgqgzZtx1G4UMoSlavw9Ey5aylk,595 tzdata/zoneinfo/America/Mexico_City,sha256=vhDy1hSceJyFa3bIqn2qRi1kgxtvrCCaaB7s65mljtY,773 tzdata/zoneinfo/America/Miquelon,sha256=aL9A5NhloNVIHze2oKf_9fe_xD4Poawa9bhNDwhpTyM,550 tzdata/zoneinfo/America/Moncton,sha256=MhwbtKj6OjEEA1GQLhCEljfE-ji5RnLrieY5YgFkjd8,1493 tzdata/zoneinfo/America/Monterrey,sha256=GWEQgKgJQV89hVpFOO6nS1AYvdM6Lcw_xeYwMfkV6bg,644 tzdata/zoneinfo/America/Montevideo,sha256=l7FjW6qscGzdvfjlbIeZ5CQ_AFWS3ZeVDS5ppMJCNM0,969 tzdata/zoneinfo/America/Montreal,sha256=rS1CerA3FRdQOUcbYaphHU_fM8-2HysVmT7BfEAboeU,1717 tzdata/zoneinfo/America/Montserrat,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Nassau,sha256=rS1CerA3FRdQOUcbYaphHU_fM8-2HysVmT7BfEAboeU,1717 tzdata/zoneinfo/America/New_York,sha256=1_IgazpFmJ_JrWPVWJIlMvpzUigNX4cXa_HbecsdH6k,1744 tzdata/zoneinfo/America/Nipigon,sha256=rS1CerA3FRdQOUcbYaphHU_fM8-2HysVmT7BfEAboeU,1717 tzdata/zoneinfo/America/Nome,sha256=_-incQnh0DwK9hJqFaYzO4osUKAUB2k2lae565sblpA,975 tzdata/zoneinfo/America/Noronha,sha256=Q0r3GtA5y2RGkOj56OTZG5tuBy1B6kfbhyrJqCgf27g,484 tzdata/zoneinfo/America/North_Dakota/Beulah,sha256=RvaBIS60bNNRmREi6BXSWEbJSrcP7J8Nmxg8OkBcrow,1043 tzdata/zoneinfo/America/North_Dakota/Center,sha256=M09x4Mx6hcBAwktvwv16YvPRmsuDjZEDwHT0Umkcgyo,990 tzdata/zoneinfo/America/North_Dakota/New_Salem,sha256=mZca9gyfO2USzax7v0mLJEYBKBVmIqylWqnfLgSsVys,990 tzdata/zoneinfo/America/North_Dakota/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/America/North_Dakota/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/America/Nuuk,sha256=v6AuVn_vGXOCnQKIahnqrzNZg0Djx2dhy3FwTd5BHjM,965 tzdata/zoneinfo/America/Ojinaga,sha256=hOEtS04g2vAElR83wB9qwd3O9DWl9unWnleiY0hEMDk,709 tzdata/zoneinfo/America/Panama,sha256=p41zBnujy9lPiiPf3WqotoyzOxhIS8F7TiDqGuwvCoE,149 tzdata/zoneinfo/America/Pangnirtung,sha256=nONS7zksGHTrbEJj73LYRZW964OncQuj_V6fNjpDoQ0,855 tzdata/zoneinfo/America/Paramaribo,sha256=C2v9tR6no54CRECWDFhANTl40UsA4AhHsdnGoNCb4_Q,187 tzdata/zoneinfo/America/Phoenix,sha256=rhFFPCHQiYTedfLv7ATckxeKe04jxeUvIJi4vUXMtUc,240 tzdata/zoneinfo/America/Port-au-Prince,sha256=wsS6VbQ__bKJ2IUMPy_Pao0CLRK5pXEBrqkaYuqs3Ns,565 tzdata/zoneinfo/America/Port_of_Spain,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Porto_Acre,sha256=VjuQUr668phq5bcH40r94BPnZBKHzJf_MQBfM6Db96U,418 tzdata/zoneinfo/America/Porto_Velho,sha256=9yPU8EXtKDQHLF745ETc9qZZ9Me2CK6jvgb6S53pSKg,394 tzdata/zoneinfo/America/Puerto_Rico,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Punta_Arenas,sha256=2Aqh7bqo-mQlnMjURDkCOeEYmeXhkzKP7OxFAvhTjjA,1218 tzdata/zoneinfo/America/Rainy_River,sha256=ANzwYGBU1PknQW4LR-H92i5c4Db95LU-UQhPhWZCjDo,1294 tzdata/zoneinfo/America/Rankin_Inlet,sha256=JQCXQBdyc8uJTjIFO4jZuzS0OjG0gRHv8MPmdzN93CU,807 tzdata/zoneinfo/America/Recife,sha256=3yZTwF3MJlkY0D48CQUTzCRwDCfGNq8EXXTZYlBgUTg,484 tzdata/zoneinfo/America/Regina,sha256=_JHuns225iE-THc9NFp-RBq4PWULAuGw2OLbpOB_UMw,638 tzdata/zoneinfo/America/Resolute,sha256=2UeJBR2ZSkn1bUZy0G0SEhBtY9vycwSRU4naK-sw044,807 tzdata/zoneinfo/America/Rio_Branco,sha256=VjuQUr668phq5bcH40r94BPnZBKHzJf_MQBfM6Db96U,418 tzdata/zoneinfo/America/Rosario,sha256=9Ij3WjT9mWMKQ43LeSUIqQuDb9zS3FSlHYPVNQJTFf0,708 tzdata/zoneinfo/America/Santa_Isabel,sha256=8fnbxtJqQnP6myWWVdev2eI1O5yBc8P5hLU9fskYMF4,1025 tzdata/zoneinfo/America/Santarem,sha256=dDEGsnrm4wrzl4sK6K8PzEroBKD7A1V7HBa8cWW4cMk,409 tzdata/zoneinfo/America/Santiago,sha256=_QBpU8K0QqLh5m2yqWfdkypIJDkPAc3dnIAc5jRQxxU,1354 tzdata/zoneinfo/America/Santo_Domingo,sha256=xmJo59mZXN7Wnf-3Jjl37mCC-8GfN6xmk2l_vngyfeI,317 tzdata/zoneinfo/America/Sao_Paulo,sha256=-izrIi8GXAKJ85l_8MVLoFp0pZm0Uihw-oapbiThiJE,952 tzdata/zoneinfo/America/Scoresbysund,sha256=3QmA-6sZqEFIJ_JzUAKni7IZQLWB_JZ1zN-HkgjgiT8,479 tzdata/zoneinfo/America/Shiprock,sha256=m7cDkg7KS2EZ6BoQVYOk9soiBlHxO0GEeat81WxBPz4,1042 tzdata/zoneinfo/America/Sitka,sha256=pF5yln--MOzEMDacNd_Id0HX9pAmge8POfcxyTNh1-0,956 tzdata/zoneinfo/America/St_Barthelemy,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/St_Johns,sha256=jBTPMhJvnQTt4YCLqLAs3EgPtSzuVO2FxDbcOdh6BaM,1878 tzdata/zoneinfo/America/St_Kitts,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/St_Lucia,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/St_Thomas,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/St_Vincent,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Swift_Current,sha256=F-b65Yaax23CsuhSmeTDl6Tv9du4IsvWvMbbSuwHkLM,368 tzdata/zoneinfo/America/Tegucigalpa,sha256=KlvqBJGswa9DIXlE3acU-pgd4IFqDeBRrUz02PmlNC0,194 tzdata/zoneinfo/America/Thule,sha256=LzL5jdmZkxRkHdA3XkoqJPG_ImllnSRhYYLQpMf_TY8,455 tzdata/zoneinfo/America/Thunder_Bay,sha256=rS1CerA3FRdQOUcbYaphHU_fM8-2HysVmT7BfEAboeU,1717 tzdata/zoneinfo/America/Tijuana,sha256=8fnbxtJqQnP6myWWVdev2eI1O5yBc8P5hLU9fskYMF4,1025 tzdata/zoneinfo/America/Toronto,sha256=rS1CerA3FRdQOUcbYaphHU_fM8-2HysVmT7BfEAboeU,1717 tzdata/zoneinfo/America/Tortola,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Vancouver,sha256=Epou71sUffvHB1rd7wT0krvo3okXAV45_TWcOFpy26Q,1330 tzdata/zoneinfo/America/Virgin,sha256=q76GKN1Uh8iJ24Fs46UHe7tH9rr6_rlBHZLW7y9wzo0,177 tzdata/zoneinfo/America/Whitehorse,sha256=CyY4jNd0fzNSdf1HlYGfaktApmH71tRNRlpOEO32DGs,1029 tzdata/zoneinfo/America/Winnipeg,sha256=ANzwYGBU1PknQW4LR-H92i5c4Db95LU-UQhPhWZCjDo,1294 tzdata/zoneinfo/America/Yakutat,sha256=pvHLVNA1mI-H9fBDnlnpI6B9XzVFQeyvI9nyIkaFNYQ,946 tzdata/zoneinfo/America/Yellowknife,sha256=Dq2mxcSNWZhMWRqxwwtMcaqwAIGMwkOzz-mW8fJscV8,970 tzdata/zoneinfo/America/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/America/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Antarctica/Casey,sha256=x-Y2IsrnKPAmYEmrkhgFSQGtbcudvVTUGSuSSBUKb1c,243 tzdata/zoneinfo/Antarctica/Davis,sha256=Pom_267rsoZl6yLvYllu_SW1kixIrSPmsd-HLztn33Y,197 tzdata/zoneinfo/Antarctica/DumontDUrville,sha256=aDABBVtu-dydiHNODt3ReC8cNkO3wTp16c-OkFIAbhk,154 tzdata/zoneinfo/Antarctica/Macquarie,sha256=WsRh5ci8UXCBgkvI1yK-4sIoI0u7tzqamj9yJlbTN14,976 tzdata/zoneinfo/Antarctica/Mawson,sha256=UYuiBSE0qZ-2kkBAa6Xq5g9NXg-W_R0P-rl2tlO0jHc,152 tzdata/zoneinfo/Antarctica/McMurdo,sha256=Dgbn5VrtvJLvWz0Qbnw5KrFijP2KQosg6S6ZAooL-7k,1043 tzdata/zoneinfo/Antarctica/Palmer,sha256=3MXfhQBaRB57_jqHZMl-M_K48NMFe4zALc7vaMyS5xw,887 tzdata/zoneinfo/Antarctica/Rothera,sha256=XeddRL2YTDfEWzQI7nDqfW-Tfg-5EebxsHsMHyzGudI,132 tzdata/zoneinfo/Antarctica/South_Pole,sha256=Dgbn5VrtvJLvWz0Qbnw5KrFijP2KQosg6S6ZAooL-7k,1043 tzdata/zoneinfo/Antarctica/Syowa,sha256=RoU-lCdq8u6o6GwvFSqHHAkt8ZXcUSc7j8cJH6pLRhw,133 tzdata/zoneinfo/Antarctica/Troll,sha256=qATzm4g2pZ0jc6RzibcN1aMj3jKB-x6F0UaV385RW90,177 tzdata/zoneinfo/Antarctica/Vostok,sha256=hJyv03dhHML8K0GJGrY8b7M0OUkEXblh_RYmdZMxWtQ,133 tzdata/zoneinfo/Antarctica/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Antarctica/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Arctic/Longyearbyen,sha256=p_2ZMteF1NaQkAuDTDVjwYEMHPLgFxG8wJJq9sB2fLc,705 tzdata/zoneinfo/Arctic/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Arctic/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Asia/Aden,sha256=RoU-lCdq8u6o6GwvFSqHHAkt8ZXcUSc7j8cJH6pLRhw,133 tzdata/zoneinfo/Asia/Almaty,sha256=iaqf5cQoVO3t6t5a8W7I2SRv1UM346tRIYZudOoLOFA,609 tzdata/zoneinfo/Asia/Amman,sha256=KOnKO4_1XRlQvLG61GTbfKImSthwBHMSnzV1ExW8i5Q,928 tzdata/zoneinfo/Asia/Anadyr,sha256=30bdZurg4Q__lCpH509TE0U7pOcEY6qxjvuPF9ai5yc,743 tzdata/zoneinfo/Asia/Aqtau,sha256=bRj27vG5HvGegFg5eIKNmq3dfteYmr7KmTs4JFO-7SM,606 tzdata/zoneinfo/Asia/Aqtobe,sha256=Pm7yI5cmfzx8CGXR2mQJDjtH12KCpx8ezFKchiJVVJ4,615 tzdata/zoneinfo/Asia/Ashgabat,sha256=OTLHdQ8jFPDvxu_IwKX_c3W3jdN6e7FGoCSEEb0XKuw,375 tzdata/zoneinfo/Asia/Ashkhabad,sha256=OTLHdQ8jFPDvxu_IwKX_c3W3jdN6e7FGoCSEEb0XKuw,375 tzdata/zoneinfo/Asia/Atyrau,sha256=1YG4QzLxPRZQeGHiOrbm0cRs8ERTNg1NF9dWEwW2Pi0,616 tzdata/zoneinfo/Asia/Baghdad,sha256=zFe6LXSfuoJjGsmYTMGjJtBcAMLiKFkD7j7-VaqKwH8,630 tzdata/zoneinfo/Asia/Bahrain,sha256=YWDWV1o3HHWxnmwlzwMWC53C84ZYPkK_gYn9-P0Xx4U,152 tzdata/zoneinfo/Asia/Baku,sha256=_Wh6ONaRatMc9lpwGO6zB9pTE38NZ4oWg4_-sZl17mA,744 tzdata/zoneinfo/Asia/Bangkok,sha256=zcjiwoLYvJpenDyvL8Rf9OnlzRj13sjLhzNArXxYTWQ,152 tzdata/zoneinfo/Asia/Barnaul,sha256=UGFYJYvtgYVS8Tqsqvj6p0OQCmN3zdY9wITWg8ODG-k,753 tzdata/zoneinfo/Asia/Beirut,sha256=FgM4gqbWFp6KuUnVn-H8UIXZgTydBeOxDdbebJ0GpUc,732 tzdata/zoneinfo/Asia/Bishkek,sha256=RXdxVxaiE5zxX5atQl-7ZesEeZVjsCXBGZ6cJbVU9pE,618 tzdata/zoneinfo/Asia/Brunei,sha256=3ajgII3xZ-Wc-dqXRTSMw8qQRDSjXlSBIxyE_sDRGTk,320 tzdata/zoneinfo/Asia/Calcutta,sha256=OgC9vhvElZ5ydWfHMLpRsDRV7NRV98GQxa0UOG63mw0,220 tzdata/zoneinfo/Asia/Chita,sha256=1Lme3ccO47R5gmTe5VCq1BSb0m_1opWibq21zvZlntg,750 tzdata/zoneinfo/Asia/Choibalsan,sha256=hsakX_o0anB6tNBNp_FKGx4k57IcODYubf1u2G_2Vqk,619 tzdata/zoneinfo/Asia/Chongqing,sha256=v4t-2C_m5j5tmPjOqTTurJAc0Wq6hetXVc4_i0KJ6oo,393 tzdata/zoneinfo/Asia/Chungking,sha256=v4t-2C_m5j5tmPjOqTTurJAc0Wq6hetXVc4_i0KJ6oo,393 tzdata/zoneinfo/Asia/Colombo,sha256=QAyjK7gtXUWfLuju1M0H3_ew6iTM-bwfzO5obgvaHy8,247 tzdata/zoneinfo/Asia/Dacca,sha256=rCGmEwbW4qkUU2QfTj5zLrydVCq8HTWl1dsqEDQOvvo,231 tzdata/zoneinfo/Asia/Damascus,sha256=AtZTDRzHEB7QnKxFXvtWsNUI1cCCe27sAfpDfQd0MwY,1234 tzdata/zoneinfo/Asia/Dhaka,sha256=rCGmEwbW4qkUU2QfTj5zLrydVCq8HTWl1dsqEDQOvvo,231 tzdata/zoneinfo/Asia/Dili,sha256=ByL6yx7Cuq6axUp5D1n8a9MtmAod_mw6JQP_ltYdOUg,170 tzdata/zoneinfo/Asia/Dubai,sha256=DZ6lBT6DGIAypvtNMB1dtoj0MBHltrH5F6EbcaDaexY,133 tzdata/zoneinfo/Asia/Dushanbe,sha256=8qbn76rf9xu47NYVdfGvjnkf2KZxNN5J8ekFiXUz3AQ,366 tzdata/zoneinfo/Asia/Famagusta,sha256=385fbaRnx-mdEaXqSyBKVBDDKPzCGKbynWYt75wwCug,940 tzdata/zoneinfo/Asia/Gaza,sha256=DYo-KXLmTmNY2MutH23-8lh7ktXdgW5jF45ISVhzDvI,2518 tzdata/zoneinfo/Asia/Harbin,sha256=v4t-2C_m5j5tmPjOqTTurJAc0Wq6hetXVc4_i0KJ6oo,393 tzdata/zoneinfo/Asia/Hebron,sha256=SGGveooiW4SUgmysD_OtCd7aWtitlbg0HRNtWfW98Mc,2536 tzdata/zoneinfo/Asia/Ho_Chi_Minh,sha256=4mp0K7AWfcwZQIKxE1qTlGVdsxQ7Je9DedOxpFpho4M,236 tzdata/zoneinfo/Asia/Hong_Kong,sha256=9AaPcyRtuXQX9zRnRTVkxX1mRs5JCbn6JTaSPvzX608,775 tzdata/zoneinfo/Asia/Hovd,sha256=eqAvD2RfuIfSDhtqk58MECIjz5X14OHZ7aO4z14kndk,594 tzdata/zoneinfo/Asia/Irkutsk,sha256=sWxp8g_aSfFan4ZyF9s6-pEX5Vgwxi_jNv7vwN06XIo,760 tzdata/zoneinfo/Asia/Istanbul,sha256=KnFjsWuUgG9pmRNI59CmDEbrYbHwMF9fS4P2E9sQgG8,1200 tzdata/zoneinfo/Asia/Jakarta,sha256=4qCZ6kix9xZriNIZsyb3xENz0IkJzZcjtENGlG_Wo4Q,248 tzdata/zoneinfo/Asia/Jayapura,sha256=BUa0kX1iOdf0E-v7415h7l0lQv4DBCYX_3dAbYmQ0xU,171 tzdata/zoneinfo/Asia/Jerusalem,sha256=n83o1YTeoFhfXIcnqvNfSKFJ4NvTqDv2zvi8qcFAIeM,1074 tzdata/zoneinfo/Asia/Kabul,sha256=pNIwTfiSG71BGKvrhKqo1xdxckAx9vfcx5nJanrL81Q,159 tzdata/zoneinfo/Asia/Kamchatka,sha256=Qix8x3s-m8UTeiwzNPBy_ZQvAzX_aaihz_PzLfTiUac,727 tzdata/zoneinfo/Asia/Karachi,sha256=ujo4wv-3oa9tfrFT5jsLcEYcjeGeBRgG2QwdXg_ijU4,266 tzdata/zoneinfo/Asia/Kashgar,sha256=hJyv03dhHML8K0GJGrY8b7M0OUkEXblh_RYmdZMxWtQ,133 tzdata/zoneinfo/Asia/Kathmandu,sha256=drjxv-ByIxodnn-FATEOJ8DQgEjEj3Qihgtkd8FCxDg,161 tzdata/zoneinfo/Asia/Katmandu,sha256=drjxv-ByIxodnn-FATEOJ8DQgEjEj3Qihgtkd8FCxDg,161 tzdata/zoneinfo/Asia/Khandyga,sha256=fdEDOsDJkLuENybqIXtTiI4k2e24dKHDfBTww9AtbSw,775 tzdata/zoneinfo/Asia/Kolkata,sha256=OgC9vhvElZ5ydWfHMLpRsDRV7NRV98GQxa0UOG63mw0,220 tzdata/zoneinfo/Asia/Krasnoyarsk,sha256=buNI5S1g7eedK-PpnrLkBFFZDUyCtHxcxXDQGF2ARos,741 tzdata/zoneinfo/Asia/Kuala_Lumpur,sha256=CVSy2aMB2U9DSAJGBqcbvLL6JNPNNwn1vIvKYFA5eF0,256 tzdata/zoneinfo/Asia/Kuching,sha256=3ajgII3xZ-Wc-dqXRTSMw8qQRDSjXlSBIxyE_sDRGTk,320 tzdata/zoneinfo/Asia/Kuwait,sha256=RoU-lCdq8u6o6GwvFSqHHAkt8ZXcUSc7j8cJH6pLRhw,133 tzdata/zoneinfo/Asia/Macao,sha256=mr89i_wpMoWhAtqZrF2SGcoILcUw6rYrDkIUNADes7E,791 tzdata/zoneinfo/Asia/Macau,sha256=mr89i_wpMoWhAtqZrF2SGcoILcUw6rYrDkIUNADes7E,791 tzdata/zoneinfo/Asia/Magadan,sha256=wAufMGWL_s1Aw2l3myAfBFtrROVPes3dMoNuDEoNwT8,751 tzdata/zoneinfo/Asia/Makassar,sha256=NV9j_RTuiU47mvJvfKE8daXH5AFYJ8Ki4gvHBJSxyLc,190 tzdata/zoneinfo/Asia/Manila,sha256=Vk8aVoXR_edPDnARFdmEui4pq4Q3yNuiPUCzeIAPLBI,238 tzdata/zoneinfo/Asia/Muscat,sha256=DZ6lBT6DGIAypvtNMB1dtoj0MBHltrH5F6EbcaDaexY,133 tzdata/zoneinfo/Asia/Nicosia,sha256=FDczuLwTlqVEC6bhsxGV7h8s_mDBoLIwl5NNm-LW2T4,597 tzdata/zoneinfo/Asia/Novokuznetsk,sha256=aYW9rpcxpf_zrOZc2vmpcqgiuCRKMHB1lMrioI43KCw,726 tzdata/zoneinfo/Asia/Novosibirsk,sha256=I2n4MCElad9sMcyJAAc4YdVT6ewbhR79OoAAuhEJfCY,753 tzdata/zoneinfo/Asia/Omsk,sha256=y7u47EObB3wI8MxKHBRTFM-BEZZqhGpzDg7x5lcwJXY,741 tzdata/zoneinfo/Asia/Oral,sha256=Q-Gf85NIvdAtU52Zkgf78rVHPlg85xyMe9Zm9ybh0po,625 tzdata/zoneinfo/Asia/Phnom_Penh,sha256=zcjiwoLYvJpenDyvL8Rf9OnlzRj13sjLhzNArXxYTWQ,152 tzdata/zoneinfo/Asia/Pontianak,sha256=o0x0jNTlwjiUqAzGX_HlzvCMru2zUURgQ4xzpS95xds,247 tzdata/zoneinfo/Asia/Pyongyang,sha256=NxC5da8oTZ4StiFQnlhjlp9FTRuMM-Xwsq3Yg4y0xkA,183 tzdata/zoneinfo/Asia/Qatar,sha256=YWDWV1o3HHWxnmwlzwMWC53C84ZYPkK_gYn9-P0Xx4U,152 tzdata/zoneinfo/Asia/Qostanay,sha256=Lm7GHuc0Ao7qy-fmTsYkqxWDKQsf3_oW_rG61edr9fg,615 tzdata/zoneinfo/Asia/Qyzylorda,sha256=JltKDEnuHmIQGYdFTAJMDDpdDA_HxjJOAHHaV7kFrlQ,624 tzdata/zoneinfo/Asia/Rangoon,sha256=6J2DXIEdTaRKqLOGeCzogo3whaoO6PJWYamIHS8A6Qw,187 tzdata/zoneinfo/Asia/Riyadh,sha256=RoU-lCdq8u6o6GwvFSqHHAkt8ZXcUSc7j8cJH6pLRhw,133 tzdata/zoneinfo/Asia/Saigon,sha256=4mp0K7AWfcwZQIKxE1qTlGVdsxQ7Je9DedOxpFpho4M,236 tzdata/zoneinfo/Asia/Sakhalin,sha256=M_TBd-03j-3Yc9KwhGEoBTwSJxWO1lPBG7ndst16PGo,755 tzdata/zoneinfo/Asia/Samarkand,sha256=KZ_q-6GMDVgJb8RFqcrbVcPC0WLczolClC4nZA1HVNU,366 tzdata/zoneinfo/Asia/Seoul,sha256=ZKcLb7zJtl52Lb0l64m29AwTcUbtyNvU0IHq-s2reN4,415 tzdata/zoneinfo/Asia/Shanghai,sha256=v4t-2C_m5j5tmPjOqTTurJAc0Wq6hetXVc4_i0KJ6oo,393 tzdata/zoneinfo/Asia/Singapore,sha256=CVSy2aMB2U9DSAJGBqcbvLL6JNPNNwn1vIvKYFA5eF0,256 tzdata/zoneinfo/Asia/Srednekolymsk,sha256=06mojetFbDd4ag1p8NK0Fg6rF2OOnZMFRRC90N2ATZc,742 tzdata/zoneinfo/Asia/Taipei,sha256=oEwscvT3aoMXjQNt2X0VfuHzLkeORN2npcEJI2h-5s8,511 tzdata/zoneinfo/Asia/Tashkent,sha256=0vpN2gI9GY50z1nea6zCPFf2B6VCu6XQQHx4l6rhnTI,366 tzdata/zoneinfo/Asia/Tbilisi,sha256=ON_Uzv2VTSk6mRefNU-aI-qkqtCoUX6oECVqpeS42eI,629 tzdata/zoneinfo/Asia/Tehran,sha256=ozLlhNXzpJCZx7bc-VpcmNdgdtn6lPtF6f9qkaDEycI,812 tzdata/zoneinfo/Asia/Tel_Aviv,sha256=n83o1YTeoFhfXIcnqvNfSKFJ4NvTqDv2zvi8qcFAIeM,1074 tzdata/zoneinfo/Asia/Thimbu,sha256=N6d_vfFvYORfMnr1fHJjYSt4DBORSbLi_2T-r2dJBnI,154 tzdata/zoneinfo/Asia/Thimphu,sha256=N6d_vfFvYORfMnr1fHJjYSt4DBORSbLi_2T-r2dJBnI,154 tzdata/zoneinfo/Asia/Tokyo,sha256=WaOHFDDw07k-YZ-jCkOkHR6IvdSf8m8J0PQFpQBwb5Y,213 tzdata/zoneinfo/Asia/Tomsk,sha256=Bf7GoFTcUeP2hYyuYpruJji33tcEoLP-80o38A6i4zU,753 tzdata/zoneinfo/Asia/Ujung_Pandang,sha256=NV9j_RTuiU47mvJvfKE8daXH5AFYJ8Ki4gvHBJSxyLc,190 tzdata/zoneinfo/Asia/Ulaanbaatar,sha256=--I8P6_e4BtRIe3wCSkPtwHOu_k9rPsw-KqQKHJC9vM,594 tzdata/zoneinfo/Asia/Ulan_Bator,sha256=--I8P6_e4BtRIe3wCSkPtwHOu_k9rPsw-KqQKHJC9vM,594 tzdata/zoneinfo/Asia/Urumqi,sha256=hJyv03dhHML8K0GJGrY8b7M0OUkEXblh_RYmdZMxWtQ,133 tzdata/zoneinfo/Asia/Ust-Nera,sha256=6NkuV1zOms-4qHQhq-cGc-cqEVgKHk7qd3MLDM-e2BA,771 tzdata/zoneinfo/Asia/Vientiane,sha256=zcjiwoLYvJpenDyvL8Rf9OnlzRj13sjLhzNArXxYTWQ,152 tzdata/zoneinfo/Asia/Vladivostok,sha256=zkOXuEDgpxX8HQGgDlh9SbAQzHOaNxX2XSI6Y4gMD-k,742 tzdata/zoneinfo/Asia/Yakutsk,sha256=xD6zA4E228dC1mIUQ7cMO-9LORSfE-Fok0awGDG6juk,741 tzdata/zoneinfo/Asia/Yangon,sha256=6J2DXIEdTaRKqLOGeCzogo3whaoO6PJWYamIHS8A6Qw,187 tzdata/zoneinfo/Asia/Yekaterinburg,sha256=q17eUyqOEK2LJYKXYLCJqylj-vmaCG2vSNMttqrQTRk,760 tzdata/zoneinfo/Asia/Yerevan,sha256=pLEBdchA8H9l-9hdA6FjHmwaj5T1jupK0u-bor1KKa0,708 tzdata/zoneinfo/Asia/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Asia/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Atlantic/Azores,sha256=KmvA_G-yNl76C0A17JdtFg7ju9LHa5JIWh15GOzLxds,1453 tzdata/zoneinfo/Atlantic/Bermuda,sha256=PuxqD2cD99Pzjb8hH99Dws053d_zXnZHjeH0kZ8LSLI,1024 tzdata/zoneinfo/Atlantic/Canary,sha256=XMmxBlscPIWXhiauKy_d5bxX4xjNMM-5Vw84FwZkT00,478 tzdata/zoneinfo/Atlantic/Cape_Verde,sha256=E5ss6xpIpD0g_VEDsFMFi-ltsebp98PBSpULoVxIAyU,175 tzdata/zoneinfo/Atlantic/Faeroe,sha256=Iw0qB0mBuviH5w3Qy8jaxCOes07ZHh2wkW8MPUWJqj0,441 tzdata/zoneinfo/Atlantic/Faroe,sha256=Iw0qB0mBuviH5w3Qy8jaxCOes07ZHh2wkW8MPUWJqj0,441 tzdata/zoneinfo/Atlantic/Jan_Mayen,sha256=p_2ZMteF1NaQkAuDTDVjwYEMHPLgFxG8wJJq9sB2fLc,705 tzdata/zoneinfo/Atlantic/Madeira,sha256=IX1jlaiB-DaaGwjnfc5pYr8eEtX7_Wol-T50QNAs3qw,1453 tzdata/zoneinfo/Atlantic/Reykjavik,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Atlantic/South_Georgia,sha256=kPGfCLQD2C6_Xc5TyAmqmXP-GYdLLPucpBn3S7ybWu8,132 tzdata/zoneinfo/Atlantic/St_Helena,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Atlantic/Stanley,sha256=QqQd8IWklNapMKjN5vF7vvVn4K-yl3VKvM5zkCKabCM,789 tzdata/zoneinfo/Atlantic/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Atlantic/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Australia/ACT,sha256=gg1FqGioj4HHMdWyx1i07QAAObYmCoBDP44PCUpgS1k,904 tzdata/zoneinfo/Australia/Adelaide,sha256=Gk1SdGRVmB233I-WETXAMCZz7L7HVzoN4aUoIcgNr3g,921 tzdata/zoneinfo/Australia/Brisbane,sha256=2kVWz9CI_qtfdb55g0iL59gUBC7lnO3GUalIQxtHADY,289 tzdata/zoneinfo/Australia/Broken_Hill,sha256=dzk9LvGA_xRStnAIjAFuTJ8Uwz_s7qGWGQmiXPgDsLY,941 tzdata/zoneinfo/Australia/Canberra,sha256=gg1FqGioj4HHMdWyx1i07QAAObYmCoBDP44PCUpgS1k,904 tzdata/zoneinfo/Australia/Currie,sha256=1IAVgf0AA3sBPXFhaxGfu9UQ_cpd4GNpsQ9xio2l4y0,1003 tzdata/zoneinfo/Australia/Darwin,sha256=ZoexbhgdUlV4leV-dhBu6AxDVkJy43xrPb9UQ3EQCdI,234 tzdata/zoneinfo/Australia/Eucla,sha256=3NqsFfMzR6-lSUPViNXBAOyJPqyokisse7uDXurURpk,314 tzdata/zoneinfo/Australia/Hobart,sha256=1IAVgf0AA3sBPXFhaxGfu9UQ_cpd4GNpsQ9xio2l4y0,1003 tzdata/zoneinfo/Australia/LHI,sha256=82i9JWWcApPQK7eex9rH1bc6kt_6_OFLTdL_uLoRqto,692 tzdata/zoneinfo/Australia/Lindeman,sha256=iHkCc0QJ7iaQffiTTXQVJ2swsC7QJxLUMHQOGCFlkTk,325 tzdata/zoneinfo/Australia/Lord_Howe,sha256=82i9JWWcApPQK7eex9rH1bc6kt_6_OFLTdL_uLoRqto,692 tzdata/zoneinfo/Australia/Melbourne,sha256=X7JPMEj_SYWyfgWFMkp6FOmT6GfyjR-lF9hFGgTavnE,904 tzdata/zoneinfo/Australia/NSW,sha256=gg1FqGioj4HHMdWyx1i07QAAObYmCoBDP44PCUpgS1k,904 tzdata/zoneinfo/Australia/North,sha256=ZoexbhgdUlV4leV-dhBu6AxDVkJy43xrPb9UQ3EQCdI,234 tzdata/zoneinfo/Australia/Perth,sha256=ZsuelcBC1YfWugH2CrlOXQcSDD4gGUJCobB1W-aupHo,306 tzdata/zoneinfo/Australia/Queensland,sha256=2kVWz9CI_qtfdb55g0iL59gUBC7lnO3GUalIQxtHADY,289 tzdata/zoneinfo/Australia/South,sha256=Gk1SdGRVmB233I-WETXAMCZz7L7HVzoN4aUoIcgNr3g,921 tzdata/zoneinfo/Australia/Sydney,sha256=gg1FqGioj4HHMdWyx1i07QAAObYmCoBDP44PCUpgS1k,904 tzdata/zoneinfo/Australia/Tasmania,sha256=1IAVgf0AA3sBPXFhaxGfu9UQ_cpd4GNpsQ9xio2l4y0,1003 tzdata/zoneinfo/Australia/Victoria,sha256=X7JPMEj_SYWyfgWFMkp6FOmT6GfyjR-lF9hFGgTavnE,904 tzdata/zoneinfo/Australia/West,sha256=ZsuelcBC1YfWugH2CrlOXQcSDD4gGUJCobB1W-aupHo,306 tzdata/zoneinfo/Australia/Yancowinna,sha256=dzk9LvGA_xRStnAIjAFuTJ8Uwz_s7qGWGQmiXPgDsLY,941 tzdata/zoneinfo/Australia/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Australia/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Brazil/Acre,sha256=VjuQUr668phq5bcH40r94BPnZBKHzJf_MQBfM6Db96U,418 tzdata/zoneinfo/Brazil/DeNoronha,sha256=Q0r3GtA5y2RGkOj56OTZG5tuBy1B6kfbhyrJqCgf27g,484 tzdata/zoneinfo/Brazil/East,sha256=-izrIi8GXAKJ85l_8MVLoFp0pZm0Uihw-oapbiThiJE,952 tzdata/zoneinfo/Brazil/West,sha256=9kgrhpryB94YOVoshJliiiDSf9mwjb3OZwX0HusNRrk,412 tzdata/zoneinfo/Brazil/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Brazil/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/CET,sha256=9q70fJErxHX0_hfgu5Wk0oH5ZZLUWhBIHJI1z7gHgBI,621 tzdata/zoneinfo/CST6CDT,sha256=ajbQjR1ESk2m3dg1sAR2slqafjcfIhw-SC4SC6F7VBY,951 tzdata/zoneinfo/Canada/Atlantic,sha256=kO5ahBM2oTLfWS4KX15FbKXfo5wg-f9vw1_hMOISGig,1672 tzdata/zoneinfo/Canada/Central,sha256=ANzwYGBU1PknQW4LR-H92i5c4Db95LU-UQhPhWZCjDo,1294 tzdata/zoneinfo/Canada/Eastern,sha256=rS1CerA3FRdQOUcbYaphHU_fM8-2HysVmT7BfEAboeU,1717 tzdata/zoneinfo/Canada/Mountain,sha256=Dq2mxcSNWZhMWRqxwwtMcaqwAIGMwkOzz-mW8fJscV8,970 tzdata/zoneinfo/Canada/Newfoundland,sha256=jBTPMhJvnQTt4YCLqLAs3EgPtSzuVO2FxDbcOdh6BaM,1878 tzdata/zoneinfo/Canada/Pacific,sha256=Epou71sUffvHB1rd7wT0krvo3okXAV45_TWcOFpy26Q,1330 tzdata/zoneinfo/Canada/Saskatchewan,sha256=_JHuns225iE-THc9NFp-RBq4PWULAuGw2OLbpOB_UMw,638 tzdata/zoneinfo/Canada/Yukon,sha256=CyY4jNd0fzNSdf1HlYGfaktApmH71tRNRlpOEO32DGs,1029 tzdata/zoneinfo/Canada/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Canada/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Chile/Continental,sha256=_QBpU8K0QqLh5m2yqWfdkypIJDkPAc3dnIAc5jRQxxU,1354 tzdata/zoneinfo/Chile/EasterIsland,sha256=EwVM74XjsboPVxK9bWmdd4nTrtvasP1zlLdxrMB_YaE,1174 tzdata/zoneinfo/Chile/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Chile/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Cuba,sha256=ms5rCuq2yBM49VmTymMtFQN3c5aBN1lkd8jjzKdnNm8,1117 tzdata/zoneinfo/EET,sha256=ftIfVTZNlKejEciANKFFxES2uv_Z4rTAgyjwvk1lLpE,497 tzdata/zoneinfo/EST,sha256=Eqcp0sCDGh_NPbcYAbBhmUob540rIs8FUnkmkZDQ0go,111 tzdata/zoneinfo/EST5EDT,sha256=RAPR1jPCcVa5nvibF24lGKApc2bRw3Y87RbesyI3BP4,951 tzdata/zoneinfo/Egypt,sha256=icuaNiEvuC6TPc2fqhDv36lpop7IDDIGO7tFGMAz0b4,1309 tzdata/zoneinfo/Eire,sha256=EcADNuAvExj-dkqylGfF8q_vv_-mRPqN0k9bCDtJW3E,1496 tzdata/zoneinfo/Etc/GMT,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/Etc/GMT+0,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/Etc/GMT+1,sha256=5L9o8TEUgtB11poIag85vRdq08LMDZmZ6DPn7UqPL_g,113 tzdata/zoneinfo/Etc/GMT+10,sha256=IvBxiqQU76qzNbuxRo8Ah9rPQSRGQGKp_SRs5u1PPkM,114 tzdata/zoneinfo/Etc/GMT+11,sha256=9MfFpFp_rt9PksMjQ23VOlir3hzTlnLz_5V2tfonhbU,114 tzdata/zoneinfo/Etc/GMT+12,sha256=l26XCFp9IbgXGvMw7NHgHzIZbHry2B5qGYfhMDHFVrw,114 tzdata/zoneinfo/Etc/GMT+2,sha256=YbbqH7B6jNoQEIjyV4-8a2cXD9lGC3vQKnEkY2ucDGI,113 tzdata/zoneinfo/Etc/GMT+3,sha256=q3D9DLfmTBUAo4YMnNUNUUKrAkKSwM5Q-vesd9A6SZQ,113 tzdata/zoneinfo/Etc/GMT+4,sha256=UghKME3laXSDZ7q74YDb4FcLnzNqXQydcZpQHvssP2k,113 tzdata/zoneinfo/Etc/GMT+5,sha256=TZ5qaoELlszW_Z5FdqAEMKk8Y_xu5XhZBNZUco55SrM,113 tzdata/zoneinfo/Etc/GMT+6,sha256=_2k3LZ5x8hVjMwwmCx6GqUwW-v1IvOkBrJjYH5bD6Qw,113 tzdata/zoneinfo/Etc/GMT+7,sha256=Di8J430WGr98Ww95tdfIo8hGxkVQfJvlx55ansDuoeQ,113 tzdata/zoneinfo/Etc/GMT+8,sha256=OIIlUFhZwL2ctx3fxINbY2HDDAmSQ7i2ZAUgX7Exjgw,113 tzdata/zoneinfo/Etc/GMT+9,sha256=1vpkIoPqBiwDWzH-fLFxwNbmdKRY7mqdiJhYQImVxaw,113 tzdata/zoneinfo/Etc/GMT-0,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/Etc/GMT-1,sha256=S81S9Z0-V-0B5U-0S0Pnbx8fv2iHtwE1LrlZk-ckLto,114 tzdata/zoneinfo/Etc/GMT-10,sha256=VvdG5IpXB_xJX4omzfrrHblkRUzkbCZXPhTrLngc7vk,115 tzdata/zoneinfo/Etc/GMT-11,sha256=2sYLfVuDFSy7Kc1WOPiY1EqquHw5Xx4HbDA1QOL1hc4,115 tzdata/zoneinfo/Etc/GMT-12,sha256=ifHVhk5fczZG3GDy_Nv7YsLNaxf8stB4MrzgWUCINlU,115 tzdata/zoneinfo/Etc/GMT-13,sha256=CMkORdXsaSyL-4N0n37Cyc1lCr22ZsWyug9_QZVe0E0,115 tzdata/zoneinfo/Etc/GMT-14,sha256=NK07ElwueU0OP8gORtcXUUug_3v4d04uxfVHMUnLM9U,115 tzdata/zoneinfo/Etc/GMT-2,sha256=QMToMLcif1S4SNPOMxMtBLqc1skUYnIhbUAjKEdAf9w,114 tzdata/zoneinfo/Etc/GMT-3,sha256=10GMvfulaJwDQiHiWEJiU_YURyjDfPcl5ugnYBugN3E,114 tzdata/zoneinfo/Etc/GMT-4,sha256=c6Kx3v41GRkrvky8k71db_UJbpyyp2OZCsjDSvjkr6s,114 tzdata/zoneinfo/Etc/GMT-5,sha256=94TvO8e_8t52bs8ry70nAquvgK8qJKQTI7lQnVCHX-U,114 tzdata/zoneinfo/Etc/GMT-6,sha256=3fH8eX--0iDijmYAQHQ0IUXheezaj6-aadZsQNAB4fE,114 tzdata/zoneinfo/Etc/GMT-7,sha256=DnsTJ3NUYYGLUwFb_L15U_GbaMF-acLVsPyTNySyH-M,114 tzdata/zoneinfo/Etc/GMT-8,sha256=kvGQUwONDBG7nhEp_wESc4xl4xNXiXEivxAv09nkr_g,114 tzdata/zoneinfo/Etc/GMT-9,sha256=U1WRFGWQAW91JXK99gY1K9d0rFZYDWHzDUR3z71Lh6Y,114 tzdata/zoneinfo/Etc/GMT0,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/Etc/Greenwich,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/Etc/UCT,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/Etc/UTC,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/Etc/Universal,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/Etc/Zulu,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/Etc/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Etc/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Europe/Amsterdam,sha256=sQ-VQqhQnwpj68p449gEMt2GuOopZAAoD-vZz6dugog,1103 tzdata/zoneinfo/Europe/Andorra,sha256=leuTyE4uduIBX0aHb_7PK_KlslpWSyS6e0SS84hKFrE,389 tzdata/zoneinfo/Europe/Astrakhan,sha256=P3E5UDgQ4gqsMi-KdMAWwOSStogdcNl9rLMVUdpFLXI,726 tzdata/zoneinfo/Europe/Athens,sha256=8f1niwVI4ymziTT2KBJV5pjfp2GtH_hB9sy3lgbGE0U,682 tzdata/zoneinfo/Europe/Belfast,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/Europe/Belgrade,sha256=qMlk8-qnognZplD7FsaMAD6aX8Yv-7sQ-oSdVPs2YtY,478 tzdata/zoneinfo/Europe/Berlin,sha256=p_2ZMteF1NaQkAuDTDVjwYEMHPLgFxG8wJJq9sB2fLc,705 tzdata/zoneinfo/Europe/Bratislava,sha256=pukw4zdc3LUffYp0iFr_if0UuGHrt1yzOdD5HBbBRpo,723 tzdata/zoneinfo/Europe/Brussels,sha256=sQ-VQqhQnwpj68p449gEMt2GuOopZAAoD-vZz6dugog,1103 tzdata/zoneinfo/Europe/Bucharest,sha256=pWUkYQ98vXhFdLu4EQqdul6r9DmB11cL4cfaAPlEbfA,661 tzdata/zoneinfo/Europe/Budapest,sha256=qNr-valoDI1mevuQXqOMkOhIcT194EczOKIijxrDMV8,766 tzdata/zoneinfo/Europe/Busingen,sha256=GZBiscMM_rI3XshMVt9SvlGJGYamKTt6Ek06YlCfRek,497 tzdata/zoneinfo/Europe/Chisinau,sha256=VfQLbvYP7ete6eHeCdMthDfGH_FLiyEXQM7pgyHFsHo,755 tzdata/zoneinfo/Europe/Copenhagen,sha256=p_2ZMteF1NaQkAuDTDVjwYEMHPLgFxG8wJJq9sB2fLc,705 tzdata/zoneinfo/Europe/Dublin,sha256=EcADNuAvExj-dkqylGfF8q_vv_-mRPqN0k9bCDtJW3E,1496 tzdata/zoneinfo/Europe/Gibraltar,sha256=t1hglDTLUIFqs91nY5lulN7oxkoAXHnh0zjyaKG2bG8,1220 tzdata/zoneinfo/Europe/Guernsey,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/Europe/Helsinki,sha256=ccpK9ZmPCZkMXoddNQ_DyONPKAuub-FPNtRpL6znpWM,481 tzdata/zoneinfo/Europe/Isle_of_Man,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/Europe/Istanbul,sha256=KnFjsWuUgG9pmRNI59CmDEbrYbHwMF9fS4P2E9sQgG8,1200 tzdata/zoneinfo/Europe/Jersey,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/Europe/Kaliningrad,sha256=57ov9G8m25w1pPdJF8zoFWzq5I6UoBMVsk2eHPelbA8,904 tzdata/zoneinfo/Europe/Kiev,sha256=0OqsfJh13GOFg6aJP1IAMaHcfawVRTcLZpt2ynK3rJA,558 tzdata/zoneinfo/Europe/Kirov,sha256=KqXGcIbMGTuOoKZYBG-5bj7kVzFbKyGMA99PA0414D0,735 tzdata/zoneinfo/Europe/Kyiv,sha256=0OqsfJh13GOFg6aJP1IAMaHcfawVRTcLZpt2ynK3rJA,558 tzdata/zoneinfo/Europe/Lisbon,sha256=Nr-w4MM_s8Zhwdu1D4cNOQiTZMwZibYswSH1nB1GUKg,1454 tzdata/zoneinfo/Europe/Ljubljana,sha256=qMlk8-qnognZplD7FsaMAD6aX8Yv-7sQ-oSdVPs2YtY,478 tzdata/zoneinfo/Europe/London,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/Europe/Luxembourg,sha256=sQ-VQqhQnwpj68p449gEMt2GuOopZAAoD-vZz6dugog,1103 tzdata/zoneinfo/Europe/Madrid,sha256=ylsyHdv8iOB-DQPtL6DIMs5dDdjn2QolIAqOJImMOyE,897 tzdata/zoneinfo/Europe/Malta,sha256=irX_nDD-BXYObaduu_vhPe1F31xmgL364dSOaT_OVco,928 tzdata/zoneinfo/Europe/Mariehamn,sha256=ccpK9ZmPCZkMXoddNQ_DyONPKAuub-FPNtRpL6znpWM,481 tzdata/zoneinfo/Europe/Minsk,sha256=86iP_xDtidkUCqjkoKhH5_El3VI21fSgoIiXl_BzUaU,808 tzdata/zoneinfo/Europe/Monaco,sha256=zViOd5xXN9cOTkcVja-reUWwJrK7NEVMxHdBgVRZsGg,1105 tzdata/zoneinfo/Europe/Moscow,sha256=7S4KCZ-0RrJBZoNDjT9W-fxaYqFsdUmn9Zy8k1s2TIo,908 tzdata/zoneinfo/Europe/Nicosia,sha256=FDczuLwTlqVEC6bhsxGV7h8s_mDBoLIwl5NNm-LW2T4,597 tzdata/zoneinfo/Europe/Oslo,sha256=p_2ZMteF1NaQkAuDTDVjwYEMHPLgFxG8wJJq9sB2fLc,705 tzdata/zoneinfo/Europe/Paris,sha256=zViOd5xXN9cOTkcVja-reUWwJrK7NEVMxHdBgVRZsGg,1105 tzdata/zoneinfo/Europe/Podgorica,sha256=qMlk8-qnognZplD7FsaMAD6aX8Yv-7sQ-oSdVPs2YtY,478 tzdata/zoneinfo/Europe/Prague,sha256=pukw4zdc3LUffYp0iFr_if0UuGHrt1yzOdD5HBbBRpo,723 tzdata/zoneinfo/Europe/Riga,sha256=HPtq7XEHXsgqU5v3ooB6isA0OhOIKvJn86mVUeKZsgA,694 tzdata/zoneinfo/Europe/Rome,sha256=hr0moG_jBXs2zyndejOPJSSv-BFu8I0AWqIRTqYSKGk,947 tzdata/zoneinfo/Europe/Samara,sha256=Vc60AJe-0-b8prNiFwZTUS1bCbWxxuEnnNcgp8YkQRY,732 tzdata/zoneinfo/Europe/San_Marino,sha256=hr0moG_jBXs2zyndejOPJSSv-BFu8I0AWqIRTqYSKGk,947 tzdata/zoneinfo/Europe/Sarajevo,sha256=qMlk8-qnognZplD7FsaMAD6aX8Yv-7sQ-oSdVPs2YtY,478 tzdata/zoneinfo/Europe/Saratov,sha256=0fN3eVFVewG-DSVk9xJABDQB1S_Nyn37bHOjj5X8Bm0,726 tzdata/zoneinfo/Europe/Simferopol,sha256=y2Nybf9LGVNqNdW_GPS-NIDRLriyH_pyxKpT0zmATK4,865 tzdata/zoneinfo/Europe/Skopje,sha256=qMlk8-qnognZplD7FsaMAD6aX8Yv-7sQ-oSdVPs2YtY,478 tzdata/zoneinfo/Europe/Sofia,sha256=0TXL2VGk6uukiUQHQCk16xvcQDsAPZ02fIQXiQKGdNQ,592 tzdata/zoneinfo/Europe/Stockholm,sha256=p_2ZMteF1NaQkAuDTDVjwYEMHPLgFxG8wJJq9sB2fLc,705 tzdata/zoneinfo/Europe/Tallinn,sha256=ylOItyle7y0jz5IzSMQgjuX1S6Xm_El1NV3CjPAAiGA,675 tzdata/zoneinfo/Europe/Tirane,sha256=I-alATWRd8mfSgvnr3dN_F9vbTB66alvz2GQo0LUbPc,604 tzdata/zoneinfo/Europe/Tiraspol,sha256=VfQLbvYP7ete6eHeCdMthDfGH_FLiyEXQM7pgyHFsHo,755 tzdata/zoneinfo/Europe/Ulyanovsk,sha256=2vK0XahtB_dKjDDXccjMjbQ2bAOfKDe66uMDqtjzHm4,760 tzdata/zoneinfo/Europe/Uzhgorod,sha256=0OqsfJh13GOFg6aJP1IAMaHcfawVRTcLZpt2ynK3rJA,558 tzdata/zoneinfo/Europe/Vaduz,sha256=GZBiscMM_rI3XshMVt9SvlGJGYamKTt6Ek06YlCfRek,497 tzdata/zoneinfo/Europe/Vatican,sha256=hr0moG_jBXs2zyndejOPJSSv-BFu8I0AWqIRTqYSKGk,947 tzdata/zoneinfo/Europe/Vienna,sha256=q8_UF23-KHqc2ay4ju0qT1TuBSpRTnlB7i6vElk4eJw,658 tzdata/zoneinfo/Europe/Vilnius,sha256=mYZJ4nkNElAAptNLaklWyt5_tOUED8fmYLLsRHZGavU,676 tzdata/zoneinfo/Europe/Volgograd,sha256=v3P6iFJ-rThJprVNDxB7ZYDrimtsW7IvQi_gJpZiJOQ,753 tzdata/zoneinfo/Europe/Warsaw,sha256=6I9aUfFoFXpBrC3YpO4OmoeUGchMYSK0dxsaKjPZOkw,923 tzdata/zoneinfo/Europe/Zagreb,sha256=qMlk8-qnognZplD7FsaMAD6aX8Yv-7sQ-oSdVPs2YtY,478 tzdata/zoneinfo/Europe/Zaporozhye,sha256=0OqsfJh13GOFg6aJP1IAMaHcfawVRTcLZpt2ynK3rJA,558 tzdata/zoneinfo/Europe/Zurich,sha256=GZBiscMM_rI3XshMVt9SvlGJGYamKTt6Ek06YlCfRek,497 tzdata/zoneinfo/Europe/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Europe/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Factory,sha256=0ytXntCnQnMWvqJgue4mdUUQRr1YxXxnnCTyZxhgr3Y,113 tzdata/zoneinfo/GB,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/GB-Eire,sha256=uyn7O8ngevKoAEzN2ZbEqStrZGlPhNVY4g_ClHNEXFc,1599 tzdata/zoneinfo/GMT,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/GMT+0,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/GMT-0,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/GMT0,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/Greenwich,sha256=3EoHVxsQiE5PTzRQydGhy_TAPvU9Bu0uTqFS2eul1dc,111 tzdata/zoneinfo/HST,sha256=up2TB-9E2uBD6IGaCSOnR96o_DENUVI9ZCE1zQS0SzY,112 tzdata/zoneinfo/Hongkong,sha256=9AaPcyRtuXQX9zRnRTVkxX1mRs5JCbn6JTaSPvzX608,775 tzdata/zoneinfo/Iceland,sha256=8-f8qg6YQP9BadNWfY-1kmZEhI9JY9es-SMghDxdSG4,130 tzdata/zoneinfo/Indian/Antananarivo,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Indian/Chagos,sha256=J_aS7rs0ZG1dPTGeokXxNJpF4Pds8u1ct49cRtX7giY,152 tzdata/zoneinfo/Indian/Christmas,sha256=zcjiwoLYvJpenDyvL8Rf9OnlzRj13sjLhzNArXxYTWQ,152 tzdata/zoneinfo/Indian/Cocos,sha256=6J2DXIEdTaRKqLOGeCzogo3whaoO6PJWYamIHS8A6Qw,187 tzdata/zoneinfo/Indian/Comoro,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Indian/Kerguelen,sha256=lEhfD1j4QnZ-wtuTU51fw6-yvc4WZz2eY8CYjMzWQ44,152 tzdata/zoneinfo/Indian/Mahe,sha256=DZ6lBT6DGIAypvtNMB1dtoj0MBHltrH5F6EbcaDaexY,133 tzdata/zoneinfo/Indian/Maldives,sha256=lEhfD1j4QnZ-wtuTU51fw6-yvc4WZz2eY8CYjMzWQ44,152 tzdata/zoneinfo/Indian/Mauritius,sha256=R6pdJalrHVK5LlGOmEsyD66_-c5a9ptJM-xE71Fo8hQ,179 tzdata/zoneinfo/Indian/Mayotte,sha256=B4OFT1LDOtprbSpdhnZi8K6OFSONL857mtpPTTGetGY,191 tzdata/zoneinfo/Indian/Reunion,sha256=DZ6lBT6DGIAypvtNMB1dtoj0MBHltrH5F6EbcaDaexY,133 tzdata/zoneinfo/Indian/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Indian/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Iran,sha256=ozLlhNXzpJCZx7bc-VpcmNdgdtn6lPtF6f9qkaDEycI,812 tzdata/zoneinfo/Israel,sha256=n83o1YTeoFhfXIcnqvNfSKFJ4NvTqDv2zvi8qcFAIeM,1074 tzdata/zoneinfo/Jamaica,sha256=pDexcAMzrv9TqLWGjVOHwIDcFMLT6Vqlzjb5AbNmkoQ,339 tzdata/zoneinfo/Japan,sha256=WaOHFDDw07k-YZ-jCkOkHR6IvdSf8m8J0PQFpQBwb5Y,213 tzdata/zoneinfo/Kwajalein,sha256=S-ZFi6idKzDaelLy7DRjGPeD0s7oVud3xLMxZKNlBk8,219 tzdata/zoneinfo/Libya,sha256=zzMBLZZh4VQ4_ARe5k4L_rsuqKP7edKvVt8F6kvj5FM,431 tzdata/zoneinfo/MET,sha256=EgkGCb0euba8FQGgUqAYFx4mRuKeRD6W5GIAyV6yDJ0,621 tzdata/zoneinfo/MST,sha256=84AZayGFK2nfpYS0-u16q9QWrYYkCwUJcNdOnG7Ai1s,111 tzdata/zoneinfo/MST7MDT,sha256=yt9ENOc1sfICs1yxJjiii6FhCQkEsEuw67zvs-EeBb4,951 tzdata/zoneinfo/Mexico/BajaNorte,sha256=8fnbxtJqQnP6myWWVdev2eI1O5yBc8P5hLU9fskYMF4,1025 tzdata/zoneinfo/Mexico/BajaSur,sha256=C5CBj73KgB8vbDbDEgqMHfPeMeglQj156WNbwYSxux8,718 tzdata/zoneinfo/Mexico/General,sha256=vhDy1hSceJyFa3bIqn2qRi1kgxtvrCCaaB7s65mljtY,773 tzdata/zoneinfo/Mexico/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Mexico/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/NZ,sha256=Dgbn5VrtvJLvWz0Qbnw5KrFijP2KQosg6S6ZAooL-7k,1043 tzdata/zoneinfo/NZ-CHAT,sha256=pnhY_Lb8V4eo6cK3yL6JZL086SI_etG6rCycppJfTHg,808 tzdata/zoneinfo/Navajo,sha256=m7cDkg7KS2EZ6BoQVYOk9soiBlHxO0GEeat81WxBPz4,1042 tzdata/zoneinfo/PRC,sha256=v4t-2C_m5j5tmPjOqTTurJAc0Wq6hetXVc4_i0KJ6oo,393 tzdata/zoneinfo/PST8PDT,sha256=8w8p5P18af0k8f2C3amKrvi4tSK83QUhUCV6QmyeTa8,951 tzdata/zoneinfo/Pacific/Apia,sha256=3HDEfICrLIehq3VLq4_r_DhQgFniSd_lXnOjdZgI6hQ,407 tzdata/zoneinfo/Pacific/Auckland,sha256=Dgbn5VrtvJLvWz0Qbnw5KrFijP2KQosg6S6ZAooL-7k,1043 tzdata/zoneinfo/Pacific/Bougainville,sha256=rqdn1Y4HSarx-vjPk00lsHNfhj3IQgKCViAsumuN_IY,201 tzdata/zoneinfo/Pacific/Chatham,sha256=pnhY_Lb8V4eo6cK3yL6JZL086SI_etG6rCycppJfTHg,808 tzdata/zoneinfo/Pacific/Chuuk,sha256=aDABBVtu-dydiHNODt3ReC8cNkO3wTp16c-OkFIAbhk,154 tzdata/zoneinfo/Pacific/Easter,sha256=EwVM74XjsboPVxK9bWmdd4nTrtvasP1zlLdxrMB_YaE,1174 tzdata/zoneinfo/Pacific/Efate,sha256=LiX_rTfipQh_Vnqb_m7OGxyBtyAUC9UANVKHUpLoCcU,342 tzdata/zoneinfo/Pacific/Enderbury,sha256=ojOG-oqi25HOnY6BFhav_3bmWg1LDILT4v-kxOFVuqI,172 tzdata/zoneinfo/Pacific/Fakaofo,sha256=Uf8zeML2X8doPg8CX-p0mMGP-IOj7aHAMe7ULD5khxA,153 tzdata/zoneinfo/Pacific/Fiji,sha256=umCNhtTuBziTXne-WAxzvYvGKqZxTYOTwK-tJhYh4MQ,396 tzdata/zoneinfo/Pacific/Funafuti,sha256=CQNWIL2DFpej6Qcvgt40z8pekS1QyNpUdzmqLyj7bY4,134 tzdata/zoneinfo/Pacific/Galapagos,sha256=Z1KJPZSvO8M_Pay9WLcNAxzjo8imPrQ7FnXNOXfZl8c,175 tzdata/zoneinfo/Pacific/Gambier,sha256=yIh86hjpDk1wRWTVJROOGqn9tkc7e9_O6zNxqs-wBoM,132 tzdata/zoneinfo/Pacific/Guadalcanal,sha256=Ui8PN0th4sb1-n0Z8ceszNCeSiE0Yu47QskNMr8r8Yw,134 tzdata/zoneinfo/Pacific/Guam,sha256=i57eM6syriUFvAbrVALnziCw_I4lENyzBcJdOaH71yU,350 tzdata/zoneinfo/Pacific/Honolulu,sha256=HapXKaoeDzLNRL4RLQGtTMVnqf522H3LuRgr6NLIj_A,221 tzdata/zoneinfo/Pacific/Johnston,sha256=HapXKaoeDzLNRL4RLQGtTMVnqf522H3LuRgr6NLIj_A,221 tzdata/zoneinfo/Pacific/Kanton,sha256=ojOG-oqi25HOnY6BFhav_3bmWg1LDILT4v-kxOFVuqI,172 tzdata/zoneinfo/Pacific/Kiritimati,sha256=cUVGmMRBgllfuYJ3X0B0zg0Bf-LPo9l7Le5ju882dx4,174 tzdata/zoneinfo/Pacific/Kosrae,sha256=pQMLJXilygPhlkm0jCo5JuVmpmYJgLIdiTVxeP59ZEg,242 tzdata/zoneinfo/Pacific/Kwajalein,sha256=S-ZFi6idKzDaelLy7DRjGPeD0s7oVud3xLMxZKNlBk8,219 tzdata/zoneinfo/Pacific/Majuro,sha256=CQNWIL2DFpej6Qcvgt40z8pekS1QyNpUdzmqLyj7bY4,134 tzdata/zoneinfo/Pacific/Marquesas,sha256=ilprkRvn-N1XjptSI_0ZwUjeuokP-5l64uKjRBp0kxw,139 tzdata/zoneinfo/Pacific/Midway,sha256=ZQ2Rh1E2ZZBVMGPNaBWS_cqKCZV-DOLBjWaX7Dhe95Y,146 tzdata/zoneinfo/Pacific/Nauru,sha256=wahZONjreNAmYwhQ2CWdKMAE3SVm4S2aYvMZqcAlSYc,183 tzdata/zoneinfo/Pacific/Niue,sha256=8WWebtgCnrMBKjuLNEYEWlktNI2op2kkKgk0Vcz8GaM,154 tzdata/zoneinfo/Pacific/Norfolk,sha256=F5W2cBezC5Xuy17cz4DJJHMYZBqENTfzc1AiYC0Ll98,247 tzdata/zoneinfo/Pacific/Noumea,sha256=ezUyn7AYWBblrZbStlItJYu7XINCLiihrCBZB-Bl-Qw,198 tzdata/zoneinfo/Pacific/Pago_Pago,sha256=ZQ2Rh1E2ZZBVMGPNaBWS_cqKCZV-DOLBjWaX7Dhe95Y,146 tzdata/zoneinfo/Pacific/Palau,sha256=VkLRsKUUVXo3zrhAXn9iM-pKySbGIVfzWoopDhmceMA,148 tzdata/zoneinfo/Pacific/Pitcairn,sha256=AJh6olJxXQzCMWKOE5ye4jHfgg1VA-9-gCZ5MbrX_8E,153 tzdata/zoneinfo/Pacific/Pohnpei,sha256=Ui8PN0th4sb1-n0Z8ceszNCeSiE0Yu47QskNMr8r8Yw,134 tzdata/zoneinfo/Pacific/Ponape,sha256=Ui8PN0th4sb1-n0Z8ceszNCeSiE0Yu47QskNMr8r8Yw,134 tzdata/zoneinfo/Pacific/Port_Moresby,sha256=aDABBVtu-dydiHNODt3ReC8cNkO3wTp16c-OkFIAbhk,154 tzdata/zoneinfo/Pacific/Rarotonga,sha256=J6a2mOrTp4bsZNovj3HjJK9AVJ89PhdEpQMMVD__i18,406 tzdata/zoneinfo/Pacific/Saipan,sha256=i57eM6syriUFvAbrVALnziCw_I4lENyzBcJdOaH71yU,350 tzdata/zoneinfo/Pacific/Samoa,sha256=ZQ2Rh1E2ZZBVMGPNaBWS_cqKCZV-DOLBjWaX7Dhe95Y,146 tzdata/zoneinfo/Pacific/Tahiti,sha256=Ivcs04hthxEQj1I_6aACc70By0lmxlvhgGFYh843e14,133 tzdata/zoneinfo/Pacific/Tarawa,sha256=CQNWIL2DFpej6Qcvgt40z8pekS1QyNpUdzmqLyj7bY4,134 tzdata/zoneinfo/Pacific/Tongatapu,sha256=mjGjNSUATfw0yLGB0zsLxz3_L1uWxPANML8K4HQQIMY,237 tzdata/zoneinfo/Pacific/Truk,sha256=aDABBVtu-dydiHNODt3ReC8cNkO3wTp16c-OkFIAbhk,154 tzdata/zoneinfo/Pacific/Wake,sha256=CQNWIL2DFpej6Qcvgt40z8pekS1QyNpUdzmqLyj7bY4,134 tzdata/zoneinfo/Pacific/Wallis,sha256=CQNWIL2DFpej6Qcvgt40z8pekS1QyNpUdzmqLyj7bY4,134 tzdata/zoneinfo/Pacific/Yap,sha256=aDABBVtu-dydiHNODt3ReC8cNkO3wTp16c-OkFIAbhk,154 tzdata/zoneinfo/Pacific/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/Pacific/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/Poland,sha256=6I9aUfFoFXpBrC3YpO4OmoeUGchMYSK0dxsaKjPZOkw,923 tzdata/zoneinfo/Portugal,sha256=Nr-w4MM_s8Zhwdu1D4cNOQiTZMwZibYswSH1nB1GUKg,1454 tzdata/zoneinfo/ROC,sha256=oEwscvT3aoMXjQNt2X0VfuHzLkeORN2npcEJI2h-5s8,511 tzdata/zoneinfo/ROK,sha256=ZKcLb7zJtl52Lb0l64m29AwTcUbtyNvU0IHq-s2reN4,415 tzdata/zoneinfo/Singapore,sha256=CVSy2aMB2U9DSAJGBqcbvLL6JNPNNwn1vIvKYFA5eF0,256 tzdata/zoneinfo/Turkey,sha256=KnFjsWuUgG9pmRNI59CmDEbrYbHwMF9fS4P2E9sQgG8,1200 tzdata/zoneinfo/UCT,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/US/Alaska,sha256=d8oMIpYvBpmLzl5I2By4ZaFEZsg_9dxgfqpIM0QFi_Y,977 tzdata/zoneinfo/US/Aleutian,sha256=q_sZgOINX4TsX9iBx1gNd6XGwBnzCjg6qpdAQhK0ieA,969 tzdata/zoneinfo/US/Arizona,sha256=rhFFPCHQiYTedfLv7ATckxeKe04jxeUvIJi4vUXMtUc,240 tzdata/zoneinfo/US/Central,sha256=wntzn_RqffBZThINcltDkhfhHkTqmlDNxJEwODtUguc,1754 tzdata/zoneinfo/US/East-Indiana,sha256=5nj0KhPvvXvg8mqc5T4EscKKWC6rBWEcsBwWg2Qy8Hs,531 tzdata/zoneinfo/US/Eastern,sha256=1_IgazpFmJ_JrWPVWJIlMvpzUigNX4cXa_HbecsdH6k,1744 tzdata/zoneinfo/US/Hawaii,sha256=HapXKaoeDzLNRL4RLQGtTMVnqf522H3LuRgr6NLIj_A,221 tzdata/zoneinfo/US/Indiana-Starke,sha256=KJCzXct8CTMItVLYLYeBqM6aT6b53gWCg6aDbsH58oI,1016 tzdata/zoneinfo/US/Michigan,sha256=I4F8Mt9nx38AF6D-steYskBa_HHO6jKU1-W0yRFr50A,899 tzdata/zoneinfo/US/Mountain,sha256=m7cDkg7KS2EZ6BoQVYOk9soiBlHxO0GEeat81WxBPz4,1042 tzdata/zoneinfo/US/Pacific,sha256=IA0FdU9tg6Nxz0CNcIUSV5dlezsL6-uh5QjP_oaj5cg,1294 tzdata/zoneinfo/US/Samoa,sha256=ZQ2Rh1E2ZZBVMGPNaBWS_cqKCZV-DOLBjWaX7Dhe95Y,146 tzdata/zoneinfo/US/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/US/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/UTC,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/Universal,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/W-SU,sha256=7S4KCZ-0RrJBZoNDjT9W-fxaYqFsdUmn9Zy8k1s2TIo,908 tzdata/zoneinfo/WET,sha256=pAiBtwIi4Sqi79_Ppm2V4VMiMrJKOUvMdCZTJeAizAc,494 tzdata/zoneinfo/Zulu,sha256=_dzh5kihcyrCmv2aFhUbKXPN8ILn7AxpD35CvmtZi5M,111 tzdata/zoneinfo/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 tzdata/zoneinfo/__pycache__/__init__.cpython-311.pyc,, tzdata/zoneinfo/iso3166.tab,sha256=gQmErUEP8d4llZmd-JcsEr_wN4EqizvWxx50a2wsBMw,4446 tzdata/zoneinfo/leapseconds,sha256=hxBfINJuU6Z6N7NQt3SECA9OWlBLFrzDhK2tYynZ7_U,3392 tzdata/zoneinfo/tzdata.zi,sha256=jIaEyl01Ua-tr6HO8OwevF53PE__XsZJnadgBOL55N0,109248 tzdata/zoneinfo/zone.tab,sha256=4sq6yxD3v1vIyrOY_ii7qiJrHq_aNSUtrN87WdXeg60,18855 tzdata/zoneinfo/zone1970.tab,sha256=QKiBcMzCUUjF6j0uOliv2GFfDc2VSbktmzhZf97v6i0,17551 tzdata/zones,sha256=4AHHgvKeqKdJ8jICkeJC_To_5HQBCB6277k0xdFg1G4,9084
castiel248/Convert
Lib/site-packages/tzdata-2023.3.dist-info/RECORD
none
mit
55,963
Wheel-Version: 1.0 Generator: bdist_wheel (0.40.0) Root-Is-Purelib: true Tag: py2-none-any Tag: py3-none-any
castiel248/Convert
Lib/site-packages/tzdata-2023.3.dist-info/WHEEL
none
mit
110
tzdata
castiel248/Convert
Lib/site-packages/tzdata-2023.3.dist-info/top_level.txt
Text
mit
7
# IANA versions like 2020a are not valid PEP 440 identifiers; the recommended # way to translate the version is to use YYYY.n where `n` is a 0-based index. __version__ = "2023.3" # This exposes the original IANA version number. IANA_VERSION = "2023c"
castiel248/Convert
Lib/site-packages/tzdata/__init__.py
Python
mit
252
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Africa/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/America/Argentina/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/America/Indiana/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/America/Kentucky/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/America/North_Dakota/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/America/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Antarctica/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Arctic/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Asia/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Atlantic/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Australia/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Brazil/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Canada/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Chile/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Etc/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Europe/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Indian/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Mexico/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/Pacific/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/US/__init__.py
Python
mit
0
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/__init__.py
Python
mit
0
# ISO 3166 alpha-2 country codes # # This file is in the public domain, so clarified as of # 2009-05-17 by Arthur David Olson. # # From Paul Eggert (2022-11-18): # This file contains a table of two-letter country codes. Columns are # separated by a single tab. Lines beginning with '#' are comments. # All text uses UTF-8 encoding. The columns of the table are as follows: # # 1. ISO 3166-1 alpha-2 country code, current as of # ISO 3166-1 N1087 (2022-09-02). See: Updates on ISO 3166-1 # https://isotc.iso.org/livelink/livelink/Open/16944257 # 2. The usual English name for the coded region, # chosen so that alphabetic sorting of subsets produces helpful lists. # This is not the same as the English name in the ISO 3166 tables. # # The table is sorted by country code. # # This table is intended as an aid for users, to help them select time # zone data appropriate for their practical needs. It is not intended # to take or endorse any position on legal or territorial claims. # #country- #code name of country, territory, area, or subdivision AD Andorra AE United Arab Emirates AF Afghanistan AG Antigua & Barbuda AI Anguilla AL Albania AM Armenia AO Angola AQ Antarctica AR Argentina AS Samoa (American) AT Austria AU Australia AW Aruba AX Åland Islands AZ Azerbaijan BA Bosnia & Herzegovina BB Barbados BD Bangladesh BE Belgium BF Burkina Faso BG Bulgaria BH Bahrain BI Burundi BJ Benin BL St Barthelemy BM Bermuda BN Brunei BO Bolivia BQ Caribbean NL BR Brazil BS Bahamas BT Bhutan BV Bouvet Island BW Botswana BY Belarus BZ Belize CA Canada CC Cocos (Keeling) Islands CD Congo (Dem. Rep.) CF Central African Rep. CG Congo (Rep.) CH Switzerland CI Côte d'Ivoire CK Cook Islands CL Chile CM Cameroon CN China CO Colombia CR Costa Rica CU Cuba CV Cape Verde CW Curaçao CX Christmas Island CY Cyprus CZ Czech Republic DE Germany DJ Djibouti DK Denmark DM Dominica DO Dominican Republic DZ Algeria EC Ecuador EE Estonia EG Egypt EH Western Sahara ER Eritrea ES Spain ET Ethiopia FI Finland FJ Fiji FK Falkland Islands FM Micronesia FO Faroe Islands FR France GA Gabon GB Britain (UK) GD Grenada GE Georgia GF French Guiana GG Guernsey GH Ghana GI Gibraltar GL Greenland GM Gambia GN Guinea GP Guadeloupe GQ Equatorial Guinea GR Greece GS South Georgia & the South Sandwich Islands GT Guatemala GU Guam GW Guinea-Bissau GY Guyana HK Hong Kong HM Heard Island & McDonald Islands HN Honduras HR Croatia HT Haiti HU Hungary ID Indonesia IE Ireland IL Israel IM Isle of Man IN India IO British Indian Ocean Territory IQ Iraq IR Iran IS Iceland IT Italy JE Jersey JM Jamaica JO Jordan JP Japan KE Kenya KG Kyrgyzstan KH Cambodia KI Kiribati KM Comoros KN St Kitts & Nevis KP Korea (North) KR Korea (South) KW Kuwait KY Cayman Islands KZ Kazakhstan LA Laos LB Lebanon LC St Lucia LI Liechtenstein LK Sri Lanka LR Liberia LS Lesotho LT Lithuania LU Luxembourg LV Latvia LY Libya MA Morocco MC Monaco MD Moldova ME Montenegro MF St Martin (French) MG Madagascar MH Marshall Islands MK North Macedonia ML Mali MM Myanmar (Burma) MN Mongolia MO Macau MP Northern Mariana Islands MQ Martinique MR Mauritania MS Montserrat MT Malta MU Mauritius MV Maldives MW Malawi MX Mexico MY Malaysia MZ Mozambique NA Namibia NC New Caledonia NE Niger NF Norfolk Island NG Nigeria NI Nicaragua NL Netherlands NO Norway NP Nepal NR Nauru NU Niue NZ New Zealand OM Oman PA Panama PE Peru PF French Polynesia PG Papua New Guinea PH Philippines PK Pakistan PL Poland PM St Pierre & Miquelon PN Pitcairn PR Puerto Rico PS Palestine PT Portugal PW Palau PY Paraguay QA Qatar RE Réunion RO Romania RS Serbia RU Russia RW Rwanda SA Saudi Arabia SB Solomon Islands SC Seychelles SD Sudan SE Sweden SG Singapore SH St Helena SI Slovenia SJ Svalbard & Jan Mayen SK Slovakia SL Sierra Leone SM San Marino SN Senegal SO Somalia SR Suriname SS South Sudan ST Sao Tome & Principe SV El Salvador SX St Maarten (Dutch) SY Syria SZ Eswatini (Swaziland) TC Turks & Caicos Is TD Chad TF French S. Terr. TG Togo TH Thailand TJ Tajikistan TK Tokelau TL East Timor TM Turkmenistan TN Tunisia TO Tonga TR Turkey TT Trinidad & Tobago TV Tuvalu TW Taiwan TZ Tanzania UA Ukraine UG Uganda UM US minor outlying islands US United States UY Uruguay UZ Uzbekistan VA Vatican City VC St Vincent VE Venezuela VG Virgin Islands (UK) VI Virgin Islands (US) VN Vietnam VU Vanuatu WF Wallis & Futuna WS Samoa (western) YE Yemen YT Mayotte ZA South Africa ZM Zambia ZW Zimbabwe
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/iso3166.tab
tab
mit
4,446
# Allowance for leap seconds added to each time zone file. # This file is in the public domain. # This file is generated automatically from the data in the public-domain # NIST format leap-seconds.list file, which can be copied from # <ftp://ftp.nist.gov/pub/time/leap-seconds.list> # or <ftp://ftp.boulder.nist.gov/pub/time/leap-seconds.list>. # The NIST file is used instead of its IERS upstream counterpart # <https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list> # because under US law the NIST file is public domain # whereas the IERS file's copyright and license status is unclear. # For more about leap-seconds.list, please see # The NTP Timescale and Leap Seconds # <https://www.eecis.udel.edu/~mills/leap.html>. # The rules for leap seconds are specified in Annex 1 (Time scales) of: # Standard-frequency and time-signal emissions. # International Telecommunication Union - Radiocommunication Sector # (ITU-R) Recommendation TF.460-6 (02/2002) # <https://www.itu.int/rec/R-REC-TF.460-6-200202-I/>. # The International Earth Rotation and Reference Systems Service (IERS) # periodically uses leap seconds to keep UTC to within 0.9 s of UT1 # (a proxy for Earth's angle in space as measured by astronomers) # and publishes leap second data in a copyrighted file # <https://hpiers.obspm.fr/iers/bul/bulc/Leap_Second.dat>. # See: Levine J. Coordinated Universal Time and the leap second. # URSI Radio Sci Bull. 2016;89(4):30-6. doi:10.23919/URSIRSB.2016.7909995 # <https://ieeexplore.ieee.org/document/7909995>. # There were no leap seconds before 1972, as no official mechanism # accounted for the discrepancy between atomic time (TAI) and the earth's # rotation. The first ("1 Jan 1972") data line in leap-seconds.list # does not denote a leap second; it denotes the start of the current definition # of UTC. # All leap-seconds are Stationary (S) at the given UTC time. # The correction (+ or -) is made at the given time, so in the unlikely # event of a negative leap second, a line would look like this: # Leap YEAR MON DAY 23:59:59 - S # Typical lines look like this: # Leap YEAR MON DAY 23:59:60 + S Leap 1972 Jun 30 23:59:60 + S Leap 1972 Dec 31 23:59:60 + S Leap 1973 Dec 31 23:59:60 + S Leap 1974 Dec 31 23:59:60 + S Leap 1975 Dec 31 23:59:60 + S Leap 1976 Dec 31 23:59:60 + S Leap 1977 Dec 31 23:59:60 + S Leap 1978 Dec 31 23:59:60 + S Leap 1979 Dec 31 23:59:60 + S Leap 1981 Jun 30 23:59:60 + S Leap 1982 Jun 30 23:59:60 + S Leap 1983 Jun 30 23:59:60 + S Leap 1985 Jun 30 23:59:60 + S Leap 1987 Dec 31 23:59:60 + S Leap 1989 Dec 31 23:59:60 + S Leap 1990 Dec 31 23:59:60 + S Leap 1992 Jun 30 23:59:60 + S Leap 1993 Jun 30 23:59:60 + S Leap 1994 Jun 30 23:59:60 + S Leap 1995 Dec 31 23:59:60 + S Leap 1997 Jun 30 23:59:60 + S Leap 1998 Dec 31 23:59:60 + S Leap 2005 Dec 31 23:59:60 + S Leap 2008 Dec 31 23:59:60 + S Leap 2012 Jun 30 23:59:60 + S Leap 2015 Jun 30 23:59:60 + S Leap 2016 Dec 31 23:59:60 + S # UTC timestamp when this leap second list expires. # Any additional leap seconds will come after this. # This Expires line is commented out for now, # so that pre-2020a zic implementations do not reject this file. #Expires 2023 Dec 28 00:00:00 # POSIX timestamps for the data in this file: #updated 1467936000 (2016-07-08 00:00:00 UTC) #expires 1703721600 (2023-12-28 00:00:00 UTC) # Updated through IERS Bulletin C65 # File expires on: 28 December 2023
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/leapseconds
none
mit
3,392
# version 2023c # This zic input file is in the public domain. R d 1916 o - Jun 14 23s 1 S R d 1916 1919 - O Su>=1 23s 0 - R d 1917 o - Mar 24 23s 1 S R d 1918 o - Mar 9 23s 1 S R d 1919 o - Mar 1 23s 1 S R d 1920 o - F 14 23s 1 S R d 1920 o - O 23 23s 0 - R d 1921 o - Mar 14 23s 1 S R d 1921 o - Jun 21 23s 0 - R d 1939 o - S 11 23s 1 S R d 1939 o - N 19 1 0 - R d 1944 1945 - Ap M>=1 2 1 S R d 1944 o - O 8 2 0 - R d 1945 o - S 16 1 0 - R d 1971 o - Ap 25 23s 1 S R d 1971 o - S 26 23s 0 - R d 1977 o - May 6 0 1 S R d 1977 o - O 21 0 0 - R d 1978 o - Mar 24 1 1 S R d 1978 o - S 22 3 0 - R d 1980 o - Ap 25 0 1 S R d 1980 o - O 31 2 0 - Z Africa/Algiers 0:12:12 - LMT 1891 Mar 16 0:9:21 - PMT 1911 Mar 11 0 d WE%sT 1940 F 25 2 1 d CE%sT 1946 O 7 0 - WET 1956 Ja 29 1 - CET 1963 Ap 14 0 d WE%sT 1977 O 21 1 d CE%sT 1979 O 26 0 d WE%sT 1981 May 1 - CET Z Atlantic/Cape_Verde -1:34:4 - LMT 1912 Ja 1 2u -2 - -02 1942 S -2 1 -01 1945 O 15 -2 - -02 1975 N 25 2 -1 - -01 Z Africa/Ndjamena 1:0:12 - LMT 1912 1 - WAT 1979 O 14 1 1 WAST 1980 Mar 8 1 - WAT Z Africa/Abidjan -0:16:8 - LMT 1912 0 - GMT R K 1940 o - Jul 15 0 1 S R K 1940 o - O 1 0 0 - R K 1941 o - Ap 15 0 1 S R K 1941 o - S 16 0 0 - R K 1942 1944 - Ap 1 0 1 S R K 1942 o - O 27 0 0 - R K 1943 1945 - N 1 0 0 - R K 1945 o - Ap 16 0 1 S R K 1957 o - May 10 0 1 S R K 1957 1958 - O 1 0 0 - R K 1958 o - May 1 0 1 S R K 1959 1981 - May 1 1 1 S R K 1959 1965 - S 30 3 0 - R K 1966 1994 - O 1 3 0 - R K 1982 o - Jul 25 1 1 S R K 1983 o - Jul 12 1 1 S R K 1984 1988 - May 1 1 1 S R K 1989 o - May 6 1 1 S R K 1990 1994 - May 1 1 1 S R K 1995 2010 - Ap lastF 0s 1 S R K 1995 2005 - S lastTh 24 0 - R K 2006 o - S 21 24 0 - R K 2007 o - S Th>=1 24 0 - R K 2008 o - Au lastTh 24 0 - R K 2009 o - Au 20 24 0 - R K 2010 o - Au 10 24 0 - R K 2010 o - S 9 24 1 S R K 2010 o - S lastTh 24 0 - R K 2014 o - May 15 24 1 S R K 2014 o - Jun 26 24 0 - R K 2014 o - Jul 31 24 1 S R K 2014 o - S lastTh 24 0 - R K 2023 ma - Ap lastF 0 1 S R K 2023 ma - O lastTh 24 0 - Z Africa/Cairo 2:5:9 - LMT 1900 O 2 K EE%sT Z Africa/Bissau -1:2:20 - LMT 1912 Ja 1 1u -1 - -01 1975 0 - GMT Z Africa/Nairobi 2:27:16 - LMT 1908 May 2:30 - +0230 1928 Jun 30 24 3 - EAT 1930 Ja 4 24 2:30 - +0230 1936 D 31 24 2:45 - +0245 1942 Jul 31 24 3 - EAT Z Africa/Monrovia -0:43:8 - LMT 1882 -0:43:8 - MMT 1919 Mar -0:44:30 - MMT 1972 Ja 7 0 - GMT R L 1951 o - O 14 2 1 S R L 1952 o - Ja 1 0 0 - R L 1953 o - O 9 2 1 S R L 1954 o - Ja 1 0 0 - R L 1955 o - S 30 0 1 S R L 1956 o - Ja 1 0 0 - R L 1982 1984 - Ap 1 0 1 S R L 1982 1985 - O 1 0 0 - R L 1985 o - Ap 6 0 1 S R L 1986 o - Ap 4 0 1 S R L 1986 o - O 3 0 0 - R L 1987 1989 - Ap 1 0 1 S R L 1987 1989 - O 1 0 0 - R L 1997 o - Ap 4 0 1 S R L 1997 o - O 4 0 0 - R L 2013 o - Mar lastF 1 1 S R L 2013 o - O lastF 2 0 - Z Africa/Tripoli 0:52:44 - LMT 1920 1 L CE%sT 1959 2 - EET 1982 1 L CE%sT 1990 May 4 2 - EET 1996 S 30 1 L CE%sT 1997 O 4 2 - EET 2012 N 10 2 1 L CE%sT 2013 O 25 2 2 - EET R MU 1982 o - O 10 0 1 - R MU 1983 o - Mar 21 0 0 - R MU 2008 o - O lastSu 2 1 - R MU 2009 o - Mar lastSu 2 0 - Z Indian/Mauritius 3:50 - LMT 1907 4 MU +04/+05 R M 1939 o - S 12 0 1 - R M 1939 o - N 19 0 0 - R M 1940 o - F 25 0 1 - R M 1945 o - N 18 0 0 - R M 1950 o - Jun 11 0 1 - R M 1950 o - O 29 0 0 - R M 1967 o - Jun 3 12 1 - R M 1967 o - O 1 0 0 - R M 1974 o - Jun 24 0 1 - R M 1974 o - S 1 0 0 - R M 1976 1977 - May 1 0 1 - R M 1976 o - Au 1 0 0 - R M 1977 o - S 28 0 0 - R M 1978 o - Jun 1 0 1 - R M 1978 o - Au 4 0 0 - R M 2008 o - Jun 1 0 1 - R M 2008 o - S 1 0 0 - R M 2009 o - Jun 1 0 1 - R M 2009 o - Au 21 0 0 - R M 2010 o - May 2 0 1 - R M 2010 o - Au 8 0 0 - R M 2011 o - Ap 3 0 1 - R M 2011 o - Jul 31 0 0 - R M 2012 2013 - Ap lastSu 2 1 - R M 2012 o - Jul 20 3 0 - R M 2012 o - Au 20 2 1 - R M 2012 o - S 30 3 0 - R M 2013 o - Jul 7 3 0 - R M 2013 o - Au 10 2 1 - R M 2013 2018 - O lastSu 3 0 - R M 2014 2018 - Mar lastSu 2 1 - R M 2014 o - Jun 28 3 0 - R M 2014 o - Au 2 2 1 - R M 2015 o - Jun 14 3 0 - R M 2015 o - Jul 19 2 1 - R M 2016 o - Jun 5 3 0 - R M 2016 o - Jul 10 2 1 - R M 2017 o - May 21 3 0 - R M 2017 o - Jul 2 2 1 - R M 2018 o - May 13 3 0 - R M 2018 o - Jun 17 2 1 - R M 2019 o - May 5 3 -1 - R M 2019 o - Jun 9 2 0 - R M 2020 o - Ap 19 3 -1 - R M 2020 o - May 31 2 0 - R M 2021 o - Ap 11 3 -1 - R M 2021 o - May 16 2 0 - R M 2022 o - Mar 27 3 -1 - R M 2022 o - May 8 2 0 - R M 2023 o - Mar 19 3 -1 - R M 2023 o - Ap 23 2 0 - R M 2024 o - Mar 10 3 -1 - R M 2024 o - Ap 14 2 0 - R M 2025 o - F 23 3 -1 - R M 2025 o - Ap 6 2 0 - R M 2026 o - F 15 3 -1 - R M 2026 o - Mar 22 2 0 - R M 2027 o - F 7 3 -1 - R M 2027 o - Mar 14 2 0 - R M 2028 o - Ja 23 3 -1 - R M 2028 o - Mar 5 2 0 - R M 2029 o - Ja 14 3 -1 - R M 2029 o - F 18 2 0 - R M 2029 o - D 30 3 -1 - R M 2030 o - F 10 2 0 - R M 2030 o - D 22 3 -1 - R M 2031 o - Ja 26 2 0 - R M 2031 o - D 14 3 -1 - R M 2032 o - Ja 18 2 0 - R M 2032 o - N 28 3 -1 - R M 2033 o - Ja 9 2 0 - R M 2033 o - N 20 3 -1 - R M 2033 o - D 25 2 0 - R M 2034 o - N 5 3 -1 - R M 2034 o - D 17 2 0 - R M 2035 o - O 28 3 -1 - R M 2035 o - D 9 2 0 - R M 2036 o - O 19 3 -1 - R M 2036 o - N 23 2 0 - R M 2037 o - O 4 3 -1 - R M 2037 o - N 15 2 0 - R M 2038 o - S 26 3 -1 - R M 2038 o - O 31 2 0 - R M 2039 o - S 18 3 -1 - R M 2039 o - O 23 2 0 - R M 2040 o - S 2 3 -1 - R M 2040 o - O 14 2 0 - R M 2041 o - Au 25 3 -1 - R M 2041 o - S 29 2 0 - R M 2042 o - Au 10 3 -1 - R M 2042 o - S 21 2 0 - R M 2043 o - Au 2 3 -1 - R M 2043 o - S 13 2 0 - R M 2044 o - Jul 24 3 -1 - R M 2044 o - Au 28 2 0 - R M 2045 o - Jul 9 3 -1 - R M 2045 o - Au 20 2 0 - R M 2046 o - Jul 1 3 -1 - R M 2046 o - Au 5 2 0 - R M 2047 o - Jun 23 3 -1 - R M 2047 o - Jul 28 2 0 - R M 2048 o - Jun 7 3 -1 - R M 2048 o - Jul 19 2 0 - R M 2049 o - May 30 3 -1 - R M 2049 o - Jul 4 2 0 - R M 2050 o - May 15 3 -1 - R M 2050 o - Jun 26 2 0 - R M 2051 o - May 7 3 -1 - R M 2051 o - Jun 18 2 0 - R M 2052 o - Ap 28 3 -1 - R M 2052 o - Jun 2 2 0 - R M 2053 o - Ap 13 3 -1 - R M 2053 o - May 25 2 0 - R M 2054 o - Ap 5 3 -1 - R M 2054 o - May 10 2 0 - R M 2055 o - Mar 28 3 -1 - R M 2055 o - May 2 2 0 - R M 2056 o - Mar 12 3 -1 - R M 2056 o - Ap 23 2 0 - R M 2057 o - Mar 4 3 -1 - R M 2057 o - Ap 8 2 0 - R M 2058 o - F 17 3 -1 - R M 2058 o - Mar 31 2 0 - R M 2059 o - F 9 3 -1 - R M 2059 o - Mar 23 2 0 - R M 2060 o - F 1 3 -1 - R M 2060 o - Mar 7 2 0 - R M 2061 o - Ja 16 3 -1 - R M 2061 o - F 27 2 0 - R M 2062 o - Ja 8 3 -1 - R M 2062 o - F 12 2 0 - R M 2062 o - D 31 3 -1 - R M 2063 o - F 4 2 0 - R M 2063 o - D 16 3 -1 - R M 2064 o - Ja 27 2 0 - R M 2064 o - D 7 3 -1 - R M 2065 o - Ja 11 2 0 - R M 2065 o - N 22 3 -1 - R M 2066 o - Ja 3 2 0 - R M 2066 o - N 14 3 -1 - R M 2066 o - D 26 2 0 - R M 2067 o - N 6 3 -1 - R M 2067 o - D 11 2 0 - R M 2068 o - O 21 3 -1 - R M 2068 o - D 2 2 0 - R M 2069 o - O 13 3 -1 - R M 2069 o - N 17 2 0 - R M 2070 o - O 5 3 -1 - R M 2070 o - N 9 2 0 - R M 2071 o - S 20 3 -1 - R M 2071 o - N 1 2 0 - R M 2072 o - S 11 3 -1 - R M 2072 o - O 16 2 0 - R M 2073 o - Au 27 3 -1 - R M 2073 o - O 8 2 0 - R M 2074 o - Au 19 3 -1 - R M 2074 o - S 30 2 0 - R M 2075 o - Au 11 3 -1 - R M 2075 o - S 15 2 0 - R M 2076 o - Jul 26 3 -1 - R M 2076 o - S 6 2 0 - R M 2077 o - Jul 18 3 -1 - R M 2077 o - Au 22 2 0 - R M 2078 o - Jul 10 3 -1 - R M 2078 o - Au 14 2 0 - R M 2079 o - Jun 25 3 -1 - R M 2079 o - Au 6 2 0 - R M 2080 o - Jun 16 3 -1 - R M 2080 o - Jul 21 2 0 - R M 2081 o - Jun 1 3 -1 - R M 2081 o - Jul 13 2 0 - R M 2082 o - May 24 3 -1 - R M 2082 o - Jun 28 2 0 - R M 2083 o - May 16 3 -1 - R M 2083 o - Jun 20 2 0 - R M 2084 o - Ap 30 3 -1 - R M 2084 o - Jun 11 2 0 - R M 2085 o - Ap 22 3 -1 - R M 2085 o - May 27 2 0 - R M 2086 o - Ap 14 3 -1 - R M 2086 o - May 19 2 0 - R M 2087 o - Mar 30 3 -1 - R M 2087 o - May 11 2 0 - Z Africa/Casablanca -0:30:20 - LMT 1913 O 26 0 M +00/+01 1984 Mar 16 1 - +01 1986 0 M +00/+01 2018 O 28 3 1 M +01/+00 Z Africa/El_Aaiun -0:52:48 - LMT 1934 -1 - -01 1976 Ap 14 0 M +00/+01 2018 O 28 3 1 M +01/+00 Z Africa/Maputo 2:10:20 - LMT 1903 Mar 2 - CAT R NA 1994 o - Mar 21 0 -1 WAT R NA 1994 2017 - S Su>=1 2 0 CAT R NA 1995 2017 - Ap Su>=1 2 -1 WAT Z Africa/Windhoek 1:8:24 - LMT 1892 F 8 1:30 - +0130 1903 Mar 2 - SAST 1942 S 20 2 2 1 SAST 1943 Mar 21 2 2 - SAST 1990 Mar 21 2 NA %s Z Africa/Lagos 0:13:35 - LMT 1905 Jul 0 - GMT 1908 Jul 0:13:35 - LMT 1914 0:30 - +0030 1919 S 1 - WAT Z Africa/Sao_Tome 0:26:56 - LMT 1884 -0:36:45 - LMT 1912 Ja 1 0u 0 - GMT 2018 Ja 1 1 1 - WAT 2019 Ja 1 2 0 - GMT R SA 1942 1943 - S Su>=15 2 1 - R SA 1943 1944 - Mar Su>=15 2 0 - Z Africa/Johannesburg 1:52 - LMT 1892 F 8 1:30 - SAST 1903 Mar 2 SA SAST R SD 1970 o - May 1 0 1 S R SD 1970 1985 - O 15 0 0 - R SD 1971 o - Ap 30 0 1 S R SD 1972 1985 - Ap lastSu 0 1 S Z Africa/Khartoum 2:10:8 - LMT 1931 2 SD CA%sT 2000 Ja 15 12 3 - EAT 2017 N 2 - CAT Z Africa/Juba 2:6:28 - LMT 1931 2 SD CA%sT 2000 Ja 15 12 3 - EAT 2021 F 2 - CAT R n 1939 o - Ap 15 23s 1 S R n 1939 o - N 18 23s 0 - R n 1940 o - F 25 23s 1 S R n 1941 o - O 6 0 0 - R n 1942 o - Mar 9 0 1 S R n 1942 o - N 2 3 0 - R n 1943 o - Mar 29 2 1 S R n 1943 o - Ap 17 2 0 - R n 1943 o - Ap 25 2 1 S R n 1943 o - O 4 2 0 - R n 1944 1945 - Ap M>=1 2 1 S R n 1944 o - O 8 0 0 - R n 1945 o - S 16 0 0 - R n 1977 o - Ap 30 0s 1 S R n 1977 o - S 24 0s 0 - R n 1978 o - May 1 0s 1 S R n 1978 o - O 1 0s 0 - R n 1988 o - Jun 1 0s 1 S R n 1988 1990 - S lastSu 0s 0 - R n 1989 o - Mar 26 0s 1 S R n 1990 o - May 1 0s 1 S R n 2005 o - May 1 0s 1 S R n 2005 o - S 30 1s 0 - R n 2006 2008 - Mar lastSu 2s 1 S R n 2006 2008 - O lastSu 2s 0 - Z Africa/Tunis 0:40:44 - LMT 1881 May 12 0:9:21 - PMT 1911 Mar 11 1 n CE%sT Z Antarctica/Casey 0 - -00 1969 8 - +08 2009 O 18 2 11 - +11 2010 Mar 5 2 8 - +08 2011 O 28 2 11 - +11 2012 F 21 17u 8 - +08 2016 O 22 11 - +11 2018 Mar 11 4 8 - +08 2018 O 7 4 11 - +11 2019 Mar 17 3 8 - +08 2019 O 4 3 11 - +11 2020 Mar 8 3 8 - +08 2020 O 4 0:1 11 - +11 Z Antarctica/Davis 0 - -00 1957 Ja 13 7 - +07 1964 N 0 - -00 1969 F 7 - +07 2009 O 18 2 5 - +05 2010 Mar 10 20u 7 - +07 2011 O 28 2 5 - +05 2012 F 21 20u 7 - +07 Z Antarctica/Mawson 0 - -00 1954 F 13 6 - +06 2009 O 18 2 5 - +05 R Tr 2005 ma - Mar lastSu 1u 2 +02 R Tr 2004 ma - O lastSu 1u 0 +00 Z Antarctica/Troll 0 - -00 2005 F 12 0 Tr %s Z Antarctica/Rothera 0 - -00 1976 D -3 - -03 Z Asia/Kabul 4:36:48 - LMT 1890 4 - +04 1945 4:30 - +0430 R AM 2011 o - Mar lastSu 2s 1 - R AM 2011 o - O lastSu 2s 0 - Z Asia/Yerevan 2:58 - LMT 1924 May 2 3 - +03 1957 Mar 4 R +04/+05 1991 Mar 31 2s 3 R +03/+04 1995 S 24 2s 4 - +04 1997 4 R +04/+05 2011 4 AM +04/+05 R AZ 1997 2015 - Mar lastSu 4 1 - R AZ 1997 2015 - O lastSu 5 0 - Z Asia/Baku 3:19:24 - LMT 1924 May 2 3 - +03 1957 Mar 4 R +04/+05 1991 Mar 31 2s 3 R +03/+04 1992 S lastSu 2s 4 - +04 1996 4 E +04/+05 1997 4 AZ +04/+05 R BD 2009 o - Jun 19 23 1 - R BD 2009 o - D 31 24 0 - Z Asia/Dhaka 6:1:40 - LMT 1890 5:53:20 - HMT 1941 O 6:30 - +0630 1942 May 15 5:30 - +0530 1942 S 6:30 - +0630 1951 S 30 6 - +06 2009 6 BD +06/+07 Z Asia/Thimphu 5:58:36 - LMT 1947 Au 15 5:30 - +0530 1987 O 6 - +06 Z Indian/Chagos 4:49:40 - LMT 1907 5 - +05 1996 6 - +06 Z Asia/Yangon 6:24:47 - LMT 1880 6:24:47 - RMT 1920 6:30 - +0630 1942 May 9 - +09 1945 May 3 6:30 - +0630 R Sh 1919 o - Ap 12 24 1 D R Sh 1919 o - S 30 24 0 S R Sh 1940 o - Jun 1 0 1 D R Sh 1940 o - O 12 24 0 S R Sh 1941 o - Mar 15 0 1 D R Sh 1941 o - N 1 24 0 S R Sh 1942 o - Ja 31 0 1 D R Sh 1945 o - S 1 24 0 S R Sh 1946 o - May 15 0 1 D R Sh 1946 o - S 30 24 0 S R Sh 1947 o - Ap 15 0 1 D R Sh 1947 o - O 31 24 0 S R Sh 1948 1949 - May 1 0 1 D R Sh 1948 1949 - S 30 24 0 S R CN 1986 o - May 4 2 1 D R CN 1986 1991 - S Su>=11 2 0 S R CN 1987 1991 - Ap Su>=11 2 1 D Z Asia/Shanghai 8:5:43 - LMT 1901 8 Sh C%sT 1949 May 28 8 CN C%sT Z Asia/Urumqi 5:50:20 - LMT 1928 6 - +06 R HK 1946 o - Ap 21 0 1 S R HK 1946 o - D 1 3:30s 0 - R HK 1947 o - Ap 13 3:30s 1 S R HK 1947 o - N 30 3:30s 0 - R HK 1948 o - May 2 3:30s 1 S R HK 1948 1952 - O Su>=28 3:30s 0 - R HK 1949 1953 - Ap Su>=1 3:30 1 S R HK 1953 1964 - O Su>=31 3:30 0 - R HK 1954 1964 - Mar Su>=18 3:30 1 S R HK 1965 1976 - Ap Su>=16 3:30 1 S R HK 1965 1976 - O Su>=16 3:30 0 - R HK 1973 o - D 30 3:30 1 S R HK 1979 o - May 13 3:30 1 S R HK 1979 o - O 21 3:30 0 - Z Asia/Hong_Kong 7:36:42 - LMT 1904 O 29 17u 8 - HKT 1941 Jun 15 3 8 1 HKST 1941 O 1 4 8 0:30 HKWT 1941 D 25 9 - JST 1945 N 18 2 8 HK HK%sT R f 1946 o - May 15 0 1 D R f 1946 o - O 1 0 0 S R f 1947 o - Ap 15 0 1 D R f 1947 o - N 1 0 0 S R f 1948 1951 - May 1 0 1 D R f 1948 1951 - O 1 0 0 S R f 1952 o - Mar 1 0 1 D R f 1952 1954 - N 1 0 0 S R f 1953 1959 - Ap 1 0 1 D R f 1955 1961 - O 1 0 0 S R f 1960 1961 - Jun 1 0 1 D R f 1974 1975 - Ap 1 0 1 D R f 1974 1975 - O 1 0 0 S R f 1979 o - Jul 1 0 1 D R f 1979 o - O 1 0 0 S Z Asia/Taipei 8:6 - LMT 1896 8 - CST 1937 O 9 - JST 1945 S 21 1 8 f C%sT R _ 1942 1943 - Ap 30 23 1 - R _ 1942 o - N 17 23 0 - R _ 1943 o - S 30 23 0 S R _ 1946 o - Ap 30 23s 1 D R _ 1946 o - S 30 23s 0 S R _ 1947 o - Ap 19 23s 1 D R _ 1947 o - N 30 23s 0 S R _ 1948 o - May 2 23s 1 D R _ 1948 o - O 31 23s 0 S R _ 1949 1950 - Ap Sa>=1 23s 1 D R _ 1949 1950 - O lastSa 23s 0 S R _ 1951 o - Mar 31 23s 1 D R _ 1951 o - O 28 23s 0 S R _ 1952 1953 - Ap Sa>=1 23s 1 D R _ 1952 o - N 1 23s 0 S R _ 1953 1954 - O lastSa 23s 0 S R _ 1954 1956 - Mar Sa>=17 23s 1 D R _ 1955 o - N 5 23s 0 S R _ 1956 1964 - N Su>=1 3:30 0 S R _ 1957 1964 - Mar Su>=18 3:30 1 D R _ 1965 1973 - Ap Su>=16 3:30 1 D R _ 1965 1966 - O Su>=16 2:30 0 S R _ 1967 1976 - O Su>=16 3:30 0 S R _ 1973 o - D 30 3:30 1 D R _ 1975 1976 - Ap Su>=16 3:30 1 D R _ 1979 o - May 13 3:30 1 D R _ 1979 o - O Su>=16 3:30 0 S Z Asia/Macau 7:34:10 - LMT 1904 O 30 8 - CST 1941 D 21 23 9 _ +09/+10 1945 S 30 24 8 _ C%sT R CY 1975 o - Ap 13 0 1 S R CY 1975 o - O 12 0 0 - R CY 1976 o - May 15 0 1 S R CY 1976 o - O 11 0 0 - R CY 1977 1980 - Ap Su>=1 0 1 S R CY 1977 o - S 25 0 0 - R CY 1978 o - O 2 0 0 - R CY 1979 1997 - S lastSu 0 0 - R CY 1981 1998 - Mar lastSu 0 1 S Z Asia/Nicosia 2:13:28 - LMT 1921 N 14 2 CY EE%sT 1998 S 2 E EE%sT Z Asia/Famagusta 2:15:48 - LMT 1921 N 14 2 CY EE%sT 1998 S 2 E EE%sT 2016 S 8 3 - +03 2017 O 29 1u 2 E EE%sT Z Asia/Tbilisi 2:59:11 - LMT 1880 2:59:11 - TBMT 1924 May 2 3 - +03 1957 Mar 4 R +04/+05 1991 Mar 31 2s 3 R +03/+04 1992 3 e +03/+04 1994 S lastSu 4 e +04/+05 1996 O lastSu 4 1 +05 1997 Mar lastSu 4 e +04/+05 2004 Jun 27 3 R +03/+04 2005 Mar lastSu 2 4 - +04 Z Asia/Dili 8:22:20 - LMT 1912 8 - +08 1942 F 21 23 9 - +09 1976 May 3 8 - +08 2000 S 17 9 - +09 Z Asia/Kolkata 5:53:28 - LMT 1854 Jun 28 5:53:20 - HMT 1870 5:21:10 - MMT 1906 5:30 - IST 1941 O 5:30 1 +0630 1942 May 15 5:30 - IST 1942 S 5:30 1 +0630 1945 O 15 5:30 - IST Z Asia/Jakarta 7:7:12 - LMT 1867 Au 10 7:7:12 - BMT 1923 D 31 16:40u 7:20 - +0720 1932 N 7:30 - +0730 1942 Mar 23 9 - +09 1945 S 23 7:30 - +0730 1948 May 8 - +08 1950 May 7:30 - +0730 1964 7 - WIB Z Asia/Pontianak 7:17:20 - LMT 1908 May 7:17:20 - PMT 1932 N 7:30 - +0730 1942 Ja 29 9 - +09 1945 S 23 7:30 - +0730 1948 May 8 - +08 1950 May 7:30 - +0730 1964 8 - WITA 1988 7 - WIB Z Asia/Makassar 7:57:36 - LMT 1920 7:57:36 - MMT 1932 N 8 - +08 1942 F 9 9 - +09 1945 S 23 8 - WITA Z Asia/Jayapura 9:22:48 - LMT 1932 N 9 - +09 1944 S 9:30 - +0930 1964 9 - WIT R i 1910 o - Ja 1 0 0 - R i 1977 o - Mar 21 23 1 - R i 1977 o - O 20 24 0 - R i 1978 o - Mar 24 24 1 - R i 1978 o - Au 5 1 0 - R i 1979 o - May 26 24 1 - R i 1979 o - S 18 24 0 - R i 1980 o - Mar 20 24 1 - R i 1980 o - S 22 24 0 - R i 1991 o - May 2 24 1 - R i 1992 1995 - Mar 21 24 1 - R i 1991 1995 - S 21 24 0 - R i 1996 o - Mar 20 24 1 - R i 1996 o - S 20 24 0 - R i 1997 1999 - Mar 21 24 1 - R i 1997 1999 - S 21 24 0 - R i 2000 o - Mar 20 24 1 - R i 2000 o - S 20 24 0 - R i 2001 2003 - Mar 21 24 1 - R i 2001 2003 - S 21 24 0 - R i 2004 o - Mar 20 24 1 - R i 2004 o - S 20 24 0 - R i 2005 o - Mar 21 24 1 - R i 2005 o - S 21 24 0 - R i 2008 o - Mar 20 24 1 - R i 2008 o - S 20 24 0 - R i 2009 2011 - Mar 21 24 1 - R i 2009 2011 - S 21 24 0 - R i 2012 o - Mar 20 24 1 - R i 2012 o - S 20 24 0 - R i 2013 2015 - Mar 21 24 1 - R i 2013 2015 - S 21 24 0 - R i 2016 o - Mar 20 24 1 - R i 2016 o - S 20 24 0 - R i 2017 2019 - Mar 21 24 1 - R i 2017 2019 - S 21 24 0 - R i 2020 o - Mar 20 24 1 - R i 2020 o - S 20 24 0 - R i 2021 2022 - Mar 21 24 1 - R i 2021 2022 - S 21 24 0 - Z Asia/Tehran 3:25:44 - LMT 1916 3:25:44 - TMT 1935 Jun 13 3:30 i +0330/+0430 1977 O 20 24 4 i +04/+05 1979 3:30 i +0330/+0430 R IQ 1982 o - May 1 0 1 - R IQ 1982 1984 - O 1 0 0 - R IQ 1983 o - Mar 31 0 1 - R IQ 1984 1985 - Ap 1 0 1 - R IQ 1985 1990 - S lastSu 1s 0 - R IQ 1986 1990 - Mar lastSu 1s 1 - R IQ 1991 2007 - Ap 1 3s 1 - R IQ 1991 2007 - O 1 3s 0 - Z Asia/Baghdad 2:57:40 - LMT 1890 2:57:36 - BMT 1918 3 - +03 1982 May 3 IQ +03/+04 R Z 1940 o - May 31 24u 1 D R Z 1940 o - S 30 24u 0 S R Z 1940 o - N 16 24u 1 D R Z 1942 1946 - O 31 24u 0 S R Z 1943 1944 - Mar 31 24u 1 D R Z 1945 1946 - Ap 15 24u 1 D R Z 1948 o - May 22 24u 2 DD R Z 1948 o - Au 31 24u 1 D R Z 1948 1949 - O 31 24u 0 S R Z 1949 o - Ap 30 24u 1 D R Z 1950 o - Ap 15 24u 1 D R Z 1950 o - S 14 24u 0 S R Z 1951 o - Mar 31 24u 1 D R Z 1951 o - N 10 24u 0 S R Z 1952 o - Ap 19 24u 1 D R Z 1952 o - O 18 24u 0 S R Z 1953 o - Ap 11 24u 1 D R Z 1953 o - S 12 24u 0 S R Z 1954 o - Jun 12 24u 1 D R Z 1954 o - S 11 24u 0 S R Z 1955 o - Jun 11 24u 1 D R Z 1955 o - S 10 24u 0 S R Z 1956 o - Jun 2 24u 1 D R Z 1956 o - S 29 24u 0 S R Z 1957 o - Ap 27 24u 1 D R Z 1957 o - S 21 24u 0 S R Z 1974 o - Jul 6 24 1 D R Z 1974 o - O 12 24 0 S R Z 1975 o - Ap 19 24 1 D R Z 1975 o - Au 30 24 0 S R Z 1980 o - Au 2 24s 1 D R Z 1980 o - S 13 24s 0 S R Z 1984 o - May 5 24s 1 D R Z 1984 o - Au 25 24s 0 S R Z 1985 o - Ap 13 24 1 D R Z 1985 o - Au 31 24 0 S R Z 1986 o - May 17 24 1 D R Z 1986 o - S 6 24 0 S R Z 1987 o - Ap 14 24 1 D R Z 1987 o - S 12 24 0 S R Z 1988 o - Ap 9 24 1 D R Z 1988 o - S 3 24 0 S R Z 1989 o - Ap 29 24 1 D R Z 1989 o - S 2 24 0 S R Z 1990 o - Mar 24 24 1 D R Z 1990 o - Au 25 24 0 S R Z 1991 o - Mar 23 24 1 D R Z 1991 o - Au 31 24 0 S R Z 1992 o - Mar 28 24 1 D R Z 1992 o - S 5 24 0 S R Z 1993 o - Ap 2 0 1 D R Z 1993 o - S 5 0 0 S R Z 1994 o - Ap 1 0 1 D R Z 1994 o - Au 28 0 0 S R Z 1995 o - Mar 31 0 1 D R Z 1995 o - S 3 0 0 S R Z 1996 o - Mar 14 24 1 D R Z 1996 o - S 15 24 0 S R Z 1997 o - Mar 20 24 1 D R Z 1997 o - S 13 24 0 S R Z 1998 o - Mar 20 0 1 D R Z 1998 o - S 6 0 0 S R Z 1999 o - Ap 2 2 1 D R Z 1999 o - S 3 2 0 S R Z 2000 o - Ap 14 2 1 D R Z 2000 o - O 6 1 0 S R Z 2001 o - Ap 9 1 1 D R Z 2001 o - S 24 1 0 S R Z 2002 o - Mar 29 1 1 D R Z 2002 o - O 7 1 0 S R Z 2003 o - Mar 28 1 1 D R Z 2003 o - O 3 1 0 S R Z 2004 o - Ap 7 1 1 D R Z 2004 o - S 22 1 0 S R Z 2005 2012 - Ap F<=1 2 1 D R Z 2005 o - O 9 2 0 S R Z 2006 o - O 1 2 0 S R Z 2007 o - S 16 2 0 S R Z 2008 o - O 5 2 0 S R Z 2009 o - S 27 2 0 S R Z 2010 o - S 12 2 0 S R Z 2011 o - O 2 2 0 S R Z 2012 o - S 23 2 0 S R Z 2013 ma - Mar F>=23 2 1 D R Z 2013 ma - O lastSu 2 0 S Z Asia/Jerusalem 2:20:54 - LMT 1880 2:20:40 - JMT 1918 2 Z I%sT R JP 1948 o - May Sa>=1 24 1 D R JP 1948 1951 - S Sa>=8 25 0 S R JP 1949 o - Ap Sa>=1 24 1 D R JP 1950 1951 - May Sa>=1 24 1 D Z Asia/Tokyo 9:18:59 - LMT 1887 D 31 15u 9 JP J%sT R J 1973 o - Jun 6 0 1 S R J 1973 1975 - O 1 0 0 - R J 1974 1977 - May 1 0 1 S R J 1976 o - N 1 0 0 - R J 1977 o - O 1 0 0 - R J 1978 o - Ap 30 0 1 S R J 1978 o - S 30 0 0 - R J 1985 o - Ap 1 0 1 S R J 1985 o - O 1 0 0 - R J 1986 1988 - Ap F>=1 0 1 S R J 1986 1990 - O F>=1 0 0 - R J 1989 o - May 8 0 1 S R J 1990 o - Ap 27 0 1 S R J 1991 o - Ap 17 0 1 S R J 1991 o - S 27 0 0 - R J 1992 o - Ap 10 0 1 S R J 1992 1993 - O F>=1 0 0 - R J 1993 1998 - Ap F>=1 0 1 S R J 1994 o - S F>=15 0 0 - R J 1995 1998 - S F>=15 0s 0 - R J 1999 o - Jul 1 0s 1 S R J 1999 2002 - S lastF 0s 0 - R J 2000 2001 - Mar lastTh 0s 1 S R J 2002 2012 - Mar lastTh 24 1 S R J 2003 o - O 24 0s 0 - R J 2004 o - O 15 0s 0 - R J 2005 o - S lastF 0s 0 - R J 2006 2011 - O lastF 0s 0 - R J 2013 o - D 20 0 0 - R J 2014 2021 - Mar lastTh 24 1 S R J 2014 2022 - O lastF 0s 0 - R J 2022 o - F lastTh 24 1 S Z Asia/Amman 2:23:44 - LMT 1931 2 J EE%sT 2022 O 28 0s 3 - +03 Z Asia/Almaty 5:7:48 - LMT 1924 May 2 5 - +05 1930 Jun 21 6 R +06/+07 1991 Mar 31 2s 5 R +05/+06 1992 Ja 19 2s 6 R +06/+07 2004 O 31 2s 6 - +06 Z Asia/Qyzylorda 4:21:52 - LMT 1924 May 2 4 - +04 1930 Jun 21 5 - +05 1981 Ap 5 1 +06 1981 O 6 - +06 1982 Ap 5 R +05/+06 1991 Mar 31 2s 4 R +04/+05 1991 S 29 2s 5 R +05/+06 1992 Ja 19 2s 6 R +06/+07 1992 Mar 29 2s 5 R +05/+06 2004 O 31 2s 6 - +06 2018 D 21 5 - +05 Z Asia/Qostanay 4:14:28 - LMT 1924 May 2 4 - +04 1930 Jun 21 5 - +05 1981 Ap 5 1 +06 1981 O 6 - +06 1982 Ap 5 R +05/+06 1991 Mar 31 2s 4 R +04/+05 1992 Ja 19 2s 5 R +05/+06 2004 O 31 2s 6 - +06 Z Asia/Aqtobe 3:48:40 - LMT 1924 May 2 4 - +04 1930 Jun 21 5 - +05 1981 Ap 5 1 +06 1981 O 6 - +06 1982 Ap 5 R +05/+06 1991 Mar 31 2s 4 R +04/+05 1992 Ja 19 2s 5 R +05/+06 2004 O 31 2s 5 - +05 Z Asia/Aqtau 3:21:4 - LMT 1924 May 2 4 - +04 1930 Jun 21 5 - +05 1981 O 6 - +06 1982 Ap 5 R +05/+06 1991 Mar 31 2s 4 R +04/+05 1992 Ja 19 2s 5 R +05/+06 1994 S 25 2s 4 R +04/+05 2004 O 31 2s 5 - +05 Z Asia/Atyrau 3:27:44 - LMT 1924 May 2 3 - +03 1930 Jun 21 5 - +05 1981 O 6 - +06 1982 Ap 5 R +05/+06 1991 Mar 31 2s 4 R +04/+05 1992 Ja 19 2s 5 R +05/+06 1999 Mar 28 2s 4 R +04/+05 2004 O 31 2s 5 - +05 Z Asia/Oral 3:25:24 - LMT 1924 May 2 3 - +03 1930 Jun 21 5 - +05 1981 Ap 5 1 +06 1981 O 6 - +06 1982 Ap 5 R +05/+06 1989 Mar 26 2s 4 R +04/+05 1992 Ja 19 2s 5 R +05/+06 1992 Mar 29 2s 4 R +04/+05 2004 O 31 2s 5 - +05 R KG 1992 1996 - Ap Su>=7 0s 1 - R KG 1992 1996 - S lastSu 0 0 - R KG 1997 2005 - Mar lastSu 2:30 1 - R KG 1997 2004 - O lastSu 2:30 0 - Z Asia/Bishkek 4:58:24 - LMT 1924 May 2 5 - +05 1930 Jun 21 6 R +06/+07 1991 Mar 31 2s 5 R +05/+06 1991 Au 31 2 5 KG +05/+06 2005 Au 12 6 - +06 R KR 1948 o - Jun 1 0 1 D R KR 1948 o - S 12 24 0 S R KR 1949 o - Ap 3 0 1 D R KR 1949 1951 - S Sa>=7 24 0 S R KR 1950 o - Ap 1 0 1 D R KR 1951 o - May 6 0 1 D R KR 1955 o - May 5 0 1 D R KR 1955 o - S 8 24 0 S R KR 1956 o - May 20 0 1 D R KR 1956 o - S 29 24 0 S R KR 1957 1960 - May Su>=1 0 1 D R KR 1957 1960 - S Sa>=17 24 0 S R KR 1987 1988 - May Su>=8 2 1 D R KR 1987 1988 - O Su>=8 3 0 S Z Asia/Seoul 8:27:52 - LMT 1908 Ap 8:30 - KST 1912 9 - JST 1945 S 8 9 KR K%sT 1954 Mar 21 8:30 KR K%sT 1961 Au 10 9 KR K%sT Z Asia/Pyongyang 8:23 - LMT 1908 Ap 8:30 - KST 1912 9 - JST 1945 Au 24 9 - KST 2015 Au 15 8:30 - KST 2018 May 4 23:30 9 - KST R l 1920 o - Mar 28 0 1 S R l 1920 o - O 25 0 0 - R l 1921 o - Ap 3 0 1 S R l 1921 o - O 3 0 0 - R l 1922 o - Mar 26 0 1 S R l 1922 o - O 8 0 0 - R l 1923 o - Ap 22 0 1 S R l 1923 o - S 16 0 0 - R l 1957 1961 - May 1 0 1 S R l 1957 1961 - O 1 0 0 - R l 1972 o - Jun 22 0 1 S R l 1972 1977 - O 1 0 0 - R l 1973 1977 - May 1 0 1 S R l 1978 o - Ap 30 0 1 S R l 1978 o - S 30 0 0 - R l 1984 1987 - May 1 0 1 S R l 1984 1991 - O 16 0 0 - R l 1988 o - Jun 1 0 1 S R l 1989 o - May 10 0 1 S R l 1990 1992 - May 1 0 1 S R l 1992 o - O 4 0 0 - R l 1993 ma - Mar lastSu 0 1 S R l 1993 1998 - S lastSu 0 0 - R l 1999 ma - O lastSu 0 0 - Z Asia/Beirut 2:22 - LMT 1880 2 l EE%sT R NB 1935 1941 - S 14 0 0:20 - R NB 1935 1941 - D 14 0 0 - Z Asia/Kuching 7:21:20 - LMT 1926 Mar 7:30 - +0730 1933 8 NB +08/+0820 1942 F 16 9 - +09 1945 S 12 8 - +08 Z Indian/Maldives 4:54 - LMT 1880 4:54 - MMT 1960 5 - +05 R X 1983 1984 - Ap 1 0 1 - R X 1983 o - O 1 0 0 - R X 1985 1998 - Mar lastSu 0 1 - R X 1984 1998 - S lastSu 0 0 - R X 2001 o - Ap lastSa 2 1 - R X 2001 2006 - S lastSa 2 0 - R X 2002 2006 - Mar lastSa 2 1 - R X 2015 2016 - Mar lastSa 2 1 - R X 2015 2016 - S lastSa 0 0 - Z Asia/Hovd 6:6:36 - LMT 1905 Au 6 - +06 1978 7 X +07/+08 Z Asia/Ulaanbaatar 7:7:32 - LMT 1905 Au 7 - +07 1978 8 X +08/+09 Z Asia/Choibalsan 7:38 - LMT 1905 Au 7 - +07 1978 8 - +08 1983 Ap 9 X +09/+10 2008 Mar 31 8 X +08/+09 Z Asia/Kathmandu 5:41:16 - LMT 1920 5:30 - +0530 1986 5:45 - +0545 R PK 2002 o - Ap Su>=2 0 1 S R PK 2002 o - O Su>=2 0 0 - R PK 2008 o - Jun 1 0 1 S R PK 2008 2009 - N 1 0 0 - R PK 2009 o - Ap 15 0 1 S Z Asia/Karachi 4:28:12 - LMT 1907 5:30 - +0530 1942 S 5:30 1 +0630 1945 O 15 5:30 - +0530 1951 S 30 5 - +05 1971 Mar 26 5 PK PK%sT R P 1999 2005 - Ap F>=15 0 1 S R P 1999 2003 - O F>=15 0 0 - R P 2004 o - O 1 1 0 - R P 2005 o - O 4 2 0 - R P 2006 2007 - Ap 1 0 1 S R P 2006 o - S 22 0 0 - R P 2007 o - S 13 2 0 - R P 2008 2009 - Mar lastF 0 1 S R P 2008 o - S 1 0 0 - R P 2009 o - S 4 1 0 - R P 2010 o - Mar 26 0 1 S R P 2010 o - Au 11 0 0 - R P 2011 o - Ap 1 0:1 1 S R P 2011 o - Au 1 0 0 - R P 2011 o - Au 30 0 1 S R P 2011 o - S 30 0 0 - R P 2012 2014 - Mar lastTh 24 1 S R P 2012 o - S 21 1 0 - R P 2013 o - S 27 0 0 - R P 2014 o - O 24 0 0 - R P 2015 o - Mar 28 0 1 S R P 2015 o - O 23 1 0 - R P 2016 2018 - Mar Sa<=30 1 1 S R P 2016 2018 - O Sa<=30 1 0 - R P 2019 o - Mar 29 0 1 S R P 2019 o - O Sa<=30 0 0 - R P 2020 2021 - Mar Sa<=30 0 1 S R P 2020 o - O 24 1 0 - R P 2021 o - O 29 1 0 - R P 2022 o - Mar 27 0 1 S R P 2022 2035 - O Sa<=30 2 0 - R P 2023 o - Ap 29 2 1 S R P 2024 o - Ap 13 2 1 S R P 2025 o - Ap 5 2 1 S R P 2026 2054 - Mar Sa<=30 2 1 S R P 2036 o - O 18 2 0 - R P 2037 o - O 10 2 0 - R P 2038 o - S 25 2 0 - R P 2039 o - S 17 2 0 - R P 2039 o - O 22 2 1 S R P 2039 2067 - O Sa<=30 2 0 - R P 2040 o - S 1 2 0 - R P 2040 o - O 13 2 1 S R P 2041 o - Au 24 2 0 - R P 2041 o - S 28 2 1 S R P 2042 o - Au 16 2 0 - R P 2042 o - S 20 2 1 S R P 2043 o - Au 1 2 0 - R P 2043 o - S 12 2 1 S R P 2044 o - Jul 23 2 0 - R P 2044 o - Au 27 2 1 S R P 2045 o - Jul 15 2 0 - R P 2045 o - Au 19 2 1 S R P 2046 o - Jun 30 2 0 - R P 2046 o - Au 11 2 1 S R P 2047 o - Jun 22 2 0 - R P 2047 o - Jul 27 2 1 S R P 2048 o - Jun 6 2 0 - R P 2048 o - Jul 18 2 1 S R P 2049 o - May 29 2 0 - R P 2049 o - Jul 3 2 1 S R P 2050 o - May 21 2 0 - R P 2050 o - Jun 25 2 1 S R P 2051 o - May 6 2 0 - R P 2051 o - Jun 17 2 1 S R P 2052 o - Ap 27 2 0 - R P 2052 o - Jun 1 2 1 S R P 2053 o - Ap 12 2 0 - R P 2053 o - May 24 2 1 S R P 2054 o - Ap 4 2 0 - R P 2054 o - May 16 2 1 S R P 2055 o - May 1 2 1 S R P 2056 o - Ap 22 2 1 S R P 2057 o - Ap 7 2 1 S R P 2058 ma - Mar Sa<=30 2 1 S R P 2068 o - O 20 2 0 - R P 2069 o - O 12 2 0 - R P 2070 o - O 4 2 0 - R P 2071 o - S 19 2 0 - R P 2072 o - S 10 2 0 - R P 2072 o - O 15 2 1 S R P 2073 o - S 2 2 0 - R P 2073 o - O 7 2 1 S R P 2074 o - Au 18 2 0 - R P 2074 o - S 29 2 1 S R P 2075 o - Au 10 2 0 - R P 2075 o - S 14 2 1 S R P 2075 ma - O Sa<=30 2 0 - R P 2076 o - Jul 25 2 0 - R P 2076 o - S 5 2 1 S R P 2077 o - Jul 17 2 0 - R P 2077 o - Au 28 2 1 S R P 2078 o - Jul 9 2 0 - R P 2078 o - Au 13 2 1 S R P 2079 o - Jun 24 2 0 - R P 2079 o - Au 5 2 1 S R P 2080 o - Jun 15 2 0 - R P 2080 o - Jul 20 2 1 S R P 2081 o - Jun 7 2 0 - R P 2081 o - Jul 12 2 1 S R P 2082 o - May 23 2 0 - R P 2082 o - Jul 4 2 1 S R P 2083 o - May 15 2 0 - R P 2083 o - Jun 19 2 1 S R P 2084 o - Ap 29 2 0 - R P 2084 o - Jun 10 2 1 S R P 2085 o - Ap 21 2 0 - R P 2085 o - Jun 2 2 1 S R P 2086 o - Ap 13 2 0 - R P 2086 o - May 18 2 1 S Z Asia/Gaza 2:17:52 - LMT 1900 O 2 Z EET/EEST 1948 May 15 2 K EE%sT 1967 Jun 5 2 Z I%sT 1996 2 J EE%sT 1999 2 P EE%sT 2008 Au 29 2 - EET 2008 S 2 P EE%sT 2010 2 - EET 2010 Mar 27 0:1 2 P EE%sT 2011 Au 2 - EET 2012 2 P EE%sT Z Asia/Hebron 2:20:23 - LMT 1900 O 2 Z EET/EEST 1948 May 15 2 K EE%sT 1967 Jun 5 2 Z I%sT 1996 2 J EE%sT 1999 2 P EE%sT R PH 1936 o - N 1 0 1 D R PH 1937 o - F 1 0 0 S R PH 1954 o - Ap 12 0 1 D R PH 1954 o - Jul 1 0 0 S R PH 1978 o - Mar 22 0 1 D R PH 1978 o - S 21 0 0 S Z Asia/Manila -15:56 - LMT 1844 D 31 8:4 - LMT 1899 May 11 8 PH P%sT 1942 May 9 - JST 1944 N 8 PH P%sT Z Asia/Qatar 3:26:8 - LMT 1920 4 - +04 1972 Jun 3 - +03 Z Asia/Riyadh 3:6:52 - LMT 1947 Mar 14 3 - +03 Z Asia/Singapore 6:55:25 - LMT 1901 6:55:25 - SMT 1905 Jun 7 - +07 1933 7 0:20 +0720 1936 7:20 - +0720 1941 S 7:30 - +0730 1942 F 16 9 - +09 1945 S 12 7:30 - +0730 1981 D 31 16u 8 - +08 Z Asia/Colombo 5:19:24 - LMT 1880 5:19:32 - MMT 1906 5:30 - +0530 1942 Ja 5 5:30 0:30 +06 1942 S 5:30 1 +0630 1945 O 16 2 5:30 - +0530 1996 May 25 6:30 - +0630 1996 O 26 0:30 6 - +06 2006 Ap 15 0:30 5:30 - +0530 R S 1920 1923 - Ap Su>=15 2 1 S R S 1920 1923 - O Su>=1 2 0 - R S 1962 o - Ap 29 2 1 S R S 1962 o - O 1 2 0 - R S 1963 1965 - May 1 2 1 S R S 1963 o - S 30 2 0 - R S 1964 o - O 1 2 0 - R S 1965 o - S 30 2 0 - R S 1966 o - Ap 24 2 1 S R S 1966 1976 - O 1 2 0 - R S 1967 1978 - May 1 2 1 S R S 1977 1978 - S 1 2 0 - R S 1983 1984 - Ap 9 2 1 S R S 1983 1984 - O 1 2 0 - R S 1986 o - F 16 2 1 S R S 1986 o - O 9 2 0 - R S 1987 o - Mar 1 2 1 S R S 1987 1988 - O 31 2 0 - R S 1988 o - Mar 15 2 1 S R S 1989 o - Mar 31 2 1 S R S 1989 o - O 1 2 0 - R S 1990 o - Ap 1 2 1 S R S 1990 o - S 30 2 0 - R S 1991 o - Ap 1 0 1 S R S 1991 1992 - O 1 0 0 - R S 1992 o - Ap 8 0 1 S R S 1993 o - Mar 26 0 1 S R S 1993 o - S 25 0 0 - R S 1994 1996 - Ap 1 0 1 S R S 1994 2005 - O 1 0 0 - R S 1997 1998 - Mar lastM 0 1 S R S 1999 2006 - Ap 1 0 1 S R S 2006 o - S 22 0 0 - R S 2007 o - Mar lastF 0 1 S R S 2007 o - N F>=1 0 0 - R S 2008 o - Ap F>=1 0 1 S R S 2008 o - N 1 0 0 - R S 2009 o - Mar lastF 0 1 S R S 2010 2011 - Ap F>=1 0 1 S R S 2012 2022 - Mar lastF 0 1 S R S 2009 2022 - O lastF 0 0 - Z Asia/Damascus 2:25:12 - LMT 1920 2 S EE%sT 2022 O 28 3 - +03 Z Asia/Dushanbe 4:35:12 - LMT 1924 May 2 5 - +05 1930 Jun 21 6 R +06/+07 1991 Mar 31 2s 5 1 +06 1991 S 9 2s 5 - +05 Z Asia/Bangkok 6:42:4 - LMT 1880 6:42:4 - BMT 1920 Ap 7 - +07 Z Asia/Ashgabat 3:53:32 - LMT 1924 May 2 4 - +04 1930 Jun 21 5 R +05/+06 1991 Mar 31 2 4 R +04/+05 1992 Ja 19 2 5 - +05 Z Asia/Dubai 3:41:12 - LMT 1920 4 - +04 Z Asia/Samarkand 4:27:53 - LMT 1924 May 2 4 - +04 1930 Jun 21 5 - +05 1981 Ap 5 1 +06 1981 O 6 - +06 1982 Ap 5 R +05/+06 1992 5 - +05 Z Asia/Tashkent 4:37:11 - LMT 1924 May 2 5 - +05 1930 Jun 21 6 R +06/+07 1991 Mar 31 2 5 R +05/+06 1992 5 - +05 Z Asia/Ho_Chi_Minh 7:6:30 - LMT 1906 Jul 7:6:30 - PLMT 1911 May 7 - +07 1942 D 31 23 8 - +08 1945 Mar 14 23 9 - +09 1945 S 2 7 - +07 1947 Ap 8 - +08 1955 Jul 7 - +07 1959 D 31 23 8 - +08 1975 Jun 13 7 - +07 R AU 1917 o - Ja 1 2s 1 D R AU 1917 o - Mar lastSu 2s 0 S R AU 1942 o - Ja 1 2s 1 D R AU 1942 o - Mar lastSu 2s 0 S R AU 1942 o - S 27 2s 1 D R AU 1943 1944 - Mar lastSu 2s 0 S R AU 1943 o - O 3 2s 1 D Z Australia/Darwin 8:43:20 - LMT 1895 F 9 - ACST 1899 May 9:30 AU AC%sT R AW 1974 o - O lastSu 2s 1 D R AW 1975 o - Mar Su>=1 2s 0 S R AW 1983 o - O lastSu 2s 1 D R AW 1984 o - Mar Su>=1 2s 0 S R AW 1991 o - N 17 2s 1 D R AW 1992 o - Mar Su>=1 2s 0 S R AW 2006 o - D 3 2s 1 D R AW 2007 2009 - Mar lastSu 2s 0 S R AW 2007 2008 - O lastSu 2s 1 D Z Australia/Perth 7:43:24 - LMT 1895 D 8 AU AW%sT 1943 Jul 8 AW AW%sT Z Australia/Eucla 8:35:28 - LMT 1895 D 8:45 AU +0845/+0945 1943 Jul 8:45 AW +0845/+0945 R AQ 1971 o - O lastSu 2s 1 D R AQ 1972 o - F lastSu 2s 0 S R AQ 1989 1991 - O lastSu 2s 1 D R AQ 1990 1992 - Mar Su>=1 2s 0 S R Ho 1992 1993 - O lastSu 2s 1 D R Ho 1993 1994 - Mar Su>=1 2s 0 S Z Australia/Brisbane 10:12:8 - LMT 1895 10 AU AE%sT 1971 10 AQ AE%sT Z Australia/Lindeman 9:55:56 - LMT 1895 10 AU AE%sT 1971 10 AQ AE%sT 1992 Jul 10 Ho AE%sT R AS 1971 1985 - O lastSu 2s 1 D R AS 1986 o - O 19 2s 1 D R AS 1987 2007 - O lastSu 2s 1 D R AS 1972 o - F 27 2s 0 S R AS 1973 1985 - Mar Su>=1 2s 0 S R AS 1986 1990 - Mar Su>=15 2s 0 S R AS 1991 o - Mar 3 2s 0 S R AS 1992 o - Mar 22 2s 0 S R AS 1993 o - Mar 7 2s 0 S R AS 1994 o - Mar 20 2s 0 S R AS 1995 2005 - Mar lastSu 2s 0 S R AS 2006 o - Ap 2 2s 0 S R AS 2007 o - Mar lastSu 2s 0 S R AS 2008 ma - Ap Su>=1 2s 0 S R AS 2008 ma - O Su>=1 2s 1 D Z Australia/Adelaide 9:14:20 - LMT 1895 F 9 - ACST 1899 May 9:30 AU AC%sT 1971 9:30 AS AC%sT R AT 1916 o - O Su>=1 2s 1 D R AT 1917 o - Mar lastSu 2s 0 S R AT 1917 1918 - O Su>=22 2s 1 D R AT 1918 1919 - Mar Su>=1 2s 0 S R AT 1967 o - O Su>=1 2s 1 D R AT 1968 o - Mar Su>=29 2s 0 S R AT 1968 1985 - O lastSu 2s 1 D R AT 1969 1971 - Mar Su>=8 2s 0 S R AT 1972 o - F lastSu 2s 0 S R AT 1973 1981 - Mar Su>=1 2s 0 S R AT 1982 1983 - Mar lastSu 2s 0 S R AT 1984 1986 - Mar Su>=1 2s 0 S R AT 1986 o - O Su>=15 2s 1 D R AT 1987 1990 - Mar Su>=15 2s 0 S R AT 1987 o - O Su>=22 2s 1 D R AT 1988 1990 - O lastSu 2s 1 D R AT 1991 1999 - O Su>=1 2s 1 D R AT 1991 2005 - Mar lastSu 2s 0 S R AT 2000 o - Au lastSu 2s 1 D R AT 2001 ma - O Su>=1 2s 1 D R AT 2006 o - Ap Su>=1 2s 0 S R AT 2007 o - Mar lastSu 2s 0 S R AT 2008 ma - Ap Su>=1 2s 0 S Z Australia/Hobart 9:49:16 - LMT 1895 S 10 AT AE%sT 1919 O 24 10 AU AE%sT 1967 10 AT AE%sT R AV 1971 1985 - O lastSu 2s 1 D R AV 1972 o - F lastSu 2s 0 S R AV 1973 1985 - Mar Su>=1 2s 0 S R AV 1986 1990 - Mar Su>=15 2s 0 S R AV 1986 1987 - O Su>=15 2s 1 D R AV 1988 1999 - O lastSu 2s 1 D R AV 1991 1994 - Mar Su>=1 2s 0 S R AV 1995 2005 - Mar lastSu 2s 0 S R AV 2000 o - Au lastSu 2s 1 D R AV 2001 2007 - O lastSu 2s 1 D R AV 2006 o - Ap Su>=1 2s 0 S R AV 2007 o - Mar lastSu 2s 0 S R AV 2008 ma - Ap Su>=1 2s 0 S R AV 2008 ma - O Su>=1 2s 1 D Z Australia/Melbourne 9:39:52 - LMT 1895 F 10 AU AE%sT 1971 10 AV AE%sT R AN 1971 1985 - O lastSu 2s 1 D R AN 1972 o - F 27 2s 0 S R AN 1973 1981 - Mar Su>=1 2s 0 S R AN 1982 o - Ap Su>=1 2s 0 S R AN 1983 1985 - Mar Su>=1 2s 0 S R AN 1986 1989 - Mar Su>=15 2s 0 S R AN 1986 o - O 19 2s 1 D R AN 1987 1999 - O lastSu 2s 1 D R AN 1990 1995 - Mar Su>=1 2s 0 S R AN 1996 2005 - Mar lastSu 2s 0 S R AN 2000 o - Au lastSu 2s 1 D R AN 2001 2007 - O lastSu 2s 1 D R AN 2006 o - Ap Su>=1 2s 0 S R AN 2007 o - Mar lastSu 2s 0 S R AN 2008 ma - Ap Su>=1 2s 0 S R AN 2008 ma - O Su>=1 2s 1 D Z Australia/Sydney 10:4:52 - LMT 1895 F 10 AU AE%sT 1971 10 AN AE%sT Z Australia/Broken_Hill 9:25:48 - LMT 1895 F 10 - AEST 1896 Au 23 9 - ACST 1899 May 9:30 AU AC%sT 1971 9:30 AN AC%sT 2000 9:30 AS AC%sT R LH 1981 1984 - O lastSu 2 1 - R LH 1982 1985 - Mar Su>=1 2 0 - R LH 1985 o - O lastSu 2 0:30 - R LH 1986 1989 - Mar Su>=15 2 0 - R LH 1986 o - O 19 2 0:30 - R LH 1987 1999 - O lastSu 2 0:30 - R LH 1990 1995 - Mar Su>=1 2 0 - R LH 1996 2005 - Mar lastSu 2 0 - R LH 2000 o - Au lastSu 2 0:30 - R LH 2001 2007 - O lastSu 2 0:30 - R LH 2006 o - Ap Su>=1 2 0 - R LH 2007 o - Mar lastSu 2 0 - R LH 2008 ma - Ap Su>=1 2 0 - R LH 2008 ma - O Su>=1 2 0:30 - Z Australia/Lord_Howe 10:36:20 - LMT 1895 F 10 - AEST 1981 Mar 10:30 LH +1030/+1130 1985 Jul 10:30 LH +1030/+11 Z Antarctica/Macquarie 0 - -00 1899 N 10 - AEST 1916 O 1 2 10 1 AEDT 1917 F 10 AU AE%sT 1919 Ap 1 0s 0 - -00 1948 Mar 25 10 AU AE%sT 1967 10 AT AE%sT 2010 10 1 AEDT 2011 10 AT AE%sT R FJ 1998 1999 - N Su>=1 2 1 - R FJ 1999 2000 - F lastSu 3 0 - R FJ 2009 o - N 29 2 1 - R FJ 2010 o - Mar lastSu 3 0 - R FJ 2010 2013 - O Su>=21 2 1 - R FJ 2011 o - Mar Su>=1 3 0 - R FJ 2012 2013 - Ja Su>=18 3 0 - R FJ 2014 o - Ja Su>=18 2 0 - R FJ 2014 2018 - N Su>=1 2 1 - R FJ 2015 2021 - Ja Su>=12 3 0 - R FJ 2019 o - N Su>=8 2 1 - R FJ 2020 o - D 20 2 1 - Z Pacific/Fiji 11:55:44 - LMT 1915 O 26 12 FJ +12/+13 Z Pacific/Gambier -8:59:48 - LMT 1912 O -9 - -09 Z Pacific/Marquesas -9:18 - LMT 1912 O -9:30 - -0930 Z Pacific/Tahiti -9:58:16 - LMT 1912 O -10 - -10 R Gu 1959 o - Jun 27 2 1 D R Gu 1961 o - Ja 29 2 0 S R Gu 1967 o - S 1 2 1 D R Gu 1969 o - Ja 26 0:1 0 S R Gu 1969 o - Jun 22 2 1 D R Gu 1969 o - Au 31 2 0 S R Gu 1970 1971 - Ap lastSu 2 1 D R Gu 1970 1971 - S Su>=1 2 0 S R Gu 1973 o - D 16 2 1 D R Gu 1974 o - F 24 2 0 S R Gu 1976 o - May 26 2 1 D R Gu 1976 o - Au 22 2:1 0 S R Gu 1977 o - Ap 24 2 1 D R Gu 1977 o - Au 28 2 0 S Z Pacific/Guam -14:21 - LMT 1844 D 31 9:39 - LMT 1901 10 - GST 1941 D 10 9 - +09 1944 Jul 31 10 Gu G%sT 2000 D 23 10 - ChST Z Pacific/Tarawa 11:32:4 - LMT 1901 12 - +12 Z Pacific/Kanton 0 - -00 1937 Au 31 -12 - -12 1979 O -11 - -11 1994 D 31 13 - +13 Z Pacific/Kiritimati -10:29:20 - LMT 1901 -10:40 - -1040 1979 O -10 - -10 1994 D 31 14 - +14 Z Pacific/Kwajalein 11:9:20 - LMT 1901 11 - +11 1937 10 - +10 1941 Ap 9 - +09 1944 F 6 11 - +11 1969 O -12 - -12 1993 Au 20 24 12 - +12 Z Pacific/Kosrae -13:8:4 - LMT 1844 D 31 10:51:56 - LMT 1901 11 - +11 1914 O 9 - +09 1919 F 11 - +11 1937 10 - +10 1941 Ap 9 - +09 1945 Au 11 - +11 1969 O 12 - +12 1999 11 - +11 Z Pacific/Nauru 11:7:40 - LMT 1921 Ja 15 11:30 - +1130 1942 Au 29 9 - +09 1945 S 8 11:30 - +1130 1979 F 10 2 12 - +12 R NC 1977 1978 - D Su>=1 0 1 - R NC 1978 1979 - F 27 0 0 - R NC 1996 o - D 1 2s 1 - R NC 1997 o - Mar 2 2s 0 - Z Pacific/Noumea 11:5:48 - LMT 1912 Ja 13 11 NC +11/+12 R NZ 1927 o - N 6 2 1 S R NZ 1928 o - Mar 4 2 0 M R NZ 1928 1933 - O Su>=8 2 0:30 S R NZ 1929 1933 - Mar Su>=15 2 0 M R NZ 1934 1940 - Ap lastSu 2 0 M R NZ 1934 1940 - S lastSu 2 0:30 S R NZ 1946 o - Ja 1 0 0 S R NZ 1974 o - N Su>=1 2s 1 D R k 1974 o - N Su>=1 2:45s 1 - R NZ 1975 o - F lastSu 2s 0 S R k 1975 o - F lastSu 2:45s 0 - R NZ 1975 1988 - O lastSu 2s 1 D R k 1975 1988 - O lastSu 2:45s 1 - R NZ 1976 1989 - Mar Su>=1 2s 0 S R k 1976 1989 - Mar Su>=1 2:45s 0 - R NZ 1989 o - O Su>=8 2s 1 D R k 1989 o - O Su>=8 2:45s 1 - R NZ 1990 2006 - O Su>=1 2s 1 D R k 1990 2006 - O Su>=1 2:45s 1 - R NZ 1990 2007 - Mar Su>=15 2s 0 S R k 1990 2007 - Mar Su>=15 2:45s 0 - R NZ 2007 ma - S lastSu 2s 1 D R k 2007 ma - S lastSu 2:45s 1 - R NZ 2008 ma - Ap Su>=1 2s 0 S R k 2008 ma - Ap Su>=1 2:45s 0 - Z Pacific/Auckland 11:39:4 - LMT 1868 N 2 11:30 NZ NZ%sT 1946 12 NZ NZ%sT Z Pacific/Chatham 12:13:48 - LMT 1868 N 2 12:15 - +1215 1946 12:45 k +1245/+1345 R CK 1978 o - N 12 0 0:30 - R CK 1979 1991 - Mar Su>=1 0 0 - R CK 1979 1990 - O lastSu 0 0:30 - Z Pacific/Rarotonga 13:20:56 - LMT 1899 D 26 -10:39:4 - LMT 1952 O 16 -10:30 - -1030 1978 N 12 -10 CK -10/-0930 Z Pacific/Niue -11:19:40 - LMT 1952 O 16 -11:20 - -1120 1964 Jul -11 - -11 Z Pacific/Norfolk 11:11:52 - LMT 1901 11:12 - +1112 1951 11:30 - +1130 1974 O 27 2s 11:30 1 +1230 1975 Mar 2 2s 11:30 - +1130 2015 O 4 2s 11 - +11 2019 Jul 11 AN +11/+12 Z Pacific/Palau -15:2:4 - LMT 1844 D 31 8:57:56 - LMT 1901 9 - +09 Z Pacific/Port_Moresby 9:48:40 - LMT 1880 9:48:32 - PMMT 1895 10 - +10 Z Pacific/Bougainville 10:22:16 - LMT 1880 9:48:32 - PMMT 1895 10 - +10 1942 Jul 9 - +09 1945 Au 21 10 - +10 2014 D 28 2 11 - +11 Z Pacific/Pitcairn -8:40:20 - LMT 1901 -8:30 - -0830 1998 Ap 27 -8 - -08 Z Pacific/Pago_Pago 12:37:12 - LMT 1892 Jul 5 -11:22:48 - LMT 1911 -11 - SST R WS 2010 o - S lastSu 0 1 - R WS 2011 o - Ap Sa>=1 4 0 - R WS 2011 o - S lastSa 3 1 - R WS 2012 2021 - Ap Su>=1 4 0 - R WS 2012 2020 - S lastSu 3 1 - Z Pacific/Apia 12:33:4 - LMT 1892 Jul 5 -11:26:56 - LMT 1911 -11:30 - -1130 1950 -11 WS -11/-10 2011 D 29 24 13 WS +13/+14 Z Pacific/Guadalcanal 10:39:48 - LMT 1912 O 11 - +11 Z Pacific/Fakaofo -11:24:56 - LMT 1901 -11 - -11 2011 D 30 13 - +13 R TO 1999 o - O 7 2s 1 - R TO 2000 o - Mar 19 2s 0 - R TO 2000 2001 - N Su>=1 2 1 - R TO 2001 2002 - Ja lastSu 2 0 - R TO 2016 o - N Su>=1 2 1 - R TO 2017 o - Ja Su>=15 3 0 - Z Pacific/Tongatapu 12:19:12 - LMT 1945 S 10 12:20 - +1220 1961 13 - +13 1999 13 TO +13/+14 R VU 1973 o - D 22 12u 1 - R VU 1974 o - Mar 30 12u 0 - R VU 1983 1991 - S Sa>=22 24 1 - R VU 1984 1991 - Mar Sa>=22 24 0 - R VU 1992 1993 - Ja Sa>=22 24 0 - R VU 1992 o - O Sa>=22 24 1 - Z Pacific/Efate 11:13:16 - LMT 1912 Ja 13 11 VU +11/+12 R G 1916 o - May 21 2s 1 BST R G 1916 o - O 1 2s 0 GMT R G 1917 o - Ap 8 2s 1 BST R G 1917 o - S 17 2s 0 GMT R G 1918 o - Mar 24 2s 1 BST R G 1918 o - S 30 2s 0 GMT R G 1919 o - Mar 30 2s 1 BST R G 1919 o - S 29 2s 0 GMT R G 1920 o - Mar 28 2s 1 BST R G 1920 o - O 25 2s 0 GMT R G 1921 o - Ap 3 2s 1 BST R G 1921 o - O 3 2s 0 GMT R G 1922 o - Mar 26 2s 1 BST R G 1922 o - O 8 2s 0 GMT R G 1923 o - Ap Su>=16 2s 1 BST R G 1923 1924 - S Su>=16 2s 0 GMT R G 1924 o - Ap Su>=9 2s 1 BST R G 1925 1926 - Ap Su>=16 2s 1 BST R G 1925 1938 - O Su>=2 2s 0 GMT R G 1927 o - Ap Su>=9 2s 1 BST R G 1928 1929 - Ap Su>=16 2s 1 BST R G 1930 o - Ap Su>=9 2s 1 BST R G 1931 1932 - Ap Su>=16 2s 1 BST R G 1933 o - Ap Su>=9 2s 1 BST R G 1934 o - Ap Su>=16 2s 1 BST R G 1935 o - Ap Su>=9 2s 1 BST R G 1936 1937 - Ap Su>=16 2s 1 BST R G 1938 o - Ap Su>=9 2s 1 BST R G 1939 o - Ap Su>=16 2s 1 BST R G 1939 o - N Su>=16 2s 0 GMT R G 1940 o - F Su>=23 2s 1 BST R G 1941 o - May Su>=2 1s 2 BDST R G 1941 1943 - Au Su>=9 1s 1 BST R G 1942 1944 - Ap Su>=2 1s 2 BDST R G 1944 o - S Su>=16 1s 1 BST R G 1945 o - Ap M>=2 1s 2 BDST R G 1945 o - Jul Su>=9 1s 1 BST R G 1945 1946 - O Su>=2 2s 0 GMT R G 1946 o - Ap Su>=9 2s 1 BST R G 1947 o - Mar 16 2s 1 BST R G 1947 o - Ap 13 1s 2 BDST R G 1947 o - Au 10 1s 1 BST R G 1947 o - N 2 2s 0 GMT R G 1948 o - Mar 14 2s 1 BST R G 1948 o - O 31 2s 0 GMT R G 1949 o - Ap 3 2s 1 BST R G 1949 o - O 30 2s 0 GMT R G 1950 1952 - Ap Su>=14 2s 1 BST R G 1950 1952 - O Su>=21 2s 0 GMT R G 1953 o - Ap Su>=16 2s 1 BST R G 1953 1960 - O Su>=2 2s 0 GMT R G 1954 o - Ap Su>=9 2s 1 BST R G 1955 1956 - Ap Su>=16 2s 1 BST R G 1957 o - Ap Su>=9 2s 1 BST R G 1958 1959 - Ap Su>=16 2s 1 BST R G 1960 o - Ap Su>=9 2s 1 BST R G 1961 1963 - Mar lastSu 2s 1 BST R G 1961 1968 - O Su>=23 2s 0 GMT R G 1964 1967 - Mar Su>=19 2s 1 BST R G 1968 o - F 18 2s 1 BST R G 1972 1980 - Mar Su>=16 2s 1 BST R G 1972 1980 - O Su>=23 2s 0 GMT R G 1981 1995 - Mar lastSu 1u 1 BST R G 1981 1989 - O Su>=23 1u 0 GMT R G 1990 1995 - O Su>=22 1u 0 GMT Z Europe/London -0:1:15 - LMT 1847 D 0 G %s 1968 O 27 1 - BST 1971 O 31 2u 0 G %s 1996 0 E GMT/BST R IE 1971 o - O 31 2u -1 - R IE 1972 1980 - Mar Su>=16 2u 0 - R IE 1972 1980 - O Su>=23 2u -1 - R IE 1981 ma - Mar lastSu 1u 0 - R IE 1981 1989 - O Su>=23 1u -1 - R IE 1990 1995 - O Su>=22 1u -1 - R IE 1996 ma - O lastSu 1u -1 - Z Europe/Dublin -0:25:21 - LMT 1880 Au 2 -0:25:21 - DMT 1916 May 21 2s -0:25:21 1 IST 1916 O 1 2s 0 G %s 1921 D 6 0 G GMT/IST 1940 F 25 2s 0 1 IST 1946 O 6 2s 0 - GMT 1947 Mar 16 2s 0 1 IST 1947 N 2 2s 0 - GMT 1948 Ap 18 2s 0 G GMT/IST 1968 O 27 1 IE IST/GMT R E 1977 1980 - Ap Su>=1 1u 1 S R E 1977 o - S lastSu 1u 0 - R E 1978 o - O 1 1u 0 - R E 1979 1995 - S lastSu 1u 0 - R E 1981 ma - Mar lastSu 1u 1 S R E 1996 ma - O lastSu 1u 0 - R W- 1977 1980 - Ap Su>=1 1s 1 S R W- 1977 o - S lastSu 1s 0 - R W- 1978 o - O 1 1s 0 - R W- 1979 1995 - S lastSu 1s 0 - R W- 1981 ma - Mar lastSu 1s 1 S R W- 1996 ma - O lastSu 1s 0 - R c 1916 o - Ap 30 23 1 S R c 1916 o - O 1 1 0 - R c 1917 1918 - Ap M>=15 2s 1 S R c 1917 1918 - S M>=15 2s 0 - R c 1940 o - Ap 1 2s 1 S R c 1942 o - N 2 2s 0 - R c 1943 o - Mar 29 2s 1 S R c 1943 o - O 4 2s 0 - R c 1944 1945 - Ap M>=1 2s 1 S R c 1944 o - O 2 2s 0 - R c 1945 o - S 16 2s 0 - R c 1977 1980 - Ap Su>=1 2s 1 S R c 1977 o - S lastSu 2s 0 - R c 1978 o - O 1 2s 0 - R c 1979 1995 - S lastSu 2s 0 - R c 1981 ma - Mar lastSu 2s 1 S R c 1996 ma - O lastSu 2s 0 - R e 1977 1980 - Ap Su>=1 0 1 S R e 1977 o - S lastSu 0 0 - R e 1978 o - O 1 0 0 - R e 1979 1995 - S lastSu 0 0 - R e 1981 ma - Mar lastSu 0 1 S R e 1996 ma - O lastSu 0 0 - R R 1917 o - Jul 1 23 1 MST R R 1917 o - D 28 0 0 MMT R R 1918 o - May 31 22 2 MDST R R 1918 o - S 16 1 1 MST R R 1919 o - May 31 23 2 MDST R R 1919 o - Jul 1 0u 1 MSD R R 1919 o - Au 16 0 0 MSK R R 1921 o - F 14 23 1 MSD R R 1921 o - Mar 20 23 2 +05 R R 1921 o - S 1 0 1 MSD R R 1921 o - O 1 0 0 - R R 1981 1984 - Ap 1 0 1 S R R 1981 1983 - O 1 0 0 - R R 1984 1995 - S lastSu 2s 0 - R R 1985 2010 - Mar lastSu 2s 1 S R R 1996 2010 - O lastSu 2s 0 - Z WET 0 E WE%sT Z CET 1 c CE%sT Z MET 1 c ME%sT Z EET 2 E EE%sT R q 1940 o - Jun 16 0 1 S R q 1942 o - N 2 3 0 - R q 1943 o - Mar 29 2 1 S R q 1943 o - Ap 10 3 0 - R q 1974 o - May 4 0 1 S R q 1974 o - O 2 0 0 - R q 1975 o - May 1 0 1 S R q 1975 o - O 2 0 0 - R q 1976 o - May 2 0 1 S R q 1976 o - O 3 0 0 - R q 1977 o - May 8 0 1 S R q 1977 o - O 2 0 0 - R q 1978 o - May 6 0 1 S R q 1978 o - O 1 0 0 - R q 1979 o - May 5 0 1 S R q 1979 o - S 30 0 0 - R q 1980 o - May 3 0 1 S R q 1980 o - O 4 0 0 - R q 1981 o - Ap 26 0 1 S R q 1981 o - S 27 0 0 - R q 1982 o - May 2 0 1 S R q 1982 o - O 3 0 0 - R q 1983 o - Ap 18 0 1 S R q 1983 o - O 1 0 0 - R q 1984 o - Ap 1 0 1 S Z Europe/Tirane 1:19:20 - LMT 1914 1 - CET 1940 Jun 16 1 q CE%sT 1984 Jul 1 E CE%sT Z Europe/Andorra 0:6:4 - LMT 1901 0 - WET 1946 S 30 1 - CET 1985 Mar 31 2 1 E CE%sT R a 1920 o - Ap 5 2s 1 S R a 1920 o - S 13 2s 0 - R a 1946 o - Ap 14 2s 1 S R a 1946 o - O 7 2s 0 - R a 1947 1948 - O Su>=1 2s 0 - R a 1947 o - Ap 6 2s 1 S R a 1948 o - Ap 18 2s 1 S R a 1980 o - Ap 6 0 1 S R a 1980 o - S 28 0 0 - Z Europe/Vienna 1:5:21 - LMT 1893 Ap 1 c CE%sT 1920 1 a CE%sT 1940 Ap 1 2s 1 c CE%sT 1945 Ap 2 2s 1 1 CEST 1945 Ap 12 2s 1 - CET 1946 1 a CE%sT 1981 1 E CE%sT Z Europe/Minsk 1:50:16 - LMT 1880 1:50 - MMT 1924 May 2 2 - EET 1930 Jun 21 3 - MSK 1941 Jun 28 1 c CE%sT 1944 Jul 3 3 R MSK/MSD 1990 3 - MSK 1991 Mar 31 2s 2 R EE%sT 2011 Mar 27 2s 3 - +03 R b 1918 o - Mar 9 0s 1 S R b 1918 1919 - O Sa>=1 23s 0 - R b 1919 o - Mar 1 23s 1 S R b 1920 o - F 14 23s 1 S R b 1920 o - O 23 23s 0 - R b 1921 o - Mar 14 23s 1 S R b 1921 o - O 25 23s 0 - R b 1922 o - Mar 25 23s 1 S R b 1922 1927 - O Sa>=1 23s 0 - R b 1923 o - Ap 21 23s 1 S R b 1924 o - Mar 29 23s 1 S R b 1925 o - Ap 4 23s 1 S R b 1926 o - Ap 17 23s 1 S R b 1927 o - Ap 9 23s 1 S R b 1928 o - Ap 14 23s 1 S R b 1928 1938 - O Su>=2 2s 0 - R b 1929 o - Ap 21 2s 1 S R b 1930 o - Ap 13 2s 1 S R b 1931 o - Ap 19 2s 1 S R b 1932 o - Ap 3 2s 1 S R b 1933 o - Mar 26 2s 1 S R b 1934 o - Ap 8 2s 1 S R b 1935 o - Mar 31 2s 1 S R b 1936 o - Ap 19 2s 1 S R b 1937 o - Ap 4 2s 1 S R b 1938 o - Mar 27 2s 1 S R b 1939 o - Ap 16 2s 1 S R b 1939 o - N 19 2s 0 - R b 1940 o - F 25 2s 1 S R b 1944 o - S 17 2s 0 - R b 1945 o - Ap 2 2s 1 S R b 1945 o - S 16 2s 0 - R b 1946 o - May 19 2s 1 S R b 1946 o - O 7 2s 0 - Z Europe/Brussels 0:17:30 - LMT 1880 0:17:30 - BMT 1892 May 1 0:17:30 0 - WET 1914 N 8 1 - CET 1916 May 1 c CE%sT 1918 N 11 11u 0 b WE%sT 1940 May 20 2s 1 c CE%sT 1944 S 3 1 b CE%sT 1977 1 E CE%sT R BG 1979 o - Mar 31 23 1 S R BG 1979 o - O 1 1 0 - R BG 1980 1982 - Ap Sa>=1 23 1 S R BG 1980 o - S 29 1 0 - R BG 1981 o - S 27 2 0 - Z Europe/Sofia 1:33:16 - LMT 1880 1:56:56 - IMT 1894 N 30 2 - EET 1942 N 2 3 1 c CE%sT 1945 1 - CET 1945 Ap 2 3 2 - EET 1979 Mar 31 23 2 BG EE%sT 1982 S 26 3 2 c EE%sT 1991 2 e EE%sT 1997 2 E EE%sT R CZ 1945 o - Ap M>=1 2s 1 S R CZ 1945 o - O 1 2s 0 - R CZ 1946 o - May 6 2s 1 S R CZ 1946 1949 - O Su>=1 2s 0 - R CZ 1947 1948 - Ap Su>=15 2s 1 S R CZ 1949 o - Ap 9 2s 1 S Z Europe/Prague 0:57:44 - LMT 1850 0:57:44 - PMT 1891 O 1 c CE%sT 1945 May 9 1 CZ CE%sT 1946 D 1 3 1 -1 GMT 1947 F 23 2 1 CZ CE%sT 1979 1 E CE%sT Z Atlantic/Faroe -0:27:4 - LMT 1908 Ja 11 0 - WET 1981 0 E WE%sT R Th 1991 1992 - Mar lastSu 2 1 D R Th 1991 1992 - S lastSu 2 0 S R Th 1993 2006 - Ap Su>=1 2 1 D R Th 1993 2006 - O lastSu 2 0 S R Th 2007 ma - Mar Su>=8 2 1 D R Th 2007 ma - N Su>=1 2 0 S Z America/Danmarkshavn -1:14:40 - LMT 1916 Jul 28 -3 - -03 1980 Ap 6 2 -3 E -03/-02 1996 0 - GMT Z America/Scoresbysund -1:27:52 - LMT 1916 Jul 28 -2 - -02 1980 Ap 6 2 -2 c -02/-01 1981 Mar 29 -1 E -01/+00 Z America/Nuuk -3:26:56 - LMT 1916 Jul 28 -3 - -03 1980 Ap 6 2 -3 E -03/-02 2023 O 29 1u -2 E -02/-01 Z America/Thule -4:35:8 - LMT 1916 Jul 28 -4 Th A%sT Z Europe/Tallinn 1:39 - LMT 1880 1:39 - TMT 1918 F 1 c CE%sT 1919 Jul 1:39 - TMT 1921 May 2 - EET 1940 Au 6 3 - MSK 1941 S 15 1 c CE%sT 1944 S 22 3 R MSK/MSD 1989 Mar 26 2s 2 1 EEST 1989 S 24 2s 2 c EE%sT 1998 S 22 2 E EE%sT 1999 O 31 4 2 - EET 2002 F 21 2 E EE%sT R FI 1942 o - Ap 2 24 1 S R FI 1942 o - O 4 1 0 - R FI 1981 1982 - Mar lastSu 2 1 S R FI 1981 1982 - S lastSu 3 0 - Z Europe/Helsinki 1:39:49 - LMT 1878 May 31 1:39:49 - HMT 1921 May 2 FI EE%sT 1983 2 E EE%sT R F 1916 o - Jun 14 23s 1 S R F 1916 1919 - O Su>=1 23s 0 - R F 1917 o - Mar 24 23s 1 S R F 1918 o - Mar 9 23s 1 S R F 1919 o - Mar 1 23s 1 S R F 1920 o - F 14 23s 1 S R F 1920 o - O 23 23s 0 - R F 1921 o - Mar 14 23s 1 S R F 1921 o - O 25 23s 0 - R F 1922 o - Mar 25 23s 1 S R F 1922 1938 - O Sa>=1 23s 0 - R F 1923 o - May 26 23s 1 S R F 1924 o - Mar 29 23s 1 S R F 1925 o - Ap 4 23s 1 S R F 1926 o - Ap 17 23s 1 S R F 1927 o - Ap 9 23s 1 S R F 1928 o - Ap 14 23s 1 S R F 1929 o - Ap 20 23s 1 S R F 1930 o - Ap 12 23s 1 S R F 1931 o - Ap 18 23s 1 S R F 1932 o - Ap 2 23s 1 S R F 1933 o - Mar 25 23s 1 S R F 1934 o - Ap 7 23s 1 S R F 1935 o - Mar 30 23s 1 S R F 1936 o - Ap 18 23s 1 S R F 1937 o - Ap 3 23s 1 S R F 1938 o - Mar 26 23s 1 S R F 1939 o - Ap 15 23s 1 S R F 1939 o - N 18 23s 0 - R F 1940 o - F 25 2 1 S R F 1941 o - May 5 0 2 M R F 1941 o - O 6 0 1 S R F 1942 o - Mar 9 0 2 M R F 1942 o - N 2 3 1 S R F 1943 o - Mar 29 2 2 M R F 1943 o - O 4 3 1 S R F 1944 o - Ap 3 2 2 M R F 1944 o - O 8 1 1 S R F 1945 o - Ap 2 2 2 M R F 1945 o - S 16 3 0 - R F 1976 o - Mar 28 1 1 S R F 1976 o - S 26 1 0 - Z Europe/Paris 0:9:21 - LMT 1891 Mar 16 0:9:21 - PMT 1911 Mar 11 0 F WE%sT 1940 Jun 14 23 1 c CE%sT 1944 Au 25 0 F WE%sT 1945 S 16 3 1 F CE%sT 1977 1 E CE%sT R DE 1946 o - Ap 14 2s 1 S R DE 1946 o - O 7 2s 0 - R DE 1947 1949 - O Su>=1 2s 0 - R DE 1947 o - Ap 6 3s 1 S R DE 1947 o - May 11 2s 2 M R DE 1947 o - Jun 29 3 1 S R DE 1948 o - Ap 18 2s 1 S R DE 1949 o - Ap 10 2s 1 S R So 1945 o - May 24 2 2 M R So 1945 o - S 24 3 1 S R So 1945 o - N 18 2s 0 - Z Europe/Berlin 0:53:28 - LMT 1893 Ap 1 c CE%sT 1945 May 24 2 1 So CE%sT 1946 1 DE CE%sT 1980 1 E CE%sT Z Europe/Gibraltar -0:21:24 - LMT 1880 Au 2 0 G %s 1957 Ap 14 2 1 - CET 1982 1 E CE%sT R g 1932 o - Jul 7 0 1 S R g 1932 o - S 1 0 0 - R g 1941 o - Ap 7 0 1 S R g 1942 o - N 2 3 0 - R g 1943 o - Mar 30 0 1 S R g 1943 o - O 4 0 0 - R g 1952 o - Jul 1 0 1 S R g 1952 o - N 2 0 0 - R g 1975 o - Ap 12 0s 1 S R g 1975 o - N 26 0s 0 - R g 1976 o - Ap 11 2s 1 S R g 1976 o - O 10 2s 0 - R g 1977 1978 - Ap Su>=1 2s 1 S R g 1977 o - S 26 2s 0 - R g 1978 o - S 24 4 0 - R g 1979 o - Ap 1 9 1 S R g 1979 o - S 29 2 0 - R g 1980 o - Ap 1 0 1 S R g 1980 o - S 28 0 0 - Z Europe/Athens 1:34:52 - LMT 1895 S 14 1:34:52 - AMT 1916 Jul 28 0:1 2 g EE%sT 1941 Ap 30 1 g CE%sT 1944 Ap 4 2 g EE%sT 1981 2 E EE%sT R h 1918 1919 - Ap 15 2 1 S R h 1918 1920 - S M>=15 3 0 - R h 1920 o - Ap 5 2 1 S R h 1945 o - May 1 23 1 S R h 1945 o - N 1 1 0 - R h 1946 o - Mar 31 2s 1 S R h 1946 o - O 7 2 0 - R h 1947 1949 - Ap Su>=4 2s 1 S R h 1947 1949 - O Su>=1 2s 0 - R h 1954 o - May 23 0 1 S R h 1954 o - O 3 0 0 - R h 1955 o - May 22 2 1 S R h 1955 o - O 2 3 0 - R h 1956 1957 - Jun Su>=1 2 1 S R h 1956 1957 - S lastSu 3 0 - R h 1980 o - Ap 6 0 1 S R h 1980 o - S 28 1 0 - R h 1981 1983 - Mar lastSu 0 1 S R h 1981 1983 - S lastSu 1 0 - Z Europe/Budapest 1:16:20 - LMT 1890 N 1 c CE%sT 1918 1 h CE%sT 1941 Ap 7 23 1 c CE%sT 1945 1 h CE%sT 1984 1 E CE%sT R I 1916 o - Jun 3 24 1 S R I 1916 1917 - S 30 24 0 - R I 1917 o - Mar 31 24 1 S R I 1918 o - Mar 9 24 1 S R I 1918 o - O 6 24 0 - R I 1919 o - Mar 1 24 1 S R I 1919 o - O 4 24 0 - R I 1920 o - Mar 20 24 1 S R I 1920 o - S 18 24 0 - R I 1940 o - Jun 14 24 1 S R I 1942 o - N 2 2s 0 - R I 1943 o - Mar 29 2s 1 S R I 1943 o - O 4 2s 0 - R I 1944 o - Ap 2 2s 1 S R I 1944 o - S 17 2s 0 - R I 1945 o - Ap 2 2 1 S R I 1945 o - S 15 1 0 - R I 1946 o - Mar 17 2s 1 S R I 1946 o - O 6 2s 0 - R I 1947 o - Mar 16 0s 1 S R I 1947 o - O 5 0s 0 - R I 1948 o - F 29 2s 1 S R I 1948 o - O 3 2s 0 - R I 1966 1968 - May Su>=22 0s 1 S R I 1966 o - S 24 24 0 - R I 1967 1969 - S Su>=22 0s 0 - R I 1969 o - Jun 1 0s 1 S R I 1970 o - May 31 0s 1 S R I 1970 o - S lastSu 0s 0 - R I 1971 1972 - May Su>=22 0s 1 S R I 1971 o - S lastSu 0s 0 - R I 1972 o - O 1 0s 0 - R I 1973 o - Jun 3 0s 1 S R I 1973 1974 - S lastSu 0s 0 - R I 1974 o - May 26 0s 1 S R I 1975 o - Jun 1 0s 1 S R I 1975 1977 - S lastSu 0s 0 - R I 1976 o - May 30 0s 1 S R I 1977 1979 - May Su>=22 0s 1 S R I 1978 o - O 1 0s 0 - R I 1979 o - S 30 0s 0 - Z Europe/Rome 0:49:56 - LMT 1866 D 12 0:49:56 - RMT 1893 O 31 23u 1 I CE%sT 1943 S 10 1 c CE%sT 1944 Jun 4 1 I CE%sT 1980 1 E CE%sT R LV 1989 1996 - Mar lastSu 2s 1 S R LV 1989 1996 - S lastSu 2s 0 - Z Europe/Riga 1:36:34 - LMT 1880 1:36:34 - RMT 1918 Ap 15 2 1:36:34 1 LST 1918 S 16 3 1:36:34 - RMT 1919 Ap 1 2 1:36:34 1 LST 1919 May 22 3 1:36:34 - RMT 1926 May 11 2 - EET 1940 Au 5 3 - MSK 1941 Jul 1 c CE%sT 1944 O 13 3 R MSK/MSD 1989 Mar lastSu 2s 2 1 EEST 1989 S lastSu 2s 2 LV EE%sT 1997 Ja 21 2 E EE%sT 2000 F 29 2 - EET 2001 Ja 2 2 E EE%sT Z Europe/Vilnius 1:41:16 - LMT 1880 1:24 - WMT 1917 1:35:36 - KMT 1919 O 10 1 - CET 1920 Jul 12 2 - EET 1920 O 9 1 - CET 1940 Au 3 3 - MSK 1941 Jun 24 1 c CE%sT 1944 Au 3 R MSK/MSD 1989 Mar 26 2s 2 R EE%sT 1991 S 29 2s 2 c EE%sT 1998 2 - EET 1998 Mar 29 1u 1 E CE%sT 1999 O 31 1u 2 - EET 2003 2 E EE%sT R MT 1973 o - Mar 31 0s 1 S R MT 1973 o - S 29 0s 0 - R MT 1974 o - Ap 21 0s 1 S R MT 1974 o - S 16 0s 0 - R MT 1975 1979 - Ap Su>=15 2 1 S R MT 1975 1980 - S Su>=15 2 0 - R MT 1980 o - Mar 31 2 1 S Z Europe/Malta 0:58:4 - LMT 1893 N 2 1 I CE%sT 1973 Mar 31 1 MT CE%sT 1981 1 E CE%sT R MD 1997 ma - Mar lastSu 2 1 S R MD 1997 ma - O lastSu 3 0 - Z Europe/Chisinau 1:55:20 - LMT 1880 1:55 - CMT 1918 F 15 1:44:24 - BMT 1931 Jul 24 2 z EE%sT 1940 Au 15 2 1 EEST 1941 Jul 17 1 c CE%sT 1944 Au 24 3 R MSK/MSD 1990 May 6 2 2 R EE%sT 1992 2 e EE%sT 1997 2 MD EE%sT R O 1918 1919 - S 16 2s 0 - R O 1919 o - Ap 15 2s 1 S R O 1944 o - Ap 3 2s 1 S R O 1944 o - O 4 2 0 - R O 1945 o - Ap 29 0 1 S R O 1945 o - N 1 0 0 - R O 1946 o - Ap 14 0s 1 S R O 1946 o - O 7 2s 0 - R O 1947 o - May 4 2s 1 S R O 1947 1949 - O Su>=1 2s 0 - R O 1948 o - Ap 18 2s 1 S R O 1949 o - Ap 10 2s 1 S R O 1957 o - Jun 2 1s 1 S R O 1957 1958 - S lastSu 1s 0 - R O 1958 o - Mar 30 1s 1 S R O 1959 o - May 31 1s 1 S R O 1959 1961 - O Su>=1 1s 0 - R O 1960 o - Ap 3 1s 1 S R O 1961 1964 - May lastSu 1s 1 S R O 1962 1964 - S lastSu 1s 0 - Z Europe/Warsaw 1:24 - LMT 1880 1:24 - WMT 1915 Au 5 1 c CE%sT 1918 S 16 3 2 O EE%sT 1922 Jun 1 O CE%sT 1940 Jun 23 2 1 c CE%sT 1944 O 1 O CE%sT 1977 1 W- CE%sT 1988 1 E CE%sT R p 1916 o - Jun 17 23 1 S R p 1916 o - N 1 1 0 - R p 1917 o - F 28 23s 1 S R p 1917 1921 - O 14 23s 0 - R p 1918 o - Mar 1 23s 1 S R p 1919 o - F 28 23s 1 S R p 1920 o - F 29 23s 1 S R p 1921 o - F 28 23s 1 S R p 1924 o - Ap 16 23s 1 S R p 1924 o - O 14 23s 0 - R p 1926 o - Ap 17 23s 1 S R p 1926 1929 - O Sa>=1 23s 0 - R p 1927 o - Ap 9 23s 1 S R p 1928 o - Ap 14 23s 1 S R p 1929 o - Ap 20 23s 1 S R p 1931 o - Ap 18 23s 1 S R p 1931 1932 - O Sa>=1 23s 0 - R p 1932 o - Ap 2 23s 1 S R p 1934 o - Ap 7 23s 1 S R p 1934 1938 - O Sa>=1 23s 0 - R p 1935 o - Mar 30 23s 1 S R p 1936 o - Ap 18 23s 1 S R p 1937 o - Ap 3 23s 1 S R p 1938 o - Mar 26 23s 1 S R p 1939 o - Ap 15 23s 1 S R p 1939 o - N 18 23s 0 - R p 1940 o - F 24 23s 1 S R p 1940 1941 - O 5 23s 0 - R p 1941 o - Ap 5 23s 1 S R p 1942 1945 - Mar Sa>=8 23s 1 S R p 1942 o - Ap 25 22s 2 M R p 1942 o - Au 15 22s 1 S R p 1942 1945 - O Sa>=24 23s 0 - R p 1943 o - Ap 17 22s 2 M R p 1943 1945 - Au Sa>=25 22s 1 S R p 1944 1945 - Ap Sa>=21 22s 2 M R p 1946 o - Ap Sa>=1 23s 1 S R p 1946 o - O Sa>=1 23s 0 - R p 1947 1965 - Ap Su>=1 2s 1 S R p 1947 1965 - O Su>=1 2s 0 - R p 1977 o - Mar 27 0s 1 S R p 1977 o - S 25 0s 0 - R p 1978 1979 - Ap Su>=1 0s 1 S R p 1978 o - O 1 0s 0 - R p 1979 1982 - S lastSu 1s 0 - R p 1980 o - Mar lastSu 0s 1 S R p 1981 1982 - Mar lastSu 1s 1 S R p 1983 o - Mar lastSu 2s 1 S Z Europe/Lisbon -0:36:45 - LMT 1884 -0:36:45 - LMT 1912 Ja 1 0u 0 p WE%sT 1966 Ap 3 2 1 - CET 1976 S 26 1 0 p WE%sT 1983 S 25 1s 0 W- WE%sT 1992 S 27 1s 1 E CE%sT 1996 Mar 31 1u 0 E WE%sT Z Atlantic/Azores -1:42:40 - LMT 1884 -1:54:32 - HMT 1912 Ja 1 2u -2 p -02/-01 1942 Ap 25 22s -2 p +00 1942 Au 15 22s -2 p -02/-01 1943 Ap 17 22s -2 p +00 1943 Au 28 22s -2 p -02/-01 1944 Ap 22 22s -2 p +00 1944 Au 26 22s -2 p -02/-01 1945 Ap 21 22s -2 p +00 1945 Au 25 22s -2 p -02/-01 1966 Ap 3 2 -1 p -01/+00 1983 S 25 1s -1 W- -01/+00 1992 S 27 1s 0 E WE%sT 1993 Mar 28 1u -1 E -01/+00 Z Atlantic/Madeira -1:7:36 - LMT 1884 -1:7:36 - FMT 1912 Ja 1 1u -1 p -01/+00 1942 Ap 25 22s -1 p +01 1942 Au 15 22s -1 p -01/+00 1943 Ap 17 22s -1 p +01 1943 Au 28 22s -1 p -01/+00 1944 Ap 22 22s -1 p +01 1944 Au 26 22s -1 p -01/+00 1945 Ap 21 22s -1 p +01 1945 Au 25 22s -1 p -01/+00 1966 Ap 3 2 0 p WE%sT 1983 S 25 1s 0 E WE%sT R z 1932 o - May 21 0s 1 S R z 1932 1939 - O Su>=1 0s 0 - R z 1933 1939 - Ap Su>=2 0s 1 S R z 1979 o - May 27 0 1 S R z 1979 o - S lastSu 0 0 - R z 1980 o - Ap 5 23 1 S R z 1980 o - S lastSu 1 0 - R z 1991 1993 - Mar lastSu 0s 1 S R z 1991 1993 - S lastSu 0s 0 - Z Europe/Bucharest 1:44:24 - LMT 1891 O 1:44:24 - BMT 1931 Jul 24 2 z EE%sT 1981 Mar 29 2s 2 c EE%sT 1991 2 z EE%sT 1994 2 e EE%sT 1997 2 E EE%sT Z Europe/Kaliningrad 1:22 - LMT 1893 Ap 1 c CE%sT 1945 Ap 10 2 O EE%sT 1946 Ap 7 3 R MSK/MSD 1989 Mar 26 2s 2 R EE%sT 2011 Mar 27 2s 3 - +03 2014 O 26 2s 2 - EET Z Europe/Moscow 2:30:17 - LMT 1880 2:30:17 - MMT 1916 Jul 3 2:31:19 R %s 1919 Jul 1 0u 3 R %s 1921 O 3 R MSK/MSD 1922 O 2 - EET 1930 Jun 21 3 R MSK/MSD 1991 Mar 31 2s 2 R EE%sT 1992 Ja 19 2s 3 R MSK/MSD 2011 Mar 27 2s 4 - MSK 2014 O 26 2s 3 - MSK Z Europe/Simferopol 2:16:24 - LMT 1880 2:16 - SMT 1924 May 2 2 - EET 1930 Jun 21 3 - MSK 1941 N 1 c CE%sT 1944 Ap 13 3 R MSK/MSD 1990 3 - MSK 1990 Jul 1 2 2 - EET 1992 Mar 20 2 c EE%sT 1994 May 3 c MSK/MSD 1996 Mar 31 0s 3 1 MSD 1996 O 27 3s 3 - MSK 1997 Mar lastSu 1u 2 E EE%sT 2014 Mar 30 2 4 - MSK 2014 O 26 2s 3 - MSK Z Europe/Astrakhan 3:12:12 - LMT 1924 May 3 - +03 1930 Jun 21 4 R +04/+05 1989 Mar 26 2s 3 R +03/+04 1991 Mar 31 2s 4 - +04 1992 Mar 29 2s 3 R +03/+04 2011 Mar 27 2s 4 - +04 2014 O 26 2s 3 - +03 2016 Mar 27 2s 4 - +04 Z Europe/Volgograd 2:57:40 - LMT 1920 Ja 3 3 - +03 1930 Jun 21 4 - +04 1961 N 11 4 R +04/+05 1988 Mar 27 2s 3 R MSK/MSD 1991 Mar 31 2s 4 - +04 1992 Mar 29 2s 3 R MSK/MSD 2011 Mar 27 2s 4 - MSK 2014 O 26 2s 3 - MSK 2018 O 28 2s 4 - +04 2020 D 27 2s 3 - MSK Z Europe/Saratov 3:4:18 - LMT 1919 Jul 1 0u 3 - +03 1930 Jun 21 4 R +04/+05 1988 Mar 27 2s 3 R +03/+04 1991 Mar 31 2s 4 - +04 1992 Mar 29 2s 3 R +03/+04 2011 Mar 27 2s 4 - +04 2014 O 26 2s 3 - +03 2016 D 4 2s 4 - +04 Z Europe/Kirov 3:18:48 - LMT 1919 Jul 1 0u 3 - +03 1930 Jun 21 4 R +04/+05 1989 Mar 26 2s 3 R MSK/MSD 1991 Mar 31 2s 4 - +04 1992 Mar 29 2s 3 R MSK/MSD 2011 Mar 27 2s 4 - MSK 2014 O 26 2s 3 - MSK Z Europe/Samara 3:20:20 - LMT 1919 Jul 1 0u 3 - +03 1930 Jun 21 4 - +04 1935 Ja 27 4 R +04/+05 1989 Mar 26 2s 3 R +03/+04 1991 Mar 31 2s 2 R +02/+03 1991 S 29 2s 3 - +03 1991 O 20 3 4 R +04/+05 2010 Mar 28 2s 3 R +03/+04 2011 Mar 27 2s 4 - +04 Z Europe/Ulyanovsk 3:13:36 - LMT 1919 Jul 1 0u 3 - +03 1930 Jun 21 4 R +04/+05 1989 Mar 26 2s 3 R +03/+04 1991 Mar 31 2s 2 R +02/+03 1992 Ja 19 2s 3 R +03/+04 2011 Mar 27 2s 4 - +04 2014 O 26 2s 3 - +03 2016 Mar 27 2s 4 - +04 Z Asia/Yekaterinburg 4:2:33 - LMT 1916 Jul 3 3:45:5 - PMT 1919 Jul 15 4 4 - +04 1930 Jun 21 5 R +05/+06 1991 Mar 31 2s 4 R +04/+05 1992 Ja 19 2s 5 R +05/+06 2011 Mar 27 2s 6 - +06 2014 O 26 2s 5 - +05 Z Asia/Omsk 4:53:30 - LMT 1919 N 14 5 - +05 1930 Jun 21 6 R +06/+07 1991 Mar 31 2s 5 R +05/+06 1992 Ja 19 2s 6 R +06/+07 2011 Mar 27 2s 7 - +07 2014 O 26 2s 6 - +06 Z Asia/Barnaul 5:35 - LMT 1919 D 10 6 - +06 1930 Jun 21 7 R +07/+08 1991 Mar 31 2s 6 R +06/+07 1992 Ja 19 2s 7 R +07/+08 1995 May 28 6 R +06/+07 2011 Mar 27 2s 7 - +07 2014 O 26 2s 6 - +06 2016 Mar 27 2s 7 - +07 Z Asia/Novosibirsk 5:31:40 - LMT 1919 D 14 6 6 - +06 1930 Jun 21 7 R +07/+08 1991 Mar 31 2s 6 R +06/+07 1992 Ja 19 2s 7 R +07/+08 1993 May 23 6 R +06/+07 2011 Mar 27 2s 7 - +07 2014 O 26 2s 6 - +06 2016 Jul 24 2s 7 - +07 Z Asia/Tomsk 5:39:51 - LMT 1919 D 22 6 - +06 1930 Jun 21 7 R +07/+08 1991 Mar 31 2s 6 R +06/+07 1992 Ja 19 2s 7 R +07/+08 2002 May 1 3 6 R +06/+07 2011 Mar 27 2s 7 - +07 2014 O 26 2s 6 - +06 2016 May 29 2s 7 - +07 Z Asia/Novokuznetsk 5:48:48 - LMT 1924 May 6 - +06 1930 Jun 21 7 R +07/+08 1991 Mar 31 2s 6 R +06/+07 1992 Ja 19 2s 7 R +07/+08 2010 Mar 28 2s 6 R +06/+07 2011 Mar 27 2s 7 - +07 Z Asia/Krasnoyarsk 6:11:26 - LMT 1920 Ja 6 6 - +06 1930 Jun 21 7 R +07/+08 1991 Mar 31 2s 6 R +06/+07 1992 Ja 19 2s 7 R +07/+08 2011 Mar 27 2s 8 - +08 2014 O 26 2s 7 - +07 Z Asia/Irkutsk 6:57:5 - LMT 1880 6:57:5 - IMT 1920 Ja 25 7 - +07 1930 Jun 21 8 R +08/+09 1991 Mar 31 2s 7 R +07/+08 1992 Ja 19 2s 8 R +08/+09 2011 Mar 27 2s 9 - +09 2014 O 26 2s 8 - +08 Z Asia/Chita 7:33:52 - LMT 1919 D 15 8 - +08 1930 Jun 21 9 R +09/+10 1991 Mar 31 2s 8 R +08/+09 1992 Ja 19 2s 9 R +09/+10 2011 Mar 27 2s 10 - +10 2014 O 26 2s 8 - +08 2016 Mar 27 2 9 - +09 Z Asia/Yakutsk 8:38:58 - LMT 1919 D 15 8 - +08 1930 Jun 21 9 R +09/+10 1991 Mar 31 2s 8 R +08/+09 1992 Ja 19 2s 9 R +09/+10 2011 Mar 27 2s 10 - +10 2014 O 26 2s 9 - +09 Z Asia/Vladivostok 8:47:31 - LMT 1922 N 15 9 - +09 1930 Jun 21 10 R +10/+11 1991 Mar 31 2s 9 R +09/+10 1992 Ja 19 2s 10 R +10/+11 2011 Mar 27 2s 11 - +11 2014 O 26 2s 10 - +10 Z Asia/Khandyga 9:2:13 - LMT 1919 D 15 8 - +08 1930 Jun 21 9 R +09/+10 1991 Mar 31 2s 8 R +08/+09 1992 Ja 19 2s 9 R +09/+10 2004 10 R +10/+11 2011 Mar 27 2s 11 - +11 2011 S 13 0s 10 - +10 2014 O 26 2s 9 - +09 Z Asia/Sakhalin 9:30:48 - LMT 1905 Au 23 9 - +09 1945 Au 25 11 R +11/+12 1991 Mar 31 2s 10 R +10/+11 1992 Ja 19 2s 11 R +11/+12 1997 Mar lastSu 2s 10 R +10/+11 2011 Mar 27 2s 11 - +11 2014 O 26 2s 10 - +10 2016 Mar 27 2s 11 - +11 Z Asia/Magadan 10:3:12 - LMT 1924 May 2 10 - +10 1930 Jun 21 11 R +11/+12 1991 Mar 31 2s 10 R +10/+11 1992 Ja 19 2s 11 R +11/+12 2011 Mar 27 2s 12 - +12 2014 O 26 2s 10 - +10 2016 Ap 24 2s 11 - +11 Z Asia/Srednekolymsk 10:14:52 - LMT 1924 May 2 10 - +10 1930 Jun 21 11 R +11/+12 1991 Mar 31 2s 10 R +10/+11 1992 Ja 19 2s 11 R +11/+12 2011 Mar 27 2s 12 - +12 2014 O 26 2s 11 - +11 Z Asia/Ust-Nera 9:32:54 - LMT 1919 D 15 8 - +08 1930 Jun 21 9 R +09/+10 1981 Ap 11 R +11/+12 1991 Mar 31 2s 10 R +10/+11 1992 Ja 19 2s 11 R +11/+12 2011 Mar 27 2s 12 - +12 2011 S 13 0s 11 - +11 2014 O 26 2s 10 - +10 Z Asia/Kamchatka 10:34:36 - LMT 1922 N 10 11 - +11 1930 Jun 21 12 R +12/+13 1991 Mar 31 2s 11 R +11/+12 1992 Ja 19 2s 12 R +12/+13 2010 Mar 28 2s 11 R +11/+12 2011 Mar 27 2s 12 - +12 Z Asia/Anadyr 11:49:56 - LMT 1924 May 2 12 - +12 1930 Jun 21 13 R +13/+14 1982 Ap 1 0s 12 R +12/+13 1991 Mar 31 2s 11 R +11/+12 1992 Ja 19 2s 12 R +12/+13 2010 Mar 28 2s 11 R +11/+12 2011 Mar 27 2s 12 - +12 Z Europe/Belgrade 1:22 - LMT 1884 1 - CET 1941 Ap 18 23 1 c CE%sT 1945 1 - CET 1945 May 8 2s 1 1 CEST 1945 S 16 2s 1 - CET 1982 N 27 1 E CE%sT R s 1918 o - Ap 15 23 1 S R s 1918 1919 - O 6 24s 0 - R s 1919 o - Ap 6 23 1 S R s 1924 o - Ap 16 23 1 S R s 1924 o - O 4 24s 0 - R s 1926 o - Ap 17 23 1 S R s 1926 1929 - O Sa>=1 24s 0 - R s 1927 o - Ap 9 23 1 S R s 1928 o - Ap 15 0 1 S R s 1929 o - Ap 20 23 1 S R s 1937 o - Jun 16 23 1 S R s 1937 o - O 2 24s 0 - R s 1938 o - Ap 2 23 1 S R s 1938 o - Ap 30 23 2 M R s 1938 o - O 2 24 1 S R s 1939 o - O 7 24s 0 - R s 1942 o - May 2 23 1 S R s 1942 o - S 1 1 0 - R s 1943 1946 - Ap Sa>=13 23 1 S R s 1943 1944 - O Su>=1 1 0 - R s 1945 1946 - S lastSu 1 0 - R s 1949 o - Ap 30 23 1 S R s 1949 o - O 2 1 0 - R s 1974 1975 - Ap Sa>=12 23 1 S R s 1974 1975 - O Su>=1 1 0 - R s 1976 o - Mar 27 23 1 S R s 1976 1977 - S lastSu 1 0 - R s 1977 o - Ap 2 23 1 S R s 1978 o - Ap 2 2s 1 S R s 1978 o - O 1 2s 0 - R Sp 1967 o - Jun 3 12 1 S R Sp 1967 o - O 1 0 0 - R Sp 1974 o - Jun 24 0 1 S R Sp 1974 o - S 1 0 0 - R Sp 1976 1977 - May 1 0 1 S R Sp 1976 o - Au 1 0 0 - R Sp 1977 o - S 28 0 0 - R Sp 1978 o - Jun 1 0 1 S R Sp 1978 o - Au 4 0 0 - Z Europe/Madrid -0:14:44 - LMT 1901 Ja 1 0u 0 s WE%sT 1940 Mar 16 23 1 s CE%sT 1979 1 E CE%sT Z Africa/Ceuta -0:21:16 - LMT 1901 Ja 1 0u 0 - WET 1918 May 6 23 0 1 WEST 1918 O 7 23 0 - WET 1924 0 s WE%sT 1929 0 - WET 1967 0 Sp WE%sT 1984 Mar 16 1 - CET 1986 1 E CE%sT Z Atlantic/Canary -1:1:36 - LMT 1922 Mar -1 - -01 1946 S 30 1 0 - WET 1980 Ap 6 0s 0 1 WEST 1980 S 28 1u 0 E WE%sT R CH 1941 1942 - May M>=1 1 1 S R CH 1941 1942 - O M>=1 2 0 - Z Europe/Zurich 0:34:8 - LMT 1853 Jul 16 0:29:46 - BMT 1894 Jun 1 CH CE%sT 1981 1 E CE%sT R T 1916 o - May 1 0 1 S R T 1916 o - O 1 0 0 - R T 1920 o - Mar 28 0 1 S R T 1920 o - O 25 0 0 - R T 1921 o - Ap 3 0 1 S R T 1921 o - O 3 0 0 - R T 1922 o - Mar 26 0 1 S R T 1922 o - O 8 0 0 - R T 1924 o - May 13 0 1 S R T 1924 1925 - O 1 0 0 - R T 1925 o - May 1 0 1 S R T 1940 o - Jul 1 0 1 S R T 1940 o - O 6 0 0 - R T 1940 o - D 1 0 1 S R T 1941 o - S 21 0 0 - R T 1942 o - Ap 1 0 1 S R T 1945 o - O 8 0 0 - R T 1946 o - Jun 1 0 1 S R T 1946 o - O 1 0 0 - R T 1947 1948 - Ap Su>=16 0 1 S R T 1947 1951 - O Su>=2 0 0 - R T 1949 o - Ap 10 0 1 S R T 1950 o - Ap 16 0 1 S R T 1951 o - Ap 22 0 1 S R T 1962 o - Jul 15 0 1 S R T 1963 o - O 30 0 0 - R T 1964 o - May 15 0 1 S R T 1964 o - O 1 0 0 - R T 1973 o - Jun 3 1 1 S R T 1973 1976 - O Su>=31 2 0 - R T 1974 o - Mar 31 2 1 S R T 1975 o - Mar 22 2 1 S R T 1976 o - Mar 21 2 1 S R T 1977 1978 - Ap Su>=1 2 1 S R T 1977 1978 - O Su>=15 2 0 - R T 1978 o - Jun 29 0 0 - R T 1983 o - Jul 31 2 1 S R T 1983 o - O 2 2 0 - R T 1985 o - Ap 20 1s 1 S R T 1985 o - S 28 1s 0 - R T 1986 1993 - Mar lastSu 1s 1 S R T 1986 1995 - S lastSu 1s 0 - R T 1994 o - Mar 20 1s 1 S R T 1995 2006 - Mar lastSu 1s 1 S R T 1996 2006 - O lastSu 1s 0 - Z Europe/Istanbul 1:55:52 - LMT 1880 1:56:56 - IMT 1910 O 2 T EE%sT 1978 Jun 29 3 T +03/+04 1984 N 1 2 2 T EE%sT 2007 2 E EE%sT 2011 Mar 27 1u 2 - EET 2011 Mar 28 1u 2 E EE%sT 2014 Mar 30 1u 2 - EET 2014 Mar 31 1u 2 E EE%sT 2015 O 25 1u 2 1 EEST 2015 N 8 1u 2 E EE%sT 2016 S 7 3 - +03 Z Europe/Kyiv 2:2:4 - LMT 1880 2:2:4 - KMT 1924 May 2 2 - EET 1930 Jun 21 3 - MSK 1941 S 20 1 c CE%sT 1943 N 6 3 R MSK/MSD 1990 Jul 1 2 2 1 EEST 1991 S 29 3 2 c EE%sT 1996 May 13 2 E EE%sT R u 1918 1919 - Mar lastSu 2 1 D R u 1918 1919 - O lastSu 2 0 S R u 1942 o - F 9 2 1 W R u 1945 o - Au 14 23u 1 P R u 1945 o - S 30 2 0 S R u 1967 2006 - O lastSu 2 0 S R u 1967 1973 - Ap lastSu 2 1 D R u 1974 o - Ja 6 2 1 D R u 1975 o - F lastSu 2 1 D R u 1976 1986 - Ap lastSu 2 1 D R u 1987 2006 - Ap Su>=1 2 1 D R u 2007 ma - Mar Su>=8 2 1 D R u 2007 ma - N Su>=1 2 0 S Z EST -5 - EST Z MST -7 - MST Z HST -10 - HST Z EST5EDT -5 u E%sT Z CST6CDT -6 u C%sT Z MST7MDT -7 u M%sT Z PST8PDT -8 u P%sT R NY 1920 o - Mar lastSu 2 1 D R NY 1920 o - O lastSu 2 0 S R NY 1921 1966 - Ap lastSu 2 1 D R NY 1921 1954 - S lastSu 2 0 S R NY 1955 1966 - O lastSu 2 0 S Z America/New_York -4:56:2 - LMT 1883 N 18 17u -5 u E%sT 1920 -5 NY E%sT 1942 -5 u E%sT 1946 -5 NY E%sT 1967 -5 u E%sT R Ch 1920 o - Jun 13 2 1 D R Ch 1920 1921 - O lastSu 2 0 S R Ch 1921 o - Mar lastSu 2 1 D R Ch 1922 1966 - Ap lastSu 2 1 D R Ch 1922 1954 - S lastSu 2 0 S R Ch 1955 1966 - O lastSu 2 0 S Z America/Chicago -5:50:36 - LMT 1883 N 18 18u -6 u C%sT 1920 -6 Ch C%sT 1936 Mar 1 2 -5 - EST 1936 N 15 2 -6 Ch C%sT 1942 -6 u C%sT 1946 -6 Ch C%sT 1967 -6 u C%sT Z America/North_Dakota/Center -6:45:12 - LMT 1883 N 18 19u -7 u M%sT 1992 O 25 2 -6 u C%sT Z America/North_Dakota/New_Salem -6:45:39 - LMT 1883 N 18 19u -7 u M%sT 2003 O 26 2 -6 u C%sT Z America/North_Dakota/Beulah -6:47:7 - LMT 1883 N 18 19u -7 u M%sT 2010 N 7 2 -6 u C%sT R De 1920 1921 - Mar lastSu 2 1 D R De 1920 o - O lastSu 2 0 S R De 1921 o - May 22 2 0 S R De 1965 1966 - Ap lastSu 2 1 D R De 1965 1966 - O lastSu 2 0 S Z America/Denver -6:59:56 - LMT 1883 N 18 19u -7 u M%sT 1920 -7 De M%sT 1942 -7 u M%sT 1946 -7 De M%sT 1967 -7 u M%sT R CA 1948 o - Mar 14 2:1 1 D R CA 1949 o - Ja 1 2 0 S R CA 1950 1966 - Ap lastSu 1 1 D R CA 1950 1961 - S lastSu 2 0 S R CA 1962 1966 - O lastSu 2 0 S Z America/Los_Angeles -7:52:58 - LMT 1883 N 18 20u -8 u P%sT 1946 -8 CA P%sT 1967 -8 u P%sT Z America/Juneau 15:2:19 - LMT 1867 O 19 15:33:32 -8:57:41 - LMT 1900 Au 20 12 -8 - PST 1942 -8 u P%sT 1946 -8 - PST 1969 -8 u P%sT 1980 Ap 27 2 -9 u Y%sT 1980 O 26 2 -8 u P%sT 1983 O 30 2 -9 u Y%sT 1983 N 30 -9 u AK%sT Z America/Sitka 14:58:47 - LMT 1867 O 19 15:30 -9:1:13 - LMT 1900 Au 20 12 -8 - PST 1942 -8 u P%sT 1946 -8 - PST 1969 -8 u P%sT 1983 O 30 2 -9 u Y%sT 1983 N 30 -9 u AK%sT Z America/Metlakatla 15:13:42 - LMT 1867 O 19 15:44:55 -8:46:18 - LMT 1900 Au 20 12 -8 - PST 1942 -8 u P%sT 1946 -8 - PST 1969 -8 u P%sT 1983 O 30 2 -8 - PST 2015 N 1 2 -9 u AK%sT 2018 N 4 2 -8 - PST 2019 Ja 20 2 -9 u AK%sT Z America/Yakutat 14:41:5 - LMT 1867 O 19 15:12:18 -9:18:55 - LMT 1900 Au 20 12 -9 - YST 1942 -9 u Y%sT 1946 -9 - YST 1969 -9 u Y%sT 1983 N 30 -9 u AK%sT Z America/Anchorage 14:0:24 - LMT 1867 O 19 14:31:37 -9:59:36 - LMT 1900 Au 20 12 -10 - AST 1942 -10 u A%sT 1967 Ap -10 - AHST 1969 -10 u AH%sT 1983 O 30 2 -9 u Y%sT 1983 N 30 -9 u AK%sT Z America/Nome 12:58:22 - LMT 1867 O 19 13:29:35 -11:1:38 - LMT 1900 Au 20 12 -11 - NST 1942 -11 u N%sT 1946 -11 - NST 1967 Ap -11 - BST 1969 -11 u B%sT 1983 O 30 2 -9 u Y%sT 1983 N 30 -9 u AK%sT Z America/Adak 12:13:22 - LMT 1867 O 19 12:44:35 -11:46:38 - LMT 1900 Au 20 12 -11 - NST 1942 -11 u N%sT 1946 -11 - NST 1967 Ap -11 - BST 1969 -11 u B%sT 1983 O 30 2 -10 u AH%sT 1983 N 30 -10 u H%sT Z Pacific/Honolulu -10:31:26 - LMT 1896 Ja 13 12 -10:30 - HST 1933 Ap 30 2 -10:30 1 HDT 1933 May 21 12 -10:30 u H%sT 1947 Jun 8 2 -10 - HST Z America/Phoenix -7:28:18 - LMT 1883 N 18 19u -7 u M%sT 1944 Ja 1 0:1 -7 - MST 1944 Ap 1 0:1 -7 u M%sT 1944 O 1 0:1 -7 - MST 1967 -7 u M%sT 1968 Mar 21 -7 - MST Z America/Boise -7:44:49 - LMT 1883 N 18 20u -8 u P%sT 1923 May 13 2 -7 u M%sT 1974 -7 - MST 1974 F 3 2 -7 u M%sT R In 1941 o - Jun 22 2 1 D R In 1941 1954 - S lastSu 2 0 S R In 1946 1954 - Ap lastSu 2 1 D Z America/Indiana/Indianapolis -5:44:38 - LMT 1883 N 18 18u -6 u C%sT 1920 -6 In C%sT 1942 -6 u C%sT 1946 -6 In C%sT 1955 Ap 24 2 -5 - EST 1957 S 29 2 -6 - CST 1958 Ap 27 2 -5 - EST 1969 -5 u E%sT 1971 -5 - EST 2006 -5 u E%sT R Ma 1951 o - Ap lastSu 2 1 D R Ma 1951 o - S lastSu 2 0 S R Ma 1954 1960 - Ap lastSu 2 1 D R Ma 1954 1960 - S lastSu 2 0 S Z America/Indiana/Marengo -5:45:23 - LMT 1883 N 18 18u -6 u C%sT 1951 -6 Ma C%sT 1961 Ap 30 2 -5 - EST 1969 -5 u E%sT 1974 Ja 6 2 -6 1 CDT 1974 O 27 2 -5 u E%sT 1976 -5 - EST 2006 -5 u E%sT R V 1946 o - Ap lastSu 2 1 D R V 1946 o - S lastSu 2 0 S R V 1953 1954 - Ap lastSu 2 1 D R V 1953 1959 - S lastSu 2 0 S R V 1955 o - May 1 0 1 D R V 1956 1963 - Ap lastSu 2 1 D R V 1960 o - O lastSu 2 0 S R V 1961 o - S lastSu 2 0 S R V 1962 1963 - O lastSu 2 0 S Z America/Indiana/Vincennes -5:50:7 - LMT 1883 N 18 18u -6 u C%sT 1946 -6 V C%sT 1964 Ap 26 2 -5 - EST 1969 -5 u E%sT 1971 -5 - EST 2006 Ap 2 2 -6 u C%sT 2007 N 4 2 -5 u E%sT R Pe 1955 o - May 1 0 1 D R Pe 1955 1960 - S lastSu 2 0 S R Pe 1956 1963 - Ap lastSu 2 1 D R Pe 1961 1963 - O lastSu 2 0 S Z America/Indiana/Tell_City -5:47:3 - LMT 1883 N 18 18u -6 u C%sT 1946 -6 Pe C%sT 1964 Ap 26 2 -5 - EST 1967 O 29 2 -6 u C%sT 1969 Ap 27 2 -5 u E%sT 1971 -5 - EST 2006 Ap 2 2 -6 u C%sT R Pi 1955 o - May 1 0 1 D R Pi 1955 1960 - S lastSu 2 0 S R Pi 1956 1964 - Ap lastSu 2 1 D R Pi 1961 1964 - O lastSu 2 0 S Z America/Indiana/Petersburg -5:49:7 - LMT 1883 N 18 18u -6 u C%sT 1955 -6 Pi C%sT 1965 Ap 25 2 -5 - EST 1966 O 30 2 -6 u C%sT 1977 O 30 2 -5 - EST 2006 Ap 2 2 -6 u C%sT 2007 N 4 2 -5 u E%sT R St 1947 1961 - Ap lastSu 2 1 D R St 1947 1954 - S lastSu 2 0 S R St 1955 1956 - O lastSu 2 0 S R St 1957 1958 - S lastSu 2 0 S R St 1959 1961 - O lastSu 2 0 S Z America/Indiana/Knox -5:46:30 - LMT 1883 N 18 18u -6 u C%sT 1947 -6 St C%sT 1962 Ap 29 2 -5 - EST 1963 O 27 2 -6 u C%sT 1991 O 27 2 -5 - EST 2006 Ap 2 2 -6 u C%sT R Pu 1946 1960 - Ap lastSu 2 1 D R Pu 1946 1954 - S lastSu 2 0 S R Pu 1955 1956 - O lastSu 2 0 S R Pu 1957 1960 - S lastSu 2 0 S Z America/Indiana/Winamac -5:46:25 - LMT 1883 N 18 18u -6 u C%sT 1946 -6 Pu C%sT 1961 Ap 30 2 -5 - EST 1969 -5 u E%sT 1971 -5 - EST 2006 Ap 2 2 -6 u C%sT 2007 Mar 11 2 -5 u E%sT Z America/Indiana/Vevay -5:40:16 - LMT 1883 N 18 18u -6 u C%sT 1954 Ap 25 2 -5 - EST 1969 -5 u E%sT 1973 -5 - EST 2006 -5 u E%sT R v 1921 o - May 1 2 1 D R v 1921 o - S 1 2 0 S R v 1941 o - Ap lastSu 2 1 D R v 1941 o - S lastSu 2 0 S R v 1946 o - Ap lastSu 0:1 1 D R v 1946 o - Jun 2 2 0 S R v 1950 1961 - Ap lastSu 2 1 D R v 1950 1955 - S lastSu 2 0 S R v 1956 1961 - O lastSu 2 0 S Z America/Kentucky/Louisville -5:43:2 - LMT 1883 N 18 18u -6 u C%sT 1921 -6 v C%sT 1942 -6 u C%sT 1946 -6 v C%sT 1961 Jul 23 2 -5 - EST 1968 -5 u E%sT 1974 Ja 6 2 -6 1 CDT 1974 O 27 2 -5 u E%sT Z America/Kentucky/Monticello -5:39:24 - LMT 1883 N 18 18u -6 u C%sT 1946 -6 - CST 1968 -6 u C%sT 2000 O 29 2 -5 u E%sT R Dt 1948 o - Ap lastSu 2 1 D R Dt 1948 o - S lastSu 2 0 S Z America/Detroit -5:32:11 - LMT 1905 -6 - CST 1915 May 15 2 -5 - EST 1942 -5 u E%sT 1946 -5 Dt E%sT 1967 Jun 14 0:1 -5 u E%sT 1969 -5 - EST 1973 -5 u E%sT 1975 -5 - EST 1975 Ap 27 2 -5 u E%sT R Me 1946 o - Ap lastSu 2 1 D R Me 1946 o - S lastSu 2 0 S R Me 1966 o - Ap lastSu 2 1 D R Me 1966 o - O lastSu 2 0 S Z America/Menominee -5:50:27 - LMT 1885 S 18 12 -6 u C%sT 1946 -6 Me C%sT 1969 Ap 27 2 -5 - EST 1973 Ap 29 2 -6 u C%sT R C 1918 o - Ap 14 2 1 D R C 1918 o - O 27 2 0 S R C 1942 o - F 9 2 1 W R C 1945 o - Au 14 23u 1 P R C 1945 o - S 30 2 0 S R C 1974 1986 - Ap lastSu 2 1 D R C 1974 2006 - O lastSu 2 0 S R C 1987 2006 - Ap Su>=1 2 1 D R C 2007 ma - Mar Su>=8 2 1 D R C 2007 ma - N Su>=1 2 0 S R j 1917 o - Ap 8 2 1 D R j 1917 o - S 17 2 0 S R j 1919 o - May 5 23 1 D R j 1919 o - Au 12 23 0 S R j 1920 1935 - May Su>=1 23 1 D R j 1920 1935 - O lastSu 23 0 S R j 1936 1941 - May M>=9 0 1 D R j 1936 1941 - O M>=2 0 0 S R j 1946 1950 - May Su>=8 2 1 D R j 1946 1950 - O Su>=2 2 0 S R j 1951 1986 - Ap lastSu 2 1 D R j 1951 1959 - S lastSu 2 0 S R j 1960 1986 - O lastSu 2 0 S R j 1987 o - Ap Su>=1 0:1 1 D R j 1987 2006 - O lastSu 0:1 0 S R j 1988 o - Ap Su>=1 0:1 2 DD R j 1989 2006 - Ap Su>=1 0:1 1 D R j 2007 2011 - Mar Su>=8 0:1 1 D R j 2007 2010 - N Su>=1 0:1 0 S Z America/St_Johns -3:30:52 - LMT 1884 -3:30:52 j N%sT 1918 -3:30:52 C N%sT 1919 -3:30:52 j N%sT 1935 Mar 30 -3:30 j N%sT 1942 May 11 -3:30 C N%sT 1946 -3:30 j N%sT 2011 N -3:30 C N%sT Z America/Goose_Bay -4:1:40 - LMT 1884 -3:30:52 - NST 1918 -3:30:52 C N%sT 1919 -3:30:52 - NST 1935 Mar 30 -3:30 - NST 1936 -3:30 j N%sT 1942 May 11 -3:30 C N%sT 1946 -3:30 j N%sT 1966 Mar 15 2 -4 j A%sT 2011 N -4 C A%sT R H 1916 o - Ap 1 0 1 D R H 1916 o - O 1 0 0 S R H 1920 o - May 9 0 1 D R H 1920 o - Au 29 0 0 S R H 1921 o - May 6 0 1 D R H 1921 1922 - S 5 0 0 S R H 1922 o - Ap 30 0 1 D R H 1923 1925 - May Su>=1 0 1 D R H 1923 o - S 4 0 0 S R H 1924 o - S 15 0 0 S R H 1925 o - S 28 0 0 S R H 1926 o - May 16 0 1 D R H 1926 o - S 13 0 0 S R H 1927 o - May 1 0 1 D R H 1927 o - S 26 0 0 S R H 1928 1931 - May Su>=8 0 1 D R H 1928 o - S 9 0 0 S R H 1929 o - S 3 0 0 S R H 1930 o - S 15 0 0 S R H 1931 1932 - S M>=24 0 0 S R H 1932 o - May 1 0 1 D R H 1933 o - Ap 30 0 1 D R H 1933 o - O 2 0 0 S R H 1934 o - May 20 0 1 D R H 1934 o - S 16 0 0 S R H 1935 o - Jun 2 0 1 D R H 1935 o - S 30 0 0 S R H 1936 o - Jun 1 0 1 D R H 1936 o - S 14 0 0 S R H 1937 1938 - May Su>=1 0 1 D R H 1937 1941 - S M>=24 0 0 S R H 1939 o - May 28 0 1 D R H 1940 1941 - May Su>=1 0 1 D R H 1946 1949 - Ap lastSu 2 1 D R H 1946 1949 - S lastSu 2 0 S R H 1951 1954 - Ap lastSu 2 1 D R H 1951 1954 - S lastSu 2 0 S R H 1956 1959 - Ap lastSu 2 1 D R H 1956 1959 - S lastSu 2 0 S R H 1962 1973 - Ap lastSu 2 1 D R H 1962 1973 - O lastSu 2 0 S Z America/Halifax -4:14:24 - LMT 1902 Jun 15 -4 H A%sT 1918 -4 C A%sT 1919 -4 H A%sT 1942 F 9 2s -4 C A%sT 1946 -4 H A%sT 1974 -4 C A%sT Z America/Glace_Bay -3:59:48 - LMT 1902 Jun 15 -4 C A%sT 1953 -4 H A%sT 1954 -4 - AST 1972 -4 H A%sT 1974 -4 C A%sT R o 1933 1935 - Jun Su>=8 1 1 D R o 1933 1935 - S Su>=8 1 0 S R o 1936 1938 - Jun Su>=1 1 1 D R o 1936 1938 - S Su>=1 1 0 S R o 1939 o - May 27 1 1 D R o 1939 1941 - S Sa>=21 1 0 S R o 1940 o - May 19 1 1 D R o 1941 o - May 4 1 1 D R o 1946 1972 - Ap lastSu 2 1 D R o 1946 1956 - S lastSu 2 0 S R o 1957 1972 - O lastSu 2 0 S R o 1993 2006 - Ap Su>=1 0:1 1 D R o 1993 2006 - O lastSu 0:1 0 S Z America/Moncton -4:19:8 - LMT 1883 D 9 -5 - EST 1902 Jun 15 -4 C A%sT 1933 -4 o A%sT 1942 -4 C A%sT 1946 -4 o A%sT 1973 -4 C A%sT 1993 -4 o A%sT 2007 -4 C A%sT R t 1919 o - Mar 30 23:30 1 D R t 1919 o - O 26 0 0 S R t 1920 o - May 2 2 1 D R t 1920 o - S 26 0 0 S R t 1921 o - May 15 2 1 D R t 1921 o - S 15 2 0 S R t 1922 1923 - May Su>=8 2 1 D R t 1922 1926 - S Su>=15 2 0 S R t 1924 1927 - May Su>=1 2 1 D R t 1927 1937 - S Su>=25 2 0 S R t 1928 1937 - Ap Su>=25 2 1 D R t 1938 1940 - Ap lastSu 2 1 D R t 1938 1939 - S lastSu 2 0 S R t 1945 1946 - S lastSu 2 0 S R t 1946 o - Ap lastSu 2 1 D R t 1947 1949 - Ap lastSu 0 1 D R t 1947 1948 - S lastSu 0 0 S R t 1949 o - N lastSu 0 0 S R t 1950 1973 - Ap lastSu 2 1 D R t 1950 o - N lastSu 2 0 S R t 1951 1956 - S lastSu 2 0 S R t 1957 1973 - O lastSu 2 0 S Z America/Toronto -5:17:32 - LMT 1895 -5 C E%sT 1919 -5 t E%sT 1942 F 9 2s -5 C E%sT 1946 -5 t E%sT 1974 -5 C E%sT R W 1916 o - Ap 23 0 1 D R W 1916 o - S 17 0 0 S R W 1918 o - Ap 14 2 1 D R W 1918 o - O 27 2 0 S R W 1937 o - May 16 2 1 D R W 1937 o - S 26 2 0 S R W 1942 o - F 9 2 1 W R W 1945 o - Au 14 23u 1 P R W 1945 o - S lastSu 2 0 S R W 1946 o - May 12 2 1 D R W 1946 o - O 13 2 0 S R W 1947 1949 - Ap lastSu 2 1 D R W 1947 1949 - S lastSu 2 0 S R W 1950 o - May 1 2 1 D R W 1950 o - S 30 2 0 S R W 1951 1960 - Ap lastSu 2 1 D R W 1951 1958 - S lastSu 2 0 S R W 1959 o - O lastSu 2 0 S R W 1960 o - S lastSu 2 0 S R W 1963 o - Ap lastSu 2 1 D R W 1963 o - S 22 2 0 S R W 1966 1986 - Ap lastSu 2s 1 D R W 1966 2005 - O lastSu 2s 0 S R W 1987 2005 - Ap Su>=1 2s 1 D Z America/Winnipeg -6:28:36 - LMT 1887 Jul 16 -6 W C%sT 2006 -6 C C%sT R r 1918 o - Ap 14 2 1 D R r 1918 o - O 27 2 0 S R r 1930 1934 - May Su>=1 0 1 D R r 1930 1934 - O Su>=1 0 0 S R r 1937 1941 - Ap Su>=8 0 1 D R r 1937 o - O Su>=8 0 0 S R r 1938 o - O Su>=1 0 0 S R r 1939 1941 - O Su>=8 0 0 S R r 1942 o - F 9 2 1 W R r 1945 o - Au 14 23u 1 P R r 1945 o - S lastSu 2 0 S R r 1946 o - Ap Su>=8 2 1 D R r 1946 o - O Su>=8 2 0 S R r 1947 1957 - Ap lastSu 2 1 D R r 1947 1957 - S lastSu 2 0 S R r 1959 o - Ap lastSu 2 1 D R r 1959 o - O lastSu 2 0 S R Sw 1957 o - Ap lastSu 2 1 D R Sw 1957 o - O lastSu 2 0 S R Sw 1959 1961 - Ap lastSu 2 1 D R Sw 1959 o - O lastSu 2 0 S R Sw 1960 1961 - S lastSu 2 0 S Z America/Regina -6:58:36 - LMT 1905 S -7 r M%sT 1960 Ap lastSu 2 -6 - CST Z America/Swift_Current -7:11:20 - LMT 1905 S -7 C M%sT 1946 Ap lastSu 2 -7 r M%sT 1950 -7 Sw M%sT 1972 Ap lastSu 2 -6 - CST R Ed 1918 1919 - Ap Su>=8 2 1 D R Ed 1918 o - O 27 2 0 S R Ed 1919 o - May 27 2 0 S R Ed 1920 1923 - Ap lastSu 2 1 D R Ed 1920 o - O lastSu 2 0 S R Ed 1921 1923 - S lastSu 2 0 S R Ed 1942 o - F 9 2 1 W R Ed 1945 o - Au 14 23u 1 P R Ed 1945 o - S lastSu 2 0 S R Ed 1947 o - Ap lastSu 2 1 D R Ed 1947 o - S lastSu 2 0 S R Ed 1972 1986 - Ap lastSu 2 1 D R Ed 1972 2006 - O lastSu 2 0 S Z America/Edmonton -7:33:52 - LMT 1906 S -7 Ed M%sT 1987 -7 C M%sT R Va 1918 o - Ap 14 2 1 D R Va 1918 o - O 27 2 0 S R Va 1942 o - F 9 2 1 W R Va 1945 o - Au 14 23u 1 P R Va 1945 o - S 30 2 0 S R Va 1946 1986 - Ap lastSu 2 1 D R Va 1946 o - S 29 2 0 S R Va 1947 1961 - S lastSu 2 0 S R Va 1962 2006 - O lastSu 2 0 S Z America/Vancouver -8:12:28 - LMT 1884 -8 Va P%sT 1987 -8 C P%sT Z America/Dawson_Creek -8:0:56 - LMT 1884 -8 C P%sT 1947 -8 Va P%sT 1972 Au 30 2 -7 - MST Z America/Fort_Nelson -8:10:47 - LMT 1884 -8 Va P%sT 1946 -8 - PST 1947 -8 Va P%sT 1987 -8 C P%sT 2015 Mar 8 2 -7 - MST R Y 1918 o - Ap 14 2 1 D R Y 1918 o - O 27 2 0 S R Y 1919 o - May 25 2 1 D R Y 1919 o - N 1 0 0 S R Y 1942 o - F 9 2 1 W R Y 1945 o - Au 14 23u 1 P R Y 1945 o - S 30 2 0 S R Y 1972 1986 - Ap lastSu 2 1 D R Y 1972 2006 - O lastSu 2 0 S R Y 1987 2006 - Ap Su>=1 2 1 D R Yu 1965 o - Ap lastSu 0 2 DD R Yu 1965 o - O lastSu 2 0 S Z America/Iqaluit 0 - -00 1942 Au -5 Y E%sT 1999 O 31 2 -6 C C%sT 2000 O 29 2 -5 C E%sT Z America/Resolute 0 - -00 1947 Au 31 -6 Y C%sT 2000 O 29 2 -5 - EST 2001 Ap 1 3 -6 C C%sT 2006 O 29 2 -5 - EST 2007 Mar 11 3 -6 C C%sT Z America/Rankin_Inlet 0 - -00 1957 -6 Y C%sT 2000 O 29 2 -5 - EST 2001 Ap 1 3 -6 C C%sT Z America/Cambridge_Bay 0 - -00 1920 -7 Y M%sT 1999 O 31 2 -6 C C%sT 2000 O 29 2 -5 - EST 2000 N 5 -6 - CST 2001 Ap 1 3 -7 C M%sT Z America/Inuvik 0 - -00 1953 -8 Y P%sT 1979 Ap lastSu 2 -7 Y M%sT 1980 -7 C M%sT Z America/Whitehorse -9:0:12 - LMT 1900 Au 20 -9 Y Y%sT 1965 -9 Yu Y%sT 1966 F 27 -8 - PST 1980 -8 C P%sT 2020 N -7 - MST Z America/Dawson -9:17:40 - LMT 1900 Au 20 -9 Y Y%sT 1965 -9 Yu Y%sT 1973 O 28 -8 - PST 1980 -8 C P%sT 2020 N -7 - MST R m 1931 o - May 1 23 1 D R m 1931 o - O 1 0 0 S R m 1939 o - F 5 0 1 D R m 1939 o - Jun 25 0 0 S R m 1940 o - D 9 0 1 D R m 1941 o - Ap 1 0 0 S R m 1943 o - D 16 0 1 W R m 1944 o - May 1 0 0 S R m 1950 o - F 12 0 1 D R m 1950 o - Jul 30 0 0 S R m 1996 2000 - Ap Su>=1 2 1 D R m 1996 2000 - O lastSu 2 0 S R m 2001 o - May Su>=1 2 1 D R m 2001 o - S lastSu 2 0 S R m 2002 2022 - Ap Su>=1 2 1 D R m 2002 2022 - O lastSu 2 0 S Z America/Cancun -5:47:4 - LMT 1922 Ja 1 6u -6 - CST 1981 D 23 -5 m E%sT 1998 Au 2 2 -6 m C%sT 2015 F 1 2 -5 - EST Z America/Merida -5:58:28 - LMT 1922 Ja 1 6u -6 - CST 1981 D 23 -5 - EST 1982 D 2 -6 m C%sT Z America/Matamoros -6:30 - LMT 1922 Ja 1 6u -6 - CST 1988 -6 u C%sT 1989 -6 m C%sT 2010 -6 u C%sT Z America/Monterrey -6:41:16 - LMT 1922 Ja 1 6u -6 - CST 1988 -6 u C%sT 1989 -6 m C%sT Z America/Mexico_City -6:36:36 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 m C%sT 2001 S 30 2 -6 - CST 2002 F 20 -6 m C%sT Z America/Ciudad_Juarez -7:5:56 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 - CST 1996 -6 m C%sT 1998 -6 - CST 1998 Ap Su>=1 3 -7 m M%sT 2010 -7 u M%sT 2022 O 30 2 -6 - CST 2022 N 30 -7 u M%sT Z America/Ojinaga -6:57:40 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 - CST 1996 -6 m C%sT 1998 -6 - CST 1998 Ap Su>=1 3 -7 m M%sT 2010 -7 u M%sT 2022 O 30 2 -6 - CST 2022 N 30 -6 u C%sT Z America/Chihuahua -7:4:20 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 - CST 1996 -6 m C%sT 1998 -6 - CST 1998 Ap Su>=1 3 -7 m M%sT 2022 O 30 2 -6 - CST Z America/Hermosillo -7:23:52 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 - CST 1942 Ap 24 -7 - MST 1949 Ja 14 -8 - PST 1970 -7 m M%sT 1999 -7 - MST Z America/Mazatlan -7:5:40 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 - CST 1942 Ap 24 -7 - MST 1949 Ja 14 -8 - PST 1970 -7 m M%sT Z America/Bahia_Banderas -7:1 - LMT 1922 Ja 1 7u -7 - MST 1927 Jun 10 23 -6 - CST 1930 N 15 -7 m M%sT 1932 Ap -6 - CST 1942 Ap 24 -7 - MST 1949 Ja 14 -8 - PST 1970 -7 m M%sT 2010 Ap 4 2 -6 m C%sT Z America/Tijuana -7:48:4 - LMT 1922 Ja 1 7u -7 - MST 1924 -8 - PST 1927 Jun 10 23 -7 - MST 1930 N 15 -8 - PST 1931 Ap -8 1 PDT 1931 S 30 -8 - PST 1942 Ap 24 -8 1 PWT 1945 Au 14 23u -8 1 PPT 1945 N 12 -8 - PST 1948 Ap 5 -8 1 PDT 1949 Ja 14 -8 - PST 1954 -8 CA P%sT 1961 -8 - PST 1976 -8 u P%sT 1996 -8 m P%sT 2001 -8 u P%sT 2002 F 20 -8 m P%sT 2010 -8 u P%sT R BB 1942 o - Ap 19 5u 1 D R BB 1942 o - Au 31 6u 0 S R BB 1943 o - May 2 5u 1 D R BB 1943 o - S 5 6u 0 S R BB 1944 o - Ap 10 5u 0:30 - R BB 1944 o - S 10 6u 0 S R BB 1977 o - Jun 12 2 1 D R BB 1977 1978 - O Su>=1 2 0 S R BB 1978 1980 - Ap Su>=15 2 1 D R BB 1979 o - S 30 2 0 S R BB 1980 o - S 25 2 0 S Z America/Barbados -3:58:29 - LMT 1911 Au 28 -4 BB A%sT 1944 -4 BB AST/-0330 1945 -4 BB A%sT R BZ 1918 1941 - O Sa>=1 24 0:30 -0530 R BZ 1919 1942 - F Sa>=8 24 0 CST R BZ 1942 o - Jun 27 24 1 CWT R BZ 1945 o - Au 14 23u 1 CPT R BZ 1945 o - D 15 24 0 CST R BZ 1947 1967 - O Sa>=1 24 0:30 -0530 R BZ 1948 1968 - F Sa>=8 24 0 CST R BZ 1973 o - D 5 0 1 CDT R BZ 1974 o - F 9 0 0 CST R BZ 1982 o - D 18 0 1 CDT R BZ 1983 o - F 12 0 0 CST Z America/Belize -5:52:48 - LMT 1912 Ap -6 BZ %s R Be 1917 o - Ap 5 24 1 - R Be 1917 o - S 30 24 0 - R Be 1918 o - Ap 13 24 1 - R Be 1918 o - S 15 24 0 S R Be 1942 o - Ja 11 2 1 D R Be 1942 o - O 18 2 0 S R Be 1943 o - Mar 21 2 1 D R Be 1943 o - O 31 2 0 S R Be 1944 1945 - Mar Su>=8 2 1 D R Be 1944 1945 - N Su>=1 2 0 S R Be 1947 o - May Su>=15 2 1 D R Be 1947 o - S Su>=8 2 0 S R Be 1948 1952 - May Su>=22 2 1 D R Be 1948 1952 - S Su>=1 2 0 S R Be 1956 o - May Su>=22 2 1 D R Be 1956 o - O lastSu 2 0 S Z Atlantic/Bermuda -4:19:18 - LMT 1890 -4:19:18 Be BMT/BST 1930 Ja 1 2 -4 Be A%sT 1974 Ap 28 2 -4 C A%sT 1976 -4 u A%sT R CR 1979 1980 - F lastSu 0 1 D R CR 1979 1980 - Jun Su>=1 0 0 S R CR 1991 1992 - Ja Sa>=15 0 1 D R CR 1991 o - Jul 1 0 0 S R CR 1992 o - Mar 15 0 0 S Z America/Costa_Rica -5:36:13 - LMT 1890 -5:36:13 - SJMT 1921 Ja 15 -6 CR C%sT R Q 1928 o - Jun 10 0 1 D R Q 1928 o - O 10 0 0 S R Q 1940 1942 - Jun Su>=1 0 1 D R Q 1940 1942 - S Su>=1 0 0 S R Q 1945 1946 - Jun Su>=1 0 1 D R Q 1945 1946 - S Su>=1 0 0 S R Q 1965 o - Jun 1 0 1 D R Q 1965 o - S 30 0 0 S R Q 1966 o - May 29 0 1 D R Q 1966 o - O 2 0 0 S R Q 1967 o - Ap 8 0 1 D R Q 1967 1968 - S Su>=8 0 0 S R Q 1968 o - Ap 14 0 1 D R Q 1969 1977 - Ap lastSu 0 1 D R Q 1969 1971 - O lastSu 0 0 S R Q 1972 1974 - O 8 0 0 S R Q 1975 1977 - O lastSu 0 0 S R Q 1978 o - May 7 0 1 D R Q 1978 1990 - O Su>=8 0 0 S R Q 1979 1980 - Mar Su>=15 0 1 D R Q 1981 1985 - May Su>=5 0 1 D R Q 1986 1989 - Mar Su>=14 0 1 D R Q 1990 1997 - Ap Su>=1 0 1 D R Q 1991 1995 - O Su>=8 0s 0 S R Q 1996 o - O 6 0s 0 S R Q 1997 o - O 12 0s 0 S R Q 1998 1999 - Mar lastSu 0s 1 D R Q 1998 2003 - O lastSu 0s 0 S R Q 2000 2003 - Ap Su>=1 0s 1 D R Q 2004 o - Mar lastSu 0s 1 D R Q 2006 2010 - O lastSu 0s 0 S R Q 2007 o - Mar Su>=8 0s 1 D R Q 2008 o - Mar Su>=15 0s 1 D R Q 2009 2010 - Mar Su>=8 0s 1 D R Q 2011 o - Mar Su>=15 0s 1 D R Q 2011 o - N 13 0s 0 S R Q 2012 o - Ap 1 0s 1 D R Q 2012 ma - N Su>=1 0s 0 S R Q 2013 ma - Mar Su>=8 0s 1 D Z America/Havana -5:29:28 - LMT 1890 -5:29:36 - HMT 1925 Jul 19 12 -5 Q C%sT R DO 1966 o - O 30 0 1 EDT R DO 1967 o - F 28 0 0 EST R DO 1969 1973 - O lastSu 0 0:30 -0430 R DO 1970 o - F 21 0 0 EST R DO 1971 o - Ja 20 0 0 EST R DO 1972 1974 - Ja 21 0 0 EST Z America/Santo_Domingo -4:39:36 - LMT 1890 -4:40 - SDMT 1933 Ap 1 12 -5 DO %s 1974 O 27 -4 - AST 2000 O 29 2 -5 u E%sT 2000 D 3 1 -4 - AST R SV 1987 1988 - May Su>=1 0 1 D R SV 1987 1988 - S lastSu 0 0 S Z America/El_Salvador -5:56:48 - LMT 1921 -6 SV C%sT R GT 1973 o - N 25 0 1 D R GT 1974 o - F 24 0 0 S R GT 1983 o - May 21 0 1 D R GT 1983 o - S 22 0 0 S R GT 1991 o - Mar 23 0 1 D R GT 1991 o - S 7 0 0 S R GT 2006 o - Ap 30 0 1 D R GT 2006 o - O 1 0 0 S Z America/Guatemala -6:2:4 - LMT 1918 O 5 -6 GT C%sT R HT 1983 o - May 8 0 1 D R HT 1984 1987 - Ap lastSu 0 1 D R HT 1983 1987 - O lastSu 0 0 S R HT 1988 1997 - Ap Su>=1 1s 1 D R HT 1988 1997 - O lastSu 1s 0 S R HT 2005 2006 - Ap Su>=1 0 1 D R HT 2005 2006 - O lastSu 0 0 S R HT 2012 2015 - Mar Su>=8 2 1 D R HT 2012 2015 - N Su>=1 2 0 S R HT 2017 ma - Mar Su>=8 2 1 D R HT 2017 ma - N Su>=1 2 0 S Z America/Port-au-Prince -4:49:20 - LMT 1890 -4:49 - PPMT 1917 Ja 24 12 -5 HT E%sT R HN 1987 1988 - May Su>=1 0 1 D R HN 1987 1988 - S lastSu 0 0 S R HN 2006 o - May Su>=1 0 1 D R HN 2006 o - Au M>=1 0 0 S Z America/Tegucigalpa -5:48:52 - LMT 1921 Ap -6 HN C%sT Z America/Jamaica -5:7:10 - LMT 1890 -5:7:10 - KMT 1912 F -5 - EST 1974 -5 u E%sT 1984 -5 - EST Z America/Martinique -4:4:20 - LMT 1890 -4:4:20 - FFMT 1911 May -4 - AST 1980 Ap 6 -4 1 ADT 1980 S 28 -4 - AST R NI 1979 1980 - Mar Su>=16 0 1 D R NI 1979 1980 - Jun M>=23 0 0 S R NI 2005 o - Ap 10 0 1 D R NI 2005 o - O Su>=1 0 0 S R NI 2006 o - Ap 30 2 1 D R NI 2006 o - O Su>=1 1 0 S Z America/Managua -5:45:8 - LMT 1890 -5:45:12 - MMT 1934 Jun 23 -6 - CST 1973 May -5 - EST 1975 F 16 -6 NI C%sT 1992 Ja 1 4 -5 - EST 1992 S 24 -6 - CST 1993 -5 - EST 1997 -6 NI C%sT Z America/Panama -5:18:8 - LMT 1890 -5:19:36 - CMT 1908 Ap 22 -5 - EST Z America/Puerto_Rico -4:24:25 - LMT 1899 Mar 28 12 -4 - AST 1942 May 3 -4 u A%sT 1946 -4 - AST Z America/Miquelon -3:44:40 - LMT 1911 May 15 -4 - AST 1980 May -3 - -03 1987 -3 C -03/-02 Z America/Grand_Turk -4:44:32 - LMT 1890 -5:7:10 - KMT 1912 F -5 - EST 1979 -5 u E%sT 2015 Mar 8 2 -4 - AST 2018 Mar 11 3 -5 u E%sT R A 1930 o - D 1 0 1 - R A 1931 o - Ap 1 0 0 - R A 1931 o - O 15 0 1 - R A 1932 1940 - Mar 1 0 0 - R A 1932 1939 - N 1 0 1 - R A 1940 o - Jul 1 0 1 - R A 1941 o - Jun 15 0 0 - R A 1941 o - O 15 0 1 - R A 1943 o - Au 1 0 0 - R A 1943 o - O 15 0 1 - R A 1946 o - Mar 1 0 0 - R A 1946 o - O 1 0 1 - R A 1963 o - O 1 0 0 - R A 1963 o - D 15 0 1 - R A 1964 1966 - Mar 1 0 0 - R A 1964 1966 - O 15 0 1 - R A 1967 o - Ap 2 0 0 - R A 1967 1968 - O Su>=1 0 1 - R A 1968 1969 - Ap Su>=1 0 0 - R A 1974 o - Ja 23 0 1 - R A 1974 o - May 1 0 0 - R A 1988 o - D 1 0 1 - R A 1989 1993 - Mar Su>=1 0 0 - R A 1989 1992 - O Su>=15 0 1 - R A 1999 o - O Su>=1 0 1 - R A 2000 o - Mar 3 0 0 - R A 2007 o - D 30 0 1 - R A 2008 2009 - Mar Su>=15 0 0 - R A 2008 o - O Su>=15 0 1 - Z America/Argentina/Buenos_Aires -3:53:48 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 A -03/-02 Z America/Argentina/Cordoba -4:16:48 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1991 Mar 3 -4 - -04 1991 O 20 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 A -03/-02 Z America/Argentina/Salta -4:21:40 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1991 Mar 3 -4 - -04 1991 O 20 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 A -03/-02 2008 O 18 -3 - -03 Z America/Argentina/Tucuman -4:20:52 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1991 Mar 3 -4 - -04 1991 O 20 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 Jun -4 - -04 2004 Jun 13 -3 A -03/-02 Z America/Argentina/La_Rioja -4:27:24 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1991 Mar -4 - -04 1991 May 7 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 Jun -4 - -04 2004 Jun 20 -3 A -03/-02 2008 O 18 -3 - -03 Z America/Argentina/San_Juan -4:34:4 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1991 Mar -4 - -04 1991 May 7 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 May 31 -4 - -04 2004 Jul 25 -3 A -03/-02 2008 O 18 -3 - -03 Z America/Argentina/Jujuy -4:21:12 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1990 Mar 4 -4 - -04 1990 O 28 -4 1 -03 1991 Mar 17 -4 - -04 1991 O 6 -3 1 -02 1992 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 A -03/-02 2008 O 18 -3 - -03 Z America/Argentina/Catamarca -4:23:8 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1991 Mar 3 -4 - -04 1991 O 20 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 Jun -4 - -04 2004 Jun 20 -3 A -03/-02 2008 O 18 -3 - -03 Z America/Argentina/Mendoza -4:35:16 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1990 Mar 4 -4 - -04 1990 O 15 -4 1 -03 1991 Mar -4 - -04 1991 O 15 -4 1 -03 1992 Mar -4 - -04 1992 O 18 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 May 23 -4 - -04 2004 S 26 -3 A -03/-02 2008 O 18 -3 - -03 R Sa 2008 2009 - Mar Su>=8 0 0 - R Sa 2007 2008 - O Su>=8 0 1 - Z America/Argentina/San_Luis -4:25:24 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1990 -3 1 -02 1990 Mar 14 -4 - -04 1990 O 15 -4 1 -03 1991 Mar -4 - -04 1991 Jun -3 - -03 1999 O 3 -4 1 -03 2000 Mar 3 -3 - -03 2004 May 31 -4 - -04 2004 Jul 25 -3 A -03/-02 2008 Ja 21 -4 Sa -04/-03 2009 O 11 -3 - -03 Z America/Argentina/Rio_Gallegos -4:36:52 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 Jun -4 - -04 2004 Jun 20 -3 A -03/-02 2008 O 18 -3 - -03 Z America/Argentina/Ushuaia -4:33:12 - LMT 1894 O 31 -4:16:48 - CMT 1920 May -4 - -04 1930 D -4 A -04/-03 1969 O 5 -3 A -03/-02 1999 O 3 -4 A -04/-03 2000 Mar 3 -3 - -03 2004 May 30 -4 - -04 2004 Jun 20 -3 A -03/-02 2008 O 18 -3 - -03 Z America/La_Paz -4:32:36 - LMT 1890 -4:32:36 - CMT 1931 O 15 -4:32:36 1 BST 1932 Mar 21 -4 - -04 R B 1931 o - O 3 11 1 - R B 1932 1933 - Ap 1 0 0 - R B 1932 o - O 3 0 1 - R B 1949 1952 - D 1 0 1 - R B 1950 o - Ap 16 1 0 - R B 1951 1952 - Ap 1 0 0 - R B 1953 o - Mar 1 0 0 - R B 1963 o - D 9 0 1 - R B 1964 o - Mar 1 0 0 - R B 1965 o - Ja 31 0 1 - R B 1965 o - Mar 31 0 0 - R B 1965 o - D 1 0 1 - R B 1966 1968 - Mar 1 0 0 - R B 1966 1967 - N 1 0 1 - R B 1985 o - N 2 0 1 - R B 1986 o - Mar 15 0 0 - R B 1986 o - O 25 0 1 - R B 1987 o - F 14 0 0 - R B 1987 o - O 25 0 1 - R B 1988 o - F 7 0 0 - R B 1988 o - O 16 0 1 - R B 1989 o - Ja 29 0 0 - R B 1989 o - O 15 0 1 - R B 1990 o - F 11 0 0 - R B 1990 o - O 21 0 1 - R B 1991 o - F 17 0 0 - R B 1991 o - O 20 0 1 - R B 1992 o - F 9 0 0 - R B 1992 o - O 25 0 1 - R B 1993 o - Ja 31 0 0 - R B 1993 1995 - O Su>=11 0 1 - R B 1994 1995 - F Su>=15 0 0 - R B 1996 o - F 11 0 0 - R B 1996 o - O 6 0 1 - R B 1997 o - F 16 0 0 - R B 1997 o - O 6 0 1 - R B 1998 o - Mar 1 0 0 - R B 1998 o - O 11 0 1 - R B 1999 o - F 21 0 0 - R B 1999 o - O 3 0 1 - R B 2000 o - F 27 0 0 - R B 2000 2001 - O Su>=8 0 1 - R B 2001 2006 - F Su>=15 0 0 - R B 2002 o - N 3 0 1 - R B 2003 o - O 19 0 1 - R B 2004 o - N 2 0 1 - R B 2005 o - O 16 0 1 - R B 2006 o - N 5 0 1 - R B 2007 o - F 25 0 0 - R B 2007 o - O Su>=8 0 1 - R B 2008 2017 - O Su>=15 0 1 - R B 2008 2011 - F Su>=15 0 0 - R B 2012 o - F Su>=22 0 0 - R B 2013 2014 - F Su>=15 0 0 - R B 2015 o - F Su>=22 0 0 - R B 2016 2019 - F Su>=15 0 0 - R B 2018 o - N Su>=1 0 1 - Z America/Noronha -2:9:40 - LMT 1914 -2 B -02/-01 1990 S 17 -2 - -02 1999 S 30 -2 B -02/-01 2000 O 15 -2 - -02 2001 S 13 -2 B -02/-01 2002 O -2 - -02 Z America/Belem -3:13:56 - LMT 1914 -3 B -03/-02 1988 S 12 -3 - -03 Z America/Santarem -3:38:48 - LMT 1914 -4 B -04/-03 1988 S 12 -4 - -04 2008 Jun 24 -3 - -03 Z America/Fortaleza -2:34 - LMT 1914 -3 B -03/-02 1990 S 17 -3 - -03 1999 S 30 -3 B -03/-02 2000 O 22 -3 - -03 2001 S 13 -3 B -03/-02 2002 O -3 - -03 Z America/Recife -2:19:36 - LMT 1914 -3 B -03/-02 1990 S 17 -3 - -03 1999 S 30 -3 B -03/-02 2000 O 15 -3 - -03 2001 S 13 -3 B -03/-02 2002 O -3 - -03 Z America/Araguaina -3:12:48 - LMT 1914 -3 B -03/-02 1990 S 17 -3 - -03 1995 S 14 -3 B -03/-02 2003 S 24 -3 - -03 2012 O 21 -3 B -03/-02 2013 S -3 - -03 Z America/Maceio -2:22:52 - LMT 1914 -3 B -03/-02 1990 S 17 -3 - -03 1995 O 13 -3 B -03/-02 1996 S 4 -3 - -03 1999 S 30 -3 B -03/-02 2000 O 22 -3 - -03 2001 S 13 -3 B -03/-02 2002 O -3 - -03 Z America/Bahia -2:34:4 - LMT 1914 -3 B -03/-02 2003 S 24 -3 - -03 2011 O 16 -3 B -03/-02 2012 O 21 -3 - -03 Z America/Sao_Paulo -3:6:28 - LMT 1914 -3 B -03/-02 1963 O 23 -3 1 -02 1964 -3 B -03/-02 Z America/Campo_Grande -3:38:28 - LMT 1914 -4 B -04/-03 Z America/Cuiaba -3:44:20 - LMT 1914 -4 B -04/-03 2003 S 24 -4 - -04 2004 O -4 B -04/-03 Z America/Porto_Velho -4:15:36 - LMT 1914 -4 B -04/-03 1988 S 12 -4 - -04 Z America/Boa_Vista -4:2:40 - LMT 1914 -4 B -04/-03 1988 S 12 -4 - -04 1999 S 30 -4 B -04/-03 2000 O 15 -4 - -04 Z America/Manaus -4:0:4 - LMT 1914 -4 B -04/-03 1988 S 12 -4 - -04 1993 S 28 -4 B -04/-03 1994 S 22 -4 - -04 Z America/Eirunepe -4:39:28 - LMT 1914 -5 B -05/-04 1988 S 12 -5 - -05 1993 S 28 -5 B -05/-04 1994 S 22 -5 - -05 2008 Jun 24 -4 - -04 2013 N 10 -5 - -05 Z America/Rio_Branco -4:31:12 - LMT 1914 -5 B -05/-04 1988 S 12 -5 - -05 2008 Jun 24 -4 - -04 2013 N 10 -5 - -05 R x 1927 1931 - S 1 0 1 - R x 1928 1932 - Ap 1 0 0 - R x 1968 o - N 3 4u 1 - R x 1969 o - Mar 30 3u 0 - R x 1969 o - N 23 4u 1 - R x 1970 o - Mar 29 3u 0 - R x 1971 o - Mar 14 3u 0 - R x 1970 1972 - O Su>=9 4u 1 - R x 1972 1986 - Mar Su>=9 3u 0 - R x 1973 o - S 30 4u 1 - R x 1974 1987 - O Su>=9 4u 1 - R x 1987 o - Ap 12 3u 0 - R x 1988 1990 - Mar Su>=9 3u 0 - R x 1988 1989 - O Su>=9 4u 1 - R x 1990 o - S 16 4u 1 - R x 1991 1996 - Mar Su>=9 3u 0 - R x 1991 1997 - O Su>=9 4u 1 - R x 1997 o - Mar 30 3u 0 - R x 1998 o - Mar Su>=9 3u 0 - R x 1998 o - S 27 4u 1 - R x 1999 o - Ap 4 3u 0 - R x 1999 2010 - O Su>=9 4u 1 - R x 2000 2007 - Mar Su>=9 3u 0 - R x 2008 o - Mar 30 3u 0 - R x 2009 o - Mar Su>=9 3u 0 - R x 2010 o - Ap Su>=1 3u 0 - R x 2011 o - May Su>=2 3u 0 - R x 2011 o - Au Su>=16 4u 1 - R x 2012 2014 - Ap Su>=23 3u 0 - R x 2012 2014 - S Su>=2 4u 1 - R x 2016 2018 - May Su>=9 3u 0 - R x 2016 2018 - Au Su>=9 4u 1 - R x 2019 ma - Ap Su>=2 3u 0 - R x 2019 2021 - S Su>=2 4u 1 - R x 2022 o - S Su>=9 4u 1 - R x 2023 ma - S Su>=2 4u 1 - Z America/Santiago -4:42:45 - LMT 1890 -4:42:45 - SMT 1910 Ja 10 -5 - -05 1916 Jul -4:42:45 - SMT 1918 S 10 -4 - -04 1919 Jul -4:42:45 - SMT 1927 S -5 x -05/-04 1932 S -4 - -04 1942 Jun -5 - -05 1942 Au -4 - -04 1946 Jul 14 24 -4 1 -03 1946 Au 28 24 -5 1 -04 1947 Mar 31 24 -5 - -05 1947 May 21 23 -4 x -04/-03 Z America/Punta_Arenas -4:43:40 - LMT 1890 -4:42:45 - SMT 1910 Ja 10 -5 - -05 1916 Jul -4:42:45 - SMT 1918 S 10 -4 - -04 1919 Jul -4:42:45 - SMT 1927 S -5 x -05/-04 1932 S -4 - -04 1942 Jun -5 - -05 1942 Au -4 - -04 1946 Au 28 24 -5 1 -04 1947 Mar 31 24 -5 - -05 1947 May 21 23 -4 x -04/-03 2016 D 4 -3 - -03 Z Pacific/Easter -7:17:28 - LMT 1890 -7:17:28 - EMT 1932 S -7 x -07/-06 1982 Mar 14 3u -6 x -06/-05 Z Antarctica/Palmer 0 - -00 1965 -4 A -04/-03 1969 O 5 -3 A -03/-02 1982 May -4 x -04/-03 2016 D 4 -3 - -03 R CO 1992 o - May 3 0 1 - R CO 1993 o - F 6 24 0 - Z America/Bogota -4:56:16 - LMT 1884 Mar 13 -4:56:16 - BMT 1914 N 23 -5 CO -05/-04 R EC 1992 o - N 28 0 1 - R EC 1993 o - F 5 0 0 - Z America/Guayaquil -5:19:20 - LMT 1890 -5:14 - QMT 1931 -5 EC -05/-04 Z Pacific/Galapagos -5:58:24 - LMT 1931 -5 - -05 1986 -6 EC -06/-05 R FK 1937 1938 - S lastSu 0 1 - R FK 1938 1942 - Mar Su>=19 0 0 - R FK 1939 o - O 1 0 1 - R FK 1940 1942 - S lastSu 0 1 - R FK 1943 o - Ja 1 0 0 - R FK 1983 o - S lastSu 0 1 - R FK 1984 1985 - Ap lastSu 0 0 - R FK 1984 o - S 16 0 1 - R FK 1985 2000 - S Su>=9 0 1 - R FK 1986 2000 - Ap Su>=16 0 0 - R FK 2001 2010 - Ap Su>=15 2 0 - R FK 2001 2010 - S Su>=1 2 1 - Z Atlantic/Stanley -3:51:24 - LMT 1890 -3:51:24 - SMT 1912 Mar 12 -4 FK -04/-03 1983 May -3 FK -03/-02 1985 S 15 -4 FK -04/-03 2010 S 5 2 -3 - -03 Z America/Cayenne -3:29:20 - LMT 1911 Jul -4 - -04 1967 O -3 - -03 Z America/Guyana -3:52:39 - LMT 1911 Au -4 - -04 1915 Mar -3:45 - -0345 1975 Au -3 - -03 1992 Mar 29 1 -4 - -04 R y 1975 1988 - O 1 0 1 - R y 1975 1978 - Mar 1 0 0 - R y 1979 1991 - Ap 1 0 0 - R y 1989 o - O 22 0 1 - R y 1990 o - O 1 0 1 - R y 1991 o - O 6 0 1 - R y 1992 o - Mar 1 0 0 - R y 1992 o - O 5 0 1 - R y 1993 o - Mar 31 0 0 - R y 1993 1995 - O 1 0 1 - R y 1994 1995 - F lastSu 0 0 - R y 1996 o - Mar 1 0 0 - R y 1996 2001 - O Su>=1 0 1 - R y 1997 o - F lastSu 0 0 - R y 1998 2001 - Mar Su>=1 0 0 - R y 2002 2004 - Ap Su>=1 0 0 - R y 2002 2003 - S Su>=1 0 1 - R y 2004 2009 - O Su>=15 0 1 - R y 2005 2009 - Mar Su>=8 0 0 - R y 2010 ma - O Su>=1 0 1 - R y 2010 2012 - Ap Su>=8 0 0 - R y 2013 ma - Mar Su>=22 0 0 - Z America/Asuncion -3:50:40 - LMT 1890 -3:50:40 - AMT 1931 O 10 -4 - -04 1972 O -3 - -03 1974 Ap -4 y -04/-03 R PE 1938 o - Ja 1 0 1 - R PE 1938 o - Ap 1 0 0 - R PE 1938 1939 - S lastSu 0 1 - R PE 1939 1940 - Mar Su>=24 0 0 - R PE 1986 1987 - Ja 1 0 1 - R PE 1986 1987 - Ap 1 0 0 - R PE 1990 o - Ja 1 0 1 - R PE 1990 o - Ap 1 0 0 - R PE 1994 o - Ja 1 0 1 - R PE 1994 o - Ap 1 0 0 - Z America/Lima -5:8:12 - LMT 1890 -5:8:36 - LMT 1908 Jul 28 -5 PE -05/-04 Z Atlantic/South_Georgia -2:26:8 - LMT 1890 -2 - -02 Z America/Paramaribo -3:40:40 - LMT 1911 -3:40:52 - PMT 1935 -3:40:36 - PMT 1945 O -3:30 - -0330 1984 O -3 - -03 R U 1923 1925 - O 1 0 0:30 - R U 1924 1926 - Ap 1 0 0 - R U 1933 1938 - O lastSu 0 0:30 - R U 1934 1941 - Mar lastSa 24 0 - R U 1939 o - O 1 0 0:30 - R U 1940 o - O 27 0 0:30 - R U 1941 o - Au 1 0 0:30 - R U 1942 o - D 14 0 0:30 - R U 1943 o - Mar 14 0 0 - R U 1959 o - May 24 0 0:30 - R U 1959 o - N 15 0 0 - R U 1960 o - Ja 17 0 1 - R U 1960 o - Mar 6 0 0 - R U 1965 o - Ap 4 0 1 - R U 1965 o - S 26 0 0 - R U 1968 o - May 27 0 0:30 - R U 1968 o - D 1 0 0 - R U 1970 o - Ap 25 0 1 - R U 1970 o - Jun 14 0 0 - R U 1972 o - Ap 23 0 1 - R U 1972 o - Jul 16 0 0 - R U 1974 o - Ja 13 0 1:30 - R U 1974 o - Mar 10 0 0:30 - R U 1974 o - S 1 0 0 - R U 1974 o - D 22 0 1 - R U 1975 o - Mar 30 0 0 - R U 1976 o - D 19 0 1 - R U 1977 o - Mar 6 0 0 - R U 1977 o - D 4 0 1 - R U 1978 1979 - Mar Su>=1 0 0 - R U 1978 o - D 17 0 1 - R U 1979 o - Ap 29 0 1 - R U 1980 o - Mar 16 0 0 - R U 1987 o - D 14 0 1 - R U 1988 o - F 28 0 0 - R U 1988 o - D 11 0 1 - R U 1989 o - Mar 5 0 0 - R U 1989 o - O 29 0 1 - R U 1990 o - F 25 0 0 - R U 1990 1991 - O Su>=21 0 1 - R U 1991 1992 - Mar Su>=1 0 0 - R U 1992 o - O 18 0 1 - R U 1993 o - F 28 0 0 - R U 2004 o - S 19 0 1 - R U 2005 o - Mar 27 2 0 - R U 2005 o - O 9 2 1 - R U 2006 2015 - Mar Su>=8 2 0 - R U 2006 2014 - O Su>=1 2 1 - Z America/Montevideo -3:44:51 - LMT 1908 Jun 10 -3:44:51 - MMT 1920 May -4 - -04 1923 O -3:30 U -0330/-03 1942 D 14 -3 U -03/-0230 1960 -3 U -03/-02 1968 -3 U -03/-0230 1970 -3 U -03/-02 1974 -3 U -03/-0130 1974 Mar 10 -3 U -03/-0230 1974 D 22 -3 U -03/-02 Z America/Caracas -4:27:44 - LMT 1890 -4:27:40 - CMT 1912 F 12 -4:30 - -0430 1965 -4 - -04 2007 D 9 3 -4:30 - -0430 2016 May 1 2:30 -4 - -04 Z Etc/UTC 0 - UTC Z Etc/GMT 0 - GMT L Etc/GMT GMT Z Etc/GMT-14 14 - +14 Z Etc/GMT-13 13 - +13 Z Etc/GMT-12 12 - +12 Z Etc/GMT-11 11 - +11 Z Etc/GMT-10 10 - +10 Z Etc/GMT-9 9 - +09 Z Etc/GMT-8 8 - +08 Z Etc/GMT-7 7 - +07 Z Etc/GMT-6 6 - +06 Z Etc/GMT-5 5 - +05 Z Etc/GMT-4 4 - +04 Z Etc/GMT-3 3 - +03 Z Etc/GMT-2 2 - +02 Z Etc/GMT-1 1 - +01 Z Etc/GMT+1 -1 - -01 Z Etc/GMT+2 -2 - -02 Z Etc/GMT+3 -3 - -03 Z Etc/GMT+4 -4 - -04 Z Etc/GMT+5 -5 - -05 Z Etc/GMT+6 -6 - -06 Z Etc/GMT+7 -7 - -07 Z Etc/GMT+8 -8 - -08 Z Etc/GMT+9 -9 - -09 Z Etc/GMT+10 -10 - -10 Z Etc/GMT+11 -11 - -11 Z Etc/GMT+12 -12 - -12 Z Factory 0 - -00 L Australia/Sydney Australia/ACT L Australia/Lord_Howe Australia/LHI L Australia/Sydney Australia/NSW L Australia/Darwin Australia/North L Australia/Brisbane Australia/Queensland L Australia/Adelaide Australia/South L Australia/Hobart Australia/Tasmania L Australia/Melbourne Australia/Victoria L Australia/Perth Australia/West L Australia/Broken_Hill Australia/Yancowinna L America/Rio_Branco Brazil/Acre L America/Noronha Brazil/DeNoronha L America/Sao_Paulo Brazil/East L America/Manaus Brazil/West L America/Halifax Canada/Atlantic L America/Winnipeg Canada/Central L America/Toronto Canada/Eastern L America/Edmonton Canada/Mountain L America/St_Johns Canada/Newfoundland L America/Vancouver Canada/Pacific L America/Regina Canada/Saskatchewan L America/Whitehorse Canada/Yukon L America/Santiago Chile/Continental L Pacific/Easter Chile/EasterIsland L America/Havana Cuba L Africa/Cairo Egypt L Europe/Dublin Eire L Etc/GMT Etc/GMT+0 L Etc/GMT Etc/GMT-0 L Etc/GMT Etc/GMT0 L Etc/GMT Etc/Greenwich L Etc/UTC Etc/UCT L Etc/UTC Etc/Universal L Etc/UTC Etc/Zulu L Europe/London GB L Europe/London GB-Eire L Etc/GMT GMT+0 L Etc/GMT GMT-0 L Etc/GMT GMT0 L Etc/GMT Greenwich L Asia/Hong_Kong Hongkong L Africa/Abidjan Iceland L Asia/Tehran Iran L Asia/Jerusalem Israel L America/Jamaica Jamaica L Asia/Tokyo Japan L Pacific/Kwajalein Kwajalein L Africa/Tripoli Libya L America/Tijuana Mexico/BajaNorte L America/Mazatlan Mexico/BajaSur L America/Mexico_City Mexico/General L Pacific/Auckland NZ L Pacific/Chatham NZ-CHAT L America/Denver Navajo L Asia/Shanghai PRC L Europe/Warsaw Poland L Europe/Lisbon Portugal L Asia/Taipei ROC L Asia/Seoul ROK L Asia/Singapore Singapore L Europe/Istanbul Turkey L Etc/UTC UCT L America/Anchorage US/Alaska L America/Adak US/Aleutian L America/Phoenix US/Arizona L America/Chicago US/Central L America/Indiana/Indianapolis US/East-Indiana L America/New_York US/Eastern L Pacific/Honolulu US/Hawaii L America/Indiana/Knox US/Indiana-Starke L America/Detroit US/Michigan L America/Denver US/Mountain L America/Los_Angeles US/Pacific L Pacific/Pago_Pago US/Samoa L Etc/UTC UTC L Etc/UTC Universal L Europe/Moscow W-SU L Etc/UTC Zulu L America/Argentina/Buenos_Aires America/Buenos_Aires L America/Argentina/Catamarca America/Catamarca L America/Argentina/Cordoba America/Cordoba L America/Indiana/Indianapolis America/Indianapolis L America/Argentina/Jujuy America/Jujuy L America/Indiana/Knox America/Knox_IN L America/Kentucky/Louisville America/Louisville L America/Argentina/Mendoza America/Mendoza L America/Puerto_Rico America/Virgin L Pacific/Pago_Pago Pacific/Samoa L Africa/Abidjan Africa/Accra L Africa/Nairobi Africa/Addis_Ababa L Africa/Nairobi Africa/Asmara L Africa/Abidjan Africa/Bamako L Africa/Lagos Africa/Bangui L Africa/Abidjan Africa/Banjul L Africa/Maputo Africa/Blantyre L Africa/Lagos Africa/Brazzaville L Africa/Maputo Africa/Bujumbura L Africa/Abidjan Africa/Conakry L Africa/Abidjan Africa/Dakar L Africa/Nairobi Africa/Dar_es_Salaam L Africa/Nairobi Africa/Djibouti L Africa/Lagos Africa/Douala L Africa/Abidjan Africa/Freetown L Africa/Maputo Africa/Gaborone L Africa/Maputo Africa/Harare L Africa/Nairobi Africa/Kampala L Africa/Maputo Africa/Kigali L Africa/Lagos Africa/Kinshasa L Africa/Lagos Africa/Libreville L Africa/Abidjan Africa/Lome L Africa/Lagos Africa/Luanda L Africa/Maputo Africa/Lubumbashi L Africa/Maputo Africa/Lusaka L Africa/Lagos Africa/Malabo L Africa/Johannesburg Africa/Maseru L Africa/Johannesburg Africa/Mbabane L Africa/Nairobi Africa/Mogadishu L Africa/Lagos Africa/Niamey L Africa/Abidjan Africa/Nouakchott L Africa/Abidjan Africa/Ouagadougou L Africa/Lagos Africa/Porto-Novo L America/Puerto_Rico America/Anguilla L America/Puerto_Rico America/Antigua L America/Puerto_Rico America/Aruba L America/Panama America/Atikokan L America/Puerto_Rico America/Blanc-Sablon L America/Panama America/Cayman L America/Phoenix America/Creston L America/Puerto_Rico America/Curacao L America/Puerto_Rico America/Dominica L America/Puerto_Rico America/Grenada L America/Puerto_Rico America/Guadeloupe L America/Puerto_Rico America/Kralendijk L America/Puerto_Rico America/Lower_Princes L America/Puerto_Rico America/Marigot L America/Puerto_Rico America/Montserrat L America/Toronto America/Nassau L America/Puerto_Rico America/Port_of_Spain L America/Puerto_Rico America/St_Barthelemy L America/Puerto_Rico America/St_Kitts L America/Puerto_Rico America/St_Lucia L America/Puerto_Rico America/St_Thomas L America/Puerto_Rico America/St_Vincent L America/Puerto_Rico America/Tortola L Pacific/Port_Moresby Antarctica/DumontDUrville L Pacific/Auckland Antarctica/McMurdo L Asia/Riyadh Antarctica/Syowa L Asia/Urumqi Antarctica/Vostok L Europe/Berlin Arctic/Longyearbyen L Asia/Riyadh Asia/Aden L Asia/Qatar Asia/Bahrain L Asia/Kuching Asia/Brunei L Asia/Singapore Asia/Kuala_Lumpur L Asia/Riyadh Asia/Kuwait L Asia/Dubai Asia/Muscat L Asia/Bangkok Asia/Phnom_Penh L Asia/Bangkok Asia/Vientiane L Africa/Abidjan Atlantic/Reykjavik L Africa/Abidjan Atlantic/St_Helena L Europe/Brussels Europe/Amsterdam L Europe/Prague Europe/Bratislava L Europe/Zurich Europe/Busingen L Europe/Berlin Europe/Copenhagen L Europe/London Europe/Guernsey L Europe/London Europe/Isle_of_Man L Europe/London Europe/Jersey L Europe/Belgrade Europe/Ljubljana L Europe/Brussels Europe/Luxembourg L Europe/Helsinki Europe/Mariehamn L Europe/Paris Europe/Monaco L Europe/Berlin Europe/Oslo L Europe/Belgrade Europe/Podgorica L Europe/Rome Europe/San_Marino L Europe/Belgrade Europe/Sarajevo L Europe/Belgrade Europe/Skopje L Europe/Berlin Europe/Stockholm L Europe/Zurich Europe/Vaduz L Europe/Rome Europe/Vatican L Europe/Belgrade Europe/Zagreb L Africa/Nairobi Indian/Antananarivo L Asia/Bangkok Indian/Christmas L Asia/Yangon Indian/Cocos L Africa/Nairobi Indian/Comoro L Indian/Maldives Indian/Kerguelen L Asia/Dubai Indian/Mahe L Africa/Nairobi Indian/Mayotte L Asia/Dubai Indian/Reunion L Pacific/Port_Moresby Pacific/Chuuk L Pacific/Tarawa Pacific/Funafuti L Pacific/Tarawa Pacific/Majuro L Pacific/Pago_Pago Pacific/Midway L Pacific/Guadalcanal Pacific/Pohnpei L Pacific/Guam Pacific/Saipan L Pacific/Tarawa Pacific/Wake L Pacific/Tarawa Pacific/Wallis L Africa/Abidjan Africa/Timbuktu L America/Argentina/Catamarca America/Argentina/ComodRivadavia L America/Adak America/Atka L America/Panama America/Coral_Harbour L America/Tijuana America/Ensenada L America/Indiana/Indianapolis America/Fort_Wayne L America/Toronto America/Montreal L America/Toronto America/Nipigon L America/Iqaluit America/Pangnirtung L America/Rio_Branco America/Porto_Acre L America/Winnipeg America/Rainy_River L America/Argentina/Cordoba America/Rosario L America/Tijuana America/Santa_Isabel L America/Denver America/Shiprock L America/Toronto America/Thunder_Bay L America/Edmonton America/Yellowknife L Pacific/Auckland Antarctica/South_Pole L Asia/Shanghai Asia/Chongqing L Asia/Shanghai Asia/Harbin L Asia/Urumqi Asia/Kashgar L Asia/Jerusalem Asia/Tel_Aviv L Europe/Berlin Atlantic/Jan_Mayen L Australia/Sydney Australia/Canberra L Australia/Hobart Australia/Currie L Europe/London Europe/Belfast L Europe/Chisinau Europe/Tiraspol L Europe/Kyiv Europe/Uzhgorod L Europe/Kyiv Europe/Zaporozhye L Pacific/Kanton Pacific/Enderbury L Pacific/Honolulu Pacific/Johnston L Pacific/Port_Moresby Pacific/Yap L Africa/Nairobi Africa/Asmera L America/Nuuk America/Godthab L Asia/Ashgabat Asia/Ashkhabad L Asia/Kolkata Asia/Calcutta L Asia/Shanghai Asia/Chungking L Asia/Dhaka Asia/Dacca L Europe/Istanbul Asia/Istanbul L Asia/Kathmandu Asia/Katmandu L Asia/Macau Asia/Macao L Asia/Yangon Asia/Rangoon L Asia/Ho_Chi_Minh Asia/Saigon L Asia/Thimphu Asia/Thimbu L Asia/Makassar Asia/Ujung_Pandang L Asia/Ulaanbaatar Asia/Ulan_Bator L Atlantic/Faroe Atlantic/Faeroe L Europe/Kyiv Europe/Kiev L Asia/Nicosia Europe/Nicosia L Pacific/Guadalcanal Pacific/Ponape L Pacific/Port_Moresby Pacific/Truk
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/tzdata.zi
zi
mit
109,248
# tzdb timezone descriptions (deprecated version) # # This file is in the public domain, so clarified as of # 2009-05-17 by Arthur David Olson. # # From Paul Eggert (2021-09-20): # This file is intended as a backward-compatibility aid for older programs. # New programs should use zone1970.tab. This file is like zone1970.tab (see # zone1970.tab's comments), but with the following additional restrictions: # # 1. This file contains only ASCII characters. # 2. The first data column contains exactly one country code. # # Because of (2), each row stands for an area that is the intersection # of a region identified by a country code and of a timezone where civil # clocks have agreed since 1970; this is a narrower definition than # that of zone1970.tab. # # Unlike zone1970.tab, a row's third column can be a Link from # 'backward' instead of a Zone. # # This table is intended as an aid for users, to help them select timezones # appropriate for their practical needs. It is not intended to take or # endorse any position on legal or territorial claims. # #country- #code coordinates TZ comments AD +4230+00131 Europe/Andorra AE +2518+05518 Asia/Dubai AF +3431+06912 Asia/Kabul AG +1703-06148 America/Antigua AI +1812-06304 America/Anguilla AL +4120+01950 Europe/Tirane AM +4011+04430 Asia/Yerevan AO -0848+01314 Africa/Luanda AQ -7750+16636 Antarctica/McMurdo New Zealand time - McMurdo, South Pole AQ -6617+11031 Antarctica/Casey Casey AQ -6835+07758 Antarctica/Davis Davis AQ -6640+14001 Antarctica/DumontDUrville Dumont-d'Urville AQ -6736+06253 Antarctica/Mawson Mawson AQ -6448-06406 Antarctica/Palmer Palmer AQ -6734-06808 Antarctica/Rothera Rothera AQ -690022+0393524 Antarctica/Syowa Syowa AQ -720041+0023206 Antarctica/Troll Troll AQ -7824+10654 Antarctica/Vostok Vostok AR -3436-05827 America/Argentina/Buenos_Aires Buenos Aires (BA, CF) AR -3124-06411 America/Argentina/Cordoba Argentina (most areas: CB, CC, CN, ER, FM, MN, SE, SF) AR -2447-06525 America/Argentina/Salta Salta (SA, LP, NQ, RN) AR -2411-06518 America/Argentina/Jujuy Jujuy (JY) AR -2649-06513 America/Argentina/Tucuman Tucuman (TM) AR -2828-06547 America/Argentina/Catamarca Catamarca (CT); Chubut (CH) AR -2926-06651 America/Argentina/La_Rioja La Rioja (LR) AR -3132-06831 America/Argentina/San_Juan San Juan (SJ) AR -3253-06849 America/Argentina/Mendoza Mendoza (MZ) AR -3319-06621 America/Argentina/San_Luis San Luis (SL) AR -5138-06913 America/Argentina/Rio_Gallegos Santa Cruz (SC) AR -5448-06818 America/Argentina/Ushuaia Tierra del Fuego (TF) AS -1416-17042 Pacific/Pago_Pago AT +4813+01620 Europe/Vienna AU -3133+15905 Australia/Lord_Howe Lord Howe Island AU -5430+15857 Antarctica/Macquarie Macquarie Island AU -4253+14719 Australia/Hobart Tasmania AU -3749+14458 Australia/Melbourne Victoria AU -3352+15113 Australia/Sydney New South Wales (most areas) AU -3157+14127 Australia/Broken_Hill New South Wales (Yancowinna) AU -2728+15302 Australia/Brisbane Queensland (most areas) AU -2016+14900 Australia/Lindeman Queensland (Whitsunday Islands) AU -3455+13835 Australia/Adelaide South Australia AU -1228+13050 Australia/Darwin Northern Territory AU -3157+11551 Australia/Perth Western Australia (most areas) AU -3143+12852 Australia/Eucla Western Australia (Eucla) AW +1230-06958 America/Aruba AX +6006+01957 Europe/Mariehamn AZ +4023+04951 Asia/Baku BA +4352+01825 Europe/Sarajevo BB +1306-05937 America/Barbados BD +2343+09025 Asia/Dhaka BE +5050+00420 Europe/Brussels BF +1222-00131 Africa/Ouagadougou BG +4241+02319 Europe/Sofia BH +2623+05035 Asia/Bahrain BI -0323+02922 Africa/Bujumbura BJ +0629+00237 Africa/Porto-Novo BL +1753-06251 America/St_Barthelemy BM +3217-06446 Atlantic/Bermuda BN +0456+11455 Asia/Brunei BO -1630-06809 America/La_Paz BQ +120903-0681636 America/Kralendijk BR -0351-03225 America/Noronha Atlantic islands BR -0127-04829 America/Belem Para (east); Amapa BR -0343-03830 America/Fortaleza Brazil (northeast: MA, PI, CE, RN, PB) BR -0803-03454 America/Recife Pernambuco BR -0712-04812 America/Araguaina Tocantins BR -0940-03543 America/Maceio Alagoas, Sergipe BR -1259-03831 America/Bahia Bahia BR -2332-04637 America/Sao_Paulo Brazil (southeast: GO, DF, MG, ES, RJ, SP, PR, SC, RS) BR -2027-05437 America/Campo_Grande Mato Grosso do Sul BR -1535-05605 America/Cuiaba Mato Grosso BR -0226-05452 America/Santarem Para (west) BR -0846-06354 America/Porto_Velho Rondonia BR +0249-06040 America/Boa_Vista Roraima BR -0308-06001 America/Manaus Amazonas (east) BR -0640-06952 America/Eirunepe Amazonas (west) BR -0958-06748 America/Rio_Branco Acre BS +2505-07721 America/Nassau BT +2728+08939 Asia/Thimphu BW -2439+02555 Africa/Gaborone BY +5354+02734 Europe/Minsk BZ +1730-08812 America/Belize CA +4734-05243 America/St_Johns Newfoundland; Labrador (southeast) CA +4439-06336 America/Halifax Atlantic - NS (most areas); PE CA +4612-05957 America/Glace_Bay Atlantic - NS (Cape Breton) CA +4606-06447 America/Moncton Atlantic - New Brunswick CA +5320-06025 America/Goose_Bay Atlantic - Labrador (most areas) CA +5125-05707 America/Blanc-Sablon AST - QC (Lower North Shore) CA +4339-07923 America/Toronto Eastern - ON, QC (most areas) CA +6344-06828 America/Iqaluit Eastern - NU (most areas) CA +484531-0913718 America/Atikokan EST - ON (Atikokan); NU (Coral H) CA +4953-09709 America/Winnipeg Central - ON (west); Manitoba CA +744144-0944945 America/Resolute Central - NU (Resolute) CA +624900-0920459 America/Rankin_Inlet Central - NU (central) CA +5024-10439 America/Regina CST - SK (most areas) CA +5017-10750 America/Swift_Current CST - SK (midwest) CA +5333-11328 America/Edmonton Mountain - AB; BC (E); NT (E); SK (W) CA +690650-1050310 America/Cambridge_Bay Mountain - NU (west) CA +682059-1334300 America/Inuvik Mountain - NT (west) CA +4906-11631 America/Creston MST - BC (Creston) CA +5546-12014 America/Dawson_Creek MST - BC (Dawson Cr, Ft St John) CA +5848-12242 America/Fort_Nelson MST - BC (Ft Nelson) CA +6043-13503 America/Whitehorse MST - Yukon (east) CA +6404-13925 America/Dawson MST - Yukon (west) CA +4916-12307 America/Vancouver Pacific - BC (most areas) CC -1210+09655 Indian/Cocos CD -0418+01518 Africa/Kinshasa Dem. Rep. of Congo (west) CD -1140+02728 Africa/Lubumbashi Dem. Rep. of Congo (east) CF +0422+01835 Africa/Bangui CG -0416+01517 Africa/Brazzaville CH +4723+00832 Europe/Zurich CI +0519-00402 Africa/Abidjan CK -2114-15946 Pacific/Rarotonga CL -3327-07040 America/Santiago most of Chile CL -5309-07055 America/Punta_Arenas Region of Magallanes CL -2709-10926 Pacific/Easter Easter Island CM +0403+00942 Africa/Douala CN +3114+12128 Asia/Shanghai Beijing Time CN +4348+08735 Asia/Urumqi Xinjiang Time CO +0436-07405 America/Bogota CR +0956-08405 America/Costa_Rica CU +2308-08222 America/Havana CV +1455-02331 Atlantic/Cape_Verde CW +1211-06900 America/Curacao CX -1025+10543 Indian/Christmas CY +3510+03322 Asia/Nicosia most of Cyprus CY +3507+03357 Asia/Famagusta Northern Cyprus CZ +5005+01426 Europe/Prague DE +5230+01322 Europe/Berlin most of Germany DE +4742+00841 Europe/Busingen Busingen DJ +1136+04309 Africa/Djibouti DK +5540+01235 Europe/Copenhagen DM +1518-06124 America/Dominica DO +1828-06954 America/Santo_Domingo DZ +3647+00303 Africa/Algiers EC -0210-07950 America/Guayaquil Ecuador (mainland) EC -0054-08936 Pacific/Galapagos Galapagos Islands EE +5925+02445 Europe/Tallinn EG +3003+03115 Africa/Cairo EH +2709-01312 Africa/El_Aaiun ER +1520+03853 Africa/Asmara ES +4024-00341 Europe/Madrid Spain (mainland) ES +3553-00519 Africa/Ceuta Ceuta, Melilla ES +2806-01524 Atlantic/Canary Canary Islands ET +0902+03842 Africa/Addis_Ababa FI +6010+02458 Europe/Helsinki FJ -1808+17825 Pacific/Fiji FK -5142-05751 Atlantic/Stanley FM +0725+15147 Pacific/Chuuk Chuuk/Truk, Yap FM +0658+15813 Pacific/Pohnpei Pohnpei/Ponape FM +0519+16259 Pacific/Kosrae Kosrae FO +6201-00646 Atlantic/Faroe FR +4852+00220 Europe/Paris GA +0023+00927 Africa/Libreville GB +513030-0000731 Europe/London GD +1203-06145 America/Grenada GE +4143+04449 Asia/Tbilisi GF +0456-05220 America/Cayenne GG +492717-0023210 Europe/Guernsey GH +0533-00013 Africa/Accra GI +3608-00521 Europe/Gibraltar GL +6411-05144 America/Nuuk most of Greenland GL +7646-01840 America/Danmarkshavn National Park (east coast) GL +7029-02158 America/Scoresbysund Scoresbysund/Ittoqqortoormiit GL +7634-06847 America/Thule Thule/Pituffik GM +1328-01639 Africa/Banjul GN +0931-01343 Africa/Conakry GP +1614-06132 America/Guadeloupe GQ +0345+00847 Africa/Malabo GR +3758+02343 Europe/Athens GS -5416-03632 Atlantic/South_Georgia GT +1438-09031 America/Guatemala GU +1328+14445 Pacific/Guam GW +1151-01535 Africa/Bissau GY +0648-05810 America/Guyana HK +2217+11409 Asia/Hong_Kong HN +1406-08713 America/Tegucigalpa HR +4548+01558 Europe/Zagreb HT +1832-07220 America/Port-au-Prince HU +4730+01905 Europe/Budapest ID -0610+10648 Asia/Jakarta Java, Sumatra ID -0002+10920 Asia/Pontianak Borneo (west, central) ID -0507+11924 Asia/Makassar Borneo (east, south); Sulawesi/Celebes, Bali, Nusa Tengarra; Timor (west) ID -0232+14042 Asia/Jayapura New Guinea (West Papua / Irian Jaya); Malukus/Moluccas IE +5320-00615 Europe/Dublin IL +314650+0351326 Asia/Jerusalem IM +5409-00428 Europe/Isle_of_Man IN +2232+08822 Asia/Kolkata IO -0720+07225 Indian/Chagos IQ +3321+04425 Asia/Baghdad IR +3540+05126 Asia/Tehran IS +6409-02151 Atlantic/Reykjavik IT +4154+01229 Europe/Rome JE +491101-0020624 Europe/Jersey JM +175805-0764736 America/Jamaica JO +3157+03556 Asia/Amman JP +353916+1394441 Asia/Tokyo KE -0117+03649 Africa/Nairobi KG +4254+07436 Asia/Bishkek KH +1133+10455 Asia/Phnom_Penh KI +0125+17300 Pacific/Tarawa Gilbert Islands KI -0247-17143 Pacific/Kanton Phoenix Islands KI +0152-15720 Pacific/Kiritimati Line Islands KM -1141+04316 Indian/Comoro KN +1718-06243 America/St_Kitts KP +3901+12545 Asia/Pyongyang KR +3733+12658 Asia/Seoul KW +2920+04759 Asia/Kuwait KY +1918-08123 America/Cayman KZ +4315+07657 Asia/Almaty most of Kazakhstan KZ +4448+06528 Asia/Qyzylorda Qyzylorda/Kyzylorda/Kzyl-Orda KZ +5312+06337 Asia/Qostanay Qostanay/Kostanay/Kustanay KZ +5017+05710 Asia/Aqtobe Aqtobe/Aktobe KZ +4431+05016 Asia/Aqtau Mangghystau/Mankistau KZ +4707+05156 Asia/Atyrau Atyrau/Atirau/Gur'yev KZ +5113+05121 Asia/Oral West Kazakhstan LA +1758+10236 Asia/Vientiane LB +3353+03530 Asia/Beirut LC +1401-06100 America/St_Lucia LI +4709+00931 Europe/Vaduz LK +0656+07951 Asia/Colombo LR +0618-01047 Africa/Monrovia LS -2928+02730 Africa/Maseru LT +5441+02519 Europe/Vilnius LU +4936+00609 Europe/Luxembourg LV +5657+02406 Europe/Riga LY +3254+01311 Africa/Tripoli MA +3339-00735 Africa/Casablanca MC +4342+00723 Europe/Monaco MD +4700+02850 Europe/Chisinau ME +4226+01916 Europe/Podgorica MF +1804-06305 America/Marigot MG -1855+04731 Indian/Antananarivo MH +0709+17112 Pacific/Majuro most of Marshall Islands MH +0905+16720 Pacific/Kwajalein Kwajalein MK +4159+02126 Europe/Skopje ML +1239-00800 Africa/Bamako MM +1647+09610 Asia/Yangon MN +4755+10653 Asia/Ulaanbaatar most of Mongolia MN +4801+09139 Asia/Hovd Bayan-Olgiy, Govi-Altai, Hovd, Uvs, Zavkhan MN +4804+11430 Asia/Choibalsan Dornod, Sukhbaatar MO +221150+1133230 Asia/Macau MP +1512+14545 Pacific/Saipan MQ +1436-06105 America/Martinique MR +1806-01557 Africa/Nouakchott MS +1643-06213 America/Montserrat MT +3554+01431 Europe/Malta MU -2010+05730 Indian/Mauritius MV +0410+07330 Indian/Maldives MW -1547+03500 Africa/Blantyre MX +1924-09909 America/Mexico_City Central Mexico MX +2105-08646 America/Cancun Quintana Roo MX +2058-08937 America/Merida Campeche, Yucatan MX +2540-10019 America/Monterrey Durango; Coahuila, Nuevo Leon, Tamaulipas (most areas) MX +2550-09730 America/Matamoros Coahuila, Nuevo Leon, Tamaulipas (US border) MX +2838-10605 America/Chihuahua Chihuahua (most areas) MX +3144-10629 America/Ciudad_Juarez Chihuahua (US border - west) MX +2934-10425 America/Ojinaga Chihuahua (US border - east) MX +2313-10625 America/Mazatlan Baja California Sur, Nayarit (most areas), Sinaloa MX +2048-10515 America/Bahia_Banderas Bahia de Banderas MX +2904-11058 America/Hermosillo Sonora MX +3232-11701 America/Tijuana Baja California MY +0310+10142 Asia/Kuala_Lumpur Malaysia (peninsula) MY +0133+11020 Asia/Kuching Sabah, Sarawak MZ -2558+03235 Africa/Maputo NA -2234+01706 Africa/Windhoek NC -2216+16627 Pacific/Noumea NE +1331+00207 Africa/Niamey NF -2903+16758 Pacific/Norfolk NG +0627+00324 Africa/Lagos NI +1209-08617 America/Managua NL +5222+00454 Europe/Amsterdam NO +5955+01045 Europe/Oslo NP +2743+08519 Asia/Kathmandu NR -0031+16655 Pacific/Nauru NU -1901-16955 Pacific/Niue NZ -3652+17446 Pacific/Auckland most of New Zealand NZ -4357-17633 Pacific/Chatham Chatham Islands OM +2336+05835 Asia/Muscat PA +0858-07932 America/Panama PE -1203-07703 America/Lima PF -1732-14934 Pacific/Tahiti Society Islands PF -0900-13930 Pacific/Marquesas Marquesas Islands PF -2308-13457 Pacific/Gambier Gambier Islands PG -0930+14710 Pacific/Port_Moresby most of Papua New Guinea PG -0613+15534 Pacific/Bougainville Bougainville PH +1435+12100 Asia/Manila PK +2452+06703 Asia/Karachi PL +5215+02100 Europe/Warsaw PM +4703-05620 America/Miquelon PN -2504-13005 Pacific/Pitcairn PR +182806-0660622 America/Puerto_Rico PS +3130+03428 Asia/Gaza Gaza Strip PS +313200+0350542 Asia/Hebron West Bank PT +3843-00908 Europe/Lisbon Portugal (mainland) PT +3238-01654 Atlantic/Madeira Madeira Islands PT +3744-02540 Atlantic/Azores Azores PW +0720+13429 Pacific/Palau PY -2516-05740 America/Asuncion QA +2517+05132 Asia/Qatar RE -2052+05528 Indian/Reunion RO +4426+02606 Europe/Bucharest RS +4450+02030 Europe/Belgrade RU +5443+02030 Europe/Kaliningrad MSK-01 - Kaliningrad RU +554521+0373704 Europe/Moscow MSK+00 - Moscow area # The obsolescent zone.tab format cannot represent Europe/Simferopol well. # Put it in RU section and list as UA. See "territorial claims" above. # Programs should use zone1970.tab instead; see above. UA +4457+03406 Europe/Simferopol Crimea RU +5836+04939 Europe/Kirov MSK+00 - Kirov RU +4844+04425 Europe/Volgograd MSK+00 - Volgograd RU +4621+04803 Europe/Astrakhan MSK+01 - Astrakhan RU +5134+04602 Europe/Saratov MSK+01 - Saratov RU +5420+04824 Europe/Ulyanovsk MSK+01 - Ulyanovsk RU +5312+05009 Europe/Samara MSK+01 - Samara, Udmurtia RU +5651+06036 Asia/Yekaterinburg MSK+02 - Urals RU +5500+07324 Asia/Omsk MSK+03 - Omsk RU +5502+08255 Asia/Novosibirsk MSK+04 - Novosibirsk RU +5322+08345 Asia/Barnaul MSK+04 - Altai RU +5630+08458 Asia/Tomsk MSK+04 - Tomsk RU +5345+08707 Asia/Novokuznetsk MSK+04 - Kemerovo RU +5601+09250 Asia/Krasnoyarsk MSK+04 - Krasnoyarsk area RU +5216+10420 Asia/Irkutsk MSK+05 - Irkutsk, Buryatia RU +5203+11328 Asia/Chita MSK+06 - Zabaykalsky RU +6200+12940 Asia/Yakutsk MSK+06 - Lena River RU +623923+1353314 Asia/Khandyga MSK+06 - Tomponsky, Ust-Maysky RU +4310+13156 Asia/Vladivostok MSK+07 - Amur River RU +643337+1431336 Asia/Ust-Nera MSK+07 - Oymyakonsky RU +5934+15048 Asia/Magadan MSK+08 - Magadan RU +4658+14242 Asia/Sakhalin MSK+08 - Sakhalin Island RU +6728+15343 Asia/Srednekolymsk MSK+08 - Sakha (E); N Kuril Is RU +5301+15839 Asia/Kamchatka MSK+09 - Kamchatka RU +6445+17729 Asia/Anadyr MSK+09 - Bering Sea RW -0157+03004 Africa/Kigali SA +2438+04643 Asia/Riyadh SB -0932+16012 Pacific/Guadalcanal SC -0440+05528 Indian/Mahe SD +1536+03232 Africa/Khartoum SE +5920+01803 Europe/Stockholm SG +0117+10351 Asia/Singapore SH -1555-00542 Atlantic/St_Helena SI +4603+01431 Europe/Ljubljana SJ +7800+01600 Arctic/Longyearbyen SK +4809+01707 Europe/Bratislava SL +0830-01315 Africa/Freetown SM +4355+01228 Europe/San_Marino SN +1440-01726 Africa/Dakar SO +0204+04522 Africa/Mogadishu SR +0550-05510 America/Paramaribo SS +0451+03137 Africa/Juba ST +0020+00644 Africa/Sao_Tome SV +1342-08912 America/El_Salvador SX +180305-0630250 America/Lower_Princes SY +3330+03618 Asia/Damascus SZ -2618+03106 Africa/Mbabane TC +2128-07108 America/Grand_Turk TD +1207+01503 Africa/Ndjamena TF -492110+0701303 Indian/Kerguelen TG +0608+00113 Africa/Lome TH +1345+10031 Asia/Bangkok TJ +3835+06848 Asia/Dushanbe TK -0922-17114 Pacific/Fakaofo TL -0833+12535 Asia/Dili TM +3757+05823 Asia/Ashgabat TN +3648+01011 Africa/Tunis TO -210800-1751200 Pacific/Tongatapu TR +4101+02858 Europe/Istanbul TT +1039-06131 America/Port_of_Spain TV -0831+17913 Pacific/Funafuti TW +2503+12130 Asia/Taipei TZ -0648+03917 Africa/Dar_es_Salaam UA +5026+03031 Europe/Kyiv most of Ukraine UG +0019+03225 Africa/Kampala UM +2813-17722 Pacific/Midway Midway Islands UM +1917+16637 Pacific/Wake Wake Island US +404251-0740023 America/New_York Eastern (most areas) US +421953-0830245 America/Detroit Eastern - MI (most areas) US +381515-0854534 America/Kentucky/Louisville Eastern - KY (Louisville area) US +364947-0845057 America/Kentucky/Monticello Eastern - KY (Wayne) US +394606-0860929 America/Indiana/Indianapolis Eastern - IN (most areas) US +384038-0873143 America/Indiana/Vincennes Eastern - IN (Da, Du, K, Mn) US +410305-0863611 America/Indiana/Winamac Eastern - IN (Pulaski) US +382232-0862041 America/Indiana/Marengo Eastern - IN (Crawford) US +382931-0871643 America/Indiana/Petersburg Eastern - IN (Pike) US +384452-0850402 America/Indiana/Vevay Eastern - IN (Switzerland) US +415100-0873900 America/Chicago Central (most areas) US +375711-0864541 America/Indiana/Tell_City Central - IN (Perry) US +411745-0863730 America/Indiana/Knox Central - IN (Starke) US +450628-0873651 America/Menominee Central - MI (Wisconsin border) US +470659-1011757 America/North_Dakota/Center Central - ND (Oliver) US +465042-1012439 America/North_Dakota/New_Salem Central - ND (Morton rural) US +471551-1014640 America/North_Dakota/Beulah Central - ND (Mercer) US +394421-1045903 America/Denver Mountain (most areas) US +433649-1161209 America/Boise Mountain - ID (south); OR (east) US +332654-1120424 America/Phoenix MST - AZ (except Navajo) US +340308-1181434 America/Los_Angeles Pacific US +611305-1495401 America/Anchorage Alaska (most areas) US +581807-1342511 America/Juneau Alaska - Juneau area US +571035-1351807 America/Sitka Alaska - Sitka area US +550737-1313435 America/Metlakatla Alaska - Annette Island US +593249-1394338 America/Yakutat Alaska - Yakutat US +643004-1652423 America/Nome Alaska (west) US +515248-1763929 America/Adak Alaska - western Aleutians US +211825-1575130 Pacific/Honolulu Hawaii UY -345433-0561245 America/Montevideo UZ +3940+06648 Asia/Samarkand Uzbekistan (west) UZ +4120+06918 Asia/Tashkent Uzbekistan (east) VA +415408+0122711 Europe/Vatican VC +1309-06114 America/St_Vincent VE +1030-06656 America/Caracas VG +1827-06437 America/Tortola VI +1821-06456 America/St_Thomas VN +1045+10640 Asia/Ho_Chi_Minh VU -1740+16825 Pacific/Efate WF -1318-17610 Pacific/Wallis WS -1350-17144 Pacific/Apia YE +1245+04512 Asia/Aden YT -1247+04514 Indian/Mayotte ZA -2615+02800 Africa/Johannesburg ZM -1525+02817 Africa/Lusaka ZW -1750+03103 Africa/Harare
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/zone.tab
tab
mit
18,855
# tzdb timezone descriptions # # This file is in the public domain. # # From Paul Eggert (2018-06-27): # This file contains a table where each row stands for a timezone where # civil timestamps have agreed since 1970. Columns are separated by # a single tab. Lines beginning with '#' are comments. All text uses # UTF-8 encoding. The columns of the table are as follows: # # 1. The countries that overlap the timezone, as a comma-separated list # of ISO 3166 2-character country codes. See the file 'iso3166.tab'. # 2. Latitude and longitude of the timezone's principal location # in ISO 6709 sign-degrees-minutes-seconds format, # either ±DDMM±DDDMM or ±DDMMSS±DDDMMSS, # first latitude (+ is north), then longitude (+ is east). # 3. Timezone name used in value of TZ environment variable. # Please see the theory.html file for how these names are chosen. # If multiple timezones overlap a country, each has a row in the # table, with each column 1 containing the country code. # 4. Comments; present if and only if countries have multiple timezones, # and useful only for those countries. For example, the comments # for the row with countries CH,DE,LI and name Europe/Zurich # are useful only for DE, since CH and LI have no other timezones. # # If a timezone covers multiple countries, the most-populous city is used, # and that country is listed first in column 1; any other countries # are listed alphabetically by country code. The table is sorted # first by country code, then (if possible) by an order within the # country that (1) makes some geographical sense, and (2) puts the # most populous timezones first, where that does not contradict (1). # # This table is intended as an aid for users, to help them select timezones # appropriate for their practical needs. It is not intended to take or # endorse any position on legal or territorial claims. # #country- #codes coordinates TZ comments AD +4230+00131 Europe/Andorra AE,OM,RE,SC,TF +2518+05518 Asia/Dubai Crozet, Scattered Is AF +3431+06912 Asia/Kabul AL +4120+01950 Europe/Tirane AM +4011+04430 Asia/Yerevan AQ -6617+11031 Antarctica/Casey Casey AQ -6835+07758 Antarctica/Davis Davis AQ -6736+06253 Antarctica/Mawson Mawson AQ -6448-06406 Antarctica/Palmer Palmer AQ -6734-06808 Antarctica/Rothera Rothera AQ -720041+0023206 Antarctica/Troll Troll AR -3436-05827 America/Argentina/Buenos_Aires Buenos Aires (BA, CF) AR -3124-06411 America/Argentina/Cordoba most areas: CB, CC, CN, ER, FM, MN, SE, SF AR -2447-06525 America/Argentina/Salta Salta (SA, LP, NQ, RN) AR -2411-06518 America/Argentina/Jujuy Jujuy (JY) AR -2649-06513 America/Argentina/Tucuman Tucumán (TM) AR -2828-06547 America/Argentina/Catamarca Catamarca (CT); Chubut (CH) AR -2926-06651 America/Argentina/La_Rioja La Rioja (LR) AR -3132-06831 America/Argentina/San_Juan San Juan (SJ) AR -3253-06849 America/Argentina/Mendoza Mendoza (MZ) AR -3319-06621 America/Argentina/San_Luis San Luis (SL) AR -5138-06913 America/Argentina/Rio_Gallegos Santa Cruz (SC) AR -5448-06818 America/Argentina/Ushuaia Tierra del Fuego (TF) AS,UM -1416-17042 Pacific/Pago_Pago Midway AT +4813+01620 Europe/Vienna AU -3133+15905 Australia/Lord_Howe Lord Howe Island AU -5430+15857 Antarctica/Macquarie Macquarie Island AU -4253+14719 Australia/Hobart Tasmania AU -3749+14458 Australia/Melbourne Victoria AU -3352+15113 Australia/Sydney New South Wales (most areas) AU -3157+14127 Australia/Broken_Hill New South Wales (Yancowinna) AU -2728+15302 Australia/Brisbane Queensland (most areas) AU -2016+14900 Australia/Lindeman Queensland (Whitsunday Islands) AU -3455+13835 Australia/Adelaide South Australia AU -1228+13050 Australia/Darwin Northern Territory AU -3157+11551 Australia/Perth Western Australia (most areas) AU -3143+12852 Australia/Eucla Western Australia (Eucla) AZ +4023+04951 Asia/Baku BB +1306-05937 America/Barbados BD +2343+09025 Asia/Dhaka BE,LU,NL +5050+00420 Europe/Brussels BG +4241+02319 Europe/Sofia BM +3217-06446 Atlantic/Bermuda BO -1630-06809 America/La_Paz BR -0351-03225 America/Noronha Atlantic islands BR -0127-04829 America/Belem Pará (east); Amapá BR -0343-03830 America/Fortaleza Brazil (northeast: MA, PI, CE, RN, PB) BR -0803-03454 America/Recife Pernambuco BR -0712-04812 America/Araguaina Tocantins BR -0940-03543 America/Maceio Alagoas, Sergipe BR -1259-03831 America/Bahia Bahia BR -2332-04637 America/Sao_Paulo Brazil (southeast: GO, DF, MG, ES, RJ, SP, PR, SC, RS) BR -2027-05437 America/Campo_Grande Mato Grosso do Sul BR -1535-05605 America/Cuiaba Mato Grosso BR -0226-05452 America/Santarem Pará (west) BR -0846-06354 America/Porto_Velho Rondônia BR +0249-06040 America/Boa_Vista Roraima BR -0308-06001 America/Manaus Amazonas (east) BR -0640-06952 America/Eirunepe Amazonas (west) BR -0958-06748 America/Rio_Branco Acre BT +2728+08939 Asia/Thimphu BY +5354+02734 Europe/Minsk BZ +1730-08812 America/Belize CA +4734-05243 America/St_Johns Newfoundland; Labrador (southeast) CA +4439-06336 America/Halifax Atlantic - NS (most areas); PE CA +4612-05957 America/Glace_Bay Atlantic - NS (Cape Breton) CA +4606-06447 America/Moncton Atlantic - New Brunswick CA +5320-06025 America/Goose_Bay Atlantic - Labrador (most areas) CA,BS +4339-07923 America/Toronto Eastern - ON, QC (most areas) CA +6344-06828 America/Iqaluit Eastern - NU (most areas) CA +4953-09709 America/Winnipeg Central - ON (west); Manitoba CA +744144-0944945 America/Resolute Central - NU (Resolute) CA +624900-0920459 America/Rankin_Inlet Central - NU (central) CA +5024-10439 America/Regina CST - SK (most areas) CA +5017-10750 America/Swift_Current CST - SK (midwest) CA +5333-11328 America/Edmonton Mountain - AB; BC (E); NT (E); SK (W) CA +690650-1050310 America/Cambridge_Bay Mountain - NU (west) CA +682059-1334300 America/Inuvik Mountain - NT (west) CA +5546-12014 America/Dawson_Creek MST - BC (Dawson Cr, Ft St John) CA +5848-12242 America/Fort_Nelson MST - BC (Ft Nelson) CA +6043-13503 America/Whitehorse MST - Yukon (east) CA +6404-13925 America/Dawson MST - Yukon (west) CA +4916-12307 America/Vancouver Pacific - BC (most areas) CH,DE,LI +4723+00832 Europe/Zurich Büsingen CI,BF,GH,GM,GN,IS,ML,MR,SH,SL,SN,TG +0519-00402 Africa/Abidjan CK -2114-15946 Pacific/Rarotonga CL -3327-07040 America/Santiago most of Chile CL -5309-07055 America/Punta_Arenas Region of Magallanes CL -2709-10926 Pacific/Easter Easter Island CN +3114+12128 Asia/Shanghai Beijing Time CN,AQ +4348+08735 Asia/Urumqi Xinjiang Time, Vostok CO +0436-07405 America/Bogota CR +0956-08405 America/Costa_Rica CU +2308-08222 America/Havana CV +1455-02331 Atlantic/Cape_Verde CY +3510+03322 Asia/Nicosia most of Cyprus CY +3507+03357 Asia/Famagusta Northern Cyprus CZ,SK +5005+01426 Europe/Prague DE,DK,NO,SE,SJ +5230+01322 Europe/Berlin most of Germany DO +1828-06954 America/Santo_Domingo DZ +3647+00303 Africa/Algiers EC -0210-07950 America/Guayaquil Ecuador (mainland) EC -0054-08936 Pacific/Galapagos Galápagos Islands EE +5925+02445 Europe/Tallinn EG +3003+03115 Africa/Cairo EH +2709-01312 Africa/El_Aaiun ES +4024-00341 Europe/Madrid Spain (mainland) ES +3553-00519 Africa/Ceuta Ceuta, Melilla ES +2806-01524 Atlantic/Canary Canary Islands FI,AX +6010+02458 Europe/Helsinki FJ -1808+17825 Pacific/Fiji FK -5142-05751 Atlantic/Stanley FM +0519+16259 Pacific/Kosrae Kosrae FO +6201-00646 Atlantic/Faroe FR,MC +4852+00220 Europe/Paris GB,GG,IM,JE +513030-0000731 Europe/London GE +4143+04449 Asia/Tbilisi GF +0456-05220 America/Cayenne GI +3608-00521 Europe/Gibraltar GL +6411-05144 America/Nuuk most of Greenland GL +7646-01840 America/Danmarkshavn National Park (east coast) GL +7029-02158 America/Scoresbysund Scoresbysund/Ittoqqortoormiit GL +7634-06847 America/Thule Thule/Pituffik GR +3758+02343 Europe/Athens GS -5416-03632 Atlantic/South_Georgia GT +1438-09031 America/Guatemala GU,MP +1328+14445 Pacific/Guam GW +1151-01535 Africa/Bissau GY +0648-05810 America/Guyana HK +2217+11409 Asia/Hong_Kong HN +1406-08713 America/Tegucigalpa HT +1832-07220 America/Port-au-Prince HU +4730+01905 Europe/Budapest ID -0610+10648 Asia/Jakarta Java, Sumatra ID -0002+10920 Asia/Pontianak Borneo (west, central) ID -0507+11924 Asia/Makassar Borneo (east, south); Sulawesi/Celebes, Bali, Nusa Tengarra; Timor (west) ID -0232+14042 Asia/Jayapura New Guinea (West Papua / Irian Jaya); Malukus/Moluccas IE +5320-00615 Europe/Dublin IL +314650+0351326 Asia/Jerusalem IN +2232+08822 Asia/Kolkata IO -0720+07225 Indian/Chagos IQ +3321+04425 Asia/Baghdad IR +3540+05126 Asia/Tehran IT,SM,VA +4154+01229 Europe/Rome JM +175805-0764736 America/Jamaica JO +3157+03556 Asia/Amman JP +353916+1394441 Asia/Tokyo KE,DJ,ER,ET,KM,MG,SO,TZ,UG,YT -0117+03649 Africa/Nairobi KG +4254+07436 Asia/Bishkek KI,MH,TV,UM,WF +0125+17300 Pacific/Tarawa Gilberts, Marshalls, Wake KI -0247-17143 Pacific/Kanton Phoenix Islands KI +0152-15720 Pacific/Kiritimati Line Islands KP +3901+12545 Asia/Pyongyang KR +3733+12658 Asia/Seoul KZ +4315+07657 Asia/Almaty most of Kazakhstan KZ +4448+06528 Asia/Qyzylorda Qyzylorda/Kyzylorda/Kzyl-Orda KZ +5312+06337 Asia/Qostanay Qostanay/Kostanay/Kustanay KZ +5017+05710 Asia/Aqtobe Aqtöbe/Aktobe KZ +4431+05016 Asia/Aqtau Mangghystaū/Mankistau KZ +4707+05156 Asia/Atyrau Atyraū/Atirau/Gur'yev KZ +5113+05121 Asia/Oral West Kazakhstan LB +3353+03530 Asia/Beirut LK +0656+07951 Asia/Colombo LR +0618-01047 Africa/Monrovia LT +5441+02519 Europe/Vilnius LV +5657+02406 Europe/Riga LY +3254+01311 Africa/Tripoli MA +3339-00735 Africa/Casablanca MD +4700+02850 Europe/Chisinau MH +0905+16720 Pacific/Kwajalein Kwajalein MM,CC +1647+09610 Asia/Yangon MN +4755+10653 Asia/Ulaanbaatar most of Mongolia MN +4801+09139 Asia/Hovd Bayan-Ölgii, Govi-Altai, Hovd, Uvs, Zavkhan MN +4804+11430 Asia/Choibalsan Dornod, Sükhbaatar MO +221150+1133230 Asia/Macau MQ +1436-06105 America/Martinique MT +3554+01431 Europe/Malta MU -2010+05730 Indian/Mauritius MV,TF +0410+07330 Indian/Maldives Kerguelen, St Paul I, Amsterdam I MX +1924-09909 America/Mexico_City Central Mexico MX +2105-08646 America/Cancun Quintana Roo MX +2058-08937 America/Merida Campeche, Yucatán MX +2540-10019 America/Monterrey Durango; Coahuila, Nuevo León, Tamaulipas (most areas) MX +2550-09730 America/Matamoros Coahuila, Nuevo León, Tamaulipas (US border) MX +2838-10605 America/Chihuahua Chihuahua (most areas) MX +3144-10629 America/Ciudad_Juarez Chihuahua (US border - west) MX +2934-10425 America/Ojinaga Chihuahua (US border - east) MX +2313-10625 America/Mazatlan Baja California Sur, Nayarit (most areas), Sinaloa MX +2048-10515 America/Bahia_Banderas Bahía de Banderas MX +2904-11058 America/Hermosillo Sonora MX +3232-11701 America/Tijuana Baja California MY,BN +0133+11020 Asia/Kuching Sabah, Sarawak MZ,BI,BW,CD,MW,RW,ZM,ZW -2558+03235 Africa/Maputo Central Africa Time NA -2234+01706 Africa/Windhoek NC -2216+16627 Pacific/Noumea NF -2903+16758 Pacific/Norfolk NG,AO,BJ,CD,CF,CG,CM,GA,GQ,NE +0627+00324 Africa/Lagos West Africa Time NI +1209-08617 America/Managua NP +2743+08519 Asia/Kathmandu NR -0031+16655 Pacific/Nauru NU -1901-16955 Pacific/Niue NZ,AQ -3652+17446 Pacific/Auckland New Zealand time NZ -4357-17633 Pacific/Chatham Chatham Islands PA,CA,KY +0858-07932 America/Panama EST - ON (Atikokan), NU (Coral H) PE -1203-07703 America/Lima PF -1732-14934 Pacific/Tahiti Society Islands PF -0900-13930 Pacific/Marquesas Marquesas Islands PF -2308-13457 Pacific/Gambier Gambier Islands PG,AQ,FM -0930+14710 Pacific/Port_Moresby Papua New Guinea (most areas), Chuuk, Yap, Dumont d'Urville PG -0613+15534 Pacific/Bougainville Bougainville PH +1435+12100 Asia/Manila PK +2452+06703 Asia/Karachi PL +5215+02100 Europe/Warsaw PM +4703-05620 America/Miquelon PN -2504-13005 Pacific/Pitcairn PR,AG,CA,AI,AW,BL,BQ,CW,DM,GD,GP,KN,LC,MF,MS,SX,TT,VC,VG,VI +182806-0660622 America/Puerto_Rico AST PS +3130+03428 Asia/Gaza Gaza Strip PS +313200+0350542 Asia/Hebron West Bank PT +3843-00908 Europe/Lisbon Portugal (mainland) PT +3238-01654 Atlantic/Madeira Madeira Islands PT +3744-02540 Atlantic/Azores Azores PW +0720+13429 Pacific/Palau PY -2516-05740 America/Asuncion QA,BH +2517+05132 Asia/Qatar RO +4426+02606 Europe/Bucharest RS,BA,HR,ME,MK,SI +4450+02030 Europe/Belgrade RU +5443+02030 Europe/Kaliningrad MSK-01 - Kaliningrad RU +554521+0373704 Europe/Moscow MSK+00 - Moscow area # Mention RU and UA alphabetically. See "territorial claims" above. RU,UA +4457+03406 Europe/Simferopol Crimea RU +5836+04939 Europe/Kirov MSK+00 - Kirov RU +4844+04425 Europe/Volgograd MSK+00 - Volgograd RU +4621+04803 Europe/Astrakhan MSK+01 - Astrakhan RU +5134+04602 Europe/Saratov MSK+01 - Saratov RU +5420+04824 Europe/Ulyanovsk MSK+01 - Ulyanovsk RU +5312+05009 Europe/Samara MSK+01 - Samara, Udmurtia RU +5651+06036 Asia/Yekaterinburg MSK+02 - Urals RU +5500+07324 Asia/Omsk MSK+03 - Omsk RU +5502+08255 Asia/Novosibirsk MSK+04 - Novosibirsk RU +5322+08345 Asia/Barnaul MSK+04 - Altai RU +5630+08458 Asia/Tomsk MSK+04 - Tomsk RU +5345+08707 Asia/Novokuznetsk MSK+04 - Kemerovo RU +5601+09250 Asia/Krasnoyarsk MSK+04 - Krasnoyarsk area RU +5216+10420 Asia/Irkutsk MSK+05 - Irkutsk, Buryatia RU +5203+11328 Asia/Chita MSK+06 - Zabaykalsky RU +6200+12940 Asia/Yakutsk MSK+06 - Lena River RU +623923+1353314 Asia/Khandyga MSK+06 - Tomponsky, Ust-Maysky RU +4310+13156 Asia/Vladivostok MSK+07 - Amur River RU +643337+1431336 Asia/Ust-Nera MSK+07 - Oymyakonsky RU +5934+15048 Asia/Magadan MSK+08 - Magadan RU +4658+14242 Asia/Sakhalin MSK+08 - Sakhalin Island RU +6728+15343 Asia/Srednekolymsk MSK+08 - Sakha (E); N Kuril Is RU +5301+15839 Asia/Kamchatka MSK+09 - Kamchatka RU +6445+17729 Asia/Anadyr MSK+09 - Bering Sea SA,AQ,KW,YE +2438+04643 Asia/Riyadh Syowa SB,FM -0932+16012 Pacific/Guadalcanal Pohnpei SD +1536+03232 Africa/Khartoum SG,MY +0117+10351 Asia/Singapore peninsular Malaysia SR +0550-05510 America/Paramaribo SS +0451+03137 Africa/Juba ST +0020+00644 Africa/Sao_Tome SV +1342-08912 America/El_Salvador SY +3330+03618 Asia/Damascus TC +2128-07108 America/Grand_Turk TD +1207+01503 Africa/Ndjamena TH,CX,KH,LA,VN +1345+10031 Asia/Bangkok north Vietnam TJ +3835+06848 Asia/Dushanbe TK -0922-17114 Pacific/Fakaofo TL -0833+12535 Asia/Dili TM +3757+05823 Asia/Ashgabat TN +3648+01011 Africa/Tunis TO -210800-1751200 Pacific/Tongatapu TR +4101+02858 Europe/Istanbul TW +2503+12130 Asia/Taipei UA +5026+03031 Europe/Kyiv most of Ukraine US +404251-0740023 America/New_York Eastern (most areas) US +421953-0830245 America/Detroit Eastern - MI (most areas) US +381515-0854534 America/Kentucky/Louisville Eastern - KY (Louisville area) US +364947-0845057 America/Kentucky/Monticello Eastern - KY (Wayne) US +394606-0860929 America/Indiana/Indianapolis Eastern - IN (most areas) US +384038-0873143 America/Indiana/Vincennes Eastern - IN (Da, Du, K, Mn) US +410305-0863611 America/Indiana/Winamac Eastern - IN (Pulaski) US +382232-0862041 America/Indiana/Marengo Eastern - IN (Crawford) US +382931-0871643 America/Indiana/Petersburg Eastern - IN (Pike) US +384452-0850402 America/Indiana/Vevay Eastern - IN (Switzerland) US +415100-0873900 America/Chicago Central (most areas) US +375711-0864541 America/Indiana/Tell_City Central - IN (Perry) US +411745-0863730 America/Indiana/Knox Central - IN (Starke) US +450628-0873651 America/Menominee Central - MI (Wisconsin border) US +470659-1011757 America/North_Dakota/Center Central - ND (Oliver) US +465042-1012439 America/North_Dakota/New_Salem Central - ND (Morton rural) US +471551-1014640 America/North_Dakota/Beulah Central - ND (Mercer) US +394421-1045903 America/Denver Mountain (most areas) US +433649-1161209 America/Boise Mountain - ID (south); OR (east) US,CA +332654-1120424 America/Phoenix MST - AZ (most areas), Creston BC US +340308-1181434 America/Los_Angeles Pacific US +611305-1495401 America/Anchorage Alaska (most areas) US +581807-1342511 America/Juneau Alaska - Juneau area US +571035-1351807 America/Sitka Alaska - Sitka area US +550737-1313435 America/Metlakatla Alaska - Annette Island US +593249-1394338 America/Yakutat Alaska - Yakutat US +643004-1652423 America/Nome Alaska (west) US +515248-1763929 America/Adak Alaska - western Aleutians US +211825-1575130 Pacific/Honolulu Hawaii UY -345433-0561245 America/Montevideo UZ +3940+06648 Asia/Samarkand Uzbekistan (west) UZ +4120+06918 Asia/Tashkent Uzbekistan (east) VE +1030-06656 America/Caracas VN +1045+10640 Asia/Ho_Chi_Minh south Vietnam VU -1740+16825 Pacific/Efate WS -1350-17144 Pacific/Apia ZA,LS,SZ -2615+02800 Africa/Johannesburg # # The next section contains experimental tab-separated comments for # use by user agents like tzselect that identify continents and oceans. # # For example, the comment "#@AQ<tab>Antarctica/" means the country code # AQ is in the continent Antarctica regardless of the Zone name, # so Pacific/Auckland should be listed under Antarctica as well as # under the Pacific because its line's country codes include AQ. # # If more than one country code is affected each is listed separated # by commas, e.g., #@IS,SH<tab>Atlantic/". If a country code is in # more than one continent or ocean, each is listed separated by # commas, e.g., the second column of "#@CY,TR<tab>Asia/,Europe/". # # These experimental comments are present only for country codes where # the continent or ocean is not already obvious from the Zone name. # For example, there is no such comment for RU since it already # corresponds to Zone names starting with both "Europe/" and "Asia/". # #@AQ Antarctica/ #@IS,SH Atlantic/ #@CY,TR Asia/,Europe/ #@SJ Arctic/ #@CC,CX,KM,MG,YT Indian/
castiel248/Convert
Lib/site-packages/tzdata/zoneinfo/zone1970.tab
tab
mit
17,551
Africa/Algiers Atlantic/Cape_Verde Africa/Ndjamena Africa/Abidjan Africa/Cairo Africa/Bissau Africa/Nairobi Africa/Monrovia Africa/Tripoli Indian/Mauritius Africa/Casablanca Africa/El_Aaiun Africa/Maputo Africa/Windhoek Africa/Lagos Africa/Sao_Tome Africa/Johannesburg Africa/Khartoum Africa/Juba Africa/Tunis Antarctica/Casey Antarctica/Davis Antarctica/Mawson Antarctica/Troll Antarctica/Rothera Asia/Kabul Asia/Yerevan Asia/Baku Asia/Dhaka Asia/Thimphu Indian/Chagos Asia/Yangon Asia/Shanghai Asia/Urumqi Asia/Hong_Kong Asia/Taipei Asia/Macau Asia/Nicosia Asia/Famagusta Asia/Tbilisi Asia/Dili Asia/Kolkata Asia/Jakarta Asia/Pontianak Asia/Makassar Asia/Jayapura Asia/Tehran Asia/Baghdad Asia/Jerusalem Asia/Tokyo Asia/Amman Asia/Almaty Asia/Qyzylorda Asia/Qostanay Asia/Aqtobe Asia/Aqtau Asia/Atyrau Asia/Oral Asia/Bishkek Asia/Seoul Asia/Pyongyang Asia/Beirut Asia/Kuching Indian/Maldives Asia/Hovd Asia/Ulaanbaatar Asia/Choibalsan Asia/Kathmandu Asia/Karachi Asia/Gaza Asia/Hebron Asia/Manila Asia/Qatar Asia/Riyadh Asia/Singapore Asia/Colombo Asia/Damascus Asia/Dushanbe Asia/Bangkok Asia/Ashgabat Asia/Dubai Asia/Samarkand Asia/Tashkent Asia/Ho_Chi_Minh Australia/Darwin Australia/Perth Australia/Eucla Australia/Brisbane Australia/Lindeman Australia/Adelaide Australia/Hobart Australia/Melbourne Australia/Sydney Australia/Broken_Hill Australia/Lord_Howe Antarctica/Macquarie Pacific/Fiji Pacific/Gambier Pacific/Marquesas Pacific/Tahiti Pacific/Guam Pacific/Tarawa Pacific/Kanton Pacific/Kiritimati Pacific/Kwajalein Pacific/Kosrae Pacific/Nauru Pacific/Noumea Pacific/Auckland Pacific/Chatham Pacific/Rarotonga Pacific/Niue Pacific/Norfolk Pacific/Palau Pacific/Port_Moresby Pacific/Bougainville Pacific/Pitcairn Pacific/Pago_Pago Pacific/Apia Pacific/Guadalcanal Pacific/Fakaofo Pacific/Tongatapu Pacific/Efate Europe/London Europe/Dublin WET CET MET EET Europe/Tirane Europe/Andorra Europe/Vienna Europe/Minsk Europe/Brussels Europe/Sofia Europe/Prague Atlantic/Faroe America/Danmarkshavn America/Scoresbysund America/Nuuk America/Thule Europe/Tallinn Europe/Helsinki Europe/Paris Europe/Berlin Europe/Gibraltar Europe/Athens Europe/Budapest Europe/Rome Europe/Riga Europe/Vilnius Europe/Malta Europe/Chisinau Europe/Warsaw Europe/Lisbon Atlantic/Azores Atlantic/Madeira Europe/Bucharest Europe/Kaliningrad Europe/Moscow Europe/Simferopol Europe/Astrakhan Europe/Volgograd Europe/Saratov Europe/Kirov Europe/Samara Europe/Ulyanovsk Asia/Yekaterinburg Asia/Omsk Asia/Barnaul Asia/Novosibirsk Asia/Tomsk Asia/Novokuznetsk Asia/Krasnoyarsk Asia/Irkutsk Asia/Chita Asia/Yakutsk Asia/Vladivostok Asia/Khandyga Asia/Sakhalin Asia/Magadan Asia/Srednekolymsk Asia/Ust-Nera Asia/Kamchatka Asia/Anadyr Europe/Belgrade Europe/Madrid Africa/Ceuta Atlantic/Canary Europe/Zurich Europe/Istanbul Europe/Kyiv EST MST HST EST5EDT CST6CDT MST7MDT PST8PDT America/New_York America/Chicago America/North_Dakota/Center America/North_Dakota/New_Salem America/North_Dakota/Beulah America/Denver America/Los_Angeles America/Juneau America/Sitka America/Metlakatla America/Yakutat America/Anchorage America/Nome America/Adak Pacific/Honolulu America/Phoenix America/Boise America/Indiana/Indianapolis America/Indiana/Marengo America/Indiana/Vincennes America/Indiana/Tell_City America/Indiana/Petersburg America/Indiana/Knox America/Indiana/Winamac America/Indiana/Vevay America/Kentucky/Louisville America/Kentucky/Monticello America/Detroit America/Menominee America/St_Johns America/Goose_Bay America/Halifax America/Glace_Bay America/Moncton America/Toronto America/Winnipeg America/Regina America/Swift_Current America/Edmonton America/Vancouver America/Dawson_Creek America/Fort_Nelson America/Iqaluit America/Resolute America/Rankin_Inlet America/Cambridge_Bay America/Inuvik America/Whitehorse America/Dawson America/Cancun America/Merida America/Matamoros America/Monterrey America/Mexico_City America/Ciudad_Juarez America/Ojinaga America/Chihuahua America/Hermosillo America/Mazatlan America/Bahia_Banderas America/Tijuana America/Barbados America/Belize Atlantic/Bermuda America/Costa_Rica America/Havana America/Santo_Domingo America/El_Salvador America/Guatemala America/Port-au-Prince America/Tegucigalpa America/Jamaica America/Martinique America/Managua America/Panama America/Puerto_Rico America/Miquelon America/Grand_Turk America/Argentina/Buenos_Aires America/Argentina/Cordoba America/Argentina/Salta America/Argentina/Tucuman America/Argentina/La_Rioja America/Argentina/San_Juan America/Argentina/Jujuy America/Argentina/Catamarca America/Argentina/Mendoza America/Argentina/San_Luis America/Argentina/Rio_Gallegos America/Argentina/Ushuaia America/La_Paz America/Noronha America/Belem America/Santarem America/Fortaleza America/Recife America/Araguaina America/Maceio America/Bahia America/Sao_Paulo America/Campo_Grande America/Cuiaba America/Porto_Velho America/Boa_Vista America/Manaus America/Eirunepe America/Rio_Branco America/Santiago America/Punta_Arenas Pacific/Easter Antarctica/Palmer America/Bogota America/Guayaquil Pacific/Galapagos Atlantic/Stanley America/Cayenne America/Guyana America/Asuncion America/Lima Atlantic/South_Georgia America/Paramaribo America/Montevideo America/Caracas Etc/UTC Etc/GMT GMT Etc/GMT-14 Etc/GMT-13 Etc/GMT-12 Etc/GMT-11 Etc/GMT-10 Etc/GMT-9 Etc/GMT-8 Etc/GMT-7 Etc/GMT-6 Etc/GMT-5 Etc/GMT-4 Etc/GMT-3 Etc/GMT-2 Etc/GMT-1 Etc/GMT+1 Etc/GMT+2 Etc/GMT+3 Etc/GMT+4 Etc/GMT+5 Etc/GMT+6 Etc/GMT+7 Etc/GMT+8 Etc/GMT+9 Etc/GMT+10 Etc/GMT+11 Etc/GMT+12 Factory Australia/ACT Australia/LHI Australia/NSW Australia/North Australia/Queensland Australia/South Australia/Tasmania Australia/Victoria Australia/West Australia/Yancowinna Brazil/Acre Brazil/DeNoronha Brazil/East Brazil/West Canada/Atlantic Canada/Central Canada/Eastern Canada/Mountain Canada/Newfoundland Canada/Pacific Canada/Saskatchewan Canada/Yukon Chile/Continental Chile/EasterIsland Cuba Egypt Eire Etc/GMT+0 Etc/GMT-0 Etc/GMT0 Etc/Greenwich Etc/UCT Etc/Universal Etc/Zulu GB GB-Eire GMT+0 GMT-0 GMT0 Greenwich Hongkong Iceland Iran Israel Jamaica Japan Kwajalein Libya Mexico/BajaNorte Mexico/BajaSur Mexico/General NZ NZ-CHAT Navajo PRC Poland Portugal ROC ROK Singapore Turkey UCT US/Alaska US/Aleutian US/Arizona US/Central US/East-Indiana US/Eastern US/Hawaii US/Indiana-Starke US/Michigan US/Mountain US/Pacific US/Samoa UTC Universal W-SU Zulu America/Buenos_Aires America/Catamarca America/Cordoba America/Indianapolis America/Jujuy America/Knox_IN America/Louisville America/Mendoza America/Virgin Pacific/Samoa Africa/Accra Africa/Addis_Ababa Africa/Asmara Africa/Bamako Africa/Bangui Africa/Banjul Africa/Blantyre Africa/Brazzaville Africa/Bujumbura Africa/Conakry Africa/Dakar Africa/Dar_es_Salaam Africa/Djibouti Africa/Douala Africa/Freetown Africa/Gaborone Africa/Harare Africa/Kampala Africa/Kigali Africa/Kinshasa Africa/Libreville Africa/Lome Africa/Luanda Africa/Lubumbashi Africa/Lusaka Africa/Malabo Africa/Maseru Africa/Mbabane Africa/Mogadishu Africa/Niamey Africa/Nouakchott Africa/Ouagadougou Africa/Porto-Novo America/Anguilla America/Antigua America/Aruba America/Atikokan America/Blanc-Sablon America/Cayman America/Creston America/Curacao America/Dominica America/Grenada America/Guadeloupe America/Kralendijk America/Lower_Princes America/Marigot America/Montserrat America/Nassau America/Port_of_Spain America/St_Barthelemy America/St_Kitts America/St_Lucia America/St_Thomas America/St_Vincent America/Tortola Antarctica/DumontDUrville Antarctica/McMurdo Antarctica/Syowa Antarctica/Vostok Arctic/Longyearbyen Asia/Aden Asia/Bahrain Asia/Brunei Asia/Kuala_Lumpur Asia/Kuwait Asia/Muscat Asia/Phnom_Penh Asia/Vientiane Atlantic/Reykjavik Atlantic/St_Helena Europe/Amsterdam Europe/Bratislava Europe/Busingen Europe/Copenhagen Europe/Guernsey Europe/Isle_of_Man Europe/Jersey Europe/Ljubljana Europe/Luxembourg Europe/Mariehamn Europe/Monaco Europe/Oslo Europe/Podgorica Europe/San_Marino Europe/Sarajevo Europe/Skopje Europe/Stockholm Europe/Vaduz Europe/Vatican Europe/Zagreb Indian/Antananarivo Indian/Christmas Indian/Cocos Indian/Comoro Indian/Kerguelen Indian/Mahe Indian/Mayotte Indian/Reunion Pacific/Chuuk Pacific/Funafuti Pacific/Majuro Pacific/Midway Pacific/Pohnpei Pacific/Saipan Pacific/Wake Pacific/Wallis Africa/Timbuktu America/Argentina/ComodRivadavia America/Atka America/Coral_Harbour America/Ensenada America/Fort_Wayne America/Montreal America/Nipigon America/Pangnirtung America/Porto_Acre America/Rainy_River America/Rosario America/Santa_Isabel America/Shiprock America/Thunder_Bay America/Yellowknife Antarctica/South_Pole Asia/Chongqing Asia/Harbin Asia/Kashgar Asia/Tel_Aviv Atlantic/Jan_Mayen Australia/Canberra Australia/Currie Europe/Belfast Europe/Tiraspol Europe/Uzhgorod Europe/Zaporozhye Pacific/Enderbury Pacific/Johnston Pacific/Yap Africa/Asmera America/Godthab Asia/Ashkhabad Asia/Calcutta Asia/Chungking Asia/Dacca Asia/Istanbul Asia/Katmandu Asia/Macao Asia/Rangoon Asia/Saigon Asia/Thimbu Asia/Ujung_Pandang Asia/Ulan_Bator Atlantic/Faeroe Europe/Kiev Europe/Nicosia Pacific/Ponape Pacific/Truk
castiel248/Convert
Lib/site-packages/tzdata/zones
none
mit
9,084
<# .Synopsis Activate a Python virtual environment for the current PowerShell session. .Description Pushes the python executable for a virtual environment to the front of the $Env:PATH environment variable and sets the prompt to signify that you are in a Python virtual environment. Makes use of the command line switches as well as the `pyvenv.cfg` file values present in the virtual environment. .Parameter VenvDir Path to the directory that contains the virtual environment to activate. The default value for this is the parent of the directory that the Activate.ps1 script is located within. .Parameter Prompt The prompt prefix to display when this virtual environment is activated. By default, this prompt is the name of the virtual environment folder (VenvDir) surrounded by parentheses and followed by a single space (ie. '(.venv) '). .Example Activate.ps1 Activates the Python virtual environment that contains the Activate.ps1 script. .Example Activate.ps1 -Verbose Activates the Python virtual environment that contains the Activate.ps1 script, and shows extra information about the activation as it executes. .Example Activate.ps1 -VenvDir C:\Users\MyUser\Common\.venv Activates the Python virtual environment located in the specified location. .Example Activate.ps1 -Prompt "MyPython" Activates the Python virtual environment that contains the Activate.ps1 script, and prefixes the current prompt with the specified string (surrounded in parentheses) while the virtual environment is active. .Notes On Windows, it may be required to enable this Activate.ps1 script by setting the execution policy for the user. You can do this by issuing the following PowerShell command: PS C:\> Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser For more information on Execution Policies: https://go.microsoft.com/fwlink/?LinkID=135170 #> Param( [Parameter(Mandatory = $false)] [String] $VenvDir, [Parameter(Mandatory = $false)] [String] $Prompt ) <# Function declarations --------------------------------------------------- #> <# .Synopsis Remove all shell session elements added by the Activate script, including the addition of the virtual environment's Python executable from the beginning of the PATH variable. .Parameter NonDestructive If present, do not remove this function from the global namespace for the session. #> function global:deactivate ([switch]$NonDestructive) { # Revert to original values # The prior prompt: if (Test-Path -Path Function:_OLD_VIRTUAL_PROMPT) { Copy-Item -Path Function:_OLD_VIRTUAL_PROMPT -Destination Function:prompt Remove-Item -Path Function:_OLD_VIRTUAL_PROMPT } # The prior PYTHONHOME: if (Test-Path -Path Env:_OLD_VIRTUAL_PYTHONHOME) { Copy-Item -Path Env:_OLD_VIRTUAL_PYTHONHOME -Destination Env:PYTHONHOME Remove-Item -Path Env:_OLD_VIRTUAL_PYTHONHOME } # The prior PATH: if (Test-Path -Path Env:_OLD_VIRTUAL_PATH) { Copy-Item -Path Env:_OLD_VIRTUAL_PATH -Destination Env:PATH Remove-Item -Path Env:_OLD_VIRTUAL_PATH } # Just remove the VIRTUAL_ENV altogether: if (Test-Path -Path Env:VIRTUAL_ENV) { Remove-Item -Path env:VIRTUAL_ENV } # Just remove VIRTUAL_ENV_PROMPT altogether. if (Test-Path -Path Env:VIRTUAL_ENV_PROMPT) { Remove-Item -Path env:VIRTUAL_ENV_PROMPT } # Just remove the _PYTHON_VENV_PROMPT_PREFIX altogether: if (Get-Variable -Name "_PYTHON_VENV_PROMPT_PREFIX" -ErrorAction SilentlyContinue) { Remove-Variable -Name _PYTHON_VENV_PROMPT_PREFIX -Scope Global -Force } # Leave deactivate function in the global namespace if requested: if (-not $NonDestructive) { Remove-Item -Path function:deactivate } } <# .Description Get-PyVenvConfig parses the values from the pyvenv.cfg file located in the given folder, and returns them in a map. For each line in the pyvenv.cfg file, if that line can be parsed into exactly two strings separated by `=` (with any amount of whitespace surrounding the =) then it is considered a `key = value` line. The left hand string is the key, the right hand is the value. If the value starts with a `'` or a `"` then the first and last character is stripped from the value before being captured. .Parameter ConfigDir Path to the directory that contains the `pyvenv.cfg` file. #> function Get-PyVenvConfig( [String] $ConfigDir ) { Write-Verbose "Given ConfigDir=$ConfigDir, obtain values in pyvenv.cfg" # Ensure the file exists, and issue a warning if it doesn't (but still allow the function to continue). $pyvenvConfigPath = Join-Path -Resolve -Path $ConfigDir -ChildPath 'pyvenv.cfg' -ErrorAction Continue # An empty map will be returned if no config file is found. $pyvenvConfig = @{ } if ($pyvenvConfigPath) { Write-Verbose "File exists, parse `key = value` lines" $pyvenvConfigContent = Get-Content -Path $pyvenvConfigPath $pyvenvConfigContent | ForEach-Object { $keyval = $PSItem -split "\s*=\s*", 2 if ($keyval[0] -and $keyval[1]) { $val = $keyval[1] # Remove extraneous quotations around a string value. if ("'""".Contains($val.Substring(0, 1))) { $val = $val.Substring(1, $val.Length - 2) } $pyvenvConfig[$keyval[0]] = $val Write-Verbose "Adding Key: '$($keyval[0])'='$val'" } } } return $pyvenvConfig } <# Begin Activate script --------------------------------------------------- #> # Determine the containing directory of this script $VenvExecPath = Split-Path -Parent $MyInvocation.MyCommand.Definition $VenvExecDir = Get-Item -Path $VenvExecPath Write-Verbose "Activation script is located in path: '$VenvExecPath'" Write-Verbose "VenvExecDir Fullname: '$($VenvExecDir.FullName)" Write-Verbose "VenvExecDir Name: '$($VenvExecDir.Name)" # Set values required in priority: CmdLine, ConfigFile, Default # First, get the location of the virtual environment, it might not be # VenvExecDir if specified on the command line. if ($VenvDir) { Write-Verbose "VenvDir given as parameter, using '$VenvDir' to determine values" } else { Write-Verbose "VenvDir not given as a parameter, using parent directory name as VenvDir." $VenvDir = $VenvExecDir.Parent.FullName.TrimEnd("\\/") Write-Verbose "VenvDir=$VenvDir" } # Next, read the `pyvenv.cfg` file to determine any required value such # as `prompt`. $pyvenvCfg = Get-PyVenvConfig -ConfigDir $VenvDir # Next, set the prompt from the command line, or the config file, or # just use the name of the virtual environment folder. if ($Prompt) { Write-Verbose "Prompt specified as argument, using '$Prompt'" } else { Write-Verbose "Prompt not specified as argument to script, checking pyvenv.cfg value" if ($pyvenvCfg -and $pyvenvCfg['prompt']) { Write-Verbose " Setting based on value in pyvenv.cfg='$($pyvenvCfg['prompt'])'" $Prompt = $pyvenvCfg['prompt']; } else { Write-Verbose " Setting prompt based on parent's directory's name. (Is the directory name passed to venv module when creating the virtual environment)" Write-Verbose " Got leaf-name of $VenvDir='$(Split-Path -Path $venvDir -Leaf)'" $Prompt = Split-Path -Path $venvDir -Leaf } } Write-Verbose "Prompt = '$Prompt'" Write-Verbose "VenvDir='$VenvDir'" # Deactivate any currently active virtual environment, but leave the # deactivate function in place. deactivate -nondestructive # Now set the environment variable VIRTUAL_ENV, used by many tools to determine # that there is an activated venv. $env:VIRTUAL_ENV = $VenvDir if (-not $Env:VIRTUAL_ENV_DISABLE_PROMPT) { Write-Verbose "Setting prompt to '$Prompt'" # Set the prompt to include the env name # Make sure _OLD_VIRTUAL_PROMPT is global function global:_OLD_VIRTUAL_PROMPT { "" } Copy-Item -Path function:prompt -Destination function:_OLD_VIRTUAL_PROMPT New-Variable -Name _PYTHON_VENV_PROMPT_PREFIX -Description "Python virtual environment prompt prefix" -Scope Global -Option ReadOnly -Visibility Public -Value $Prompt function global:prompt { Write-Host -NoNewline -ForegroundColor Green "($_PYTHON_VENV_PROMPT_PREFIX) " _OLD_VIRTUAL_PROMPT } $env:VIRTUAL_ENV_PROMPT = $Prompt } # Clear PYTHONHOME if (Test-Path -Path Env:PYTHONHOME) { Copy-Item -Path Env:PYTHONHOME -Destination Env:_OLD_VIRTUAL_PYTHONHOME Remove-Item -Path Env:PYTHONHOME } # Add the venv to the PATH Copy-Item -Path Env:PATH -Destination Env:_OLD_VIRTUAL_PATH $Env:PATH = "$VenvExecDir$([System.IO.Path]::PathSeparator)$Env:PATH" # SIG # Begin signature block # MIIpiQYJKoZIhvcNAQcCoIIpejCCKXYCAQExDzANBglghkgBZQMEAgEFADB5Bgor # BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG # KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCBnL745ElCYk8vk # dBtMuQhLeWJ3ZGfzKW4DHCYzAn+QB6CCDi8wggawMIIEmKADAgECAhAIrUCyYNKc # TJ9ezam9k67ZMA0GCSqGSIb3DQEBDAUAMGIxCzAJBgNVBAYTAlVTMRUwEwYDVQQK # EwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5jb20xITAfBgNV # BAMTGERpZ2lDZXJ0IFRydXN0ZWQgUm9vdCBHNDAeFw0yMTA0MjkwMDAwMDBaFw0z # NjA0MjgyMzU5NTlaMGkxCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5EaWdpQ2VydCwg # SW5jLjFBMD8GA1UEAxM4RGlnaUNlcnQgVHJ1c3RlZCBHNCBDb2RlIFNpZ25pbmcg # UlNBNDA5NiBTSEEzODQgMjAyMSBDQTEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAw # ggIKAoICAQDVtC9C0CiteLdd1TlZG7GIQvUzjOs9gZdwxbvEhSYwn6SOaNhc9es0 # JAfhS0/TeEP0F9ce2vnS1WcaUk8OoVf8iJnBkcyBAz5NcCRks43iCH00fUyAVxJr # Q5qZ8sU7H/Lvy0daE6ZMswEgJfMQ04uy+wjwiuCdCcBlp/qYgEk1hz1RGeiQIXhF # LqGfLOEYwhrMxe6TSXBCMo/7xuoc82VokaJNTIIRSFJo3hC9FFdd6BgTZcV/sk+F # LEikVoQ11vkunKoAFdE3/hoGlMJ8yOobMubKwvSnowMOdKWvObarYBLj6Na59zHh # 3K3kGKDYwSNHR7OhD26jq22YBoMbt2pnLdK9RBqSEIGPsDsJ18ebMlrC/2pgVItJ # wZPt4bRc4G/rJvmM1bL5OBDm6s6R9b7T+2+TYTRcvJNFKIM2KmYoX7BzzosmJQay # g9Rc9hUZTO1i4F4z8ujo7AqnsAMrkbI2eb73rQgedaZlzLvjSFDzd5Ea/ttQokbI # YViY9XwCFjyDKK05huzUtw1T0PhH5nUwjewwk3YUpltLXXRhTT8SkXbev1jLchAp # QfDVxW0mdmgRQRNYmtwmKwH0iU1Z23jPgUo+QEdfyYFQc4UQIyFZYIpkVMHMIRro # OBl8ZhzNeDhFMJlP/2NPTLuqDQhTQXxYPUez+rbsjDIJAsxsPAxWEQIDAQABo4IB # WTCCAVUwEgYDVR0TAQH/BAgwBgEB/wIBADAdBgNVHQ4EFgQUaDfg67Y7+F8Rhvv+ # YXsIiGX0TkIwHwYDVR0jBBgwFoAU7NfjgtJxXWRM3y5nP+e6mK4cD08wDgYDVR0P # AQH/BAQDAgGGMBMGA1UdJQQMMAoGCCsGAQUFBwMDMHcGCCsGAQUFBwEBBGswaTAk # BggrBgEFBQcwAYYYaHR0cDovL29jc3AuZGlnaWNlcnQuY29tMEEGCCsGAQUFBzAC # hjVodHRwOi8vY2FjZXJ0cy5kaWdpY2VydC5jb20vRGlnaUNlcnRUcnVzdGVkUm9v # dEc0LmNydDBDBgNVHR8EPDA6MDigNqA0hjJodHRwOi8vY3JsMy5kaWdpY2VydC5j # b20vRGlnaUNlcnRUcnVzdGVkUm9vdEc0LmNybDAcBgNVHSAEFTATMAcGBWeBDAED # MAgGBmeBDAEEATANBgkqhkiG9w0BAQwFAAOCAgEAOiNEPY0Idu6PvDqZ01bgAhql # +Eg08yy25nRm95RysQDKr2wwJxMSnpBEn0v9nqN8JtU3vDpdSG2V1T9J9Ce7FoFF # UP2cvbaF4HZ+N3HLIvdaqpDP9ZNq4+sg0dVQeYiaiorBtr2hSBh+3NiAGhEZGM1h # mYFW9snjdufE5BtfQ/g+lP92OT2e1JnPSt0o618moZVYSNUa/tcnP/2Q0XaG3Ryw # YFzzDaju4ImhvTnhOE7abrs2nfvlIVNaw8rpavGiPttDuDPITzgUkpn13c5Ubdld # AhQfQDN8A+KVssIhdXNSy0bYxDQcoqVLjc1vdjcshT8azibpGL6QB7BDf5WIIIJw # 8MzK7/0pNVwfiThV9zeKiwmhywvpMRr/LhlcOXHhvpynCgbWJme3kuZOX956rEnP # LqR0kq3bPKSchh/jwVYbKyP/j7XqiHtwa+aguv06P0WmxOgWkVKLQcBIhEuWTatE # QOON8BUozu3xGFYHKi8QxAwIZDwzj64ojDzLj4gLDb879M4ee47vtevLt/B3E+bn # KD+sEq6lLyJsQfmCXBVmzGwOysWGw/YmMwwHS6DTBwJqakAwSEs0qFEgu60bhQji # WQ1tygVQK+pKHJ6l/aCnHwZ05/LWUpD9r4VIIflXO7ScA+2GRfS0YW6/aOImYIbq # yK+p/pQd52MbOoZWeE4wggd3MIIFX6ADAgECAhAHHxQbizANJfMU6yMM0NHdMA0G # CSqGSIb3DQEBCwUAMGkxCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5EaWdpQ2VydCwg # SW5jLjFBMD8GA1UEAxM4RGlnaUNlcnQgVHJ1c3RlZCBHNCBDb2RlIFNpZ25pbmcg # UlNBNDA5NiBTSEEzODQgMjAyMSBDQTEwHhcNMjIwMTE3MDAwMDAwWhcNMjUwMTE1 # MjM1OTU5WjB8MQswCQYDVQQGEwJVUzEPMA0GA1UECBMGT3JlZ29uMRIwEAYDVQQH # EwlCZWF2ZXJ0b24xIzAhBgNVBAoTGlB5dGhvbiBTb2Z0d2FyZSBGb3VuZGF0aW9u # MSMwIQYDVQQDExpQeXRob24gU29mdHdhcmUgRm91bmRhdGlvbjCCAiIwDQYJKoZI # hvcNAQEBBQADggIPADCCAgoCggIBAKgc0BTT+iKbtK6f2mr9pNMUTcAJxKdsuOiS # YgDFfwhjQy89koM7uP+QV/gwx8MzEt3c9tLJvDccVWQ8H7mVsk/K+X+IufBLCgUi # 0GGAZUegEAeRlSXxxhYScr818ma8EvGIZdiSOhqjYc4KnfgfIS4RLtZSrDFG2tN1 # 6yS8skFa3IHyvWdbD9PvZ4iYNAS4pjYDRjT/9uzPZ4Pan+53xZIcDgjiTwOh8VGu # ppxcia6a7xCyKoOAGjvCyQsj5223v1/Ig7Dp9mGI+nh1E3IwmyTIIuVHyK6Lqu35 # 2diDY+iCMpk9ZanmSjmB+GMVs+H/gOiofjjtf6oz0ki3rb7sQ8fTnonIL9dyGTJ0 # ZFYKeb6BLA66d2GALwxZhLe5WH4Np9HcyXHACkppsE6ynYjTOd7+jN1PRJahN1oE # RzTzEiV6nCO1M3U1HbPTGyq52IMFSBM2/07WTJSbOeXjvYR7aUxK9/ZkJiacl2iZ # I7IWe7JKhHohqKuceQNyOzxTakLcRkzynvIrk33R9YVqtB4L6wtFxhUjvDnQg16x # ot2KVPdfyPAWd81wtZADmrUtsZ9qG79x1hBdyOl4vUtVPECuyhCxaw+faVjumapP # Unwo8ygflJJ74J+BYxf6UuD7m8yzsfXWkdv52DjL74TxzuFTLHPyARWCSCAbzn3Z # Ily+qIqDAgMBAAGjggIGMIICAjAfBgNVHSMEGDAWgBRoN+Drtjv4XxGG+/5hewiI # ZfROQjAdBgNVHQ4EFgQUt/1Teh2XDuUj2WW3siYWJgkZHA8wDgYDVR0PAQH/BAQD # AgeAMBMGA1UdJQQMMAoGCCsGAQUFBwMDMIG1BgNVHR8Ega0wgaowU6BRoE+GTWh0 # dHA6Ly9jcmwzLmRpZ2ljZXJ0LmNvbS9EaWdpQ2VydFRydXN0ZWRHNENvZGVTaWdu # aW5nUlNBNDA5NlNIQTM4NDIwMjFDQTEuY3JsMFOgUaBPhk1odHRwOi8vY3JsNC5k # aWdpY2VydC5jb20vRGlnaUNlcnRUcnVzdGVkRzRDb2RlU2lnbmluZ1JTQTQwOTZT # SEEzODQyMDIxQ0ExLmNybDA+BgNVHSAENzA1MDMGBmeBDAEEATApMCcGCCsGAQUF # BwIBFhtodHRwOi8vd3d3LmRpZ2ljZXJ0LmNvbS9DUFMwgZQGCCsGAQUFBwEBBIGH # MIGEMCQGCCsGAQUFBzABhhhodHRwOi8vb2NzcC5kaWdpY2VydC5jb20wXAYIKwYB # BQUHMAKGUGh0dHA6Ly9jYWNlcnRzLmRpZ2ljZXJ0LmNvbS9EaWdpQ2VydFRydXN0 # ZWRHNENvZGVTaWduaW5nUlNBNDA5NlNIQTM4NDIwMjFDQTEuY3J0MAwGA1UdEwEB # /wQCMAAwDQYJKoZIhvcNAQELBQADggIBABxv4AeV/5ltkELHSC63fXAFYS5tadcW # TiNc2rskrNLrfH1Ns0vgSZFoQxYBFKI159E8oQQ1SKbTEubZ/B9kmHPhprHya08+ # VVzxC88pOEvz68nA82oEM09584aILqYmj8Pj7h/kmZNzuEL7WiwFa/U1hX+XiWfL # IJQsAHBla0i7QRF2de8/VSF0XXFa2kBQ6aiTsiLyKPNbaNtbcucaUdn6vVUS5izW # OXM95BSkFSKdE45Oq3FForNJXjBvSCpwcP36WklaHL+aHu1upIhCTUkzTHMh8b86 # WmjRUqbrnvdyR2ydI5l1OqcMBjkpPpIV6wcc+KY/RH2xvVuuoHjlUjwq2bHiNoX+ # W1scCpnA8YTs2d50jDHUgwUo+ciwpffH0Riq132NFmrH3r67VaN3TuBxjI8SIZM5 # 8WEDkbeoriDk3hxU8ZWV7b8AW6oyVBGfM06UgkfMb58h+tJPrFx8VI/WLq1dTqMf # ZOm5cuclMnUHs2uqrRNtnV8UfidPBL4ZHkTcClQbCoz0UbLhkiDvIS00Dn+BBcxw # /TKqVL4Oaz3bkMSsM46LciTeucHY9ExRVt3zy7i149sd+F4QozPqn7FrSVHXmem3 # r7bjyHTxOgqxRCVa18Vtx7P/8bYSBeS+WHCKcliFCecspusCDSlnRUjZwyPdP0VH # xaZg2unjHY3rMYIasDCCGqwCAQEwfTBpMQswCQYDVQQGEwJVUzEXMBUGA1UEChMO # RGlnaUNlcnQsIEluYy4xQTA/BgNVBAMTOERpZ2lDZXJ0IFRydXN0ZWQgRzQgQ29k # ZSBTaWduaW5nIFJTQTQwOTYgU0hBMzg0IDIwMjEgQ0ExAhAHHxQbizANJfMU6yMM # 0NHdMA0GCWCGSAFlAwQCAQUAoIHEMBkGCSqGSIb3DQEJAzEMBgorBgEEAYI3AgEE # MBwGCisGAQQBgjcCAQsxDjAMBgorBgEEAYI3AgEVMC8GCSqGSIb3DQEJBDEiBCBn # AZ6P7YvTwq0fbF62o7E75R0LxsW5OtyYiFESQckLhjBYBgorBgEEAYI3AgEMMUow # SKBGgEQAQgB1AGkAbAB0ADoAIABSAGUAbABlAGEAcwBlAF8AdgAzAC4AMQAxAC4A # MQBfADIAMAAyADIAMQAyADAANgAuADAAMTANBgkqhkiG9w0BAQEFAASCAgCUdOps # v3eE2jWZC7R7IKjKvAhB1gqrrqyEOYU6Cy/U9zWWGw8t+HD9dJSqPiUm0mPoRYp8 # 7DNFKsAGUczwXyI144D50rnrn8qma2mhxw7FmrOcwu+Yw3VYoke9OHy/oiyRKd7s # NifbuVOepKGHgz/36TTstpclCCd4CsT/nDp1DIZbDYLcJXeRm1dfTM64GRO8JVF5 # IpYVLoDzzTmj3Jyh+9172T9l/1jymYmanKmXfjnbOTgtpyPZU1RXFYGi/LIl8KXK # SgPjbN+cWjcTxEOagcKdaDGF6NL+zV0a7cCBkarnTpt9GP5nRXVMFLsphn+9e9R0 # Rj7z62LPu1U2s9lwCAVFtnECE/5rLu8yGIKKAHNbyb6iX/4EJKeoUc47oXHgJmvB # 5Ch6oSjTKjSU/bOFDTEO0qIeR7wn7oONu3rjM+2ftVw4hsI1a2+Q0CPP+jMxTAV+ # Iw1UzNFwbNf6lELnoK0zVSYwcd4pTi1F7/ZRfuo4u+hExkMEY3kz4+7RbeZIuJnJ # x6WfiyPLOmIqXSm+y9qkBm+TLRVBW4/6ccIeGpSPvsse27YioQ5eZleXJnG4KfpR # LRRvsq6rhR3a07P0/ZT8H3sP0TY1xOB7KdzTOENXrcAz77t0qYvJhABeKdUAzOyQ # G3WD2r9CJvyuL8CLYp/xdIqW1yPEOogYW2YE5KGCFz0wghc5BgorBgEEAYI3AwMB # MYIXKTCCFyUGCSqGSIb3DQEHAqCCFxYwghcSAgEDMQ8wDQYJYIZIAWUDBAIBBQAw # dwYLKoZIhvcNAQkQAQSgaARmMGQCAQEGCWCGSAGG/WwHATAxMA0GCWCGSAFlAwQC # AQUABCDl0KR5xtUwOHsKmWo2svZfpRLlEzNgxZDMnLShuhGYmAIQbnZ9CIcvuYaF # E9nJOOmu7hgPMjAyMjEyMDYyMDA2MjdaoIITBzCCBsAwggSooAMCAQICEAxNaXJL # lPo8Kko9KQeAPVowDQYJKoZIhvcNAQELBQAwYzELMAkGA1UEBhMCVVMxFzAVBgNV # BAoTDkRpZ2lDZXJ0LCBJbmMuMTswOQYDVQQDEzJEaWdpQ2VydCBUcnVzdGVkIEc0 # IFJTQTQwOTYgU0hBMjU2IFRpbWVTdGFtcGluZyBDQTAeFw0yMjA5MjEwMDAwMDBa # Fw0zMzExMjEyMzU5NTlaMEYxCzAJBgNVBAYTAlVTMREwDwYDVQQKEwhEaWdpQ2Vy # dDEkMCIGA1UEAxMbRGlnaUNlcnQgVGltZXN0YW1wIDIwMjIgLSAyMIICIjANBgkq # hkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAz+ylJjrGqfJru43BDZrboegUhXQzGias # 0BxVHh42bbySVQxh9J0Jdz0Vlggva2Sk/QaDFteRkjgcMQKW+3KxlzpVrzPsYYrp # pijbkGNcvYlT4DotjIdCriak5Lt4eLl6FuFWxsC6ZFO7KhbnUEi7iGkMiMbxvuAv # fTuxylONQIMe58tySSgeTIAehVbnhe3yYbyqOgd99qtu5Wbd4lz1L+2N1E2VhGjj # gMtqedHSEJFGKes+JvK0jM1MuWbIu6pQOA3ljJRdGVq/9XtAbm8WqJqclUeGhXk+ # DF5mjBoKJL6cqtKctvdPbnjEKD+jHA9QBje6CNk1prUe2nhYHTno+EyREJZ+TeHd # wq2lfvgtGx/sK0YYoxn2Off1wU9xLokDEaJLu5i/+k/kezbvBkTkVf826uV8Mefz # wlLE5hZ7Wn6lJXPbwGqZIS1j5Vn1TS+QHye30qsU5Thmh1EIa/tTQznQZPpWz+D0 # CuYUbWR4u5j9lMNzIfMvwi4g14Gs0/EH1OG92V1LbjGUKYvmQaRllMBY5eUuKZCm # t2Fk+tkgbBhRYLqmgQ8JJVPxvzvpqwcOagc5YhnJ1oV/E9mNec9ixezhe7nMZxMH # msF47caIyLBuMnnHC1mDjcbu9Sx8e47LZInxscS451NeX1XSfRkpWQNO+l3qRXMc # hH7XzuLUOncCAwEAAaOCAYswggGHMA4GA1UdDwEB/wQEAwIHgDAMBgNVHRMBAf8E # AjAAMBYGA1UdJQEB/wQMMAoGCCsGAQUFBwMIMCAGA1UdIAQZMBcwCAYGZ4EMAQQC # MAsGCWCGSAGG/WwHATAfBgNVHSMEGDAWgBS6FtltTYUvcyl2mi91jGogj57IbzAd # BgNVHQ4EFgQUYore0GH8jzEU7ZcLzT0qlBTfUpwwWgYDVR0fBFMwUTBPoE2gS4ZJ # aHR0cDovL2NybDMuZGlnaWNlcnQuY29tL0RpZ2lDZXJ0VHJ1c3RlZEc0UlNBNDA5 # NlNIQTI1NlRpbWVTdGFtcGluZ0NBLmNybDCBkAYIKwYBBQUHAQEEgYMwgYAwJAYI # KwYBBQUHMAGGGGh0dHA6Ly9vY3NwLmRpZ2ljZXJ0LmNvbTBYBggrBgEFBQcwAoZM # aHR0cDovL2NhY2VydHMuZGlnaWNlcnQuY29tL0RpZ2lDZXJ0VHJ1c3RlZEc0UlNB # NDA5NlNIQTI1NlRpbWVTdGFtcGluZ0NBLmNydDANBgkqhkiG9w0BAQsFAAOCAgEA # VaoqGvNG83hXNzD8deNP1oUj8fz5lTmbJeb3coqYw3fUZPwV+zbCSVEseIhjVQlG # OQD8adTKmyn7oz/AyQCbEx2wmIncePLNfIXNU52vYuJhZqMUKkWHSphCK1D8G7We # CDAJ+uQt1wmJefkJ5ojOfRu4aqKbwVNgCeijuJ3XrR8cuOyYQfD2DoD75P/fnRCn # 6wC6X0qPGjpStOq/CUkVNTZZmg9U0rIbf35eCa12VIp0bcrSBWcrduv/mLImlTgZ # iEQU5QpZomvnIj5EIdI/HMCb7XxIstiSDJFPPGaUr10CU+ue4p7k0x+GAWScAMLp # WnR1DT3heYi/HAGXyRkjgNc2Wl+WFrFjDMZGQDvOXTXUWT5Dmhiuw8nLw/ubE19q # tcfg8wXDWd8nYiveQclTuf80EGf2JjKYe/5cQpSBlIKdrAqLxksVStOYkEVgM4Dg # I974A6T2RUflzrgDQkfoQTZxd639ouiXdE4u2h4djFrIHprVwvDGIqhPm73YHJpR # xC+a9l+nJ5e6li6FV8Bg53hWf2rvwpWaSxECyIKcyRoFfLpxtU56mWz06J7UWpjI # n7+NuxhcQ/XQKujiYu54BNu90ftbCqhwfvCXhHjjCANdRyxjqCU4lwHSPzra5eX2 # 5pvcfizM/xdMTQCi2NYBDriL7ubgclWJLCcZYfZ3AYwwggauMIIElqADAgECAhAH # Nje3JFR82Ees/ShmKl5bMA0GCSqGSIb3DQEBCwUAMGIxCzAJBgNVBAYTAlVTMRUw # EwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5jb20x # ITAfBgNVBAMTGERpZ2lDZXJ0IFRydXN0ZWQgUm9vdCBHNDAeFw0yMjAzMjMwMDAw # MDBaFw0zNzAzMjIyMzU5NTlaMGMxCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5EaWdp # Q2VydCwgSW5jLjE7MDkGA1UEAxMyRGlnaUNlcnQgVHJ1c3RlZCBHNCBSU0E0MDk2 # IFNIQTI1NiBUaW1lU3RhbXBpbmcgQ0EwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAw # ggIKAoICAQDGhjUGSbPBPXJJUVXHJQPE8pE3qZdRodbSg9GeTKJtoLDMg/la9hGh # RBVCX6SI82j6ffOciQt/nR+eDzMfUBMLJnOWbfhXqAJ9/UO0hNoR8XOxs+4rgISK # Ihjf69o9xBd/qxkrPkLcZ47qUT3w1lbU5ygt69OxtXXnHwZljZQp09nsad/ZkIdG # AHvbREGJ3HxqV3rwN3mfXazL6IRktFLydkf3YYMZ3V+0VAshaG43IbtArF+y3kp9 # zvU5EmfvDqVjbOSmxR3NNg1c1eYbqMFkdECnwHLFuk4fsbVYTXn+149zk6wsOeKl # SNbwsDETqVcplicu9Yemj052FVUmcJgmf6AaRyBD40NjgHt1biclkJg6OBGz9vae # 5jtb7IHeIhTZgirHkr+g3uM+onP65x9abJTyUpURK1h0QCirc0PO30qhHGs4xSnz # yqqWc0Jon7ZGs506o9UD4L/wojzKQtwYSH8UNM/STKvvmz3+DrhkKvp1KCRB7UK/ # BZxmSVJQ9FHzNklNiyDSLFc1eSuo80VgvCONWPfcYd6T/jnA+bIwpUzX6ZhKWD7T # A4j+s4/TXkt2ElGTyYwMO1uKIqjBJgj5FBASA31fI7tk42PgpuE+9sJ0sj8eCXbs # q11GdeJgo1gJASgADoRU7s7pXcheMBK9Rp6103a50g5rmQzSM7TNsQIDAQABo4IB # XTCCAVkwEgYDVR0TAQH/BAgwBgEB/wIBADAdBgNVHQ4EFgQUuhbZbU2FL3Mpdpov # dYxqII+eyG8wHwYDVR0jBBgwFoAU7NfjgtJxXWRM3y5nP+e6mK4cD08wDgYDVR0P # AQH/BAQDAgGGMBMGA1UdJQQMMAoGCCsGAQUFBwMIMHcGCCsGAQUFBwEBBGswaTAk # BggrBgEFBQcwAYYYaHR0cDovL29jc3AuZGlnaWNlcnQuY29tMEEGCCsGAQUFBzAC # hjVodHRwOi8vY2FjZXJ0cy5kaWdpY2VydC5jb20vRGlnaUNlcnRUcnVzdGVkUm9v # dEc0LmNydDBDBgNVHR8EPDA6MDigNqA0hjJodHRwOi8vY3JsMy5kaWdpY2VydC5j # b20vRGlnaUNlcnRUcnVzdGVkUm9vdEc0LmNybDAgBgNVHSAEGTAXMAgGBmeBDAEE # AjALBglghkgBhv1sBwEwDQYJKoZIhvcNAQELBQADggIBAH1ZjsCTtm+YqUQiAX5m # 1tghQuGwGC4QTRPPMFPOvxj7x1Bd4ksp+3CKDaopafxpwc8dB+k+YMjYC+VcW9dt # h/qEICU0MWfNthKWb8RQTGIdDAiCqBa9qVbPFXONASIlzpVpP0d3+3J0FNf/q0+K # LHqrhc1DX+1gtqpPkWaeLJ7giqzl/Yy8ZCaHbJK9nXzQcAp876i8dU+6WvepELJd # 6f8oVInw1YpxdmXazPByoyP6wCeCRK6ZJxurJB4mwbfeKuv2nrF5mYGjVoarCkXJ # 38SNoOeY+/umnXKvxMfBwWpx2cYTgAnEtp/Nh4cku0+jSbl3ZpHxcpzpSwJSpzd+ # k1OsOx0ISQ+UzTl63f8lY5knLD0/a6fxZsNBzU+2QJshIUDQtxMkzdwdeDrknq3l # NHGS1yZr5Dhzq6YBT70/O3itTK37xJV77QpfMzmHQXh6OOmc4d0j/R0o08f56PGY # X/sr2H7yRp11LB4nLCbbbxV7HhmLNriT1ObyF5lZynDwN7+YAN8gFk8n+2BnFqFm # ut1VwDophrCYoCvtlUG3OtUVmDG0YgkPCr2B2RP+v6TR81fZvAT6gt4y3wSJ8ADN # XcL50CN/AAvkdgIm2fBldkKmKYcJRyvmfxqkhQ/8mJb2VVQrH4D6wPIOK+XW+6kv # RBVK5xMOHds3OBqhK/bt1nz8MIIFjTCCBHWgAwIBAgIQDpsYjvnQLefv21DiCEAY # WjANBgkqhkiG9w0BAQwFADBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNl # cnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdp # Q2VydCBBc3N1cmVkIElEIFJvb3QgQ0EwHhcNMjIwODAxMDAwMDAwWhcNMzExMTA5 # MjM1OTU5WjBiMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkw # FwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSEwHwYDVQQDExhEaWdpQ2VydCBUcnVz # dGVkIFJvb3QgRzQwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC/5pBz # aN675F1KPDAiMGkz7MKnJS7JIT3yithZwuEppz1Yq3aaza57G4QNxDAf8xukOBbr # VsaXbR2rsnnyyhHS5F/WBTxSD1Ifxp4VpX6+n6lXFllVcq9ok3DCsrp1mWpzMpTR # EEQQLt+C8weE5nQ7bXHiLQwb7iDVySAdYyktzuxeTsiT+CFhmzTrBcZe7FsavOvJ # z82sNEBfsXpm7nfISKhmV1efVFiODCu3T6cw2Vbuyntd463JT17lNecxy9qTXtyO # j4DatpGYQJB5w3jHtrHEtWoYOAMQjdjUN6QuBX2I9YI+EJFwq1WCQTLX2wRzKm6R # AXwhTNS8rhsDdV14Ztk6MUSaM0C/CNdaSaTC5qmgZ92kJ7yhTzm1EVgX9yRcRo9k # 98FpiHaYdj1ZXUJ2h4mXaXpI8OCiEhtmmnTK3kse5w5jrubU75KSOp493ADkRSWJ # tppEGSt+wJS00mFt6zPZxd9LBADMfRyVw4/3IbKyEbe7f/LVjHAsQWCqsWMYRJUa # dmJ+9oCw++hkpjPRiQfhvbfmQ6QYuKZ3AeEPlAwhHbJUKSWJbOUOUlFHdL4mrLZB # dd56rF+NP8m800ERElvlEFDrMcXKchYiCd98THU/Y+whX8QgUWtvsauGi0/C1kVf # nSD8oR7FwI+isX4KJpn15GkvmB0t9dmpsh3lGwIDAQABo4IBOjCCATYwDwYDVR0T # AQH/BAUwAwEB/zAdBgNVHQ4EFgQU7NfjgtJxXWRM3y5nP+e6mK4cD08wHwYDVR0j # BBgwFoAUReuir/SSy4IxLVGLp6chnfNtyA8wDgYDVR0PAQH/BAQDAgGGMHkGCCsG # AQUFBwEBBG0wazAkBggrBgEFBQcwAYYYaHR0cDovL29jc3AuZGlnaWNlcnQuY29t # MEMGCCsGAQUFBzAChjdodHRwOi8vY2FjZXJ0cy5kaWdpY2VydC5jb20vRGlnaUNl # cnRBc3N1cmVkSURSb290Q0EuY3J0MEUGA1UdHwQ+MDwwOqA4oDaGNGh0dHA6Ly9j # cmwzLmRpZ2ljZXJ0LmNvbS9EaWdpQ2VydEFzc3VyZWRJRFJvb3RDQS5jcmwwEQYD # VR0gBAowCDAGBgRVHSAAMA0GCSqGSIb3DQEBDAUAA4IBAQBwoL9DXFXnOF+go3Qb # PbYW1/e/Vwe9mqyhhyzshV6pGrsi+IcaaVQi7aSId229GhT0E0p6Ly23OO/0/4C5 # +KH38nLeJLxSA8hO0Cre+i1Wz/n096wwepqLsl7Uz9FDRJtDIeuWcqFItJnLnU+n # BgMTdydE1Od/6Fmo8L8vC6bp8jQ87PcDx4eo0kxAGTVGamlUsLihVo7spNU96LHc # /RzY9HdaXFSMb++hUD38dglohJ9vytsgjTVgHAIDyyCwrFigDkBjxZgiwbJZ9VVr # zyerbHbObyMt9H5xaiNrIv8SuFQtJ37YOtnwtoeW/VvRXKwYw02fc7cBqZ9Xql4o # 4rmUMYIDdjCCA3ICAQEwdzBjMQswCQYDVQQGEwJVUzEXMBUGA1UEChMORGlnaUNl # cnQsIEluYy4xOzA5BgNVBAMTMkRpZ2lDZXJ0IFRydXN0ZWQgRzQgUlNBNDA5NiBT # SEEyNTYgVGltZVN0YW1waW5nIENBAhAMTWlyS5T6PCpKPSkHgD1aMA0GCWCGSAFl # AwQCAQUAoIHRMBoGCSqGSIb3DQEJAzENBgsqhkiG9w0BCRABBDAcBgkqhkiG9w0B # CQUxDxcNMjIxMjA2MjAwNjI3WjArBgsqhkiG9w0BCRACDDEcMBowGDAWBBTzhyJN # hjOCkjWplLy9j5bp/hx8czAvBgkqhkiG9w0BCQQxIgQgjZC+rPrPBAlmFuP+OmvD # yh8xqQf/ReQsUWtJ8pZa3hUwNwYLKoZIhvcNAQkQAi8xKDAmMCQwIgQgx/ThvjIo # iSCr4iY6vhrE/E/meBwtZNBMgHVXoCO1tvowDQYJKoZIhvcNAQEBBQAEggIAAgln # xfP1/ZMQMCTCCrVb3qm7DI8RVNeUM4QEZuxpKvqe9reisD1nem6Z1zKW+5oP7NxF # /0u8JCTKwkpMZv8m/qcp7TQ3vwHbRqRpNNw/CFd/H0OrLnD14r3jhnNoS/XU0jZi # U/f9vNl/4qStFMu30yKuxlsycj/At2/ohTZBSWPdv9e+XL3mLZ8HMmwRR5o9Kldg # p/ErSHOYSqaQLx5/eBF59qtIKsw1WAQITvCW7zTII/gEuCz+myl+7aBAaPrW0mUa # FVrWQL/Ug3PcwNB7ZK+py7q9eXmQShskSaWXYnl8qCJj4Yex6/D3BMZnDIGXamia # sH41UoqaeJaqcPvErMyvnCC928552hFjpmEz3PFyVdS04KfjE71CmzDiSNy/jWMM # W748v6ZnqIGUkYev8D0D4aiZBoYzi4uHuVS7NPCbTakIIbxXeT9Jw1L4xVe6tN+l # ucDC5UVeuZ8dB2OU+oX0sjTvFRG8V1O2OBBLyNKHtCkFXgpkgFH1Ff/c/XCFgLFV # ymSCD/LY0EBtJvNUe7EBGM7TWwSVfDNEqz2rAvMERz6F4GRq6MJ5aVfPZ6mx/7qj # Qs3ScAftPwKYlGJWYmewG+AvHjaHB4Yv1q/19tMjTIiQ4YLk0GaHd6BanFmwpe0f # Abhwpg6wH7UGifzI6/6kgrdXF80c98cDuAxVg2w= # SIG # End signature block
castiel248/Convert
Scripts/Activate.ps1
PowerShell
mit
23,695
# This file must be used with "source bin/activate" *from bash* # you cannot run it directly deactivate () { # reset old environment variables if [ -n "${_OLD_VIRTUAL_PATH:-}" ] ; then PATH="${_OLD_VIRTUAL_PATH:-}" export PATH unset _OLD_VIRTUAL_PATH fi if [ -n "${_OLD_VIRTUAL_PYTHONHOME:-}" ] ; then PYTHONHOME="${_OLD_VIRTUAL_PYTHONHOME:-}" export PYTHONHOME unset _OLD_VIRTUAL_PYTHONHOME fi # This should detect bash and zsh, which have a hash command that must # be called to get it to forget past commands. Without forgetting # past commands the $PATH changes we made may not be respected if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then hash -r 2> /dev/null fi if [ -n "${_OLD_VIRTUAL_PS1:-}" ] ; then PS1="${_OLD_VIRTUAL_PS1:-}" export PS1 unset _OLD_VIRTUAL_PS1 fi unset VIRTUAL_ENV unset VIRTUAL_ENV_PROMPT if [ ! "${1:-}" = "nondestructive" ] ; then # Self destruct! unset -f deactivate fi } # unset irrelevant variables deactivate nondestructive VIRTUAL_ENV="C:\Users\Castiel\Desktop\Zajęcia Python\zaliczenie\Converter" export VIRTUAL_ENV _OLD_VIRTUAL_PATH="$PATH" PATH="$VIRTUAL_ENV/Scripts:$PATH" export PATH # unset PYTHONHOME if set # this will fail if PYTHONHOME is set to the empty string (which is bad anyway) # could use `if (set -u; : $PYTHONHOME) ;` in bash if [ -n "${PYTHONHOME:-}" ] ; then _OLD_VIRTUAL_PYTHONHOME="${PYTHONHOME:-}" unset PYTHONHOME fi if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT:-}" ] ; then _OLD_VIRTUAL_PS1="${PS1:-}" PS1="(Converter) ${PS1:-}" export PS1 VIRTUAL_ENV_PROMPT="(Converter) " export VIRTUAL_ENV_PROMPT fi # This should detect bash and zsh, which have a hash command that must # be called to get it to forget past commands. Without forgetting # past commands the $PATH changes we made may not be respected if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then hash -r 2> /dev/null fi
castiel248/Convert
Scripts/activate
none
mit
2,042
@echo off rem This file is UTF-8 encoded, so we need to update the current code page while executing it for /f "tokens=2 delims=:." %%a in ('"%SystemRoot%\System32\chcp.com"') do ( set _OLD_CODEPAGE=%%a ) if defined _OLD_CODEPAGE ( "%SystemRoot%\System32\chcp.com" 65001 > nul ) set VIRTUAL_ENV=C:\Users\Castiel\Desktop\Zajęcia Python\zaliczenie\Converter if not defined PROMPT set PROMPT=$P$G if defined _OLD_VIRTUAL_PROMPT set PROMPT=%_OLD_VIRTUAL_PROMPT% if defined _OLD_VIRTUAL_PYTHONHOME set PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME% set _OLD_VIRTUAL_PROMPT=%PROMPT% set PROMPT=(Converter) %PROMPT% if defined PYTHONHOME set _OLD_VIRTUAL_PYTHONHOME=%PYTHONHOME% set PYTHONHOME= if defined _OLD_VIRTUAL_PATH set PATH=%_OLD_VIRTUAL_PATH% if not defined _OLD_VIRTUAL_PATH set _OLD_VIRTUAL_PATH=%PATH% set PATH=%VIRTUAL_ENV%\Scripts;%PATH% set VIRTUAL_ENV_PROMPT=(Converter) :END if defined _OLD_CODEPAGE ( "%SystemRoot%\System32\chcp.com" %_OLD_CODEPAGE% > nul set _OLD_CODEPAGE= )
castiel248/Convert
Scripts/activate.bat
Batchfile
mit
1,006
@echo off if defined _OLD_VIRTUAL_PROMPT ( set "PROMPT=%_OLD_VIRTUAL_PROMPT%" ) set _OLD_VIRTUAL_PROMPT= if defined _OLD_VIRTUAL_PYTHONHOME ( set "PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%" set _OLD_VIRTUAL_PYTHONHOME= ) if defined _OLD_VIRTUAL_PATH ( set "PATH=%_OLD_VIRTUAL_PATH%" ) set _OLD_VIRTUAL_PATH= set VIRTUAL_ENV= set VIRTUAL_ENV_PROMPT= :END
castiel248/Convert
Scripts/deactivate.bat
Batchfile
mit
371
castiel248/Convert
length_converter/app_conv/__init__.py
Python
mit
0
from django.contrib import admin # Register your models here.
castiel248/Convert
length_converter/app_conv/admin.py
Python
mit
63
from django.apps import AppConfig class AppConvConfig(AppConfig): default_auto_field = 'django.db.models.BigAutoField' name = 'app_conv'
castiel248/Convert
length_converter/app_conv/apps.py
Python
mit
147
castiel248/Convert
length_converter/app_conv/migrations/__init__.py
Python
mit
0
from django.db import models from django import forms class Form(models.Model): def __init__(self, wartosc, miara): self.wartosc = wartosc self.miara = miara
castiel248/Convert
length_converter/app_conv/models.py
Python
mit
169
<html> <head> <title>Length Converter</title> <meta charset="utf-8"> <style> body { background-color: mintcream; } #logo{ background-color: lightseagreen; margin: 20; padding: 20; box-sizing: border-box; } h1{ font-family: "Times New Roman", Times, serif; text-align: center; text-decoration-line: underline; font-size: 50px; } table, th, td { border: 1px solid black; } tr:hover{ background-color: #D6EEEE; } </style> </head> <body> <div id="logo"><h1>Length Converter<h1></div> <div id="centre"> <h2>Kalkulator jednostek długości</h2> <a href=" "><button>Wróc</button></a><br> <p> {{ num }} {{ jedn }} w przeliczeniu na :</p> <table> <tr> <th>Nazwa</th> <th>Symbol</th> <th>Wynik</th> <tr> <tr> <td>Metr</td> <td>m</td> <td> {{ m }}</td> </tr> <tr> <td>Kilometr</td> <td>km</td> <td>{{ km }} </td> </tr> <tr> <td>Decymetr</td> <td>dm</td> <td> {{ dm }}</td> </tr> <tr> <td>Centymetr</td> <td>cm</td> <td>{{ cm }} </td> </tr> <tr> <td>Milimetr</td> <td>mm</td> <td>{{ mm }} </td> </tr> <tr> <td>Mila</td> <td>mi</td> <td>{{ mi }} </td> </tr> </div> </body> </html>
castiel248/Convert
length_converter/app_conv/templates/convert.html
HTML
mit
1,264
<html> <head> <title>Length Converter</title> <meta charset="utf-8"> <style> body { background-color: mintcream; } #logo{ background-color: lightseagreen; margin: 20; padding: 20; box-sizing: border-box; } h1{ font-family: "Times New Roman", Times, serif; text-align: center; text-decoration-line: underline; font-size: 50px; } </style> </head> <body> <div id="logo"><h1>Length Converter<h1></div> <div id="centre"> <h2>Kalkulator jednostek długości</h2> <form action='/convert', method='post'> {% csrf_token %} <p>Wpisz wartość i jednostkę długości:</p> <input type="number" name="number"><br><br> <select name="jednostka"> <option>metr</option> <option>kilometr</option> <option>decymetr</option> <option>centymetr </option> <option>milimetr </option> <option>mila </option> </select><br><br> {{ form.as_p }} <input type="submit"> </form> </div> <body> </html>
castiel248/Convert
length_converter/app_conv/templates/index.html
HTML
mit
1,019
from django.test import TestCase # Create your tests here.
castiel248/Convert
length_converter/app_conv/tests.py
Python
mit
60
from django.urls import path from django.contrib import admin from . import views urlpatterns = [ path('', views.index, name='index'), path('convert', views.convert, name='convert'), ]
castiel248/Convert
length_converter/app_conv/urls.py
Python
mit
196