From 6d8c37ba2a5d7d3bc0fbac5db3e9346758f3d77a Mon Sep 17 00:00:00 2001 From: Tamas Nepusz Date: Mon, 1 Apr 2024 19:47:12 +0200 Subject: [PATCH] chore: started adding some partial typing of bpy modules --- typings/bpy/__init__.pyi | 11 +++++++++++ typings/bpy/path.pyi | 4 ++++ typings/bpy/types.pyi | 7 +++++++ 3 files changed, 22 insertions(+) create mode 100644 typings/bpy/__init__.pyi create mode 100644 typings/bpy/path.pyi create mode 100644 typings/bpy/types.pyi diff --git a/typings/bpy/__init__.pyi b/typings/bpy/__init__.pyi new file mode 100644 index 0000000..db7f19d --- /dev/null +++ b/typings/bpy/__init__.pyi @@ -0,0 +1,11 @@ +from typing import Tuple + +from .types import Context + +class _App: + version: Tuple[int, int, int] + version_file: Tuple[int, int, int] + version_string: str + +app: _App +context: Context diff --git a/typings/bpy/path.pyi b/typings/bpy/path.pyi new file mode 100644 index 0000000..a275691 --- /dev/null +++ b/typings/bpy/path.pyi @@ -0,0 +1,4 @@ +from pathlib import Path +from typing import Union + +def basename(path: Union[str, Path]) -> str: ... diff --git a/typings/bpy/types.pyi b/typings/bpy/types.pyi new file mode 100644 index 0000000..ea407c8 --- /dev/null +++ b/typings/bpy/types.pyi @@ -0,0 +1,7 @@ +from sbstudio.plugin.model import DroneShowAddonProperties + +class Scene: + skybrush: DroneShowAddonProperties + +class Context: + scene: Scene