Skip to content

Commit

Permalink
Import underlying parser function as an underscored variable
Browse files Browse the repository at this point in the history
This function is not a part of the public interface for this module.
  • Loading branch information
pradyunsg committed Jan 14, 2023
1 parent 63e6571 commit 997640d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/packaging/requirements.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import urllib.parse
from typing import Any, List, Optional, Set

from ._parser import parse_requirement
from ._parser import parse_requirement as _parse_requirement
from ._tokenizer import ParserSyntaxError
from .markers import Marker, _normalize_extra_values
from .specifiers import SpecifierSet
Expand All @@ -32,7 +32,7 @@ class Requirement:

def __init__(self, requirement_string: str) -> None:
try:
parsed = parse_requirement(requirement_string)
parsed = _parse_requirement(requirement_string)
except ParserSyntaxError as e:
raise InvalidRequirement(str(e)) from e

Expand Down

0 comments on commit 997640d

Please sign in to comment.