mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 14:37:29 -06:00
Fix name/file-location oops.
This commit is contained in:
parent
fe2098376f
commit
935c71edda
1 changed files with 2 additions and 2 deletions
|
@ -162,12 +162,12 @@ class PostProcessingPlugin(QObject, Extension):
|
|||
# Iterate over all scripts.
|
||||
if script_name not in sys.modules:
|
||||
try:
|
||||
file_location = __name__ + "." + script_name, os.path.join(path, script_name + ".py")
|
||||
file_location = os.path.join(path, script_name + ".py")
|
||||
trust_instance = Trust.getInstanceOrNone()
|
||||
if trust_instance is not None and Trust.signatureFileExistsFor(file_location):
|
||||
if not trust_instance.signedFileCheck(file_location):
|
||||
raise Exception("Can't validate script {0}".format(file_location))
|
||||
spec = importlib.util.spec_from_file_location(file_location)
|
||||
spec = importlib.util.spec_from_file_location(__name__ + "." + script_name, file_location)
|
||||
loaded_script = importlib.util.module_from_spec(spec)
|
||||
if spec.loader is None:
|
||||
continue
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue