344 Commits

Author SHA1 Message Date
c.lamboo
a7329841e6 Revert "removed all generic materials"
This reverts commit 71332716cc6ac19351798aae7fe48ab95088597b.
2024-03-21 11:25:24 +01:00
Saumya Jain
71332716cc removed all generic materials
Only materials available for method is available in the _material_map

CURA-11729
2024-03-21 10:37:12 +01:00
Saumya Jain
81001b60cf GUID of material ASA was from generic ASA, now given Ultimaker ASA GUID
CURA-11729
2024-03-20 14:32:22 +01:00
c.lamboo
77e949830a Add missing ABS-CF material to material map
CURA-11710
2024-03-11 13:04:26 +01:00
Saumya Jain
0da0c720dd Changed names of materials as per materials list
Removed materials with GUID not found

CURA-11710
2024-03-11 11:04:51 +01:00
Casper Lamboo
3fee8ba851
Update cura/PrinterOutput/Models/MaterialOutputModel.py 2024-03-08 16:59:04 +01:00
c.lamboo
6e6ca515cd Add missing nylon material to material map
CURA-11709
2024-03-08 16:07:41 +01:00
Jelle Spijker
7a4d26452a
Fix testing against literal instead of value
Contribute to CURA-10831
2023-12-04 14:00:42 +01:00
saumya.jain
7ce91f5ad8 material translation, saving to .makerbot on cloud by default when Method printer is selected
CURA-11138
2023-11-01 11:03:19 +01:00
saumya.jain
ce132e4c3f Function name changed to make it a bit generic
CURA-11138
2023-10-31 11:48:44 +01:00
saumya.jain
1a139f44bc parsing method printer nozzles
CURA-11138
2023-10-30 16:13:50 +01:00
saumya.jain
39ec9c9279 printertype Parsing function made static
CURA-11138
2023-10-30 14:31:17 +01:00
saumya.jain
37e236405a fix for functions
CURA-11138
2023-10-27 09:30:06 +02:00
saumya.jain
cf78ae0dca Method printers method, methodx, methodxl read from cloud
CURA-11138
2023-10-26 16:17:03 +02:00
c.lamboo
0e1262126a Fix memory leak issues in minitor page
Issue was that QT (incorrectly?) asserted that there was a binding loop between width and height in the `NetworkMJPGImage` component. This caused the height to evalualte to `infinity`, making QT create a buffer with an infinite amount of memory. Solved by calculating a serpeate `img_scale_factor` which both the width and height uses.

CURA-11180
2023-10-19 11:53:41 +02:00
Remco Burema
b4405d886b Reverse sorting, newer machines on top.
Same brand or name, but with a higher number should generally be first, so reverse sorting.

CURA-9769
2022-10-20 10:24:01 +02:00
c.lamboo
8d9e9a9dbf Use modern python typing
CURA-9278
2022-09-12 17:04:40 +02:00
Jaime van Kessel
438871648b
Don't notify qml of update if no configurations changed
This might be the cause of #11608, but i'm not entirely sure. Whatever
the case, it's also not going to hurt checking this...
2022-08-31 16:31:39 +02:00
Jaime van Kessel
0516b27f2b
Clean up formatting of documentation
Boyscouting!

CURA-8463
2022-08-26 13:35:13 +02:00
Jelle Spijker
cc9a413a49
Merge pull request #12909 from digitalfrost/310722
Use dataclasses for Peripheral
2022-08-23 10:23:47 +02:00
Ghostkeeper
84cf72d58f
Document shortcoming of isMine check
Contributes to issue CURA-9220.
2022-08-01 10:49:29 +02:00
digitalfrost
cfeab2e6c0 Use dataclasses for Peripheral
Since Peripheral is a data class use dataclasses
2022-07-31 11:46:03 +02:00
Ghostkeeper
8871fd6224
Add property of the print job being made by the current user
According to the Account API, is this print job made by the same user?
This property is a bit inaccurate, in that this matches by the user name. The user name might be duplicate in some systems.

Contributes to issue CURA-9220.
2022-07-25 17:28:56 +02:00
Remco Burema
a2d721b6ac Always return int's.
The problem was probably 'max', but cast the others just to be sure. (This would cause the C++ part of Qt to think it wasbeing given a float from Pyton somehow.)

should fix CURA-9196
2022-04-26 16:54:46 +02:00
Ghostkeeper
d1d45b4f41
Fix enum to FormDataType
Stupid enum change...

Contributes to issue CURA-9119.
2022-04-11 13:23:03 +02:00
j.delarago
aa190024d4 Update enum, this fixes connecting to printers
CURA-8640
2022-04-05 16:01:17 +02:00
Jelle Spijker
12ee57e4ad
Merge branch 'master' into CURA-8640_PyQt6
# Conflicts:
#	cura/UI/CuraSplashScreen.py
2022-03-28 15:02:18 +02:00
Jaime van Kessel
74eac8f4b9 Remove printeroutput model
CURA-7810
2022-03-24 13:41:10 +01:00
Ghostkeeper
ec5bb444c0
Don't change metadata if there is no global stack
We'll miss that status update then, but the next time Cura starts it'll update the printer status anyway.

Found during testing of CURA-8591.
2022-01-05 17:15:38 +01:00
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
9674c54efb
Better type checking and handling of optionals
Adds type checking here and there to catch such errors in the future.
This makes it handle the optional fields of this model better.

Contributes to issue CURA-8730.
2021-12-08 17:36:09 +01:00
Remco Burema
1253b41537
Only perform materials-sync-job for capable printers.
part of CURA-8671
2021-12-02 12:22:55 +01:00
Ghostkeeper
116046a8b2
Fix binding printer_id to response callbacks
With the lambda it would capture the variable of printer_id. It wouldn't actually store the value of printer_id in teh created lambda. As a result, it was using the current value of printer_id when the lambda executes, rather than the value of printer_id when the lambda is constructed. A bit weird how that works in Python's lambdas.

With partial functions it works properly.

Contributes to issue CURA-8609.
2021-10-27 14:06:04 +02:00
Ghostkeeper
f99fedc58b
Fix API misalignments with confirm material upload action
The API endpoint got renamed (without my awareness). It also needed to be a POST request, probably since the beginning. And apparently it needs everything to be in a sub-field called 'data' for some reason.

Contributes to issue CURA-8609.
2021-10-27 13:38:58 +02:00
Ghostkeeper
1c6ad019a3
Response data is contained in sub-field 'data'
The entire response is contained in a lone 'data' field in the response. Why this is necessary I don't know, because indeed everything the server can tell us is data so everything would be in a 'data' field. But that's how the API reacts so that's how we'll have to parse it.

Contributes to issue CURA-8609.
2021-10-27 13:16:39 +02:00
Ghostkeeper
8bd6fe7c2b
API changed: material_profile_name instead of file_name
Contributes to issue CURA-8609.
2021-10-18 15:15:37 +02:00
Ghostkeeper
0583814dfa
Fix HttpNetworkManager not providing error parameter if there is no error
Contributes to issue CURA-8609.
2021-10-15 16:00:54 +02:00
Ghostkeeper
889000242d
Document UploadMaterialsJob class better
Including all of its signals and methods.

Contributes to issue CURA-8609.
2021-10-15 15:42:12 +02:00
Ghostkeeper
e05fa87b48
Handle errors reading material archive back in
It could be that this archive is not accessible any more for whatever reason. Write-only file systems, quarantined files, etc. Whatever the reason, Cura shouldn't crash on this because it's not in Cura's control.

Contributes to issue CURA-8609.
2021-10-15 15:24:05 +02:00
Ghostkeeper
4262dfaf5d
Better handle errors in local part of upload job
It could be that the archive fails to save because the user doesn't have access to its own temporary folder, the firewall quarantines the archive, there's not enough disk space, whatever. These errors need to be handled and not crash Cura.

Contributes to issue CURA-8609.
2021-10-15 15:17:59 +02:00
Ghostkeeper
dfcefe11cc
Use enum for printer status constants
This indicates how we're using it, and also allows for use of symbols in the code rather than strings, which integrate better with tooling.

Contributes to issue CURA-8609.
2021-10-15 14:51:07 +02:00
Ghostkeeper
24cd2046f8
Initialise _printer_metadata as a list instead of a dict
It should become a list later on, in any case.

Contributes to issue CURA-8609.
2021-10-13 10:13:06 +02:00
Ghostkeeper
af54316690
Typing fixes
Some things the CI is complaining about.

Contributes to issue CURA-8609.
2021-10-13 10:00:22 +02:00
Ghostkeeper
a703e6b882
Use lambdas instead of functools
Partialmethod is not callable apparently. I think the problem is that it's calling the method outside of the scope of the class here. I'm probably not using it right. Lambas are easier since they automatically take their scope along with them.

Contributes to issue CURA-8609.
2021-10-12 17:47:05 +02:00
Ghostkeeper
2d53a548dc
Remove superfluous error handling
If there is an error, it'll go into onError and handle the error there.

Contributes to issue CURA-8609.
2021-10-12 17:38:47 +02:00
Ghostkeeper
cf860829c7
Provide upload request metadata as body of a PUT request
Apparently the API is now a PUT request rather than a GET request. It needs a bit more metadata which can be hard-coded for our client.

Contributes to issue CURA-8609.
2021-10-12 17:21:25 +02:00
Ghostkeeper
2b6a82ecf1
Match on strings for metadata
It doesn't automatically cast these in the query.

Contributes to issue CURA-8609.
2021-10-12 17:08:58 +02:00
Ghostkeeper
3ffffad1ed
Send progress update when failed
And update all of the printer statuses to make them appear failed, if we have a general failure in an earlier stage.

Contributes to issue CURA-8609.
2021-10-12 16:15:58 +02:00
Ghostkeeper
0fa6f650f6
Expose printer status updates via progress update signal
This way we can ask the printer status from QML even if it's updated via a job on a different thread and different class and all that.

Contributes to issue CURA-8609.
2021-10-12 16:06:53 +02:00