Tool module: make all "import as" imports relative

This commit is contained in:
Dion Moult
2024-07-18 16:29:20 +10:00
parent 72ecfbb9e1
commit 3d02b60160
40 changed files with 43 additions and 43 deletions
+1 -1
View File
@@ -18,7 +18,7 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import ifcopenshell.util.element import ifcopenshell.util.element
from typing import Union from typing import Union
+1 -1
View File
@@ -24,7 +24,7 @@ import os
import ifcopenshell.api import ifcopenshell.api
import ifcopenshell.util.element import ifcopenshell.util.element
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim import blenderbim.bim
import addon_utils import addon_utils
import types import types
+1 -1
View File
@@ -19,7 +19,7 @@
import bpy import bpy
import mathutils import mathutils
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
from mathutils import Matrix, Vector from mathutils import Matrix, Vector
from typing import Any, Sequence from typing import Any, Sequence
+1 -1
View File
@@ -22,7 +22,7 @@ import ifcopenshell
import ifcopenshell.guid import ifcopenshell.guid
import ifcopenshell.util.brick import ifcopenshell.util.brick
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
from contextlib import contextmanager from contextlib import contextmanager
import datetime import datetime
+1 -1
View File
@@ -1,5 +1,5 @@
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import bpy import bpy
import json import json
+1 -1
View File
@@ -21,7 +21,7 @@ import bpy
import json import json
import ifcopenshell import ifcopenshell
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
from contextlib import contextmanager from contextlib import contextmanager
from mathutils import Vector from mathutils import Vector
+1 -1
View File
@@ -18,7 +18,7 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import ifcopenshell.util.element import ifcopenshell.util.element
from typing import Union from typing import Union
+1 -1
View File
@@ -18,7 +18,7 @@
import bpy import bpy
import blenderbim.bim.helper import blenderbim.bim.helper
import blenderbim.tool as tool from .. import tool
import blenderbim.core.tool import blenderbim.core.tool
+1 -1
View File
@@ -1,7 +1,7 @@
import os import os
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import ifcopenshell.util.element import ifcopenshell.util.element
import ifcopenshell.util.date import ifcopenshell.util.date
import ifcopenshell.util.cost import ifcopenshell.util.cost
+1 -1
View File
@@ -24,7 +24,7 @@ import blenderbim.core.tool
import blenderbim.core.root import blenderbim.core.root
import blenderbim.core.spatial import blenderbim.core.spatial
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.tool as tool from .. import tool
import json import json
from math import pi from math import pi
from mathutils import Vector, Matrix from mathutils import Vector, Matrix
+1 -1
View File
@@ -20,7 +20,7 @@ import os
import bpy import bpy
import ifcopenshell.express import ifcopenshell.express
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
from ..bim.ifc import IfcStore from ..bim.ifc import IfcStore
+1 -1
View File
@@ -31,7 +31,7 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
# There is always one class in each tool file, which implements the interface # There is always one class in each tool file, which implements the interface
+1 -1
View File
@@ -19,7 +19,7 @@
import bpy import bpy
import ifcopenshell.util.system import ifcopenshell.util.system
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
from ..bim import import_ifc from ..bim import import_ifc
+1 -1
View File
@@ -33,7 +33,7 @@ import subprocess
import numpy as np import numpy as np
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.tool as tool from .. import tool
import ifcopenshell.api import ifcopenshell.api
import ifcopenshell.geom import ifcopenshell.geom
import ifcopenshell.util.representation import ifcopenshell.util.representation
+1 -1
View File
@@ -35,7 +35,7 @@ import blenderbim.core.style
import blenderbim.core.spatial import blenderbim.core.spatial
import blenderbim.core.system import blenderbim.core.system
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.import_ifc import blenderbim.bim.import_ifc
from collections import defaultdict from collections import defaultdict
from math import radians, pi from math import radians, pi
@@ -22,7 +22,7 @@ import numpy as np
import ifcopenshell import ifcopenshell
import ifcopenshell.api.georeference import ifcopenshell.api.georeference
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
from math import radians, cos, sin from math import radians, cos, sin
+1 -1
View File
@@ -24,7 +24,7 @@ import ifcopenshell.ifcopenshell_wrapper as ifcopenshell_wrapper
import ifcopenshell.util.element import ifcopenshell.util.element
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.bim.handler import blenderbim.bim.handler
import blenderbim.tool as tool from .. import tool
from ..bim.ifc import IfcStore, IFC_CONNECTED_TYPE from ..bim.ifc import IfcStore, IFC_CONNECTED_TYPE
from typing import Optional, Union, Any, final from typing import Optional, Union, Any, final
+1 -1
View File
@@ -4,7 +4,7 @@ import bpy
import logging import logging
from ..bim import import_ifc from ..bim import import_ifc
from ..bim.ifc import IfcStore from ..bim.ifc import IfcStore
import blenderbim.tool as tool from .. import tool
# allows git import even if git executable isn't found # allows git import even if git executable isn't found
os.environ["GIT_PYTHON_REFRESH"] = "quiet" os.environ["GIT_PYTHON_REFRESH"] = "quiet"
+1 -1
View File
@@ -18,7 +18,7 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
class Library(blenderbim.core.tool.Library): class Library(blenderbim.core.tool.Library):
+1 -1
View File
@@ -26,7 +26,7 @@ import ifcopenshell.util.element
import ifcopenshell.util.shape import ifcopenshell.util.shape
import ifcopenshell.util.unit import ifcopenshell.util.unit
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.import_ifc import blenderbim.bim.import_ifc
import numpy as np import numpy as np
import numpy.typing as npt import numpy.typing as npt
+1 -1
View File
@@ -22,7 +22,7 @@ import ifcopenshell
import ifcopenshell.api.material import ifcopenshell.api.material
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.core.material import blenderbim.core.material
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
import ifcopenshell.util.unit import ifcopenshell.util.unit
import ifcopenshell.util.element import ifcopenshell.util.element
+1 -1
View File
@@ -21,7 +21,7 @@ import bmesh
import ifcopenshell import ifcopenshell
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.core.root import blenderbim.core.root
import blenderbim.tool as tool from .. import tool
from mathutils import Vector, Matrix from mathutils import Vector, Matrix
from ..bim.ifc import IfcStore from ..bim.ifc import IfcStore
+2 -2
View File
@@ -30,8 +30,8 @@ import ifcopenshell.util.placement
import ifcopenshell.util.representation import ifcopenshell.util.representation
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.core.geometry as geometry from ..core. import geometry
from math import atan, degrees from math import atan, degrees
from mathutils import Matrix, Vector from mathutils import Matrix, Vector
from copy import deepcopy from copy import deepcopy
+1 -1
View File
@@ -17,7 +17,7 @@
# along with BlenderBIM Add-on. If not, see <http://www.gnu.org/licenses/>. # along with BlenderBIM Add-on. If not, see <http://www.gnu.org/licenses/>.
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import ifcopenshell.util.element import ifcopenshell.util.element
+1 -1
View File
@@ -18,7 +18,7 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
import ifcopenshell import ifcopenshell
from typing import Union, Any from typing import Union, Any
+1 -1
View File
@@ -23,7 +23,7 @@ import ifcopenshell.util.unit
import ifcopenshell.util.placement import ifcopenshell.util.placement
import ifcopenshell.util.representation import ifcopenshell.util.representation
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import PIL.ImageDraw import PIL.ImageDraw
from ..bim.module.model.decorator import ProfileDecorator from ..bim.module.model.decorator import ProfileDecorator
from typing import Union from typing import Union
+1 -1
View File
@@ -28,7 +28,7 @@ import blenderbim.core.root
import blenderbim.core.unit import blenderbim.core.unit
import blenderbim.core.owner import blenderbim.core.owner
import blenderbim.bim.schema import blenderbim.bim.schema
import blenderbim.tool as tool from .. import tool
from ..bim.ifc import IfcStore from ..bim.ifc import IfcStore
from pathlib import Path from pathlib import Path
from typing import Optional from typing import Optional
+1 -1
View File
@@ -20,7 +20,7 @@ import bpy
import ifcopenshell import ifcopenshell
import ifcopenshell.util.element import ifcopenshell.util.element
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.schema import blenderbim.bim.schema
from typing import Union from typing import Union
+1 -1
View File
@@ -19,7 +19,7 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.bim.schema import blenderbim.bim.schema
import blenderbim.tool as tool from .. import tool
import ifcopenshell import ifcopenshell
import ifcopenshell.util.unit import ifcopenshell.util.unit
import ifcopenshell.util.element import ifcopenshell.util.element
+2 -2
View File
@@ -20,9 +20,9 @@
import bpy import bpy
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
import blenderbim.bim.module.sequence.helper as helper from ..bim.module.sequence. import helper
import json import json
import time import time
import isodate import isodate
+1 -1
View File
@@ -28,7 +28,7 @@ import blenderbim.core.aggregate
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.core.material import blenderbim.core.material
import blenderbim.core.style import blenderbim.core.style
import blenderbim.tool as tool from .. import tool
from typing import Union, Optional, Any from typing import Union, Optional, Any
+2 -2
View File
@@ -31,9 +31,9 @@ import ifcopenshell.util.element
import ifcopenshell.util.unit import ifcopenshell.util.unit
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.core import blenderbim.core
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
import blenderbim.bim.module.sequence.helper as helper from ..bim.module.sequence. import helper
from dateutil import parser from dateutil import parser
from datetime import datetime from datetime import datetime
from typing import Optional, Any, Union from typing import Optional, Any, Union
+1 -1
View File
@@ -34,7 +34,7 @@ import blenderbim.core.tool
import blenderbim.core.root import blenderbim.core.root
import blenderbim.core.spatial import blenderbim.core.spatial
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.tool as tool from .. import tool
import json import json
from math import pi from math import pi
from mathutils import Vector, Matrix from mathutils import Vector, Matrix
+1 -1
View File
@@ -22,7 +22,7 @@ import json
import blenderbim.bim.helper import blenderbim.bim.helper
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.core.structural import blenderbim.core.structural
import blenderbim.tool as tool from .. import tool
from ..bim.ifc import IfcStore from ..bim.ifc import IfcStore
from pprint import pprint from pprint import pprint
+1 -1
View File
@@ -22,7 +22,7 @@ import ifcopenshell
import ifcopenshell.util.element import ifcopenshell.util.element
import ifcopenshell.util.representation import ifcopenshell.util.representation
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
from mathutils import Color from mathutils import Color
from typing import Union, Any, Optional, Literal from typing import Union, Any, Optional, Literal
+1 -1
View File
@@ -19,7 +19,7 @@
import bpy import bpy
import ifcopenshell.api import ifcopenshell.api
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import numpy as np import numpy as np
+1 -1
View File
@@ -23,7 +23,7 @@ import blenderbim.bim.helper
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.core.root import blenderbim.core.root
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
from ..bim import import_ifc from ..bim import import_ifc
import re import re
from math import pi, cos, sin from math import pi, cos, sin
+1 -1
View File
@@ -22,7 +22,7 @@ import ifcopenshell.util.element
import ifcopenshell.util.representation import ifcopenshell.util.representation
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.core.geometry import blenderbim.core.geometry
import blenderbim.tool as tool from .. import tool
import blenderbim.bim.helper import blenderbim.bim.helper
from typing import Union from typing import Union
+1 -1
View File
@@ -20,7 +20,7 @@ import bpy
import json import json
import ifcopenshell import ifcopenshell
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
class Unit(blenderbim.core.tool.Unit): class Unit(blenderbim.core.tool.Unit):
+1 -1
View File
@@ -19,7 +19,7 @@
import bpy import bpy
from ..bim.module.web.data import WebData from ..bim.module.web.data import WebData
import blenderbim.core.tool import blenderbim.core.tool
import blenderbim.tool as tool from .. import tool
import ifcopenshell.api.sequence import ifcopenshell.api.sequence
import socket import socket
import os import os