help@rskworld.in +91 93305 39277
RSK World
  • Home
  • Development
    • Web Development
    • Mobile Apps
    • Software
    • Games
    • Project
  • Technologies
    • Data Science
    • AI Development
    • Cloud Development
    • Blockchain
    • Cyber Security
    • Dev Tools
    • Testing Tools
  • Blog
  • About
  • Contact

Theme Settings

Color Scheme
Display Options
Font Size
100%
Back to Project
RSK World
travel-assistant-bot
/
.venv
/
Lib
/
site-packages
/
pip
/
_vendor
/
rich
/
__pycache__
RSK World
travel-assistant-bot
Travel Assistant Bot - Python + Flask + OpenAI API + Travel Bot + Flight Search + Hotel Booking + Weather
__pycache__
  • __init__.cpython-313.pyc6.7 KB
  • __main__.cpython-313.pyc10 KB
  • _cell_widths.cpython-313.pyc7.7 KB
  • _emoji_codes.cpython-313.pyc201.2 KB
  • _emoji_replace.cpython-313.pyc1.7 KB
  • _export_format.cpython-313.pyc2.3 KB
  • _extension.cpython-313.pyc573 B
  • _fileno.cpython-313.pyc875 B
  • _inspect.cpython-313.pyc12.1 KB
  • _log_render.cpython-313.pyc4.3 KB
  • _loop.cpython-313.pyc1.9 KB
  • _null_file.cpython-313.pyc3.7 KB
  • _palettes.cpython-313.pyc5.1 KB
  • _pick.cpython-313.pyc753 B
  • _ratio.cpython-313.pyc6.5 KB
  • _spinners.cpython-313.pyc12.9 KB
  • _stack.cpython-313.pyc1 KB
  • _timer.cpython-313.pyc902 B
  • _win32_console.cpython-313.pyc27.9 KB
  • _windows.cpython-313.pyc2.5 KB
  • _windows_renderer.cpython-313.pyc3.6 KB
  • _wrap.cpython-313.pyc3.3 KB
  • abc.cpython-313.pyc1.7 KB
  • align.cpython-313.pyc12.2 KB
  • ansi.cpython-313.pyc9.1 KB
  • bar.cpython-313.pyc4.3 KB
  • box.cpython-313.pyc11.6 KB
  • cells.cpython-313.pyc5.6 KB
  • color.cpython-313.pyc26 KB
  • color_triplet.cpython-313.pyc1.7 KB
  • columns.cpython-313.pyc8.5 KB
  • console.cpython-313.pyc110 KB
  • constrain.cpython-313.pyc2.3 KB
  • containers.cpython-313.pyc9.1 KB
  • control.cpython-313.pyc10.7 KB
  • default_styles.cpython-313.pyc9.4 KB
  • diagnose.cpython-313.pyc1.5 KB
  • emoji.cpython-313.pyc4.2 KB
  • errors.cpython-313.pyc2 KB
  • file_proxy.cpython-313.pyc3.7 KB
  • filesize.cpython-313.pyc2.9 KB
  • highlighter.cpython-313.pyc9.8 KB
  • json.cpython-313.pyc5.8 KB
  • jupyter.cpython-313.pyc5.3 KB
  • layout.cpython-313.pyc19.7 KB
  • live.cpython-313.pyc19.2 KB
  • live_render.cpython-313.pyc4.8 KB
  • logging.cpython-313.pyc13.2 KB
  • markup.cpython-313.pyc9.5 KB
  • measure.cpython-313.pyc6.1 KB
  • padding.cpython-313.pyc7 KB
  • pager.cpython-313.pyc1.9 KB
  • palette.cpython-313.pyc5.2 KB
  • panel.cpython-313.pyc11.9 KB
  • pretty.cpython-313.pyc39.9 KB
  • progress.cpython-313.pyc73 KB
  • progress_bar.cpython-313.pyc10.2 KB
  • prompt.cpython-313.pyc14.3 KB
  • protocol.cpython-313.pyc1.9 KB
  • region.cpython-313.pyc659 B
  • repr.cpython-313.pyc6.6 KB
  • rule.cpython-313.pyc6.5 KB
  • scope.cpython-313.pyc3.7 KB
  • screen.cpython-313.pyc2.5 KB
  • segment.cpython-313.pyc27.3 KB
  • spinner.cpython-313.pyc6 KB
  • status.cpython-313.pyc5.9 KB
  • style.cpython-313.pyc33.7 KB
  • styled.cpython-313.pyc2.2 KB
  • syntax.cpython-313.pyc38.7 KB
  • table.cpython-313.pyc43 KB
  • terminal_theme.cpython-313.pyc3.4 KB
  • text.cpython-313.pyc58.5 KB
  • theme.cpython-313.pyc6.2 KB
  • themes.cpython-313.pyc348 B
  • traceback.cpython-313.pyc31.1 KB
  • tree.cpython-313.pyc11.3 KB
command_context.pytarget_python.py
.venv/Lib/site-packages/pip/_internal/cli/command_context.py
Raw Download
Find: Go to:
from contextlib import ExitStack, contextmanager
from typing import ContextManager, Generator, TypeVar

_T = TypeVar("_T", covariant=True)


class CommandContextMixIn:
    def __init__(self) -> None:
        super().__init__()
        self._in_main_context = False
        self._main_context = ExitStack()

    @contextmanager
    def main_context(self) -> Generator[None, None, None]:
        assert not self._in_main_context

        self._in_main_context = True
        try:
            with self._main_context:
                yield
        finally:
            self._in_main_context = False

    def enter_context(self, context_provider: ContextManager[_T]) -> _T:
        assert self._in_main_context

        return self._main_context.enter_context(context_provider)
28 lines•774 B
python
.venv/Lib/site-packages/pip/_internal/models/target_python.py
Raw Download
Find: Go to:
import sys
from typing import List, Optional, Set, Tuple

from pip._vendor.packaging.tags import Tag

from pip._internal.utils.compatibility_tags import get_supported, version_info_to_nodot
from pip._internal.utils.misc import normalize_version_info


class TargetPython:
    """
    Encapsulates the properties of a Python interpreter one is targeting
    for a package install, download, etc.
    """

    __slots__ = [
        "_given_py_version_info",
        "abis",
        "implementation",
        "platforms",
        "py_version",
        "py_version_info",
        "_valid_tags",
        "_valid_tags_set",
    ]

    def __init__(
        self,
        platforms: Optional[List[str]] = None,
        py_version_info: Optional[Tuple[int, ...]] = None,
        abis: Optional[List[str]] = None,
        implementation: Optional[str] = None,
    ) -> None:
        """
        :param platforms: A list of strings or None. If None, searches for
            packages that are supported by the current system. Otherwise, will
            find packages that can be built on the platforms passed in. These
            packages will only be downloaded for distribution: they will
            not be built locally.
        :param py_version_info: An optional tuple of ints representing the
            Python version information to use (e.g. `sys.version_info[:3]`).
            This can have length 1, 2, or 3 when provided.
        :param abis: A list of strings or None. This is passed to
            compatibility_tags.py's get_supported() function as is.
        :param implementation: A string or None. This is passed to
            compatibility_tags.py's get_supported() function as is.
        """
        # Store the given py_version_info for when we call get_supported().
        self._given_py_version_info = py_version_info

        if py_version_info is None:
            py_version_info = sys.version_info[:3]
        else:
            py_version_info = normalize_version_info(py_version_info)

        py_version = ".".join(map(str, py_version_info[:2]))

        self.abis = abis
        self.implementation = implementation
        self.platforms = platforms
        self.py_version = py_version
        self.py_version_info = py_version_info

        # This is used to cache the return value of get_(un)sorted_tags.
        self._valid_tags: Optional[List[Tag]] = None
        self._valid_tags_set: Optional[Set[Tag]] = None

    def format_given(self) -> str:
        """
        Format the given, non-None attributes for display.
        """
        display_version = None
        if self._given_py_version_info is not None:
            display_version = ".".join(
                str(part) for part in self._given_py_version_info
            )

        key_values = [
            ("platforms", self.platforms),
            ("version_info", display_version),
            ("abis", self.abis),
            ("implementation", self.implementation),
        ]
        return " ".join(
            f"{key}={value!r}" for key, value in key_values if value is not None
        )

    def get_sorted_tags(self) -> List[Tag]:
        """
        Return the supported PEP 425 tags to check wheel candidates against.

        The tags are returned in order of preference (most preferred first).
        """
        if self._valid_tags is None:
            # Pass versions=None if no py_version_info was given since
            # versions=None uses special default logic.
            py_version_info = self._given_py_version_info
            if py_version_info is None:
                version = None
            else:
                version = version_info_to_nodot(py_version_info)

            tags = get_supported(
                version=version,
                platforms=self.platforms,
                abis=self.abis,
                impl=self.implementation,
            )
            self._valid_tags = tags

        return self._valid_tags

    def get_unsorted_tags(self) -> Set[Tag]:
        """Exactly the same as get_sorted_tags, but returns a set.

        This is important for performance.
        """
        if self._valid_tags_set is None:
            self._valid_tags_set = set(self.get_sorted_tags())

        return self._valid_tags_set
122 lines•4.2 KB
python
🚀 Support RSK World

Subscribe to our YouTube channel for latest tutorials & updates!



Click subscribe & support our work ❤️

About RSK World

Founded by Molla Samser, with Designer & Tester Rima Khatun, RSK World is your one-stop destination for free programming resources, source code, and development tools.

Founder: Molla Samser
Designer & Tester: Rima Khatun

Development

  • Game Development
  • Web Development
  • Mobile Development
  • AI Development
  • Development Tools

Legal

  • Terms & Conditions
  • Privacy Policy
  • Disclaimer

Contact Info

Nutanhat, Mongolkote
Purba Burdwan, West Bengal
India, 713147

+91 93305 39277

hello@rskworld.in
support@rskworld.in

© 2026 RSK World. All rights reserved.

Content used for educational purposes only. View Disclaimer