mirror of
https://github.com/python/cpython.git
synced 2025-07-07 19:35:27 +00:00
gh-114713: Revert gh-114731 (#133330)
Revert "gh-114713: Handle case of an empty string passed to `zoneinfo.ZoneInfo` (#114731)"
This reverts commit 884df116d7
.
This commit is contained in:
parent
ca0a96dfaa
commit
fe44fc4f43
3 changed files with 0 additions and 7 deletions
|
@ -237,7 +237,6 @@ class ZoneInfoTest(TzPathUserMixin, ZoneInfoTestBase):
|
|||
"../zoneinfo/America/Los_Angeles", # Traverses above TZPATH
|
||||
"America/../America/Los_Angeles", # Not normalized
|
||||
"America/./Los_Angeles",
|
||||
"",
|
||||
]
|
||||
|
||||
for bad_key in bad_keys:
|
||||
|
|
|
@ -83,11 +83,6 @@ _TEST_PATH = os.path.normpath(os.path.join("_", "_"))[:-1]
|
|||
|
||||
|
||||
def _validate_tzfile_path(path, _base=_TEST_PATH):
|
||||
if not path:
|
||||
raise ValueError(
|
||||
"ZoneInfo key must not be an empty string"
|
||||
)
|
||||
|
||||
if os.path.isabs(path):
|
||||
raise ValueError(
|
||||
f"ZoneInfo keys may not be absolute paths, got: {path}"
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
Handle case of an empty string passed to :class:`zoneinfo.ZoneInfo`.
|
Loading…
Add table
Add a link
Reference in a new issue