Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AARD-1741: Exporter PIP Dependency Updates #1024

Merged
merged 12 commits into from
Aug 2, 2024
47 changes: 26 additions & 21 deletions exporter/SynthesisFusionAddin/Synthesis.py
Original file line number Diff line number Diff line change
@@ -1,29 +1,35 @@
# DO NOT CHANGE ORDER, OR ADD IMPORTS BEFORE UNTIL END COMMENT

import os
from shutil import rmtree
import sys

import adsk.core

from .src.general_imports import APP_NAME, DESCRIPTION, INTERNAL_ID, gm
from .src.Logging import getLogger, logFailure, setupLogger
from .src.UI import (
HUI,
Camera,
ConfigCommand,
Handlers,
Helper,
MarkingMenu,
ShowAPSAuthCommand,
ShowWebsiteCommand,
)
from .src.UI.Toolbar import Toolbar
# Currently required for `resolveDependencies()`, will be required for absolute imports.
sys.path.append(os.path.dirname(os.path.abspath(__file__)))

from .src.Dependencies import resolveDependencies # isort:skip

# END OF RESTRICTION
# Transition: AARD-1741
# Import order should be removed in AARD-1737 and `setupLogger()` moved to `__init__.py`
from .src.Logging import getLogger, logFailure, setupLogger # isort:skip

# Transition: AARD-1721
# Should attempt to fix this ordering scheme within AARD-1741
from .src.APS import APS # isort:skip
setupLogger()

try:
from .src.general_imports import APP_NAME, DESCRIPTION, INTERNAL_ID, gm
from .src.UI import (
HUI,
Camera,
ConfigCommand,
MarkingMenu,
ShowAPSAuthCommand,
ShowWebsiteCommand,
)
from .src.UI.Toolbar import Toolbar
except (ImportError, ModuleNotFoundError) as error:
getLogger().warn(f"Running resolve dependencies with error of:\n{error}")
result = resolveDependencies()
if result:
adsk.core.Application.get().userInterface.messageBox("Installed required dependencies.\nPlease restart Fusion.")


@logFailure
Expand All @@ -33,7 +39,6 @@ def run(_):
Arguments:
**context** *context* -- Fusion context to derive app and UI.
"""
setupLogger()

# Remove all items prior to start just to make sure
unregister_all()
Expand Down
191 changes: 0 additions & 191 deletions exporter/SynthesisFusionAddin/proto/deps.py

This file was deleted.

Loading
Loading