26 Commits

Author SHA1 Message Date
Jaime van Kessel
0944e63808
Merge pull request #12947 from digitalfrost/040822
MachineErrorChecker.py: Use one line conditional assignment
2022-09-06 15:04:10 +02:00
Jaime van Kessel
5b9ff198f4
Merge branch '030822' of github.com:digitalfrost/Cura 2022-09-06 15:02:32 +02:00
digitalfrost
9f3a1cfe0a Use f-string and info method with Logger
Use f-string and info method for Logger instead of "Old Style" string
formating.
2022-08-23 19:53:50 +02:00
digitalfrost
a39fed1dc3 Use one line conditional assignment
Use one line conditional assignement instead of if else block.
The intent is now clearer and the code is easier to read.
2022-08-04 09:45:47 +02:00
digitalfrost
fad47856e4 Rename _start_time to _check_start_time
This better reflects what _start_time is and makes the code easier
to read. _check_start_time is  self documenting.
The current comment next to _start_time is erroneous
since _start_time is not "measuring the checking time"
2022-08-03 11:40:15 +02:00
digitalfrost
556b009a9d Fix Bug in timing MachineErrorChecker execution
We want the Logger in line 215 to give the execution time in seconds
so we don't want the start time to be the epoch.
Currently the logger will output something like
time = 1659518458.5s
not like
time = 3.0s
2022-08-03 11:26:39 +02:00
digitalfrost
cba2e07adc
Remove extra spaces 2022-08-02 09:08:46 +02:00
digitalfrost
b13b7a892d Move _error_check_timer initialization to a separate function
This simplifies understanding the class __init__ function
2022-08-02 08:55:17 +02:00
Jaime van Kessel
509b7d65d5 Fix error checking never setting state to "hasError"
CURA-9249

Fixes #12082
2022-05-05 13:39:30 +02:00
Jaime van Kessel
ffa0106937 Check multiple settings per update of event loop
It seems that in Qt5, the update loop was triggered a lot more often than in qt6.
Since we used that to handle the error checking, this made it so that you sometimes had to wait
for quite some time untill the slicing would start (as that is blocked by the error checker)
2022-04-19 17:00:06 +02:00
Remco Burema
abe7c1bf7f
Search/replace Qt5->Qt6.
part of upgrading Qt to v6.2: CURA-8591
2021-12-28 14:46:02 +01:00
luz paz
d68f375e38 Fix various typos
Found via `codespell -q 3 -S *.po,*.pot -L childs,initialy,lod,ned,te,slicable,sur,tutoriels,wont`
2021-09-07 11:33:54 -04:00
Jaime van Kessel
27277d4e54
Add missing typing 2020-06-24 15:28:41 +02:00
Jaime van Kessel
ac0c0d0698
Let the error checker calculate the error values a bit more "on demand"
Previously it would just re-try all settings, but this really isn't needed (since
we have a setting relationship object that can tell us what settings depend on what).
This won't speed things up in a worst case scenario (since that will still be "caluclate
all the settings") but it will speed it up in most cases.

Most setting changes now only trigger a calculation that takes <0.2 sec isntead of the 1.1 sec.
Yes, those numbers seem big, but the error checking is already built in such a way that it spreads this
out over multiple frames (so it's not actually freezing that time, but it is doing shit it shouldn't do!)

CURA-7106
2020-06-23 14:54:56 +02:00
Jelle Spijker
120541a8db
Updated comments in Models
Converted doxygen style comments to reStructuredText style in the files
 found in Cura/cura/Model directory recursively  using the script
dox_2_rst.py (provided in the Uranium repo). Comments were manually
 checked and changed if needed.

 Note: dox_2rst.py struggles with decorated functions.
2020-05-08 18:59:38 +02:00
Jaime van Kessel
eaf8b3491e
Fix typing issue 2020-01-10 17:49:47 +01:00
Jaime van Kessel
81b33b8649
Add some missing typing 2020-01-10 14:58:53 +01:00
Jaime van Kessel
be675d9343
Remove unused signal 2019-10-11 14:33:08 +02:00
Jaime van Kessel
0ff9d72c4c
Remove use of deprecated extruders property 2019-09-13 17:27:16 +02:00
Jaime van Kessel
4b956953a6 Fix incorect error checking
We don't need to check the global stack for errors, as the correct values are already checked by looking at the extruder stacks
2019-07-31 10:24:31 +02:00
Lipu Fei
2054413952 Add handling for ValidatorState.Invalid
CURA-6497

ValidatorState.Invalid is set if a string setting has allow_empty =
False and its value is empty.
2019-05-09 12:07:16 +02:00
Jaime van Kessel
d495ec18bb Filter a bit more intelligently on when to check for errors
CURA-6016
2018-12-10 15:28:20 +01:00
Jaime van Kessel
729d78e14a Updated another set of typing 2018-09-10 16:08:31 +02:00
Lipu Fei
c8a882849f Simplify task queue for machine error check
CURA-5059
2018-03-13 16:08:46 +01:00
Jack Ha
9e0a78929a CURA-5059 changed error check timer interval and added measured time in logging 2018-03-13 16:02:57 +01:00
Lipu Fei
934d297e6c Split error checking into smaller sub-tasks
CURA-5059

Split stack error checking into smaller sub-tasks so running them on the Qt
thread will not block GUI updates from happening for too long.
2018-03-13 13:21:44 +01:00