Commit graph

6608 commits

Author SHA1 Message Date
Kostas Karmas
e2699a5ab8 Display the correct message when opening deleted files from Recent
If a file that existed in the Recent Files list was deleted, Cura was still trying to open the file
on user's request without properly displaying an error if the file was not found.

This is now fixed by popping up a message to indicate that the file doesn't exist.

CURA-7996
2021-02-05 12:10:23 +01:00
Ghostkeeper
ba5b033499
Don't crash when not able to read maximum file name length
Just use a safe-ish maximum then.

Fixes Sentry issue CURA-1QY.
2021-02-04 17:10:03 +01:00
Remco Burema
06666bddca
Fix recent files hint when file opens via dialoges. 2021-01-29 14:49:32 +01:00
Jaime van Kessel
f85cad37cf
Expand the logging for the auth data a bit more
We're getting some reports that people are suddenly logged out. The working
theory is that they are mixing staging & production builds. This logging
should tell us enough to find out if that is the case!
2021-01-28 10:31:47 +01:00
Remco Burema
9197a1ca51
Fix crash on open project from term or by file.
Opening a .3mf file or other project would cause a crash if the preference for always opening as a project (as opposed to importing models or 'always ask') was set. Traced back to a typo.

CURA-7987
2021-01-23 12:02:57 +01:00
Remco Burema
e681a6d32d
Fix camera not found on pre-slice snapshot/thumbnail. 2021-01-22 18:07:59 +01:00
Ghostkeeper
4380cdbd86
Don't crash on malformed JSON structures
JSON dictionaries need to have a certain structure such as strings as keys. If that's not correct it gives a TypeError. Don't crash on those; give a similar error message as when the values in the JSON are invalid.
2021-01-19 16:31:31 +01:00
Ghostkeeper
1b8463ba30
Catch TypeError when parsing setting version
Someone had a list in the setting version, which then crashed Cura.
2021-01-19 14:09:46 +01:00
Ghostkeeper
640e038ce7
Catch OSError when authorizing connection
Fixes Sentry issue CURA-1GW.
2021-01-19 11:05:55 +01:00
Jaime van Kessel
5d9affc690
Drop objects to buildplate that have been scaled
Otherwise they could be floating very high above the buildplate.

CURA-7855
2021-01-15 15:21:57 +01:00
Konstantinos Karmas
0edd6278f8
Merge pull request #9089 from Ultimaker/CURA-7864_open_remote_files_mvp
Open remote files MVP
2021-01-12 11:04:29 +01:00
Jelle Spijker
d16c5f1991
Merge pull request #9012 from Ultimaker/CURA-7868_Introduce_file_provider_plugin_type
CURA-7868: Introduce the file provider plugin type
2021-01-11 18:24:18 +01:00
Kostas Karmas
3282ad7a41 Don't add temporary files in the recent files list if F5 is pressed
CURA-7864
2021-01-11 12:52:23 +01:00
Konstantinos Karmas
9562dc01f4
Merge pull request #8718 from Ultimaker/speed_up_container_tree
Simplify and speed up the extending of the qualities list
2021-01-08 16:00:52 +01:00
Remco Burema
13d45e3a55
Typing typo.
CURA-7864
2021-01-08 13:51:03 +01:00
Remco Burema
aa0a08500e
Temproray files shouldn't be in recent file list.
CURA-7864
2021-01-08 13:44:23 +01:00
Ghostkeeper
0788df4797
Add log entry upon exporting container
Quite a salient moment in the log. According to our log levels definitions this must be info since it's the direct result of a user interaction.
2021-01-06 14:11:15 +01:00
Remco Burema
a25a51eddb
Windows workaround for OAuth data removal from config.
Windows won't allow long keys in the backend the keyring python package uses as a backend. This means the access_token part can't be stored in the obvious way. Timeboxed some attempts at working around this limitation, but couldn't make it work within the time set. As this is mostly an extra precaustion protecting users that share config folders around against themselves (in other words, if this goes wrong it's not unreasonable to blame the user) it's not top critical, and the important part of that (the refresh_token) can proceed, giving any potential attacker only a 10 minute window from the moment any user shares their %appdata%/cura files (again, this is not how we intent for users to behave, but they can and will do it this way).

CURA-7180
2020-12-24 14:39:22 +01:00
Kostas Karmas
71994eaaf9 Change the Open File(s) option according to the file providers count
When there is only one file provider (i.e. the local file provider), the Open File(s) will be a
simple item in the File menu.
When there are more than one file providers, the Open File(s) will become a submenu in the File
menu, which will contain all the file providers as submenu items.

CURA-7868
2020-12-23 17:13:14 +01:00
Jaime van Kessel
7f27ff5432
Reset scene metadata if the buildplate was cleared
CURA-7615
2020-12-23 14:08:59 +01:00
Jaime van Kessel
bff3ba577b
Store auth & refresh key in keyring instead of in preferences
People tend to share configuration folders, which just isn't secure.

CURA-7180
2020-12-21 14:02:45 +01:00
Kostas Karmas
43615a57b6 Change client scope in the Account
CURA-7868
2020-12-18 14:34:29 +01:00
Jaime van Kessel
037b5d5b44
Ensure that the skirt_brim_line_width is selected from right extruder
This fixes CURA-7835 and Fixes #8716
2020-12-18 11:31:55 +01:00
Jaime van Kessel
7096f64ca2
Fix crash when extruder could not be found
Fixes #8891
2020-12-07 16:45:28 +01:00
Jaime van Kessel
99c12de6b0
Merge branch 'master' of github.com:Ultimaker/Cura into fix_grouping_below_build_plate 2020-11-25 15:42:15 +01:00
Jaime van Kessel
68bc75e7a2
Merge branch 'CURA-7501_fix_warning_preloaded_plugins' of github.com:Ultimaker/Cura 2020-11-16 15:24:31 +01:00
Remco Burema
9afbc64934
Merge branch '4.8' 2020-11-10 11:31:53 +01:00
Kostas Karmas
4b35bd1724 Correct the print sequence when discarding the current changes
CURA-7827
2020-11-09 18:10:50 +01:00
Kostas Karmas
fab2c31b4f Cover the last remaining case when setting the print sequence
If for some reason the print sequence is set to one-at-a-time be default in the printer definition
and the number of extruders of the printer is set to >=2, then the print_sequence won't show up in
neither the quality changes nor the user changes, yet it will still have "one-at-a-time" as a
value. In a such case, it will still need to be set to "all-at-once" in the user changes.

This is a theoretical case, as it is very unlikely for a printer to have "one-at-a-time" set by
default in its definition (.def.json) file and still be able to support more than one extruders.
But it is a world full of possibilities out there, so you never know...

CURA-7827
2020-11-09 16:55:43 +01:00
Kostas Karmas
07453e101e Add detailed documentation for _correctPrintSequence function
CURA-7827
2020-11-09 16:32:05 +01:00
Kostas Karmas
2ccdd11098 Properly set the print sequence in the correct container
Previously, the print sequence would be always set to all-at-once in the user container whenever
the second extruder would be enabled. This was causing an interface issue, where the circular
reset-setting arrow would appear next to the setting, even if the quality changes already had the
correct value ("all-at-once").

This is now fixed by checking the following:
- If print_sequence == "one_at_a_time" in the quality (so it is already saved in a quality profile)
then set the print_sequence to "all_at_once" in the user changes so that it will be displayed as
an unsaved change
- If print_sequence == "one_at_a_time" in the user changes container only, meaning that it is not
saved in any quality profiles, then just reset the print_sequence in the user changes, so that it
will have the correct value ("all-at-once") without the reset-setting arrow appearing next to it.

CURA-7827
2020-11-09 16:20:13 +01:00
Jaime van Kessel
01648a329e
Convert list of all base_files into set
Co-authored-by: Ghostkeeper <Ghostkeeper@users.noreply.github.com>
2020-11-09 15:28:13 +01:00
Jaime van Kessel
5a14ef2a56
Simplify and speed up the extending of the qualities list 2020-11-09 14:14:32 +01:00
Kostas Karmas
a1c7ebe1c3 Fix mypy complaints
CURA-7827
2020-11-05 19:04:29 +01:00
Kostas Karmas
845c994cbc Replace f string since it's not available in Python3.5
That should fix the failing test which produces a SyntaxError.

CURA-7827
2020-11-05 17:38:34 +01:00
Kostas Karmas
1a759f81df Change print sequence when the number of enabled extruders changes
Fixes https://github.com/Ultimaker/Cura/issues/8682 while still maintaining the correct behavior for CURA-6914.

CURA-7827
2020-11-05 16:58:47 +01:00
Jaime van Kessel
080832fcf2
Merge branch '4.8' of github.com:Ultimaker/Cura 2020-11-04 11:07:38 +01:00
Kostas Karmas
726175a01d Merge branch '4.8' of https://github.com/Ultimaker/Cura into 4.8 2020-11-04 09:22:42 +01:00
Kostas Karmas
881e4406a4 Ensure the organization_id is None 2020-11-04 09:21:28 +01:00
Jaime van Kessel
526eb8dacd
Gracefully handle exceptions in arrange
CURA-7785
2020-11-03 09:48:54 +01:00
Ghostkeeper
39287264d9
Pynest2d.Point requires integer coordinates
These were floats. Rounding numpy-floats still results in floats so I'm just using int(). The result is rounded down instead of nearest, but the difference is at most 50 nanometres anyway.

Contributes to issue CURA-7501.
2020-10-30 18:12:18 +01:00
Ghostkeeper
ef1952f34c
Fix providing floats to integer parameters
In newer Python versions this results in a warning.

Contributes to issue CURA-7501.
2020-10-30 17:45:57 +01:00
Ghostkeeper
31ee864f04
Disallow printer names that start with a dot
Fixes #8639.
2020-10-30 11:10:46 +01:00
Kostas Karmas
309c5fe9f9 Merge branch '4.8' 2020-10-27 14:42:38 +01:00
Jaime van Kessel
d35d6b087a
Reset the entire transformation when merging
This fixes the issue when the packing algorithm rotated an object

CURA-7796
2020-10-27 13:44:33 +01:00
Konstantinos Karmas
4e6097f499
Revert "Prevent duplicate adding of extruders" 2020-10-27 11:29:08 +01:00
Ghostkeeper
5cfe18d31c
Clarify user-facing string to remove internal terminology
The user doesn't know what a global stack is. This is a message that more clearly specifies what is really happening as far as the user can see.

The global stack may be None if this code is executed while there is no active printer. Normally the only time there is no active printer is:
- during first launch, while in the welcome screen
- during start-up until the profiles have been loaded
- if there was a profile corruption of some kind with the active printer.

So this function should not get called during those times. It probably isn't called except for the last case (in which case it's acceptable I guess).
This change is made after a request from a translator what the hell this means.

Contributes to issue CURA-7783.
2020-10-27 10:54:07 +01:00
Konstantinos Karmas
4804072625
Merge pull request #8553 from Ultimaker/CURA-7501_no_double_adding_extruders
Prevent duplicate adding of extruders
2020-10-26 17:02:51 +01:00
Jaime van Kessel
10ed7c1288
Merge branch '4.8' of github.com:Ultimaker/Cura 2020-10-22 13:41:44 +02:00
Kostas Karmas
03dc8d00fe Up the SDK version to 7.4.0
In preparation for release of the 4.8.

CURA-7795
2020-10-22 11:29:25 +02:00