$84 GRAYBYTE WORDPRESS FILE MANAGER $61

SERVER : vnpttt-amd7f72-h1.vietnix.vn #1 SMP Fri May 24 12:42:50 UTC 2024
SERVER IP : 103.200.23.149 | ADMIN IP 216.73.216.22
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/opt/cloudlinux/venv/lib/python3.11/site-packages/tap/

HOME
Current File : /opt/cloudlinux/venv/lib/python3.11/site-packages/tap//directive.py
import re


class Directive:
    """A representation of a result line directive."""

    skip_pattern = re.compile(
        r"""^SKIP\S*
            (?P<whitespace>\s*) # Optional whitespace.
            (?P<reason>.*)      # Slurp up the rest.""",
        re.IGNORECASE | re.VERBOSE,
    )
    todo_pattern = re.compile(
        r"""^TODO\b             # The directive name
            (?P<whitespace>\s*) # Immediately following must be whitespace.
            (?P<reason>.*)      # Slurp up the rest.""",
        re.IGNORECASE | re.VERBOSE,
    )

    def __init__(self, text):
        r"""Initialize the directive by parsing the text.

        The text is assumed to be everything after a '#\s*' on a result line.
        """
        self._text = text
        self._skip = False
        self._todo = False
        self._reason = None

        match = self.skip_pattern.match(text)
        if match:
            self._skip = True
            self._reason = match.group("reason")

        match = self.todo_pattern.match(text)
        if match:
            if match.group("whitespace"):
                self._todo = True
            else:
                # Catch the case where the directive has no descriptive text.
                if match.group("reason") == "":
                    self._todo = True
            self._reason = match.group("reason")

    @property
    def text(self):
        """Get the entire text."""
        return self._text

    @property
    def skip(self):
        """Check if the directive is a SKIP type."""
        return self._skip

    @property
    def todo(self):
        """Check if the directive is a TODO type."""
        return self._todo

    @property
    def reason(self):
        """Get the reason for the directive."""
        return self._reason

Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
17 Dec 2025 3.08 AM
root / root
0755
__pycache__
--
14 Aug 2025 9.24 PM
root / root
0755
tests
--
14 Aug 2025 9.30 PM
root / root
0755
__init__.py
0.083 KB
17 Apr 2025 8.10 PM
root / root
0644
__main__.py
0.047 KB
17 Apr 2025 8.10 PM
root / root
0644
adapter.py
1.474 KB
17 Apr 2025 8.10 PM
root / root
0644
directive.py
1.749 KB
17 Apr 2025 8.10 PM
root / root
0644
formatter.py
0.744 KB
17 Apr 2025 8.10 PM
root / root
0644
line.py
4.563 KB
17 Apr 2025 8.10 PM
root / root
0644
loader.py
2.874 KB
17 Apr 2025 8.10 PM
root / root
0644
main.py
2.074 KB
17 Apr 2025 8.10 PM
root / root
0644
parser.py
6.628 KB
17 Apr 2025 8.10 PM
root / root
0644
rules.py
3.299 KB
17 Apr 2025 8.10 PM
root / root
0644
runner.py
4.947 KB
17 Apr 2025 8.10 PM
root / root
0644
tracker.py
7.398 KB
17 Apr 2025 8.10 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME
Static GIF