Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2014-12-18 15:52:31 +0300
committerCampbell Barton <ideasman42@gmail.com>2014-12-18 15:52:31 +0300
commitf0f1c7995b3fed05248b93a8e57d77f033e0df28 (patch)
treeb040b1c97f7635a2dac88836159635d9505a44b1 /release
parent9f61350a05eb77dfa28ccce57ca15269e9bafcf1 (diff)
PyAPI: disallow assigning members to 'bpy.ops'
Diffstat (limited to 'release')
-rw-r--r--release/scripts/modules/bpy/__init__.py4
-rw-r--r--release/scripts/modules/bpy/ops.py1
2 files changed, 3 insertions, 2 deletions
diff --git a/release/scripts/modules/bpy/__init__.py b/release/scripts/modules/bpy/__init__.py
index 3a2f9bde2c7..b0d2233b380 100644
--- a/release/scripts/modules/bpy/__init__.py
+++ b/release/scripts/modules/bpy/__init__.py
@@ -38,10 +38,10 @@ __all__ = (
from _bpy import types, props, app, data, context
# python modules
-from . import utils, path, ops
+from . import utils, path
# fake operator module
-ops = ops.ops_fake_module
+from .ops import ops_fake_module as ops
def main():
diff --git a/release/scripts/modules/bpy/ops.py b/release/scripts/modules/bpy/ops.py
index 1bdb9eba48c..d3d9255123b 100644
--- a/release/scripts/modules/bpy/ops.py
+++ b/release/scripts/modules/bpy/ops.py
@@ -36,6 +36,7 @@ class BPyOps:
bpy.ops
"""
+ __slots__ = ()
def __getattr__(self, module):
"""