mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Merge pull request #2894 from markparonyan/mypy-utils-zipfile-zstd
fix(typing): resolve mypy errors in utils.zipfile_zstd
This commit is contained in:
3 files changed
+9
-6
No files matched your search
@@ -2,7 +2,7 @@
|
||||
from . import _zipfile
|
||||
|
||||
from zipfile import *
|
||||
from zipfile import (
|
||||
from ._zipfile import (
|
||||
ZIP_ZSTANDARD,
|
||||
ZSTANDARD_VERSION,
|
||||
)
|
||||
@@ -1,13 +1,18 @@
|
||||
import zipfile
|
||||
import zipfile as _zipfile_module
|
||||
import zstandard as zstd
|
||||
import inspect
|
||||
from typing import Any
|
||||
|
||||
from ._patcher import patch
|
||||
|
||||
zipfile: Any = _zipfile_module
|
||||
|
||||
zipfile.ZIP_ZSTANDARD = 93
|
||||
ZIP_ZSTANDARD = 93
|
||||
ZSTANDARD_VERSION = 20
|
||||
|
||||
zipfile.ZIP_ZSTANDARD = ZIP_ZSTANDARD
|
||||
zipfile.compressor_names[zipfile.ZIP_ZSTANDARD] = "zstandard"
|
||||
zipfile.ZSTANDARD_VERSION = 20
|
||||
zipfile.ZSTANDARD_VERSION = ZSTANDARD_VERSION
|
||||
|
||||
|
||||
@patch(zipfile, "_check_compression")
|
||||
|
||||
Reference in new issue
Block a user