From da736cc4be16c5706bd1fdfae16f10dd3229782b Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Thu, 25 Apr 2019 14:11:42 +0200 Subject: [PATCH] Add import redirects with deprecation warning so we don't break plugin compatibility --- cura/PrinterOutput/PrintJobOutputModel.py | 4 ++++ cura/PrinterOutput/PrinterOutputModel.py | 4 ++++ cura/PrinterOutputDevice.py | 4 ++++ 3 files changed, 12 insertions(+) create mode 100644 cura/PrinterOutput/PrintJobOutputModel.py create mode 100644 cura/PrinterOutput/PrinterOutputModel.py create mode 100644 cura/PrinterOutputDevice.py diff --git a/cura/PrinterOutput/PrintJobOutputModel.py b/cura/PrinterOutput/PrintJobOutputModel.py new file mode 100644 index 0000000000..a810d40e9a --- /dev/null +++ b/cura/PrinterOutput/PrintJobOutputModel.py @@ -0,0 +1,4 @@ +import warnings +warnings.warn("Importing cura.PrinterOutput.PrintJobOutputModel has been deprecated since 4.1, use cura.PrinterOutput.Models.PrintJobOutputModel inststad", DeprecationWarning, stacklevel=2) +# We moved the the models to one submodule deeper +from cura.PrinterOutput.Models.PrintJobOutputModel import PrintJobOutputModel \ No newline at end of file diff --git a/cura/PrinterOutput/PrinterOutputModel.py b/cura/PrinterOutput/PrinterOutputModel.py new file mode 100644 index 0000000000..736e6c7aa3 --- /dev/null +++ b/cura/PrinterOutput/PrinterOutputModel.py @@ -0,0 +1,4 @@ +import warnings +warnings.warn("Importing cura.PrinterOutput.PrinterOutputModel has been deprecated since 4.1, use cura.PrinterOutput.Models.PrinterOutputModel inststad", DeprecationWarning, stacklevel=2) +# We moved the the models to one submodule deeper +from cura.PrinterOutput.Models.PrinterOutputModel import PrinterOutputModel \ No newline at end of file diff --git a/cura/PrinterOutputDevice.py b/cura/PrinterOutputDevice.py new file mode 100644 index 0000000000..0da1ae349d --- /dev/null +++ b/cura/PrinterOutputDevice.py @@ -0,0 +1,4 @@ +import warnings +warnings.warn("Importing cura.PrinterOutputDevice has been deprecated since 4.1, use cura.PrinterOutput.PrinterOutputDevice inststad", DeprecationWarning, stacklevel=2) +# We moved the PrinterOutput device to it's own submodule. +from cura.PrinterOutput.PrinterOutputDevice import PrinterOutputDevice, ConnectionState \ No newline at end of file