46 Commits

Author SHA1 Message Date
Remco Burema
20b435af76
Qt5->Qt6: More renamed stuff.
part of CURA-8591
2021-12-29 11:18:49 +01: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
Ghostkeeper
3f92b46ac8
Don't restart refresh token while it's already processing
If two requests to the API occur at the same time, they will both see at the same time that they need an access token, and if it is expired they will both see that it needs refreshing. The server then sees two refreshes, both with the same refresh token. This is not allowed. The second one then gets a failure to refresh the token, which causes the user to log out.
Instead, we'll stop one of the refresh requests. They were fire-and-forget anyway, so it's not needed to actually continue the request.

Contributes to issue CURA-8539.
2021-11-22 18:52:43 +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
Ghostkeeper
8f9e0da400
Fix binding of extruder enable checkbox if there is no active stack
There was a typo there.

Contributes to issue CURA-7501.
2020-10-16 14:03:59 +02:00
Kostas Karmas
8a7dd2cfdf Update Toolbox labels to be aligned with the Digital Factory
CURA-7605
2020-07-27 11:58:55 +02:00
Jaime van Kessel
29bd061184
Fix incorrect update of set 2020-07-07 10:47:39 +02:00
Nino van Hooff
979407eddf Additional typing fixes
CURA-7473
2020-06-29 11:10:50 +02:00
Nino van Hooff
c815b098d4 Fix a bug where a package sync dialog would incorrectly not be shown
1. user subscribes to a package
2. dismisses the license/unsubscribes
3. subscribes to the same packafe again

in this scenario we want to notify the user again after step 3. This was
not the case because situations in step 1 and  3 are equal and thus the
user was considered notified.

CURA-7473
2020-06-26 16:28:03 +02:00
Nino van Hooff
4f1a18f102 Add Install Pending Updates button to Account popup
CURA-7473
2020-06-26 11:37:01 +02:00
Jaime van Kessel
fd2a7689cc
Remove overly spammy logging 2020-06-04 14:32:37 +02:00
Nino van Hooff
a3f968188f Add timeout to CloudPackageChecker request
Prevents it from getting stuck in the SYNCING state

CURA-7290
2020-05-14 15:14:51 +02:00
Nino van Hooff
fbc0be30ec Fix typing issue in CloudPackageChecker
CURA-7290
2020-05-12 15:40:53 +02:00
Nino van Hooff
b40b8e8489 Merge remote-tracking branch 'origin/master' into CURA-7290_manual_account_sync
# Conflicts:
#	cura/API/Account.py
2020-05-12 14:59:01 +02:00
Nino van Hooff
1ae050bbc5 Expose Account.SyncState as an Enum to QML
Provides a single source of truth

CURA-7290
2020-05-08 11:09:48 +02:00
Nino van Hooff
9b79b70f2b Merge branch 'CURA-7290_auto_sync_packages' into CURA-7290_manual_account_sync
# Conflicts:
#	cura/API/Account.py
#	plugins/UM3NetworkPrinting/src/Cloud/CloudOutputDeviceManager.py
2020-05-06 16:03:37 +02:00
Nino van Hooff
3ac0e7bed9 Consider all packages when calculating account discrepancies
Not just the user-subscribed ones

CURA-7245
2020-05-06 16:01:36 +02:00
Nino van Hooff
5b245434d0 Add _last_check_packages type hint
CURA-7290
2020-05-04 17:32:54 +02:00
Nino van Hooff
eac884fcd2 Convert SYNC_STATES to Enum
CURA-7290
2020-05-04 17:26:38 +02:00
Nino van Hooff
88ff68e40c Also check for package updates automatically
Moves the 30-second sync timer from CloudOutputDeviceManager to
Account and subscribes CloudPackageChecker to the timer.

CURA-7290
2020-05-04 16:56:09 +02:00
Nino van Hooff
eeea1692fd Register CloudPackageChecker as Account sync service
CURA-7290
2020-05-04 14:08:36 +02:00
Nino van Hooff
db758a7e19 Add None-checks to CloudPackageChecker
Might help prevent the sync message to show multiple times

CURA-7364
2020-04-15 17:16:38 +02:00
Remco Burema
c20b2c6ee0
Merge pull request #7211 from Ultimaker/CURA-7150_proper_http_request_headers
CURA-7150_proper_http_request_headers
2020-03-24 11:25:07 +01:00
Nino van Hooff
96ed85f9c0 Move UltimakerCloudAuthentication and UltimakerCloudScope
...to their own module
Fixes an import error where UltimakerCloudScope was used my both the
Toolbox and CuraDrive plugins

CURA-7150
2020-03-12 17:48:54 +01:00
Nino van Hooff
7e2177a8cd Rename _loginStateChanged for consistency
CURA-7251
2020-02-25 16:25:03 +01:00
Nino van Hooff
cf689ee3b0 Hide the Cloud Sync message when the user logs out
CURA-7251
2020-02-25 16:21:06 +01:00
Nino van Hooff
27902fe38f Use JsonDecorator scope in the Toolbox and CloudSync
Improves security by disallowing other content than json for requests

CURA-7150
2020-02-25 14:41:02 +01:00
Ghostkeeper
f918f39fc2
Don't use a newline at the beginning of the sync message
Again, this breaks stuff. See the previous commit.

Contributes to issue CURA-7201.
2020-02-24 14:33:10 +01:00
Ghostkeeper
633bdac21a
Don't start message with a newline
That breaks a couple of things:
* It messes up the layout of the message.
* The translations need to have this newline in as well, or they won't be accepted by gettext.
* The x-test translation puts 'xxxx' before the translation, so this one won't compile any more.

Contributes to issue CURA-7201.
2020-02-24 14:21:39 +01:00
Dimitriovski
9282423db1
Added lifetime=0 to the sync_message to make it stay there 2020-02-24 10:59:41 +01:00
Nino van Hooff
5beba6050f Fix api version checking
CURA-7207
2020-02-11 09:52:39 +01:00
Nino van Hooff
eec7d2f0cd Use default timeout for sync dialog 2020-01-30 14:56:19 +01:00
Dimitriovski
aa2c612925
PR review changes 2020-01-27 13:25:29 +01:00
Dimitriovski
537891d80b
Further improvements and refactors to the CloudPackageChecker 2020-01-24 16:05:35 +01:00
Dimitriovski
ae494110ba
Removed unnecessary line (because we still want to show the Compatability Dialog even if there are only Incompatible packages)
CURA-7090
2020-01-24 11:28:36 +01:00
Dimitriovski
5c498de1e4
Use meaningful variable name && some TODOs for later.
CURA-7090
2020-01-21 15:07:11 +01:00
Dimitriovski
e7ed93c132
fixed typing
CURA-7090
2020-01-21 14:51:53 +01:00
Dimitriovski
8abaa60052
Passed the sdk_version to the reevalute() function
CURA-7090
2020-01-21 11:24:31 +01:00
Dimitriovski
365c30fadb
Added check to reevaluate dismissed incompatible packages (in case the package gets updated and has the correct SDK version)
CURA-7090-addition
2020-01-21 09:52:33 +01:00
Nino van Hooff
46133fe2f3 Do not start Sync flow when there are no compatible packages to sync
(and remove unused import)

CURA-6983
2020-01-16 14:44:37 +01:00
Nino van Hooff
6763bed95f Fix Toolbox import error (continued)
(and remove unused import)

CURA-6983
2020-01-16 14:39:10 +01:00
Jaime van Kessel
0f7f39745d
Add missing typing
CURA-6983
2020-01-15 16:57:10 +01:00
Nino van Hooff
248a4cbb94 Fix merge issues
CURA-6983
2020-01-15 16:14:17 +01:00
Nino van Hooff
88d210d12d Fix The toolbox license dialog
CURA-6983
2020-01-10 11:47:36 +01:00
Nino van Hooff
883243b533 Move UltimaterCloudScope to Cura project
CURA-6983
2020-01-10 11:42:48 +01:00
Nino van Hooff
1a816ad010 Introduce the SyncOrchestrator
CURA-6983
2020-01-10 11:42:48 +01:00