# HG changeset patch # User Drew Perttula # Date 2019-06-06 00:06:00 # Node ID 88ca10c9e31a22d5eb7f4f1a0ebffd0cf906a5ef # Parent 947b8267652e353504edc4eba8a0261c695e59a2 hack up stubs to pass mypy. they're very weak right now Ignore-this: f4c854346bc206725a1065079d8d158f diff --git a/stubs/PIL/Image.pyi b/stubs/PIL/Image.pyi --- a/stubs/PIL/Image.pyi +++ b/stubs/PIL/Image.pyi @@ -2,7 +2,6 @@ # # NOTE: This dynamically typed stub was automatically generated by stubgen. -import __builtin__ from typing import Any, Optional logger: Any @@ -13,7 +12,6 @@ class _imaging_not_installed: def __getattr__(self, id: Any) -> None: ... MAX_IMAGE_PIXELS: Any -builtins = __builtin__ USE_CFFI_ACCESS: Any HAS_CFFI: bool diff --git a/stubs/PIL/__init__.pyi b/stubs/PIL/__init__.pyi --- a/stubs/PIL/__init__.pyi +++ b/stubs/PIL/__init__.pyi @@ -1,6 +1,8 @@ # Stubs for PIL (Python 3) # -# NOTE: This dynamically typed stub was automatically generated by stubgen. -VERSION: str -PILLOW_VERSION: str +class Image: + @classmethod + def open(cls) -> Image: ... + @classmethod + def frombytes(cls, mode, size, data): ... diff --git a/stubs/moviepy/__init__.pyi b/stubs/moviepy/__init__.pyi --- a/stubs/moviepy/__init__.pyi +++ b/stubs/moviepy/__init__.pyi @@ -1,5 +1,5 @@ # Stubs for moviepy (Python 3) # -# NOTE: This dynamically typed stub was automatically generated by stubgen. + -from .version import __version__ + diff --git a/stubs/moviepy/config.pyi b/stubs/moviepy/config.pyi --- a/stubs/moviepy/config.pyi +++ b/stubs/moviepy/config.pyi @@ -2,7 +2,7 @@ # # NOTE: This dynamically typed stub was automatically generated by stubgen. -from .compat import DEVNULL + from .config_defaults import FFMPEG_BINARY, IMAGEMAGICK_BINARY from typing import Any, Optional diff --git a/stubs/moviepy/editor.pyi b/stubs/moviepy/editor.pyi --- a/stubs/moviepy/editor.pyi +++ b/stubs/moviepy/editor.pyi @@ -5,11 +5,14 @@ from .audio.AudioClip import AudioClip, CompositeAudioClip, concatenate_audioclips from .audio.io.AudioFileClip import AudioFileClip from .tools import cvsecs -from .video.VideoClip import ColorClip, ImageClip, TextClip, VideoClip +from .video.VideoClip import ColorClip, ImageClip, TextClip from .video.compositing.CompositeVideoClip import CompositeVideoClip, clips_array from .video.compositing.concatenate import concatenate, concatenate_videoclips from .video.io.ImageSequenceClip import ImageSequenceClip from .video.io.VideoFileClip import VideoFileClip from .video.io.downloader import download_webfile -from .video.io.html_tools import ipython_display -from .video.io.sliders import sliders + +class VideoClip: + def __init__(self, make_frame, duration) -> None: ... + fps: float + def write_videofile(self, path: str, **kw): ... diff --git a/stubs/moviepy/tools.pyi b/stubs/moviepy/tools.pyi --- a/stubs/moviepy/tools.pyi +++ b/stubs/moviepy/tools.pyi @@ -1,8 +1,6 @@ # Stubs for moviepy.tools (Python 3) # -# NOTE: This dynamically typed stub was automatically generated by stubgen. -from .compat import DEVNULL from typing import Any, Optional def sys_write_flush(s: Any) -> None: ... diff --git a/stubs/moviepy/video/VideoClip.pyi b/stubs/moviepy/video/VideoClip.pyi --- a/stubs/moviepy/video/VideoClip.pyi +++ b/stubs/moviepy/video/VideoClip.pyi @@ -3,7 +3,6 @@ # NOTE: This dynamically typed stub was automatically generated by stubgen. from ..Clip import Clip -from ..compat import DEVNULL, string_types from ..config import get_setting from ..decorators import add_mask_if_none, apply_to_mask, convert_masks_to_RGB, convert_to_seconds, outplace, requires_duration, use_clip_fps_by_default from ..tools import deprecated_version_of, extensions_dict, find_extension, is_string, subprocess_call diff --git a/stubs/moviepy/video/io/html_tools.pyi b/stubs/moviepy/video/io/html_tools.pyi --- a/stubs/moviepy/video/io/html_tools.pyi +++ b/stubs/moviepy/video/io/html_tools.pyi @@ -1,19 +1,7 @@ # Stubs for moviepy.video.io.html_tools (Python 3) # -# NOTE: This dynamically typed stub was automatically generated by stubgen. + from ..VideoClip import ImageClip, VideoClip from .ffmpeg_reader import ffmpeg_parse_infos -from IPython.display import HTML from typing import Any, Optional - -ipython_available: bool - -class HTML2(HTML): - def __add__(self, other: Any): ... - -sorry: str -templates: Any - -def html_embed(clip: Any, filetype: Optional[Any] = ..., maxduration: int = ..., rd_kwargs: Optional[Any] = ..., center: bool = ..., **html_kwargs: Any): ... -def ipython_display(clip: Any, filetype: Optional[Any] = ..., maxduration: int = ..., t: Optional[Any] = ..., fps: Optional[Any] = ..., rd_kwargs: Optional[Any] = ..., center: bool = ..., **html_kwargs: Any): ... diff --git a/stubs/numpy/__init__.pyi b/stubs/numpy/__init__.pyi --- a/stubs/numpy/__init__.pyi +++ b/stubs/numpy/__init__.pyi @@ -4,3 +4,5 @@ from typing import Any array: Any linalg: Any + +def asarray(a: Any) -> array: ...