Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
67047c006c | ||
|
|
2d872baaec | ||
|
|
a412ff42cb | ||
|
|
06cd4ead8d | ||
|
|
13995e30b7 | ||
|
|
0d6d0f7256 | ||
|
|
1e8cb55be9 | ||
|
|
e63161ae17 | ||
|
|
f41dc58d97 | ||
|
|
522abbddbe | ||
|
|
fecc162b5d | ||
|
|
accb222a92 | ||
|
|
0768e3e72b | ||
|
|
4b04e8fd79 | ||
|
|
2edd2ba887 | ||
|
|
fcef3a1bbd | ||
|
|
d1d24dba9a | ||
|
|
2c640ff8b8 | ||
|
|
0331a25ae3 | ||
|
|
326422013a | ||
|
|
9b4da62e69 | ||
|
|
c0096c41a0 | ||
|
|
b46a66caa8 | ||
|
|
6711813fef | ||
|
|
7726e5c04e | ||
|
|
495d99fbe9 | ||
|
|
a35b7cddf2 | ||
|
|
f2af5e8b86 | ||
|
|
289c3a4d0f | ||
|
|
4cb67fe72c | ||
|
|
b79fc94a4e | ||
|
|
fca626a3d6 | ||
|
|
f5a04973c4 | ||
|
|
1c9ff91bae | ||
|
|
e1e521300b | ||
|
|
c1e8bc717a | ||
|
|
22d7392769 | ||
|
|
904e7d2ecd | ||
|
|
b3173386ae | ||
|
|
1e3b8dfb2c | ||
|
|
94d172ab67 | ||
|
|
7dac6ca433 | ||
|
|
9aeeb5fecc | ||
|
|
52f65b469d | ||
|
|
0843c0fbc7 | ||
|
|
11607fbc73 | ||
|
|
1521b76090 | ||
|
|
a33a7b4d67 | ||
|
|
c00fdbf73b | ||
|
|
af32858549 | ||
|
|
d1104ddbae | ||
|
|
e2519abbbe | ||
|
|
967b3bbff8 | ||
|
|
9721aec32a | ||
|
|
68952c20bd | ||
|
|
9775d99feb | ||
|
|
bfcff9a1cd | ||
|
|
5ca286f4e3 | ||
|
|
7dae700215 | ||
|
|
58806a3d00 | ||
|
|
72cc1afb45 | ||
|
|
323131cbc5 | ||
|
|
f389773036 | ||
|
|
0a04043922 | ||
|
|
84fa3b6073 | ||
|
|
d6576306b0 | ||
|
|
8970fb42b1 | ||
|
|
55e8cc1118 | ||
|
|
43e2f79575 | ||
|
|
132e2cb244 | ||
|
|
de6d1afdd6 | ||
|
|
0a1cc68a6b | ||
|
|
f1309dad1d | ||
|
|
b353c4eee2 | ||
|
|
34c30ed73f | ||
|
|
c28faa8032 | ||
|
|
8da5bb2d42 | ||
|
|
54c885f1ad | ||
|
|
65fe048ade | ||
|
|
3574c2ddf9 | ||
|
|
1dc0f1fb31 | ||
|
|
30ddbfd324 | ||
|
|
5c522d86ca | ||
|
|
f785c8180b | ||
|
|
18e7d2b72a | ||
|
|
410c3ee5f6 | ||
|
|
48825fd4c2 | ||
|
|
ff9c83ea25 | ||
|
|
2c18a40dcb | ||
|
|
0b6dd7e76e | ||
|
|
d68c7bfc67 | ||
|
|
c879ad27f4 | ||
|
|
d1914824c6 | ||
|
|
79196eeaf7 | ||
|
|
6491db730d | ||
|
|
bd07cda205 | ||
|
|
9c7ca0ab7a | ||
|
|
c4da5d6764 | ||
|
|
47187c233d | ||
|
|
982ed793d9 | ||
|
|
718306073e | ||
|
|
df6e94f7a3 | ||
|
|
1a2739c640 | ||
|
|
9d318a4031 | ||
|
|
292d608b97 | ||
|
|
2d7cb40633 | ||
|
|
ce9315850f | ||
|
|
b8dbc627cb | ||
|
|
73df8c2407 | ||
|
|
55ec8b1809 | ||
|
|
33eba705bf | ||
|
|
9ec3a6ae7a | ||
|
|
ec2ba63425 | ||
|
|
6097222b7b | ||
|
|
40396847e3 | ||
|
|
a296574c70 | ||
|
|
547962f4bc | ||
|
|
1d2ceefb72 | ||
|
|
3d4422021e | ||
|
|
3b5c11a2bb | ||
|
|
4908d94c97 | ||
|
|
17a7e508c3 | ||
|
|
0069c94d35 | ||
|
|
99e7824913 | ||
|
|
ceade46dd7 | ||
|
|
bc66d29d02 | ||
|
|
9ea1074b03 | ||
|
|
6e069211cc | ||
|
|
8d3befb01f | ||
|
|
42a6cab92e | ||
|
|
083e424529 | ||
|
|
d5eefcd1a5 | ||
|
|
c1670d03c8 | ||
|
|
b2637eb06a | ||
|
|
47179f2956 | ||
|
|
d64b8512ab | ||
|
|
602ec5c495 | ||
|
|
a63ee9355e | ||
|
|
e44ae7a024 | ||
|
|
76ad332287 | ||
|
|
93ab7bb089 | ||
|
|
b4e7e73e29 | ||
|
|
92ad53a9ec | ||
|
|
21c9c51858 | ||
|
|
38a321e175 | ||
|
|
32050c31ae | ||
|
|
f020fc1bc6 | ||
|
|
a1e8694073 | ||
|
|
e748b52098 | ||
|
|
961b41f0fe | ||
|
|
4f59e0fd48 | ||
|
|
e441976682 | ||
|
|
864ac12097 | ||
|
|
ee854f44cc | ||
|
|
cc5c19dde9 | ||
|
|
aab629d80e | ||
|
|
4e2afbc170 | ||
|
|
8668c6200a | ||
|
|
e01f391b30 | ||
|
|
92618362e1 | ||
|
|
d071684d41 | ||
|
|
7d0bd6a339 | ||
|
|
1b5a654a2d | ||
|
|
f0ee7f343e | ||
|
|
f36a6a0409 | ||
|
|
de8be65be7 | ||
|
|
780948fe7d | ||
|
|
c27936a9db | ||
|
|
caad7a3f60 | ||
|
|
7c75c882d3 | ||
|
|
9594b75b78 | ||
|
|
3e16f0901a | ||
|
|
8866ed716d | ||
|
|
cf16392e18 | ||
|
|
34e4a20866 | ||
|
|
0f157d3747 | ||
|
|
1b3a8acf0d | ||
|
|
fdb4e75241 | ||
|
|
4dbb24ecd7 | ||
|
|
a15e2de251 | ||
|
|
c652bed871 | ||
|
|
1ed6730400 | ||
|
|
dde99736e4 | ||
|
|
334f2c35f9 | ||
|
|
aacd59ae78 | ||
|
|
253a38c32d | ||
|
|
e08becbb4c | ||
|
|
09a043b393 | ||
|
|
9eafe9979a | ||
|
|
086a2c9f82 | ||
|
|
058dbd0c2e | ||
|
|
54c8923087 | ||
|
|
0c58566789 | ||
|
|
d2917346f5 | ||
|
|
e7f1302f3c | ||
|
|
eca74233eb | ||
|
|
1025f0be43 | ||
|
|
295b96f259 | ||
|
|
adea0db344 | ||
|
|
0c4f4383e3 | ||
|
|
36fb7805e5 | ||
|
|
c7afd7951c | ||
|
|
f489f4ffd1 | ||
|
|
9f2821fe96 | ||
|
|
dcc1148863 | ||
|
|
ba96ba8fe8 | ||
|
|
02566ae9d0 | ||
|
|
8080e65366 | ||
|
|
e972026ad0 | ||
|
|
6592be63f8 | ||
|
|
8b5626e49c | ||
|
|
be4a931e32 | ||
|
|
548da0d64f | ||
|
|
45aa26f13e | ||
|
|
25f26170ff | ||
|
|
4a64bc6023 | ||
|
|
8e6773d19f | ||
|
|
dfcddea581 | ||
|
|
ff59e275bf | ||
|
|
0f8f1ec8e0 | ||
|
|
0e302d440f | ||
|
|
980616519d | ||
|
|
434751634f | ||
|
|
c35708a422 | ||
|
|
64464a38ce | ||
|
|
4c76225c41 | ||
|
|
1f4bfa854b | ||
|
|
4be18c2668 | ||
|
|
225cca34e1 | ||
|
|
9a4149164b | ||
|
|
cf9243c2e7 | ||
|
|
0e482151fd | ||
|
|
c5bf58e1cc | ||
|
|
38b7be0142 | ||
|
|
28a515ba6a | ||
|
|
b6b562399e | ||
|
|
3654512085 | ||
|
|
e7dbd804ce | ||
|
|
7fd03265d4 | ||
|
|
369679bae5 | ||
|
|
27e1f2e6e7 | ||
|
|
109cbeea6a | ||
|
|
606199dcc9 | ||
|
|
38868303da | ||
|
|
75b5fe198f | ||
|
|
fe65f18f78 | ||
|
|
e1e302f93d | ||
|
|
1cea388481 | ||
|
|
14a3d903d7 | ||
|
|
34d6a6f8ce | ||
|
|
6a03532ea7 | ||
|
|
649bfdbe37 | ||
|
|
8ce2290d63 | ||
|
|
b1413abfff | ||
|
|
772914f38c | ||
|
|
c6b4eee437 | ||
|
|
e67f72ce3d | ||
|
|
de6da3f360 | ||
|
|
b744c341eb | ||
|
|
697af69e97 | ||
|
|
601451a3f1 | ||
|
|
81d523b73d | ||
|
|
deacd9c188 | ||
|
|
3c5aa60d2b | ||
|
|
6e0024149e | ||
|
|
1b876f1cf3 | ||
|
|
580e5f5122 | ||
|
|
22f6a38f0a | ||
|
|
620aa4dfe0 | ||
|
|
dd3b318327 | ||
|
|
1ccc787222 | ||
|
|
f8e7ae7436 | ||
|
|
3ae284d9a7 | ||
|
|
caf5be562e | ||
|
|
069e83c63c | ||
|
|
0cf345f29b | ||
|
|
0fda153d60 | ||
|
|
c01a34f358 | ||
|
|
deee737660 | ||
|
|
8425c7b973 | ||
|
|
1e42db040d | ||
|
|
e2d4b64510 | ||
|
|
61136edeea | ||
|
|
7614ef40d3 | ||
|
|
935639a51a | ||
|
|
ec689e3939 | ||
|
|
84f95b1099 | ||
|
|
fd8788dd34 | ||
|
|
32a8646135 | ||
|
|
09cc7cf5f7 | ||
|
|
496e9f0ec4 | ||
|
|
18b2ecd64c | ||
|
|
cc6f61c62e | ||
|
|
de149613cb | ||
|
|
a7ca374955 | ||
|
|
61ac8430d6 | ||
|
|
6b4dfcb960 | ||
|
|
d7d3272905 | ||
|
|
9eb29a8ce0 | ||
|
|
bf16bd1180 | ||
|
|
7b5315383b | ||
|
|
72729ad418 | ||
|
|
e6f902cbe7 | ||
|
|
9b14f32279 | ||
|
|
7ad4d75588 | ||
|
|
5a623b486c | ||
|
|
920283cf87 | ||
|
|
becd16b892 | ||
|
|
f59c1ce804 | ||
|
|
c71972c0f8 | ||
|
|
47a9a40ec9 | ||
|
|
5c1fffc3d0 | ||
|
|
fe090cc6cc | ||
|
|
ab3c4ab66c | ||
|
|
1d6b7244b5 | ||
|
|
ea17566aba | ||
|
|
315ed57916 | ||
|
|
1014582b4b | ||
|
|
cf77053901 | ||
|
|
f040482b18 | ||
|
|
523fadd930 | ||
|
|
97d0fbd2c9 | ||
|
|
3b820f6848 | ||
|
|
e8b9f385b4 | ||
|
|
95bc1006a0 | ||
|
|
14ef17163f | ||
|
|
9a1bd8af87 | ||
|
|
a292a12c4a | ||
|
|
200a3ef4eb | ||
|
|
88582beb55 | ||
|
|
6d7c8bbda6 | ||
|
|
9a7f92174a | ||
|
|
61431c0df3 | ||
|
|
a301fc6da9 | ||
|
|
cc0b63cbb9 | ||
|
|
e08dc0b5aa | ||
|
|
a368a7f1c9 | ||
|
|
020403dc54 | ||
|
|
6a601d4f8e | ||
|
|
7a3b370469 | ||
|
|
e676d53e9f | ||
|
|
40b231f692 | ||
|
|
86664fdb39 | ||
|
|
4ebb5cf42d | ||
|
|
e8bee435af | ||
|
|
082f977f7a | ||
|
|
237a2c0add | ||
|
|
2e47f49f7a | ||
|
|
05919363e1 | ||
|
|
7c8547555c | ||
|
|
ce0c77f0bf | ||
|
|
aec041b014 | ||
|
|
58b32803df | ||
|
|
6d447f8408 | ||
|
|
54d359f730 | ||
|
|
4d9f0fca41 | ||
|
|
41146c2b7c | ||
|
|
99d7157cb7 | ||
|
|
c8b5662ff2 | ||
|
|
b781681e0f | ||
|
|
5edeecdc8c | ||
|
|
f82ec61463 | ||
|
|
372a8d2ea8 | ||
|
|
9c5d1dec59 | ||
|
|
feff5e0978 | ||
|
|
019bf5acd4 | ||
|
|
717aafee08 | ||
|
|
67c5a5e168 | ||
|
|
6310afa261 | ||
|
|
cd6ae6e47b | ||
|
|
b01e1c269d | ||
|
|
49fb0f87d5 | ||
|
|
8956e7a173 | ||
|
|
9fa20f0e52 | ||
|
|
6bf8384c35 | ||
|
|
1dacbc35bf | ||
|
|
7522dbed1d | ||
|
|
d433c919ec | ||
|
|
a6f701802f | ||
|
|
e03feeb7ac | ||
|
|
00068114a1 | ||
|
|
6a7e11eb7c | ||
|
|
6f987577f4 | ||
|
|
819d690bc3 | ||
|
|
dbfe487f13 | ||
|
|
21a82bbdb6 | ||
|
|
47e9afa811 | ||
|
|
f9edea0c2c | ||
|
|
8ef3d1dcad | ||
|
|
fcfef25c93 | ||
|
|
604d2f7811 | ||
|
|
727fd12939 | ||
|
|
100fe5f290 | ||
|
|
a721256204 | ||
|
|
24d2efd3ce | ||
|
|
1acf69cb6d | ||
|
|
3815c340a8 | ||
|
|
5e8220055f | ||
|
|
38eff3fe6f | ||
|
|
4e47ecabf8 | ||
|
|
c36a378b60 | ||
|
|
9a7ebde76b | ||
|
|
c23bafd788 | ||
|
|
1aea92a5f1 | ||
|
|
df9617ac1e | ||
|
|
0b23417f45 | ||
|
|
828ba56952 | ||
|
|
63723baf07 | ||
|
|
b60b20d784 | ||
|
|
1e0bdc8b8c | ||
|
|
b47b39af99 | ||
|
|
6bc4d8fca4 | ||
|
|
1e01e587f3 | ||
|
|
d8f5dd701b | ||
|
|
bee609a316 | ||
|
|
fb38c396e8 | ||
|
|
904b3c6cf5 | ||
|
|
7f2b79bcd5 | ||
|
|
dd692d6f30 | ||
|
|
5d021d76a0 | ||
|
|
5794a347f1 | ||
|
|
2db230549e | ||
|
|
01484b630a | ||
|
|
5d8535cb9c | ||
|
|
21d3622c2e | ||
|
|
008cde6ef6 | ||
|
|
4df57cd8fe | ||
|
|
f53380c04e | ||
|
|
8af45e2f21 | ||
|
|
0da47858fa | ||
|
|
abfffa3231 | ||
|
|
e056ccdf29 | ||
|
|
e334d8b073 | ||
|
|
f1673c148f | ||
|
|
ae5a1dc6dc | ||
|
|
7fcc3551ca | ||
|
|
f3fdac7e5a | ||
|
|
d8088887e1 | ||
|
|
379411cea7 | ||
|
|
5e953c12a1 | ||
|
|
bd58138acf | ||
|
|
44b4c6cc40 | ||
|
|
f3f1061f9d | ||
|
|
bba95e9000 | ||
|
|
fa81791c29 | ||
|
|
a4072723bf | ||
|
|
d451acdd4f | ||
|
|
a1a15e40e0 | ||
|
|
0c264ca0d2 | ||
|
|
9e4b0f83d8 | ||
|
|
2b8d831308 | ||
|
|
fcb0f877b8 | ||
|
|
c74e3a0a0b | ||
|
|
ea64c017e8 | ||
|
|
70a104e32a | ||
|
|
75a37f5ce7 | ||
|
|
e4d083028c | ||
|
|
6bab550830 | ||
|
|
f9916783e9 | ||
|
|
e00375e586 | ||
|
|
41fab8a36c | ||
|
|
c05b6572c5 | ||
|
|
1ae6b73f7a | ||
|
|
670ca15997 | ||
|
|
ea5ef34cc1 | ||
|
|
958fc7600d | ||
|
|
13d894e74b | ||
|
|
353309fc60 | ||
|
|
3501179257 | ||
|
|
f993f744ba | ||
|
|
68410cb3d7 | ||
|
|
db009e3ba2 | ||
|
|
09d3c44161 | ||
|
|
c2814651f9 | ||
|
|
eb46815789 | ||
|
|
449fa0c7ec | ||
|
|
0489dfeaee | ||
|
|
a9b395dac8 | ||
|
|
44a40b8297 | ||
|
|
49728f18c6 | ||
|
|
f6ec0bca6e | ||
|
|
6a069de240 | ||
|
|
2287c65784 | ||
|
|
3b26a2f7d2 | ||
|
|
18ffdcff6b | ||
|
|
faab946aeb | ||
|
|
a48e069aa6 | ||
|
|
d4d5bed514 | ||
|
|
97f84f120c | ||
|
|
cdc69ea93c | ||
|
|
467dd344cf | ||
|
|
6b9c9f47da | ||
|
|
b7f17531d2 | ||
|
|
987379d6e7 | ||
|
|
62b1d91901 | ||
|
|
7cb5013b08 | ||
|
|
06a3baa588 | ||
|
|
07934d26eb | ||
|
|
3ae97a3e13 | ||
|
|
5f22e68985 | ||
|
|
df1dc17c51 | ||
|
|
71aa405b26 | ||
|
|
2d2986922d | ||
|
|
7b5dbef166 | ||
|
|
da61a49bd8 | ||
|
|
002802bb20 | ||
|
|
45b59494ca | ||
|
|
83530ec7b9 | ||
|
|
918b70185e | ||
|
|
6aa89b77dc | ||
|
|
1679b45cd6 | ||
|
|
4728a1a5a9 | ||
|
|
c35a387520 | ||
|
|
d7aae66886 | ||
|
|
67ab9d577a | ||
|
|
d987cb23c1 | ||
|
|
10d045d743 | ||
|
|
44818993ff | ||
|
|
970b9c3384 | ||
|
|
89f94be96a | ||
|
|
52cfd93301 | ||
|
|
2a8d103dc6 | ||
|
|
d452051c0a | ||
|
|
99b32fc6c3 | ||
|
|
5b4f4e3d77 | ||
|
|
c66b451efd | ||
|
|
4e9437114b | ||
|
|
52c7321c78 | ||
|
|
ef94646083 | ||
|
|
37f3396be3 | ||
|
|
f8f461b804 | ||
|
|
5396daa7f6 | ||
|
|
bb51dc23fc | ||
|
|
2733838574 | ||
|
|
a23d92158b | ||
|
|
99225244f1 | ||
|
|
e30f1b9f82 | ||
|
|
054bbead72 | ||
|
|
30294e9009 | ||
|
|
bf5bc14c87 | ||
|
|
f6dd13af7a | ||
|
|
5760b4b264 | ||
|
|
49b995b234 | ||
|
|
8cf5ca9589 | ||
|
|
ae36a3905a | ||
|
|
bfd847f0a6 | ||
|
|
e14cb44e13 | ||
|
|
17ad63dabf | ||
|
|
ef81702219 | ||
|
|
7cbe6244ae | ||
|
|
112a8b9c8b | ||
|
|
98b692d845 | ||
|
|
f4f7c87640 | ||
|
|
39cda08d07 | ||
|
|
3a1611e5c4 | ||
|
|
5af5cbbb37 | ||
|
|
a657ebd528 | ||
|
|
e628aedbc1 | ||
|
|
7736cf1e6d | ||
|
|
41e74df8d3 | ||
|
|
ac3b8ebfcc | ||
|
|
e0543de8ef | ||
|
|
f243a52823 | ||
|
|
94013ddb70 | ||
|
|
9cfcbd3929 | ||
|
|
6cfbdc6062 | ||
|
|
d3334b29d9 | ||
|
|
94ce6f1dd1 | ||
|
|
c623e90ebc | ||
|
|
b6e49b59a7 | ||
|
|
f416e96414 | ||
|
|
347f53baa4 | ||
|
|
9ecf39febe | ||
|
|
582b03f21f | ||
|
|
ff0b94c78d | ||
|
|
f5c8b04958 | ||
|
|
36818057a3 | ||
|
|
a5cff5bc3d | ||
|
|
a4bff305b3 | ||
|
|
6b149e2fc9 | ||
|
|
38fce1665b | ||
|
|
f51a98768c | ||
|
|
4d04c323f6 | ||
|
|
94116bfd53 | ||
|
|
a05761e63f | ||
|
|
89469d38ae | ||
|
|
bd2616e888 | ||
|
|
02e996436d | ||
|
|
a3f2e0b56c | ||
|
|
337e49208a | ||
|
|
b052925424 | ||
|
|
970c867ee4 | ||
|
|
c4295d6a81 | ||
|
|
d60cab1962 | ||
|
|
b01e327f9d | ||
|
|
09af2813d0 | ||
|
|
2f69a84352 | ||
|
|
13260fa219 | ||
|
|
9a90093dda | ||
|
|
8292408c79 | ||
|
|
9165f83084 | ||
|
|
c2ef371089 | ||
|
|
fa9472d4aa | ||
|
|
037e92c447 | ||
|
|
170804d4df | ||
|
|
ac129a2576 | ||
|
|
db8d420860 | ||
|
|
7d7cbb1760 | ||
|
|
89979f1bee | ||
|
|
bd241e8e6c | ||
|
|
7939b0ae4d | ||
|
|
6b57ba2d7d | ||
|
|
2c5465f9a6 | ||
|
|
1565129cfb | ||
|
|
b8d4a58207 | ||
|
|
900f03dc8a | ||
|
|
0c4c4a9d18 | ||
|
|
ff4ed38329 | ||
|
|
5f78ab7b73 | ||
|
|
6556d555bd | ||
|
|
d318ff82b8 | ||
|
|
ff53a826f9 | ||
|
|
abb14dc17a | ||
|
|
a45c86eed1 | ||
|
|
c30380d423 | ||
|
|
d79e777911 | ||
|
|
335e635ec7 | ||
|
|
a5754a8552 | ||
|
|
a8c91ff6ba | ||
|
|
6285fd8010 | ||
|
|
c69f20c648 | ||
|
|
88c93a7c11 | ||
|
|
92629468c0 | ||
|
|
56a1d4f966 | ||
|
|
799aedcaed | ||
|
|
de42ce73f7 | ||
|
|
962e09906e | ||
|
|
f607f55683 | ||
|
|
8e464f59ac | ||
|
|
91b524813c | ||
|
|
1b45047826 | ||
|
|
edd4d90b12 | ||
|
|
0a3ad8a880 | ||
|
|
82615791a2 | ||
|
|
4548be34f0 | ||
|
|
2b5af2c36a | ||
|
|
a939130748 | ||
|
|
b7e373c40f | ||
|
|
dae0264a58 | ||
|
|
b2e50e13d4 | ||
|
|
cb4404a833 | ||
|
|
38bb81cfe7 | ||
|
|
1667f9bd52 | ||
|
|
1ec61a9fe6 | ||
|
|
98c84b6bb9 | ||
|
|
76f48b3b13 | ||
|
|
8596ae5c4a | ||
|
|
c1482eaacd | ||
|
|
e23fe4a925 | ||
|
|
8939537fb5 | ||
|
|
2f08b90200 | ||
|
|
68ca2c5e51 | ||
|
|
343195477b | ||
|
|
4caf4ef09b | ||
|
|
54677f96f4 | ||
|
|
0ba987e126 | ||
|
|
0325628693 | ||
|
|
e522633c98 | ||
|
|
e14c00f135 | ||
|
|
b0a4a49f99 | ||
|
|
5b4839369e | ||
|
|
1ff02b9f1c | ||
|
|
e2c1fa3d43 | ||
|
|
39a466e316 | ||
|
|
9e940eacc3 | ||
|
|
2e38f237de | ||
|
|
7f36ffdafd | ||
|
|
39b2da3230 | ||
|
|
c489829efb | ||
|
|
e30e129e2a | ||
|
|
32d5b25013 | ||
|
|
6227a0dfb9 | ||
|
|
e234c6146e | ||
|
|
c146731e5a | ||
|
|
5ee242be4a | ||
|
|
556878a774 | ||
|
|
00aa4876e9 | ||
|
|
f72f948744 | ||
|
|
e5e8581f9a | ||
|
|
3ad4818488 | ||
|
|
b3cc44cea5 | ||
|
|
95a9f84b39 | ||
|
|
371f1a818f | ||
|
|
4ed5f7ed28 | ||
|
|
4eb81aae9d | ||
|
|
dafa4c97ad | ||
|
|
0268cafa90 | ||
|
|
a5caac8d38 | ||
|
|
7ca9d56327 | ||
|
|
d9323b7172 | ||
|
|
8f6d67195d | ||
|
|
342d526a51 | ||
|
|
d7c5f57c98 | ||
|
|
d89ca38ee8 | ||
|
|
cb969be403 | ||
|
|
7cb649c303 | ||
|
|
6d7d365b27 | ||
|
|
8ad720e554 | ||
|
|
37190da2d6 | ||
|
|
2746139fa6 | ||
|
|
c9f10ae723 | ||
|
|
202006149c | ||
|
|
671973062e | ||
|
|
1d15c2a176 | ||
|
|
5e490ec7fd | ||
|
|
1889a40241 | ||
|
|
6d2be1743a | ||
|
|
e9e4adf09b | ||
|
|
535ad6eae6 | ||
|
|
c4167a82c5 | ||
|
|
087a9ece2c | ||
|
|
b77380a8ac | ||
|
|
169275b052 | ||
|
|
757dfcf5c7 | ||
|
|
8e39eac207 | ||
|
|
9e48b8ab65 | ||
|
|
36b07b2337 | ||
|
|
e57c46fb67 | ||
|
|
df8226b8c5 | ||
|
|
2f89082df2 | ||
|
|
e0943527d6 | ||
|
|
108db045ce | ||
|
|
025986794f | ||
|
|
ac2354907a | ||
|
|
7b5d2e3e0c | ||
|
|
efa556a812 | ||
|
|
7f9764c386 | ||
|
|
e95e546c08 | ||
|
|
b0e7df47a6 | ||
|
|
257fc0d1cd | ||
|
|
3fe2b611bc | ||
|
|
d6c63a5cb9 | ||
|
|
ad8205c386 | ||
|
|
6efd4dfd08 | ||
|
|
469bf844ee | ||
|
|
4f58c64881 | ||
|
|
b428faacc8 | ||
|
|
4e3adcc3f3 | ||
|
|
f88147003c | ||
|
|
bbbe85f737 | ||
|
|
fc97d0b424 | ||
|
|
b054ec47ad | ||
|
|
87e7a19fdd | ||
|
|
fed257b5d8 | ||
|
|
e53ae8cd56 | ||
|
|
a9f76dd1a3 | ||
|
|
6bc5b8a7a9 | ||
|
|
cb9bedb6a0 | ||
|
|
5ff790048d | ||
|
|
f32ea65b2c | ||
|
|
1f957e1ee2 | ||
|
|
32be5ca87c | ||
|
|
9cb3631ad0 | ||
|
|
743ff35bcf | ||
|
|
df706f61db | ||
|
|
791e759b40 | ||
|
|
22fdc1d933 | ||
|
|
aa383e3ca1 | ||
|
|
472fda6645 | ||
|
|
bd35de80c3 | ||
|
|
52fe19e5f9 | ||
|
|
c2f09b1715 | ||
|
|
8876ab0ce5 | ||
|
|
ad8910354c | ||
|
|
e8d6a9b221 | ||
|
|
f3cfe2ba48 | ||
|
|
d2ecb0a28f | ||
|
|
134ee77e4a | ||
|
|
10f3f72b9c | ||
|
|
1ccc1fa47b | ||
|
|
2972d38cef | ||
|
|
4662606907 | ||
|
|
2c50aa789a | ||
|
|
78b6d3a5e2 | ||
|
|
a920c4fe21 | ||
|
|
9e62b250ac | ||
|
|
52468e7e1c | ||
|
|
03722e5e70 | ||
|
|
9112a800c8 | ||
|
|
177d235b29 | ||
|
|
2de2dc7c31 | ||
|
|
8074a06d33 | ||
|
|
75c801d63f | ||
|
|
ed07764f09 | ||
|
|
a929100889 | ||
|
|
286376321c | ||
|
|
4a36a3eed2 | ||
|
|
7867052339 | ||
|
|
8a0252ccfe | ||
|
|
e84293c415 | ||
|
|
250e83ad7e | ||
|
|
660724741c | ||
|
|
a5f87597ad | ||
|
|
8bf9b8650d | ||
|
|
ebef35a573 | ||
|
|
d6da819cd6 | ||
|
|
2fbc81604a | ||
|
|
2ca63febee | ||
|
|
224674f27e | ||
|
|
2f1d71a98c | ||
|
|
7366110f07 | ||
|
|
e5eb72cbfb | ||
|
|
b0028cd3fb | ||
|
|
2343caea30 | ||
|
|
61d037f188 | ||
|
|
2a79d9183a | ||
|
|
5dbc88b6f2 | ||
|
|
83876806db | ||
|
|
5a5785be4a | ||
|
|
25cd4f8201 | ||
|
|
2d72a52338 | ||
|
|
b5a161594d | ||
|
|
a24363c4b0 | ||
|
|
524562527e | ||
|
|
26856d052f | ||
|
|
17f8817b78 | ||
|
|
4eb1d2bf80 | ||
|
|
62120affae | ||
|
|
66b501cfaa | ||
|
|
140bf9aa5a | ||
|
|
711ca457f2 | ||
|
|
07ae4ffe14 | ||
|
|
3800b21e69 | ||
|
|
196b152ec4 | ||
|
|
970810dc92 | ||
|
|
4fec14197b | ||
|
|
b354334a2e | ||
|
|
a934750504 | ||
|
|
9dc29689f4 | ||
|
|
8518b40b5f | ||
|
|
aabd624f88 | ||
|
|
6ae88ab8c6 | ||
|
|
6251031d6e | ||
|
|
249b3f442b | ||
|
|
ff6012bb00 | ||
|
|
a137946e3a | ||
|
|
909dd551d6 | ||
|
|
687b449207 | ||
|
|
efe552264c | ||
|
|
44fcd4e305 | ||
|
|
b7e788ec1b | ||
|
|
90704e292b | ||
|
|
e964d2410c | ||
|
|
09284cd9b9 | ||
|
|
97d37c5078 | ||
|
|
432090a56a | ||
|
|
1847b41f7e | ||
|
|
4963a4b849 | ||
|
|
46e425de88 | ||
|
|
376d38e0cf | ||
|
|
92c43ee6f9 | ||
|
|
cce37f0501 | ||
|
|
2e8f543aa3 | ||
|
|
d2dfd22a2c | ||
|
|
b83dd76c89 | ||
|
|
b51cb31b46 | ||
|
|
eea1050a18 | ||
|
|
71b2cc87a3 | ||
|
|
a37165d7d9 | ||
|
|
b06f804e9e | ||
|
|
d64ca79f05 | ||
|
|
490ade5e17 | ||
|
|
573503e84d | ||
|
|
9e0e4bf7b6 | ||
|
|
452645d950 | ||
|
|
d2bb731bd7 | ||
|
|
2062acd372 | ||
|
|
40b5c272c4 | ||
|
|
31e4df44f9 | ||
|
|
cd3c8ebbe6 | ||
|
|
fe13348fd3 | ||
|
|
903dd36d68 | ||
|
|
59a435a787 | ||
|
|
71cc312ccc | ||
|
|
8d1ae438e5 | ||
|
|
7ebcb47955 | ||
|
|
71e60183c5 | ||
|
|
9c055137eb | ||
|
|
eaa8933782 | ||
|
|
0d330e3c5a | ||
|
|
18ed113122 | ||
|
|
48e454856c | ||
|
|
917b86655f | ||
|
|
7a2225b332 | ||
|
|
20237a73ac | ||
|
|
4a3f894064 | ||
|
|
0c9098f7bf | ||
|
|
53a2e04501 | ||
|
|
c6f5f1a0f7 | ||
|
|
1cff2581db | ||
|
|
7ab4b90d07 | ||
|
|
fd4ff2bf37 | ||
|
|
5cf02ac9ee | ||
|
|
460481c9c2 | ||
|
|
2806676707 | ||
|
|
76f93d8875 | ||
|
|
30359f52ab | ||
|
|
0020f029d1 | ||
|
|
9559f09ec7 | ||
|
|
542edbc3e6 | ||
|
|
f82d50b0f6 | ||
|
|
e224b0ac71 | ||
|
|
68f4ecefb0 | ||
|
|
d73d930e5f | ||
|
|
8c1262dd3f | ||
|
|
792fe328ef | ||
|
|
111a37e97e | ||
|
|
c2bb234c20 | ||
|
|
0a634a76a0 | ||
|
|
41c0dac19d | ||
|
|
f728423f29 | ||
|
|
61e5184377 | ||
|
|
a2527998c2 | ||
|
|
2dda3a0e32 | ||
|
|
e2394446b0 | ||
|
|
d248df3826 | ||
|
|
1befd0ecc1 | ||
|
|
386ae7609d | ||
|
|
7587f34c94 | ||
|
|
6b54a15ed9 | ||
|
|
d391f0c12b | ||
|
|
8460a4173d | ||
|
|
fe7149c715 | ||
|
|
443647e78e | ||
|
|
dc19ad4c4c | ||
|
|
50bb0bcfd4 | ||
|
|
e15946ff79 | ||
|
|
fd94fc94a0 | ||
|
|
798bc2b225 | ||
|
|
6728302bb3 | ||
|
|
f7a3e6a6ee | ||
|
|
8eba3fef0a | ||
|
|
e93d2104fd | ||
|
|
a7aa58e524 | ||
|
|
c442906379 | ||
|
|
0834288cfc | ||
|
|
faff20943f | ||
|
|
bb0b01aa01 | ||
|
|
14661339ef | ||
|
|
8ca188e509 | ||
|
|
3da4877d50 | ||
|
|
382f10557e | ||
|
|
d9c6cca370 | ||
|
|
88a962b3ab | ||
|
|
3173783620 | ||
|
|
5d0cb14f71 | ||
|
|
60d84b7d06 | ||
|
|
abf4f90f0e | ||
|
|
93d77e6b25 | ||
|
|
fd13b18ef7 | ||
|
|
13ab34a5c8 | ||
|
|
033e567d2a | ||
|
|
2a67772f46 | ||
|
|
f69718b060 | ||
|
|
a97b8c2fd9 | ||
|
|
08c384ac68 | ||
|
|
00354f4a1e | ||
|
|
d03d4b7b4c | ||
|
|
1a9b6c01a6 | ||
|
|
c4dc7d0f55 | ||
|
|
38ddd3102d | ||
|
|
6dd501217a | ||
|
|
5a60af9d13 | ||
|
|
887304fe18 | ||
|
|
2bd8aa00f3 | ||
|
|
e58387b4f2 | ||
|
|
1de58b7be1 | ||
|
|
58d8deefcd | ||
|
|
cb8ce62ec4 | ||
|
|
e49a4d8cfa | ||
|
|
fdf0f75ffa | ||
|
|
5fb8674937 | ||
|
|
d3871e3487 | ||
|
|
9dd9badb33 | ||
|
|
3de9635180 | ||
|
|
e2f626d421 | ||
|
|
b7a8c29fb4 | ||
|
|
15f10d4a84 | ||
|
|
0faf2792e9 | ||
|
|
caa1a3d76f | ||
|
|
fae01d2c75 | ||
|
|
248235c5e0 | ||
|
|
2febfcd8b3 | ||
|
|
704331525f | ||
|
|
6c279f155a | ||
|
|
e5afde2c2c | ||
|
|
f5b99a6e34 | ||
|
|
8ef13ba529 | ||
|
|
654055da61 | ||
|
|
68f67219ed | ||
|
|
436ffb6db8 | ||
|
|
b569cc456b | ||
|
|
023b9eda90 | ||
|
|
fe2dbf699d | ||
|
|
17c6c83503 | ||
|
|
688e4d36d1 | ||
|
|
86b886ede7 | ||
|
|
392149b504 | ||
|
|
acd05cdcc5 | ||
|
|
1a67b5b3fc | ||
|
|
473d4a752a | ||
|
|
33a5e389fd | ||
|
|
287a13b944 | ||
|
|
5282db6871 | ||
|
|
b79618d752 | ||
|
|
391930e2cb | ||
|
|
4630cc8ee0 | ||
|
|
4e83466af3 | ||
|
|
b7e08c7ddc | ||
|
|
85ef3f1df2 | ||
|
|
6e44149284 | ||
|
|
534f3aa2d4 | ||
|
|
13e5cf45ec | ||
|
|
4cb103e042 | ||
|
|
701208484a | ||
|
|
02252d1254 | ||
|
|
8347f182ef | ||
|
|
7e4faa20b7 | ||
|
|
717eef25da | ||
|
|
31fbebdbb9 | ||
|
|
afe224ae08 | ||
|
|
d09f75a815 | ||
|
|
812ce40e35 | ||
|
|
f8e6e4e3db | ||
|
|
db81bf1e72 | ||
|
|
9c89c4c999 | ||
|
|
d133bd47e5 | ||
|
|
90391d2897 | ||
|
|
66cad78c41 | ||
|
|
4e91f47e8b | ||
|
|
4b753d03dc | ||
|
|
6f18749df1 | ||
|
|
eab0ce8aee | ||
|
|
ba00b4d675 | ||
|
|
9bc8638d80 | ||
|
|
d124efdb71 | ||
|
|
4f1b781219 | ||
|
|
6673536e10 | ||
|
|
118afd4720 | ||
|
|
a0cbc10ba7 | ||
|
|
38b7640769 | ||
|
|
b266f1ca55 | ||
|
|
0ef0eff917 | ||
|
|
fd29efe88e | ||
|
|
cd3acfb384 | ||
|
|
f9548a7ece | ||
|
|
ce5275c91e | ||
|
|
d9c8351025 | ||
|
|
73a16f6075 | ||
|
|
a92372ec7e | ||
|
|
4967d19b6a | ||
|
|
8a1db8e4c5 | ||
|
|
7b773f6fd2 | ||
|
|
0d120b2977 | ||
|
|
bf71a20ac1 | ||
|
|
846d3a63bc | ||
|
|
15d6bf3a70 | ||
|
|
cec1bc6c0f | ||
|
|
69681a27d6 | ||
|
|
0adcfc693d | ||
|
|
b73507fd2b | ||
|
|
bea6bd013c | ||
|
|
5456f5a70a | ||
|
|
9a881012e2 | ||
|
|
d62df7643b | ||
|
|
e980444f86 | ||
|
|
7d40320a5b | ||
|
|
09456b923f | ||
|
|
39e6c11c39 | ||
|
|
5aef014773 | ||
|
|
9738884ff8 | ||
|
|
27b625a614 | ||
|
|
9d1f4fb126 | ||
|
|
096e9fc326 | ||
|
|
f577d6b45d | ||
|
|
bd7a28af5b | ||
|
|
104b0a504c | ||
|
|
40bfbe0d7b | ||
|
|
4bf5984ace | ||
|
|
4b64fb7f47 | ||
|
|
7e11104b9c | ||
|
|
3de5bca48b | ||
|
|
81471df419 | ||
|
|
99ef84788a | ||
|
|
bfbf9fb66e | ||
|
|
6074a3d964 | ||
|
|
74e82afa24 | ||
|
|
2b5c14b3c3 | ||
|
|
e5b167bcb4 | ||
|
|
a70928aac6 | ||
|
|
7548e7a623 | ||
|
|
8d9034b5a4 | ||
|
|
b5194ffc00 | ||
|
|
fa6cda3356 | ||
|
|
4d9ec9a7e3 | ||
|
|
e44a2fdd97 | ||
|
|
95ac669d5c | ||
|
|
5e899204f0 | ||
|
|
c3eebdb158 | ||
|
|
8369d311bf | ||
|
|
13b85fbbd0 | ||
|
|
ddd2711f95 | ||
|
|
9addbbb9a1 | ||
|
|
735e2c6c94 | ||
|
|
9d2ee2b55b | ||
|
|
7988e7487f | ||
|
|
4bbe49ac6d | ||
|
|
9e32439f44 | ||
|
|
3ebb36f877 | ||
|
|
d8eb57548d | ||
|
|
d8072f0e05 | ||
|
|
3d7016f500 | ||
|
|
41e3a0390f | ||
|
|
42a9a1976d | ||
|
|
569991e55c | ||
|
|
b2996f10ff | ||
|
|
42fb4f4700 | ||
|
|
52934602cd | ||
|
|
2a0eda5c34 | ||
|
|
a3b3fbe269 | ||
|
|
2fe177ffb8 | ||
|
|
d8bc75222f | ||
|
|
c3bb651d9e | ||
|
|
135cf6a9cc | ||
|
|
be4b98b9da | ||
|
|
673b367902 | ||
|
|
81626ceec5 | ||
|
|
b653ee59c8 | ||
|
|
79abe31a06 | ||
|
|
30a523b8c1 | ||
|
|
c104f45b16 | ||
|
|
a9bc814016 | ||
|
|
edd00cfa80 | ||
|
|
60baf54d7b | ||
|
|
536f5458bb | ||
|
|
a4cc3a9309 | ||
|
|
b7adf115ee | ||
|
|
f72b92caff | ||
|
|
d3e7842c3a | ||
|
|
555bdefd46 | ||
|
|
7cf0f552f5 | ||
|
|
246c614635 | ||
|
|
df62f08ec3 | ||
|
|
b6f71eeb3b | ||
|
|
e2a7e07a0a | ||
|
|
b3acd36092 | ||
|
|
7a037b9c66 | ||
|
|
c1cf359b43 | ||
|
|
206c22f6aa | ||
|
|
14959c2d66 | ||
|
|
eb3760715f | ||
|
|
e02679a587 | ||
|
|
4064b3fc72 | ||
|
|
e3f2a16e92 | ||
|
|
2d883d6d20 | ||
|
|
a9441400b3 | ||
|
|
09781613ce | ||
|
|
63b63f6aad | ||
|
|
1637187c76 | ||
|
|
303ef405bb | ||
|
|
bf3da2a662 | ||
|
|
b8194ecc84 | ||
|
|
472ab367b0 | ||
|
|
8f50180543 | ||
|
|
2fa18f5855 | ||
|
|
11eae082fc | ||
|
|
885446328d | ||
|
|
8cb4d84905 | ||
|
|
a4ce92c963 | ||
|
|
0da52cb366 | ||
|
|
57ea18a9a4 | ||
|
|
c84d39a803 | ||
|
|
06478415b5 | ||
|
|
6a8a1c31e3 | ||
|
|
cce7961ee3 | ||
|
|
725227338a | ||
|
|
c55c568bbd | ||
|
|
45d8c28883 | ||
|
|
8076e59861 | ||
|
|
d59eaa2a91 | ||
|
|
f7ad87449a | ||
|
|
b41df46491 | ||
|
|
08bfae216c | ||
|
|
64db784d8d | ||
|
|
5a91b8db48 | ||
|
|
5205d2e352 | ||
|
|
9c923be5f0 | ||
|
|
88328bbe0e | ||
|
|
132614045c | ||
|
|
a33b037364 | ||
|
|
33b27e450f | ||
|
|
a5d541dafc | ||
|
|
258f3725bf | ||
|
|
c4d8e344d1 | ||
|
|
f3128a15d9 | ||
|
|
6f224bd825 | ||
|
|
58bbbc2ad9 | ||
|
|
75de062b55 | ||
|
|
58f73f3ed9 | ||
|
|
85dfcbd156 | ||
|
|
a6cec7d2ef | ||
|
|
6d7f8a2a64 | ||
|
|
8869748ecc | ||
|
|
e0b0f2ae18 | ||
|
|
440ccf165e | ||
|
|
7e0b187cb8 | ||
|
|
025f545ef7 | ||
|
|
6af1afb546 | ||
|
|
1dd1eb3768 | ||
|
|
77d126fc09 | ||
|
|
4a3902c060 | ||
|
|
83cdd4d79d | ||
|
|
1d1191eae0 | ||
|
|
1efa0fa1e6 | ||
|
|
1852578136 | ||
|
|
085424f192 | ||
|
|
db23bed00b | ||
|
|
fdb2ba8146 | ||
|
|
9c31fa88a5 | ||
|
|
c5439da9d2 | ||
|
|
e5caa3d0bf | ||
|
|
a821346b07 | ||
|
|
561bf83d88 | ||
|
|
baf8941f31 | ||
|
|
f7dec5542b | ||
|
|
6ec8b97ddb | ||
|
|
0ac9ea518c | ||
|
|
9f80aefcc9 | ||
|
|
c1fe8f5a35 | ||
|
|
fcecb5c0f0 | ||
|
|
25005b547c | ||
|
|
35343705ca | ||
|
|
22e894c245 | ||
|
|
4ef01610d0 | ||
|
|
bb065828f2 | ||
|
|
d0637f61d4 | ||
|
|
84319366d1 | ||
|
|
92ea6ee9aa | ||
|
|
2152c401bf | ||
|
|
dbfe7fece1 | ||
|
|
9c5d996ea2 | ||
|
|
b8e7cfb506 | ||
|
|
822f757f9d | ||
|
|
b04aff7d5e | ||
|
|
0070349d66 | ||
|
|
0cbad44055 | ||
|
|
2571d32134 | ||
|
|
64ee8bac60 | ||
|
|
da392b9c9f | ||
|
|
3179a1846f | ||
|
|
b3912b2281 | ||
|
|
db14723ea2 | ||
|
|
28831a68dd | ||
|
|
fb4e95bf8e | ||
|
|
6f18495395 | ||
|
|
028425542f | ||
|
|
339d1df5a9 | ||
|
|
2abe67a24c | ||
|
|
fc2ef8a09c | ||
|
|
0809540bd7 | ||
|
|
47267abcd1 | ||
|
|
23f130da58 | ||
|
|
3a71d39785 | ||
|
|
c41aecc2b8 | ||
|
|
9af6b42bdd | ||
|
|
7cb910a69a | ||
|
|
c30db16085 | ||
|
|
832a0c88aa | ||
|
|
972c2823a0 | ||
|
|
f10bfa67ca | ||
|
|
fb834f81ee | ||
|
|
957ba43320 | ||
|
|
133850f61c | ||
|
|
f782cfe83f | ||
|
|
70254e910c | ||
|
|
f981cca47e | ||
|
|
06f62bd874 | ||
|
|
23bcbba013 | ||
|
|
cb18d3fe32 | ||
|
|
95694453f4 | ||
|
|
0825e0660f | ||
|
|
0224037478 | ||
|
|
819d4d0fdf | ||
|
|
cedbf039d2 | ||
|
|
d1711f0376 | ||
|
|
1c43e193ba | ||
|
|
047b9f544a | ||
|
|
4f1cd6b3a2 | ||
|
|
e4914b8bd3 | ||
|
|
da2c9632ea | ||
|
|
8a3a87efac | ||
|
|
8cdae335a2 | ||
|
|
75ad9aeeb6 | ||
|
|
709f7a76f1 | ||
|
|
c04fade9a7 | ||
|
|
2ecbd9f8c8 | ||
|
|
3e24b68b45 | ||
|
|
46a0c3057f | ||
|
|
902407ed92 | ||
|
|
ccbe9311d7 | ||
|
|
8ea7528d41 | ||
|
|
82dffa50f7 | ||
|
|
0d51e5bb1c | ||
|
|
fd7fbcc113 | ||
|
|
5791562c6a | ||
|
|
6582740a1e | ||
|
|
73ce6f43ab | ||
|
|
bc746a49e9 | ||
|
|
e8d5449a8f | ||
|
|
01f5a58709 | ||
|
|
61769262f6 | ||
|
|
faa8174846 | ||
|
|
0eb441058e | ||
|
|
32a31a7d4a | ||
|
|
01bae0c95c | ||
|
|
ada873be1d | ||
|
|
a95407c815 | ||
|
|
e0722e6c28 | ||
|
|
e32aa3f2c8 | ||
|
|
8e764e34ee | ||
|
|
cfb0eb84e2 | ||
|
|
effefffe74 | ||
|
|
8148fd7679 | ||
|
|
f8079c3f50 | ||
|
|
4c3e44d50e | ||
|
|
a2ccf414e6 | ||
|
|
02c42ecdc0 | ||
|
|
c6dfdf8d4b | ||
|
|
10af43285b | ||
|
|
25dc4528af | ||
|
|
bb61bbb2b4 | ||
|
|
e6ec48b8a1 | ||
|
|
98c7ad0c20 | ||
|
|
52bb94e272 | ||
|
|
e0f8ae8986 | ||
|
|
291fa88a82 | ||
|
|
88b622e282 | ||
|
|
3fcd5adfbd | ||
|
|
1f9c9bed42 | ||
|
|
f1401d3f1e | ||
|
|
5216729834 | ||
|
|
bab4782b8c | ||
|
|
eada72a4d9 | ||
|
|
088b4a8059 | ||
|
|
90aa5ed3d4 | ||
|
|
3c8d2f2df5 | ||
|
|
283c44e35e | ||
|
|
125673b846 | ||
|
|
fb6ff04013 | ||
|
|
6a3f1d28fb | ||
|
|
2abff3b589 | ||
|
|
c84f49e852 | ||
|
|
de0660f678 | ||
|
|
ee36e2abd3 | ||
|
|
11eb731b3d | ||
|
|
01d37fc9ee | ||
|
|
59cbfaf8ff | ||
|
|
b8e4ac21d0 | ||
|
|
2db2532c2f | ||
|
|
d42c74d34a | ||
|
|
551d6aab68 | ||
|
|
2c87133f3d | ||
|
|
296af89b02 | ||
|
|
18ad764ef5 | ||
|
|
ec86b3328e | ||
|
|
820ad59539 | ||
|
|
b3fff6e95f | ||
|
|
763888e83a | ||
|
|
c6bb825f7e | ||
|
|
c3ba9c8453 | ||
|
|
a3ba266a6b | ||
|
|
9a8b8d86d5 | ||
|
|
b108fc939c | ||
|
|
40082456c1 | ||
|
|
43bf55d503 | ||
|
|
b9a5e1db69 | ||
|
|
03d421c629 | ||
|
|
066e7d1e39 | ||
|
|
4fd641dc74 | ||
|
|
541844ce3c | ||
|
|
33147b0305 | ||
|
|
55f5c472a0 | ||
|
|
d166bafa8d | ||
|
|
00e6a3856f | ||
|
|
1587ee6402 | ||
|
|
eadb4a5bb6 | ||
|
|
5c63e618b1 | ||
|
|
be3907c7d1 | ||
|
|
8732ec9756 | ||
|
|
7d3d3408eb | ||
|
|
6afb291440 | ||
|
|
522ee49b5b | ||
|
|
de9fdf79c4 | ||
|
|
26dbf59251 | ||
|
|
8ad0aadb52 | ||
|
|
87921061d9 | ||
|
|
6812001639 | ||
|
|
00616a3d73 | ||
|
|
a7a78c11d4 | ||
|
|
60c7974aa4 | ||
|
|
441db2dbbc | ||
|
|
066d3d7422 | ||
|
|
98b71a5870 | ||
|
|
77989d2a76 | ||
|
|
f35fe32a92 | ||
|
|
b79f669351 | ||
|
|
528bd90d02 | ||
|
|
b8d23c8bc1 | ||
|
|
bb822fb9dd | ||
|
|
77aeb6146e | ||
|
|
de253e5086 | ||
|
|
986591aed4 | ||
|
|
48f87b2979 | ||
|
|
ec12bd7cd4 | ||
|
|
b3b19dc136 | ||
|
|
9f1abee023 | ||
|
|
fca7005bfa | ||
|
|
fcf7358855 | ||
|
|
c050bd15ac | ||
|
|
3e236dc57d | ||
|
|
aa0ea299ea | ||
|
|
57a58b3bd7 | ||
|
|
67005577b7 | ||
|
|
b1f9e070a4 | ||
|
|
b5aae0b8fa | ||
|
|
1b5b243760 | ||
|
|
6545f9a816 | ||
|
|
c11288ff65 | ||
|
|
ed70944f69 | ||
|
|
16b690089d | ||
|
|
88cb28cec9 | ||
|
|
15c390b199 | ||
|
|
a77fbfe0c2 | ||
|
|
8b09b11faa | ||
|
|
bad3612ed2 | ||
|
|
b079978384 | ||
|
|
b36a776f51 | ||
|
|
13558c01f9 | ||
|
|
777c02135e | ||
|
|
793bb714eb | ||
|
|
8229842334 | ||
|
|
ef6b39757b | ||
|
|
2cae028d47 | ||
|
|
38a711ac56 | ||
|
|
a8747f7e36 | ||
|
|
17e6f5d508 | ||
|
|
133a4658ee | ||
|
|
0a2e2ed297 | ||
|
|
86934c8863 | ||
|
|
13eb5ec7ed | ||
|
|
6ce6160f3d | ||
|
|
9c39dd7303 | ||
|
|
9bdbb930ad | ||
|
|
6b41dbc12b | ||
|
|
3f4a70cf92 | ||
|
|
41eb9481b3 | ||
|
|
743d590d52 | ||
|
|
900e8a2aaf | ||
|
|
06816fb8dc | ||
|
|
cc0a17f2ac | ||
|
|
9b1b4420a3 | ||
|
|
263925625b | ||
|
|
f72dfb48e1 | ||
|
|
e064400900 | ||
|
|
eb5a3d1d36 | ||
|
|
03d24ff3b9 | ||
|
|
107954021b | ||
|
|
99e1c3ac00 | ||
|
|
2ea8981a48 | ||
|
|
d1f54b5a22 | ||
|
|
1c55a12207 | ||
|
|
58dba3a79a | ||
|
|
e9d17f0f0f | ||
|
|
4ea76f84c5 | ||
|
|
ac345daba2 | ||
|
|
3cf694a333 | ||
|
|
26c8c5f03f | ||
|
|
f2bd5d605e | ||
|
|
0560e9da02 | ||
|
|
cec8d15b46 | ||
|
|
38c9840e30 | ||
|
|
f77e49be7f | ||
|
|
d465f23309 | ||
|
|
00cb71898a | ||
|
|
328c08b775 | ||
|
|
ca7aa322c3 | ||
|
|
5c20e264e2 | ||
|
|
987a6b3cf8 | ||
|
|
6b3d68f9aa | ||
|
|
fcd34265c8 | ||
|
|
088b0cf1e7 | ||
|
|
e6061fdd9c | ||
|
|
aa65671ac7 | ||
|
|
cf8a30cc4e | ||
|
|
6ba1e10b8b | ||
|
|
2a96864c07 | ||
|
|
14bd0632c0 | ||
|
|
48fceac0fe | ||
|
|
d174d7ab80 | ||
|
|
a2d38016ec | ||
|
|
cf25291dee | ||
|
|
ad246deb9e | ||
|
|
6d4f8266cd | ||
|
|
991dab58d5 | ||
|
|
0de0e4ea9b | ||
|
|
9b3c1947d9 | ||
|
|
364d692db2 | ||
|
|
b002e41a00 | ||
|
|
f3080daa47 | ||
|
|
06ab173b21 | ||
|
|
26789a2bb7 | ||
|
|
4a5308b4ab | ||
|
|
c2509fad9c | ||
|
|
eeb216e08d | ||
|
|
2761608c1e | ||
|
|
f4eb60dc6a | ||
|
|
a0a8d641c3 | ||
|
|
27536388f2 | ||
|
|
21c8bd54f5 | ||
|
|
fa5619fad7 | ||
|
|
e32f469de4 | ||
|
|
8bc99f928c | ||
|
|
6221175649 | ||
|
|
b252da477c | ||
|
|
022c59a094 | ||
|
|
bc8abdfc62 | ||
|
|
d8cffc4b22 | ||
|
|
312760f86a | ||
|
|
5ea22c602c | ||
|
|
8a977e8777 | ||
|
|
65753a0539 | ||
|
|
f1518e6fe6 | ||
|
|
c7e248b142 | ||
|
|
59ca2188d9 | ||
|
|
7540aa6b72 | ||
|
|
c479c5455c | ||
|
|
84cc89832b | ||
|
|
9554079e4b | ||
|
|
481faf8da1 | ||
|
|
fd6c7cd48f | ||
|
|
9441ea572d | ||
|
|
0414e4a6a6 | ||
|
|
ebfc6f2f26 | ||
|
|
0b1db60d8b | ||
|
|
f9c738541f | ||
|
|
6c21911eb0 | ||
|
|
fd7fdec565 | ||
|
|
b892b43ee1 | ||
|
|
14c1dfe9a3 | ||
|
|
1180e4e27b | ||
|
|
b2d70de144 | ||
|
|
0bb343e1d3 | ||
|
|
92b048c789 | ||
|
|
a6eac3911b | ||
|
|
80bc82df55 | ||
|
|
651a8f315b | ||
|
|
158f14df89 | ||
|
|
93a80fe256 | ||
|
|
398e10588c | ||
|
|
6d1f610085 | ||
|
|
bd95dad85e | ||
|
|
bf8301bd6a | ||
|
|
231006ab26 | ||
|
|
69f9c523f9 | ||
|
|
2364474ea6 | ||
|
|
00067768da | ||
|
|
744f4d0f42 | ||
|
|
ad269751b8 | ||
|
|
4c77f07bc9 | ||
|
|
e974cb8ec5 | ||
|
|
48c02e1018 | ||
|
|
3ef97bf4d7 | ||
|
|
5aad696c5c | ||
|
|
9837f67140 | ||
|
|
dc53942015 | ||
|
|
79581c390a | ||
|
|
c30e54d75c | ||
|
|
55adb7ca33 | ||
|
|
980b72607e | ||
|
|
ce16f861b3 | ||
|
|
51406b7c42 | ||
|
|
2fcbf49348 | ||
|
|
5f34d5df27 | ||
|
|
a0df4e78b5 | ||
|
|
f398ee90b0 | ||
|
|
23fcdc0365 | ||
|
|
e91da1cd8d | ||
|
|
4e0d3725cb | ||
|
|
f45cb1560f | ||
|
|
7214b9f2c2 | ||
|
|
37990996b7 | ||
|
|
772ee76e76 | ||
|
|
024b58097e | ||
|
|
2cc1fe7fe2 | ||
|
|
e0cd48df92 | ||
|
|
d45d2f5123 | ||
|
|
532ac0264d | ||
|
|
caaaa2e4e9 | ||
|
|
02aad445aa | ||
|
|
eb5e2c94a3 | ||
|
|
ced74f5b45 | ||
|
|
01e557a689 | ||
|
|
b8b01558ce | ||
|
|
bf7d4173cd | ||
|
|
0ff0da4a7b | ||
|
|
08c90e0909 | ||
|
|
b2552795dc | ||
|
|
4b5eff5ec6 | ||
|
|
bedcbb80be | ||
|
|
09509ca61d | ||
|
|
8bf3f4ff50 | ||
|
|
2d925a2665 | ||
|
|
490ef61e19 | ||
|
|
a1548e1c1d | ||
|
|
77e48335da | ||
|
|
14b8fd7fa5 | ||
|
|
0afa854763 | ||
|
|
052408982a | ||
|
|
68c57cc4eb | ||
|
|
3d1f3be4fc | ||
|
|
9eb4f3f843 | ||
|
|
4ad7b38648 | ||
|
|
ce2463588d | ||
|
|
9804e3eca0 | ||
|
|
e9fb3a3ebb | ||
|
|
b65b97870f | ||
|
|
0c243e0dc2 | ||
|
|
d88b1fbec0 | ||
|
|
38c410f80f | ||
|
|
46bd2ce7e9 | ||
|
|
10fc631700 | ||
|
|
8f78784be3 | ||
|
|
4479dd0222 | ||
|
|
9466e5d001 | ||
|
|
4b3d883639 | ||
|
|
4439f5aad0 | ||
|
|
cb50646134 | ||
|
|
0781cb1d41 | ||
|
|
eb2ed341a2 | ||
|
|
e5f6824304 | ||
|
|
c8e5820c7d | ||
|
|
8e03dbfa14 | ||
|
|
8372b1f433 | ||
|
|
b6cf895c56 | ||
|
|
25e05418d8 | ||
|
|
2e134ba8b0 | ||
|
|
76f4ffc0a1 | ||
|
|
21cc58ad14 | ||
|
|
b65a3bb903 | ||
|
|
e49adcac85 | ||
|
|
813c2be35a | ||
|
|
3ad4b7b0a5 | ||
|
|
e7b455f880 | ||
|
|
a9819cc2f9 | ||
|
|
0b95894da1 | ||
|
|
9c3d7bbbc3 | ||
|
|
01b3b8a0e0 | ||
|
|
50983c8524 | ||
|
|
e99f762974 | ||
|
|
468155c9c8 | ||
|
|
880124bbe0 | ||
|
|
7df78defb1 | ||
|
|
b719fd1c15 | ||
|
|
d0aa81c977 | ||
|
|
13de4b4b1d | ||
|
|
4fba88d197 | ||
|
|
77753ca026 | ||
|
|
fd53f47f86 | ||
|
|
af4f97f2df | ||
|
|
44f5916cd4 | ||
|
|
4e80d69e51 | ||
|
|
020180a4a7 | ||
|
|
a21934abba | ||
|
|
42ac133436 | ||
|
|
464b431741 | ||
|
|
42018ae29a | ||
|
|
054bbd8a9b | ||
|
|
4093995ba0 | ||
|
|
ff0e4f50da | ||
|
|
d1fdbd5080 | ||
|
|
abfcc6e5aa | ||
|
|
b89b6970c6 | ||
|
|
40eb3c1072 | ||
|
|
178131945e | ||
|
|
452ee8e156 | ||
|
|
8ba23e84ca | ||
|
|
807b44a35e | ||
|
|
f4e7ab424b | ||
|
|
e88e6ba292 | ||
|
|
25c56a5402 | ||
|
|
4cbddf66d3 | ||
|
|
c5e7212fa2 | ||
|
|
0f8f4579d6 | ||
|
|
12126621c5 | ||
|
|
a093dbc36f | ||
|
|
0f325b95c1 | ||
|
|
7fc0f48659 | ||
|
|
dfe345007e | ||
|
|
4fe6e0545a | ||
|
|
c84e199e87 | ||
|
|
9ba9c3b9c5 | ||
|
|
791f0457fb | ||
|
|
56ad1841d4 | ||
|
|
adbcc07bae | ||
|
|
b161a1f093 | ||
|
|
79f7a5a1e7 | ||
|
|
679674df22 | ||
|
|
5989d243d3 | ||
|
|
97cb0088f6 | ||
|
|
2ed36ed383 | ||
|
|
12b8a54081 | ||
|
|
a35e145649 | ||
|
|
f77be701a2 | ||
|
|
e9401b7090 | ||
|
|
b138c2bccf | ||
|
|
76c2113ad4 | ||
|
|
bfe5bc179c | ||
|
|
d7298cee06 | ||
|
|
fbcbb3f5f7 | ||
|
|
0c2169dd9c | ||
|
|
7828258fdb | ||
|
|
edb4d0fe04 | ||
|
|
69dec6e83f | ||
|
|
4d27de032d | ||
|
|
7073c12444 | ||
|
|
60be6349f5 | ||
|
|
ec55890c55 | ||
|
|
83ed6a4297 | ||
|
|
1c07974f6c | ||
|
|
c3e430b472 | ||
|
|
a8fef06aa8 | ||
|
|
281eb346a5 | ||
|
|
15c8bd7d6d | ||
|
|
d0d1da3456 | ||
|
|
7c73ff78bc | ||
|
|
e508898564 | ||
|
|
c33e9e4c85 | ||
|
|
1f9fe8c868 | ||
|
|
8f2e4ad978 | ||
|
|
b82d955ec7 | ||
|
|
832d2f4155 | ||
|
|
c336452f6c | ||
|
|
a9b6edde2b | ||
|
|
d59ef5c711 | ||
|
|
375480c707 | ||
|
|
60cacb9447 | ||
|
|
e0309dc6c0 | ||
|
|
cd6009c180 | ||
|
|
a21f5c4497 | ||
|
|
c159ab7fe2 | ||
|
|
251ed7a2a2 | ||
|
|
e949e0198f | ||
|
|
29bd4e96d6 | ||
|
|
5d5ca0d7aa | ||
|
|
e7df4b8d6d | ||
|
|
1a6dbb3f4a | ||
|
|
10e834f623 | ||
|
|
5ce34f774e | ||
|
|
0456896d71 | ||
|
|
e06c09e206 | ||
|
|
a6d3299b91 | ||
|
|
0a7f2a209b | ||
|
|
67f7580506 | ||
|
|
aab3a7bd63 | ||
|
|
d0f5592421 | ||
|
|
bb6ea4d81b | ||
|
|
7e32e5be8f | ||
|
|
266cae3509 | ||
|
|
0dcbffb9d2 | ||
|
|
fb8c56be57 | ||
|
|
2bc0c4a77f | ||
|
|
187c09e7da | ||
|
|
5c62b33967 | ||
|
|
5db9acb359 | ||
|
|
962d6ab27f | ||
|
|
21699699b6 | ||
|
|
8fec0859d9 | ||
|
|
1b9ff1b0e2 | ||
|
|
ee2d644239 | ||
|
|
a50db4b08e | ||
|
|
6f5707a0fc | ||
|
|
fbd8a97ffd | ||
|
|
4147ffa503 | ||
|
|
cf053ddbed | ||
|
|
b1101f5150 | ||
|
|
3a9d581423 | ||
|
|
142a1b0dcb | ||
|
|
a33f44ea25 | ||
|
|
23e58d2fc1 | ||
|
|
be2ef79686 | ||
|
|
2e897f19ac | ||
|
|
16e96743c5 | ||
|
|
4c6c764c5c | ||
|
|
e86ba9a395 | ||
|
|
c1c09d417d | ||
|
|
f8d225a768 | ||
|
|
4c3f4c2a8b | ||
|
|
cc3d34635e | ||
|
|
c81c93896b | ||
|
|
120406d115 | ||
|
|
d72ae6102b | ||
|
|
4adfad8708 | ||
|
|
2e6d65378f | ||
|
|
3cdc59d7f1 | ||
|
|
5156cdbe68 | ||
|
|
4ec1a9af39 | ||
|
|
1109bd35e7 | ||
|
|
0915c45f72 | ||
|
|
b2c1bb4b53 | ||
|
|
3bb06a1a33 | ||
|
|
8ad165c625 | ||
|
|
841b86a017 | ||
|
|
c0c249ece9 | ||
|
|
5fc194accd | ||
|
|
ed6c01c12a | ||
|
|
e309646504 | ||
|
|
96ee80afd2 | ||
|
|
8aec836d22 | ||
|
|
697df4f3ce | ||
|
|
ac3f4d598c | ||
|
|
836fbef6d8 | ||
|
|
ce4cf38547 | ||
|
|
38a5da1c35 | ||
|
|
b205e84d4b | ||
|
|
7ab4d12548 | ||
|
|
f6c3e5991d | ||
|
|
188b59a319 | ||
|
|
b3594e367e | ||
|
|
12d40122d1 | ||
|
|
2e11a7b860 | ||
|
|
f20185db3a | ||
|
|
0db323d0c5 | ||
|
|
639d8d4c5f | ||
|
|
5e0b53b651 | ||
|
|
1ebfa4b1dd | ||
|
|
35c45df86c | ||
|
|
a50e8bbbb5 | ||
|
|
4665070601 | ||
|
|
b34fc8e05e | ||
|
|
a3ece229f2 | ||
|
|
fc53febb87 | ||
|
|
dad956b5c9 | ||
|
|
981110d4b2 | ||
|
|
81efd3251c | ||
|
|
24dc12023b | ||
|
|
cbd94a9020 | ||
|
|
77db00a2ea | ||
|
|
f53be57f0d | ||
|
|
9db4559b0c | ||
|
|
23a249ca0f | ||
|
|
665078e1a4 | ||
|
|
cfae406a4c | ||
|
|
00c14e6936 | ||
|
|
6a1b162e7b | ||
|
|
a2fd39b3c4 | ||
|
|
bda2fd94e3 | ||
|
|
3171958a8c | ||
|
|
9e207ca8a1 | ||
|
|
5d321926bb | ||
|
|
3d3e0212c6 | ||
|
|
e3d44d7d06 | ||
|
|
d39c124f35 | ||
|
|
8603ea4b6f | ||
|
|
422f1b2b5e | ||
|
|
a681048df6 | ||
|
|
d689496802 | ||
|
|
fed3ec9616 | ||
|
|
5a23b46c11 | ||
|
|
2b96e57923 | ||
|
|
885e88a5e0 | ||
|
|
fe481e12b3 | ||
|
|
cbdf85c27a | ||
|
|
751867d5b8 | ||
|
|
674637f6b2 | ||
|
|
9056f5d610 | ||
|
|
0feae3ba18 | ||
|
|
1cc3ddb03c | ||
|
|
33cafbbd8a | ||
|
|
c4fcc59efd | ||
|
|
528bbba6ed | ||
|
|
d274a9c73d | ||
|
|
905c05ba06 | ||
|
|
c3619a3795 | ||
|
|
dffb33727d | ||
|
|
78724163b1 | ||
|
|
b6a09abb83 | ||
|
|
77b6d83e0b | ||
|
|
fcacf28c45 | ||
|
|
7c6b85a0ad | ||
|
|
5e55d637af | ||
|
|
8942d7d50d | ||
|
|
3e5d82c665 | ||
|
|
0ad09e422d | ||
|
|
0657160389 | ||
|
|
cfde6342a8 | ||
|
|
832c27ed18 | ||
|
|
1bea7654b8 | ||
|
|
38ea778ccf | ||
|
|
31f300f6d8 | ||
|
|
4e8bb688aa | ||
|
|
563d623278 | ||
|
|
24790e8b2a | ||
|
|
58806dee68 | ||
|
|
59d78ba893 | ||
|
|
7770ee3d08 | ||
|
|
2d9ad41e49 | ||
|
|
821156c9d6 | ||
|
|
9e5982be29 | ||
|
|
39c87d19b7 | ||
|
|
d029abc8f3 | ||
|
|
7b5848b9c3 | ||
|
|
53bfbf5acf | ||
|
|
917c9e54ba | ||
|
|
d8d9c7fe64 | ||
|
|
6c0f2de780 | ||
|
|
700975d670 | ||
|
|
4fda12b512 | ||
|
|
9fac314d71 | ||
|
|
9dfee34f01 | ||
|
|
dc8473bc4d | ||
|
|
c1c75f032d | ||
|
|
9ad180c02a | ||
|
|
7795320fc8 | ||
|
|
a54c8fbeb7 | ||
|
|
0c62465a22 | ||
|
|
785b0caaf2 | ||
|
|
3d4c50d481 | ||
|
|
263c297bed | ||
|
|
c0975ed15e | ||
|
|
ce6de6efa6 | ||
|
|
561c1fc338 | ||
|
|
e94affe588 | ||
|
|
43e3648ba7 | ||
|
|
63938c6fd3 | ||
|
|
f21a1093f3 | ||
|
|
72318fa696 | ||
|
|
babc581c5d | ||
|
|
c28fb4164b | ||
|
|
a6db08992f | ||
|
|
2dea5e0ffc | ||
|
|
9cab4d510a | ||
|
|
41621826d8 | ||
|
|
2149030dbb | ||
|
|
8c0bd7e5e3 | ||
|
|
5283682c47 | ||
|
|
b53d20d2ee | ||
|
|
ed6bdf97d1 | ||
|
|
93cfa564f7 | ||
|
|
579b8fce96 | ||
|
|
d1d9462423 | ||
|
|
299f9c4a26 | ||
|
|
5c27e974fb | ||
|
|
53bd4b1ea9 | ||
|
|
3d10fff7de | ||
|
|
8107d65504 | ||
|
|
9a4cebfb61 | ||
|
|
5c81833415 | ||
|
|
d88ca50de0 | ||
|
|
b75b53d05a | ||
|
|
c2cae5b2fc | ||
|
|
30e962b447 | ||
|
|
f710bb535e | ||
|
|
814b02900b | ||
|
|
4958353335 | ||
|
|
9884c52c4e | ||
|
|
0cd4fc8655 | ||
|
|
5d07c5a0b2 | ||
|
|
cf20b3a3c3 | ||
|
|
dbe4acd47d | ||
|
|
b7a0f5bee5 | ||
|
|
0adb62b485 | ||
|
|
a439608fe7 | ||
|
|
e82efd24d3 | ||
|
|
3d1f3ed068 | ||
|
|
bac972de53 | ||
|
|
95310991b8 | ||
|
|
f60a759dca | ||
|
|
4f6f829dc3 | ||
|
|
8962ebd175 | ||
|
|
218b3c87db | ||
|
|
c12a0f8cdf | ||
|
|
4a41ccb4e6 | ||
|
|
0d1f53d58d | ||
|
|
fea07917fa | ||
|
|
003c2e0dca | ||
|
|
ce38ef6289 | ||
|
|
2457c58817 | ||
|
|
ab6dd66bad | ||
|
|
d430fe35c5 | ||
|
|
9650c71155 | ||
|
|
95da7551d2 | ||
|
|
667473f90e | ||
|
|
cf9e17ebfd | ||
|
|
ec55909305 | ||
|
|
3e03f7c12a | ||
|
|
edc2005b2c | ||
|
|
72f3fa6eda | ||
|
|
48c02c6f55 | ||
|
|
8b7643332b | ||
|
|
639619ff93 | ||
|
|
0a08ef0ed4 | ||
|
|
b3f35c579b | ||
|
|
bcb74d01b6 | ||
|
|
8a8b88af13 | ||
|
|
58ed405c88 | ||
|
|
a3d4f80599 | ||
|
|
7bfd55f3f0 | ||
|
|
153b5de1d4 | ||
|
|
932b7a094d | ||
|
|
47b8c661e7 | ||
|
|
3bb0f51d08 | ||
|
|
32fc5ccd3e | ||
|
|
4f3cba32da | ||
|
|
b2c60ba884 | ||
|
|
a2323a7bb2 | ||
|
|
537ed2d11f | ||
|
|
f318cc5e28 | ||
|
|
1001cc607e | ||
|
|
35d480bc48 | ||
|
|
37f51ef983 | ||
|
|
943d7ce31a | ||
|
|
bc54ddf19f | ||
|
|
7d091d18ee | ||
|
|
599e24634c | ||
|
|
e998edd083 | ||
|
|
e15ca55558 | ||
|
|
23a2801284 | ||
|
|
9a6da3f46f | ||
|
|
fbb881bb42 | ||
|
|
87d65c150b | ||
|
|
bb2fcd5b00 | ||
|
|
cfe8b1a764 | ||
|
|
aee1dff718 | ||
|
|
54bd41903b | ||
|
|
c813df9afe | ||
|
|
e312f66823 | ||
|
|
648c10c91f | ||
|
|
2cf902c6c3 | ||
|
|
26934fae02 | ||
|
|
74ba9364f4 | ||
|
|
18222420ee | ||
|
|
89a37766df | ||
|
|
cf02471db7 | ||
|
|
ff9b7de615 | ||
|
|
b7ad8faaee | ||
|
|
34facfe764 | ||
|
|
c83b6288aa | ||
|
|
b66f86de71 | ||
|
|
581cd19446 |
No files matched your search
@@ -11,6 +11,7 @@ trim_trailing_whitespace = true
|
|||||||
|
|
||||||
[**.py]
|
[**.py]
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
|
indent_size = 4
|
||||||
|
|
||||||
[src/octoprint/static/js/app/**.js]
|
[src/octoprint/static/js/app/**.js]
|
||||||
indent_style = space
|
indent_style = space
|
||||||
|
|||||||
@@ -1,29 +1,31 @@
|
|||||||
|
---
|
||||||
|
name: Bug report
|
||||||
|
about: Create a report to help improve OctoPrint
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
<!--
|
||||||
READ THE FOLLOWING FIRST:
|
READ THE FOLLOWING FIRST:
|
||||||
|
|
||||||
If not already done, please read the "guidelines for contributing"
|
If not already done, please read the the Contribution Guidelines that
|
||||||
aka the Contribution Guidelines that are linked ^-- just up there
|
are linked to the right under "Helpful resources" > "Contributing".
|
||||||
in the big yellow box.
|
|
||||||
|
|
||||||
Also read the FAQ: https://github.com/foosel/OctoPrint/wiki/FAQ.
|
Also read the FAQ: https://faq.octoprint.org
|
||||||
|
|
||||||
This is a bug and feature tracker, please only use it to report bugs
|
This is a bug and feature tracker, please only use it to report bugs
|
||||||
or request features within OctoPrint (not OctoPi, not any OctoPrint
|
or request features within OctoPrint (not OctoPi, not any OctoPrint
|
||||||
plugins and not unofficial OctoPrint versions).
|
plugins and not unofficial OctoPrint versions).
|
||||||
|
|
||||||
Do not seek support here ("I need help with ...", "I have a
|
Do not seek support here ("I need help with ...", "I have a
|
||||||
question ..."), that belongs on the mailing list or the G+ community
|
question ..."), that belongs on the community forum at
|
||||||
(both linked in the "guidelines for contributing" linked above, read
|
community.octoprint.org, NOT here.
|
||||||
them!), NOT here.
|
|
||||||
|
|
||||||
Mark requests with a "[Request]" prefix in the title please. For bug
|
Mark requests with a "[Request]" prefix in the title please. For bug
|
||||||
reports fully fill out the bug reporting template (if you don't know
|
reports fully fill out the bug reporting template (if you don't know
|
||||||
where to find some information - it's all described in the Contribution
|
where to find some information - it's all described in the Contribution
|
||||||
Guidelines linked up there in the big yellow box).
|
Guidelines linked up there in the big yellow box).
|
||||||
|
|
||||||
When reporting a bug do NOT delete ANY lines from the template but
|
When reporting a bug do NOT delete ANY lines from the template.
|
||||||
those enclosed in [ and ] - and those please DO delete, they are
|
|
||||||
only provided for your information and removing them makes your
|
|
||||||
ticket more readable :)
|
|
||||||
|
|
||||||
Make sure any bug you want to report is still present with the CURRENT
|
Make sure any bug you want to report is still present with the CURRENT
|
||||||
OctoPrint version and that it does not vanish when you start OctoPrint
|
OctoPrint version and that it does not vanish when you start OctoPrint
|
||||||
@@ -31,27 +33,27 @@ in safe mode - how to do that is also explained in the Contribution
|
|||||||
Guidelines linked up there in the big yellow box.
|
Guidelines linked up there in the big yellow box.
|
||||||
|
|
||||||
Thank you!
|
Thank you!
|
||||||
|
-->
|
||||||
(Before submitting your ticket, please delete this text up to and
|
|
||||||
including the line too - it's only here for you, we already know it
|
|
||||||
by heart ;))
|
|
||||||
|
|
||||||
----
|
|
||||||
|
|
||||||
#### What were you doing?
|
#### What were you doing?
|
||||||
|
|
||||||
[Please be as specific as possible here. The maintainers will need to
|
<!--
|
||||||
|
Please be as specific as possible here. The maintainers will need to
|
||||||
reproduce your issue in order to fix it and that is not possible if they
|
reproduce your issue in order to fix it and that is not possible if they
|
||||||
don't know what you did to get it to happen in the first place.
|
don't know what you did to get it to happen in the first place.
|
||||||
|
|
||||||
Ideally provide exact steps to follow in order to reproduce your problem:
|
Ideally provide exact steps to follow in order to reproduce your problem:
|
||||||
|
-->
|
||||||
|
|
||||||
1. ...
|
1. Go to '...'
|
||||||
2. ...
|
2. Click on '....'
|
||||||
3. ...
|
3. Scroll down to '....'
|
||||||
|
4. See error
|
||||||
|
|
||||||
|
<!--
|
||||||
If you encountered a problem with specific files of any sorts, make sure
|
If you encountered a problem with specific files of any sorts, make sure
|
||||||
to also include a link to a file with which to reproduce the problem.]
|
to also include a link to a file with which to reproduce the problem.
|
||||||
|
-->
|
||||||
|
|
||||||
#### What did you expect to happen?
|
#### What did you expect to happen?
|
||||||
|
|
||||||
@@ -59,50 +61,75 @@ to also include a link to a file with which to reproduce the problem.]
|
|||||||
|
|
||||||
#### Did the same happen when running OctoPrint in safe mode?
|
#### Did the same happen when running OctoPrint in safe mode?
|
||||||
|
|
||||||
[Try to reproduce your problem in safe mode. You can find information
|
<!--
|
||||||
on how to enable safe mode in the Contribution Guidelines.]
|
Test if you can reproduce your problem in safe mode. You can find information
|
||||||
|
on how to enable safe mode in the Contribution Guidelines.
|
||||||
|
|
||||||
#### Branch & Commit or Version of OctoPrint
|
If you can't reproduce in safe mode, this is a bug with one of your
|
||||||
|
installed third party plugins. Don't open a ticket here!
|
||||||
|
|
||||||
[Can be found in the lower left corner of the web interface. ALWAYS INCLUDE.]
|
If you can't test this in safe mode, state why.
|
||||||
|
-->
|
||||||
|
|
||||||
|
#### Version of OctoPrint
|
||||||
|
|
||||||
|
<!--
|
||||||
|
Can be found in the lower left corner of the web interface. ALWAYS INCLUDE.
|
||||||
|
-->
|
||||||
|
|
||||||
#### Operating System running OctoPrint
|
#### Operating System running OctoPrint
|
||||||
|
|
||||||
[OctoPi, Linux, Windows, MacOS, something else? With version please.
|
<!--
|
||||||
OctoPi's version can be found in /etc/octopi_version]
|
OctoPi, Linux, Windows, MacOS, something else? With version please.
|
||||||
|
OctoPi's version can be found in /etc/octopi_version or in the lower left
|
||||||
|
corner of the web interface.
|
||||||
|
-->
|
||||||
|
|
||||||
#### Printer model & used firmware incl. version
|
#### Printer model & used firmware incl. version
|
||||||
|
|
||||||
[If applicable, always include if unsure.]
|
<!--
|
||||||
|
If applicable, always include if unsure.
|
||||||
|
-->
|
||||||
|
|
||||||
#### Browser and Version of Browser, Operating System running Browser
|
#### Browser and version of browser, operating system running browser
|
||||||
|
|
||||||
[If applicable, always include if unsure.]
|
<!--
|
||||||
|
If applicable, always include if unsure.
|
||||||
|
-->
|
||||||
|
|
||||||
#### Link to octoprint.log
|
#### Link to octoprint.log
|
||||||
|
|
||||||
[On gist.github.com or pastebin.com. ALWAYS INCLUDE and never truncate.
|
<!--
|
||||||
The Contribution Guidelines tell you where to find that.]
|
On gist.github.com or pastebin.com. ALWAYS INCLUDE and never truncate.
|
||||||
|
|
||||||
|
The Contribution Guidelines tell you where to find that.
|
||||||
|
-->
|
||||||
|
|
||||||
#### Link to contents of terminal tab or serial.log
|
#### Link to contents of terminal tab or serial.log
|
||||||
|
|
||||||
[On gist.github.com or pastebin.com. If applicable, always include if unsure or
|
<!--
|
||||||
|
On gist.github.com or pastebin.com. If applicable, always include if unsure or
|
||||||
reporting communication issues. Never truncate.
|
reporting communication issues. Never truncate.
|
||||||
|
|
||||||
serial.log is usually not written due to performance reasons and must be
|
serial.log is usually not written due to performance reasons and must be
|
||||||
enabled explicitly. Provide at the very least the FULL contents of your
|
enabled explicitly. Provide at the very least the FULL contents of your
|
||||||
terminal tab at the time of the bug occurrence, even if you do not have
|
terminal tab at the time of the bug occurrence, even if you do not have
|
||||||
a serial.log (which the Contribution Guidelines tell you where to find).]
|
a serial.log (which the Contribution Guidelines tell you where to find).
|
||||||
|
-->
|
||||||
|
|
||||||
#### Link to contents of Javascript console in the browser
|
#### Link to contents of Javascript console in the browser
|
||||||
|
|
||||||
[On gist.github.com or pastebin.com or alternatively a screenshot. If applicable -
|
<!--
|
||||||
|
On gist.github.com or pastebin.com or alternatively a screenshot. If applicable -
|
||||||
always include if unsure or reporting UI issues.
|
always include if unsure or reporting UI issues.
|
||||||
|
|
||||||
The Contribution Guidelines tell you where to find that.]
|
The Contribution Guidelines tell you where to find that.
|
||||||
|
-->
|
||||||
|
|
||||||
#### Screenshot(s)/video(s) showing the problem:
|
#### Screenshot(s)/video(s) showing the problem:
|
||||||
|
|
||||||
[If applicable. Always include if unsure or reporting UI issues.]
|
<!--
|
||||||
|
If applicable. Always include if unsure or reporting UI issues.
|
||||||
|
-->
|
||||||
|
|
||||||
I have read the FAQ.
|
I have read the FAQ.
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
---
|
||||||
|
name: Feature request
|
||||||
|
about: Suggest an idea for this project
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
<!--
|
||||||
|
Please make sure to add [Request] to your issue's title. Thank you!
|
||||||
|
-->
|
||||||
|
|
||||||
|
**Is your feature request related to a problem? Please describe.**
|
||||||
|
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||||
|
|
||||||
|
**Describe the solution you'd like**
|
||||||
|
A clear and concise description of what you want to happen.
|
||||||
|
|
||||||
|
**Describe alternatives you've considered**
|
||||||
|
A clear and concise description of any alternative solutions or features you've considered.
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context or screenshots about the feature request here.
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
<!--
|
||||||
Thank you for your interest into contributing to OctoPrint, it's
|
Thank you for your interest into contributing to OctoPrint, it's
|
||||||
highly appreciated!
|
highly appreciated!
|
||||||
|
|
||||||
@@ -7,6 +8,7 @@ as well that contains important information.
|
|||||||
|
|
||||||
As a summary, please make sure you have ticked all points on this
|
As a summary, please make sure you have ticked all points on this
|
||||||
checklist:
|
checklist:
|
||||||
|
-->
|
||||||
|
|
||||||
* [ ] Your changes are not possible to do through a plugin and relevant
|
* [ ] Your changes are not possible to do through a plugin and relevant
|
||||||
to a large audience (ideally all users of OctoPrint)
|
to a large audience (ideally all users of OctoPrint)
|
||||||
@@ -16,12 +18,13 @@ checklist:
|
|||||||
Brainstorming ticket
|
Brainstorming ticket
|
||||||
* [ ] Your PR targets OctoPrint's devel branch, or maintenance if it's
|
* [ ] Your PR targets OctoPrint's devel branch, or maintenance if it's
|
||||||
a bug fix for an issue present in the current stable version (no PRs
|
a bug fix for an issue present in the current stable version (no PRs
|
||||||
against master or anything else)
|
against master or anything else please)
|
||||||
* [ ] Your PR was opened from a custom branch on your repository
|
* [ ] Your PR was opened from a custom branch on your repository
|
||||||
(no PRs from your version of master, maintenance or devel please),
|
(no PRs from your version of master, maintenance or devel please),
|
||||||
e.g. dev/my_new_feature
|
e.g. dev/my_new_feature or fix/my_bugfix
|
||||||
* [ ] Your PR only contains relevant changes: no unrelated files,
|
* [ ] Your PR only contains relevant changes: no unrelated files,
|
||||||
no dead code, ideally only one commit - rebase your PR if necessary!
|
no dead code, ideally only one commit - rebase and squash your PR
|
||||||
|
if necessary!
|
||||||
* [ ] Your changes follow the existing coding style
|
* [ ] Your changes follow the existing coding style
|
||||||
* [ ] If your changes include style sheets: You have modified the
|
* [ ] If your changes include style sheets: You have modified the
|
||||||
.less source files, not the .css files (those are generated with
|
.less source files, not the .css files (those are generated with
|
||||||
@@ -32,11 +35,10 @@ checklist:
|
|||||||
nothing broke
|
nothing broke
|
||||||
* [ ] You have added yourself to the AUTHORS.md file :)
|
* [ ] You have added yourself to the AUTHORS.md file :)
|
||||||
|
|
||||||
Feel free to delete all this help text, then describe
|
<!--
|
||||||
your PR further. You may use the template provided below to do that.
|
Describe your PR further using the template provided below. The more
|
||||||
The more details the better!
|
details the better!
|
||||||
|
-->
|
||||||
----
|
|
||||||
|
|
||||||
#### What does this PR do and why is it necessary?
|
#### What does this PR do and why is it necessary?
|
||||||
|
|
||||||
|
|||||||
@@ -31,9 +31,12 @@ OctoPrint.egg-info
|
|||||||
*.codekit
|
*.codekit
|
||||||
|
|
||||||
venv
|
venv
|
||||||
|
venv2
|
||||||
|
venv3
|
||||||
venv26
|
venv26
|
||||||
venv27
|
venv27
|
||||||
venv33
|
venv33
|
||||||
venv34
|
venv34
|
||||||
venv35
|
venv35
|
||||||
venv36
|
venv36
|
||||||
|
venv37
|
||||||
@@ -1,12 +1,22 @@
|
|||||||
---
|
---
|
||||||
|
|
||||||
language: python
|
language: python
|
||||||
|
dist: xenial
|
||||||
|
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- python: '3.7'
|
||||||
|
env: RUN_FLAKE8=true
|
||||||
|
|
||||||
python:
|
python:
|
||||||
|
- "3.7"
|
||||||
|
- "3.6"
|
||||||
- "2.7"
|
- "2.7"
|
||||||
install:
|
install:
|
||||||
- pip install -e .[develop]
|
- pip install -e .[develop]
|
||||||
script:
|
script:
|
||||||
- nosetests --with-doctest
|
- test -n "$RUN_FLAKE8" || pytest
|
||||||
|
- test -z "$RUN_FLAKE8" || flake8 --ignore=D,E,W,F401 src/ tests setup.py
|
||||||
sudo: false
|
sudo: false
|
||||||
git:
|
git:
|
||||||
depth: 250
|
depth: 250
|
||||||
@@ -7,23 +7,27 @@
|
|||||||
# The file is processed from top to bottom, the first matching line wins. If <tag> or <reference commit> are left out,
|
# The file is processed from top to bottom, the first matching line wins. If <tag> or <reference commit> are left out,
|
||||||
# the lookup table does not apply to the matched branches
|
# the lookup table does not apply to the matched branches
|
||||||
|
|
||||||
# master and rc shall not use the lookup table, only tags
|
# master, meta, rc and prerelease shall not use the lookup table, only tags
|
||||||
master
|
master
|
||||||
|
meta/.*
|
||||||
rc/.*
|
rc/.*
|
||||||
|
hotfix/.*
|
||||||
prerelease
|
prerelease
|
||||||
|
|
||||||
# neither should disconnected checkouts, e.g. 'git checkout <tag>'
|
# neither should disconnected checkouts, e.g. 'git checkout <tag>'
|
||||||
HEAD
|
HEAD
|
||||||
\(detached.*
|
\(detached.*
|
||||||
|
|
||||||
# maintenance is currently the branch for preparation of maintenance release 1.3.3
|
# maintenance is currently the branch for preparation of maintenance release 1.3.12
|
||||||
# so are any fix/... and improve/... branches
|
# so are any fix/... and improve/... branches
|
||||||
maintenance 1.3.3 0a69dbeddb301d5a32827a3f0d561f875df24234 pep440-dev
|
maintenance 1.3.12 73df8c2407f04756261acfe62ac3d72877f8a97d pep440-dev
|
||||||
fix/.* 1.3.3 0a69dbeddb301d5a32827a3f0d561f875df24234 pep440-dev
|
fix/.* 1.3.12 73df8c2407f04756261acfe62ac3d72877f8a97d pep440-dev
|
||||||
improve/.* 1.3.3 0a69dbeddb301d5a32827a3f0d561f875df24234 pep440-dev
|
improve/.* 1.3.12 73df8c2407f04756261acfe62ac3d72877f8a97d pep440-dev
|
||||||
|
|
||||||
# staging/maintenance is currently the branch for preparation of 1.3.3rc4 (if we'll need that)
|
# staging/maintenance is currently the branch for preparation of 1.3.11rc4
|
||||||
staging/maintenance 1.3.3rc4 ce1541e956778b732458599a21f38b6783a0c2ec pep440-dev
|
# so is regressionfix/...
|
||||||
|
staging/maintenance 1.3.11rc4 af3285854995fb5b910fd2ce869e26c02d57bbc2 pep440-dev
|
||||||
|
regressionfix/.* 1.3.11rc4 af3285854995fb5b910fd2ce869e26c02d57bbc2 pep440-dev
|
||||||
|
|
||||||
# every other branch is a development branch and thus gets resolved to 1.4.0-dev for now
|
# every other branch is a development branch and thus gets resolved to 1.4.0-dev for now
|
||||||
.* 1.4.0 7f5d03d0549bcbd26f40e7e4a3297ea5204fb1cc pep440-dev
|
.* 1.4.0 7f5d03d0549bcbd26f40e7e4a3297ea5204fb1cc pep440-dev
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
# Authors
|
# Authors
|
||||||
|
|
||||||
The following people have contributed to OctoPrint's code base (ordered by
|
The following people have contributed to OctoPrint's code base (ordered roughly by
|
||||||
date of first contribution):
|
date of first contribution):
|
||||||
|
|
||||||
* [Gina Häußge](https://github.com/foosel)
|
* [Gina Häußge](https://github.com/foosel)
|
||||||
@@ -61,25 +61,50 @@ date of first contribution):
|
|||||||
* [Siim Raud](https://github.com/2ndalpha)
|
* [Siim Raud](https://github.com/2ndalpha)
|
||||||
* ["geoporalis"](https://github.com/geoporalis)
|
* ["geoporalis"](https://github.com/geoporalis)
|
||||||
* [Andrew Malota](https://github.com/2bitoperations)
|
* [Andrew Malota](https://github.com/2bitoperations)
|
||||||
* [Alexander Leisentritt](https://github.com/Alex9779)
|
|
||||||
* [therealbstern](https://github.com/therealbstern)
|
|
||||||
* [Ishwar Agarwal](https://github.com/agarwali)
|
* [Ishwar Agarwal](https://github.com/agarwali)
|
||||||
* [Kye Hoover](https://github.com/eykrevooh)
|
* [Kye Hoover](https://github.com/eykrevooh)
|
||||||
|
* [Joseph Carrick](https://github.com/carricktel)
|
||||||
|
* [Alexander Leisentritt](https://github.com/Alex9779)
|
||||||
|
* [therealbstern](https://github.com/therealbstern)
|
||||||
* [Philipp Baum](https://github.com/philphilphil)
|
* [Philipp Baum](https://github.com/philphilphil)
|
||||||
* [Kyle Evans](https://github.com/kevans91)
|
* [Kyle Evans](https://github.com/kevans91)
|
||||||
* [Javier Martínez Arrieta](https://github.com/Javierma)
|
* [Javier Martínez Arrieta](https://github.com/Javierma)
|
||||||
* ["MirceaDan"](https://github.com/ByReaL)
|
* [Mircea Dan Gheorghe](https://github.com/ByReaL)
|
||||||
* [Ovidiu Hossu](https://github.com/MoonshineSG)
|
* [Ovidiu Hossu](https://github.com/MoonshineSG)
|
||||||
* [Eyck Jentzsch](https://github.com/eyck)
|
* [Eyck Jentzsch](https://github.com/eyck)
|
||||||
* [Mathias Rangel Wulff](https://github.com/mathiasrw)
|
* [Mathias Rangel Wulff](https://github.com/mathiasrw)
|
||||||
* [Clemens Niemeyer](https://github.com/clemniem)
|
* [Clemens Niemeyer](https://github.com/clemniem)
|
||||||
* ["I-am-me"](https://github.com/I-am-me)
|
* ["I-am-me"](https://github.com/I-am-me)
|
||||||
|
* [J-J Heinonen](https://github.com/jammi)
|
||||||
* [Noah Martin](https://github.com/noahsmartin)
|
* [Noah Martin](https://github.com/noahsmartin)
|
||||||
* [Eyal Soha](https://github.com/eyal0)
|
* [Eyal Soha](https://github.com/eyal0)
|
||||||
* [Greg Hulands](https://github.com/ghulands)
|
* [Greg Hulands](https://github.com/ghulands)
|
||||||
* [Andreas Werner](https://github.com/gallore)
|
* [Andreas Werner](https://github.com/gallore)
|
||||||
* [Shawn Bruce](https://github.com/kantlivelong)
|
* [Shawn Bruce](https://github.com/kantlivelong)
|
||||||
* [Claudiu Ceia] (https://github.com/ClaudiuCeia)
|
* [Claudiu Ceia](https://github.com/ClaudiuCeia)
|
||||||
|
* [Goswin von Brederlow](https://github.com/mrvn)
|
||||||
|
* [Luke McKechnie](https://github.com/galamdring)
|
||||||
|
* [Peter Backx](https://github.com/pbackx)
|
||||||
|
* [Josh Major](https://github.com/astateofblank)
|
||||||
|
* ["alex-gh"](https://github.com/alex-gh)
|
||||||
|
* [Bernd Zeimetz](https://github.com/bzed)
|
||||||
|
* [Daniele Forsi](https://github.com/dforsi)
|
||||||
|
* [Ganey](https://github.com/ganey)
|
||||||
|
* [Sven Lohrmann](https://github.com/malnvenshorn)
|
||||||
|
* [Andy Castille](https://github.com/klikini)
|
||||||
|
* [Zachary Nofzinger](https://github.com/ZachNo)
|
||||||
|
* [Gaston Dombiak](https://github.com/gdombiak)
|
||||||
|
* [Brad Fisher](https://github.com/bradcfisher)
|
||||||
|
* [Aldo Hoeben](https://github.com/fieldofview)
|
||||||
|
* [Henning Groß](https://github.com/hgross)
|
||||||
|
* [Jubaleth](https://github.com/jubaleth)
|
||||||
|
* [Matthias Urlichs](https://github.com/smurfix)
|
||||||
|
* [Daniel Joyce](https://github.com/DanielJoyce)
|
||||||
|
* [Andy Qua](https://github.com/AndyQ)
|
||||||
|
* [Fabio Santos](https://github.com/Fabi0San)
|
||||||
|
* [Jack Wilsdon](https://github.com/jackwilsdon)
|
||||||
|
* [Ryan Finnie](https://github.com/rfinnie)
|
||||||
|
* [Timur Duehr](https://github.com/tduehr)
|
||||||
|
|
||||||
OctoPrint started off as a fork of [Cura](https://github.com/daid/Cura) by
|
OctoPrint started off as a fork of [Cura](https://github.com/daid/Cura) by
|
||||||
[Daid Braam](https://github.com/daid). Parts of its communication layer and
|
[Daid Braam](https://github.com/daid). Parts of its communication layer and
|
||||||
|
|||||||
@@ -21,45 +21,41 @@ or **[creating pull requests](#pull-requests)**.
|
|||||||
|
|
||||||
## Issues, Tickets, however you may call them
|
## Issues, Tickets, however you may call them
|
||||||
|
|
||||||
Please read the following short instructions fully and follow them. You can
|
Please read the following instructions fully and follow them. You can
|
||||||
help the project tremendously this way: not only do you help the maintainers
|
help the project tremendously this way: not only do you help the maintainers
|
||||||
to **address problems in a timely manner** but also keep it possible for them
|
to **address problems in a timely manner** but also keep it possible for them
|
||||||
to **fix bugs, add new and improve on existing functionality** instead of doing
|
to **fix bugs, add new and improve on existing functionality** instead of doing
|
||||||
nothing but ticket management.
|
nothing but ticket management.
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
- **[Read the FAQ](https://github.com/foosel/OctoPrint/wiki/FAQ)**
|
- **[Read the FAQ](https://faq.octoprint.org)**
|
||||||
- If you want to report a **bug**, [read "How to file a bug report" below](#how-to-file-a-bug-report)
|
- If you want to report a **bug**, [read "How to file a bug report" below](#how-to-file-a-bug-report)
|
||||||
and *[use the provided template](#what-should-i-include-in-a-ticket)*.
|
and *[use the provided template](#what-should-i-include-in-a-ticket)*.
|
||||||
You do not need to do anything else with your ticket.
|
You do not need to do anything else with your ticket.
|
||||||
- If you want to post a **feature request** or a **documentation request**, add `[Request]`
|
- If you want to post a **feature request** or a **documentation request**, add `[Request]`
|
||||||
to your issue's title (e.g. `[Request] Awesome new feature`). A question on how to run/change/setup
|
to your issue's title (e.g. `[Request] Awesome new feature`). A question on how to run/change/setup
|
||||||
something is **not** what qualifies as a request here, use the
|
something is **not** what qualifies as a request here, use the
|
||||||
[Mailinglist](https://groups.google.com/group/octoprint) or the
|
[community forum at community.octoprint.org](https://community.octoprint.org) for
|
||||||
[Google+ Community](https://plus.google.com/communities/102771308349328485741) for
|
|
||||||
such support issues.
|
such support issues.
|
||||||
- If you are a **developer** that wants to brainstorm a pull request or possible
|
- If you are a **developer** that wants to brainstorm a pull request or possible
|
||||||
changes to the plugin system, add [Brainstorming] to your issue's title (e.g.
|
changes to the plugin system, please get in touch on the
|
||||||
`[Brainstorming] New plugin hook for doing some cool stuff`).
|
[community forum at community.octoprint.org](https://community.octoprint.org/c/development).
|
||||||
- If you need **support**, have a **question** or some **other reason** that
|
- If you need **support**, have a **question** or some **other reason** that
|
||||||
doesn't fit any of the above categories, the issue tracker is not the right place.
|
doesn't fit any of the above categories, the issue tracker is not the right place.
|
||||||
Consult the [Mailinglist](https://groups.google.com/group/octoprint) or the
|
Consult the [community forum at community.octoprint.org](https://community.octoprint.org/c/support) instead.
|
||||||
[Google+ Community](https://plus.google.com/communities/102771308349328485741) instead.
|
|
||||||
|
|
||||||
No matter what kind of ticket you create, never mix two or more "ticket reasons"
|
No matter what kind of ticket you create, never mix two or more "ticket reasons"
|
||||||
into one ticket: One ticket per bug, request, brainstorming thread please.
|
into one ticket: One ticket per bug, request, brainstorming thread please.
|
||||||
|
|
||||||
----
|
> 👉 **Note**
|
||||||
|
>
|
||||||
**Note**: A bot is in place that monitors new tickets, automatically
|
> A bot is in place that monitors new tickets, automatically
|
||||||
categorizes them and checks new bug reports for usage of the provided template.
|
> categorizes them and checks new bug reports for usage of the provided template.
|
||||||
That bot will only bother you if you open a ticket that appears to be a bug (no
|
> That bot will only bother you if you open a ticket that appears to be a bug (no
|
||||||
`[Request]` or `[Brainstorming]` in the title) without the template, and it
|
> `[Request]` in the title) without the complete template, and it
|
||||||
will do that only to ensure that all information needed to solve the issue is
|
> will do that only to ensure that all information needed to solve the issue is
|
||||||
available for the maintainers to directly start tackling that problem.
|
> available for the maintainers to directly start tackling that problem.
|
||||||
|
|
||||||
----
|
|
||||||
|
|
||||||
## How to file a bug report
|
## How to file a bug report
|
||||||
|
|
||||||
@@ -72,22 +68,25 @@ following section *completely* and also follow the instructions in the
|
|||||||
|
|
||||||
### What should I do before submitting a bug report?
|
### What should I do before submitting a bug report?
|
||||||
|
|
||||||
1. **Make sure you are at the right location**. This is the Github repository
|
1. **Make sure you are at the right location**. This is the bug tracker
|
||||||
of the official version of OctoPrint, which is the 3D print server and
|
of the official version of OctoPrint, which is the 3D print server and
|
||||||
corresponding web interface itself.
|
corresponding web interface itself.
|
||||||
|
|
||||||
**This is not the Github respository of OctoPi**, which is the preconfigured
|
**OctoPrint doesn't manage your network connection or your webcam nor
|
||||||
|
can it fix your printer not getting detected as a serial interface** -
|
||||||
|
if you have any kinds of problems with that, get in touch on the
|
||||||
|
[community forum](https://community.octoprint.org).
|
||||||
|
|
||||||
|
**This is not the bug tracker of OctoPi**, which is the preconfigured
|
||||||
Raspberry Pi image including OctoPrint among other things - that one can be found
|
Raspberry Pi image including OctoPrint among other things - that one can be found
|
||||||
[here](https://github.com/guysoft/OctoPi). Please note that while we do have
|
[here](https://github.com/guysoft/OctoPi). If you have any kind of specific
|
||||||
some entries regarding OctoPi in the FAQ, any bugs should be reported in the
|
issue with how the OctoPi system is setup, go there please.
|
||||||
[proper bug tracker](https://github.com/guysoft/OctoPi/issues) which - again -
|
|
||||||
is not here.
|
|
||||||
|
|
||||||
**This is also not the Github repository of any OctoPrint Plugins you
|
**This is also not the bug tracker of any OctoPrint Plugins you
|
||||||
might have installed**. Report any issues with those in their corresponding
|
might have installed**. Report any issues with those in their corresponding
|
||||||
bug tracker (probably linked to from the plugin's homepage).
|
bug tracker (probably linked to from the plugin's homepage).
|
||||||
|
|
||||||
Finally, **this is also not the right issue tracker if you are running a
|
Finally, **this is also not the right bug tracker if you are running a
|
||||||
forked version of OctoPrint**. Seek help for such unofficial versions from
|
forked version of OctoPrint**. Seek help for such unofficial versions from
|
||||||
the people maintaining them instead.
|
the people maintaining them instead.
|
||||||
|
|
||||||
@@ -101,7 +100,7 @@ following section *completely* and also follow the instructions in the
|
|||||||
more about safe mode in the [docs](http://docs.octoprint.org/en/master/features/safemode.html).
|
more about safe mode in the [docs](http://docs.octoprint.org/en/master/features/safemode.html).
|
||||||
|
|
||||||
You might also want to try the current development version of OctoPrint
|
You might also want to try the current development version of OctoPrint
|
||||||
(if you aren't already). Refer to the [FAQ](https://github.com/foosel/OctoPrint/wiki/FAQ)
|
(if you aren't already). Refer to the [FAQ](https://faq.octoprint.org)
|
||||||
for information on how to do this.
|
for information on how to do this.
|
||||||
|
|
||||||
3. The problem still exists? Then please **look through the
|
3. The problem still exists? Then please **look through the
|
||||||
@@ -111,8 +110,8 @@ following section *completely* and also follow the instructions in the
|
|||||||
Sorting through duplicates of the same issue sometimes causes more work than
|
Sorting through duplicates of the same issue sometimes causes more work than
|
||||||
fixing it. Take the time to filter through possible duplicates and be really
|
fixing it. Take the time to filter through possible duplicates and be really
|
||||||
sure that your problem definitely is a new one. Try more than one search query
|
sure that your problem definitely is a new one. Try more than one search query
|
||||||
(e.g. do not only search for "webcam" if you happen to run into an issue
|
(e.g. do not only search for "timelapse" if you happen to run into an issue
|
||||||
with your webcam, also search for "timelapse" etc). Do not only read the subject lines
|
with your webcam, also search for "recording" etc). Do not only read the subject lines
|
||||||
of tickets that look like they might be related, but also read the ticket itself!
|
of tickets that look like they might be related, but also read the ticket itself!
|
||||||
|
|
||||||
**Very important:** Please make absolutely sure that if you find a bug that looks like
|
**Very important:** Please make absolutely sure that if you find a bug that looks like
|
||||||
@@ -126,84 +125,149 @@ following section *completely* and also follow the instructions in the
|
|||||||
makes it more difficult due to on top of having to figure out the original problem
|
makes it more difficult due to on top of having to figure out the original problem
|
||||||
there's now also a [red herring](https://en.wikipedia.org/wiki/Red_herring) interfering - so please be
|
there's now also a [red herring](https://en.wikipedia.org/wiki/Red_herring) interfering - so please be
|
||||||
very diligent here!
|
very diligent here!
|
||||||
|
|
||||||
|
If in doubt about any of the above - get in touch on the [community forum](https://community.octoprint.org)
|
||||||
|
instead of opening a ticket here. If you are actually running into a bug, we'll figure it out together
|
||||||
|
there.
|
||||||
|
|
||||||
### What should I include in a bug report?
|
### What should I include in a bug report?
|
||||||
|
|
||||||
First of all make sure your use **a descriptive title**. "It doesn't work"
|
First of all make sure your use **a descriptive title**. "It doesn't work"
|
||||||
and similar unspecific complaints are NOT descriptive titles.
|
and similar unspecific complaints are NOT descriptive titles.
|
||||||
|
|
||||||
**Always use the following template** (please remove what's within `[...]`, that's
|
**Always use the following template, even if only adding a "me too" to an
|
||||||
only provided here as some additional information for you), **even if only adding a
|
existing ticket**:
|
||||||
"me too" to an existing ticket**:
|
|
||||||
|
|
||||||
#### What were you doing?
|
```
|
||||||
|
<!--
|
||||||
|
READ THE FOLLOWING FIRST:
|
||||||
|
|
||||||
[Please be as specific as possible here. The maintainers will need to
|
If not already done, please read the the Contribution Guidelines that
|
||||||
reproduce your issue in order to fix it and that is not possible if they
|
are linked to the right under "Helpful resources" > "Contributing".
|
||||||
don't know what you did to get it to happen in the first place.
|
|
||||||
|
|
||||||
Ideally provide exact steps to follow in order to reproduce your problem:
|
Also read the FAQ: https://faq.octoprint.org
|
||||||
|
|
||||||
1. ...
|
This is a bug and feature tracker, please only use it to report bugs
|
||||||
2. ...
|
or request features within OctoPrint (not OctoPi, not any OctoPrint
|
||||||
3. ...
|
plugins and not unofficial OctoPrint versions).
|
||||||
|
|
||||||
If you encountered a problem with specific files of any sorts, make sure
|
Do not seek support here ("I need help with ...", "I have a
|
||||||
to also include a link to a file with which to reproduce the problem.]
|
question ..."), that belongs on the community forum at
|
||||||
|
community.octoprint.org, NOT here.
|
||||||
|
|
||||||
#### What did you expect to happen?
|
Mark requests with a "[Request]" prefix in the title please. For bug
|
||||||
|
reports fully fill out the bug reporting template (if you don't know
|
||||||
|
where to find some information - it's all described in the Contribution
|
||||||
|
Guidelines linked up there in the big yellow box).
|
||||||
|
|
||||||
#### What happened instead?
|
When reporting a bug do NOT delete ANY lines from the template.
|
||||||
|
|
||||||
#### Did the same happen when running OctoPrint in safe mode?
|
Make sure any bug you want to report is still present with the CURRENT
|
||||||
|
OctoPrint version and that it does not vanish when you start OctoPrint
|
||||||
|
in safe mode - how to do that is also explained in the Contribution
|
||||||
|
Guidelines linked up there in the big yellow box.
|
||||||
|
|
||||||
[Try to reproduce your problem in safe mode. You can find information
|
Thank you!
|
||||||
on how to enable safe mode in the Contribution Guidelines.]
|
-->
|
||||||
|
|
||||||
#### Branch & Commit or Version of OctoPrint
|
#### What were you doing?
|
||||||
|
|
||||||
[Can be found in the lower left corner of the web interface. ALWAYS INCLUDE.]
|
<!--
|
||||||
|
Please be as specific as possible here. The maintainers will need to
|
||||||
|
reproduce your issue in order to fix it and that is not possible if they
|
||||||
|
don't know what you did to get it to happen in the first place.
|
||||||
|
|
||||||
#### Operating System running OctoPrint
|
Ideally provide exact steps to follow in order to reproduce your problem:
|
||||||
|
-->
|
||||||
|
|
||||||
[OctoPi, Linux, Windows, MacOS, something else? With version please,
|
1. ...
|
||||||
OctoPi's version can be found in /etc/octopi_version]
|
2. ...
|
||||||
|
3. ...
|
||||||
|
|
||||||
#### Printer model & used firmware incl. version
|
<!--
|
||||||
|
If you encountered a problem with specific files of any sorts, make sure
|
||||||
|
to also include a link to a file with which to reproduce the problem.
|
||||||
|
-->
|
||||||
|
|
||||||
[If applicable, always include if unsure.]
|
#### What did you expect to happen?
|
||||||
|
|
||||||
#### Browser and Version of Browser, Operating System running Browser
|
#### What happened instead?
|
||||||
|
|
||||||
[If applicable, always include if unsure.]
|
#### Did the same happen when running OctoPrint in safe mode?
|
||||||
|
|
||||||
#### Link to octoprint.log
|
<!--
|
||||||
|
Test if you can reproduce your problem in safe mode. You can find information
|
||||||
|
on how to enable safe mode in the Contribution Guidelines.
|
||||||
|
|
||||||
[On gist.github.com or pastebin.com. ALWAYS INCLUDE and never truncate.
|
If you can't reproduce in safe mode, this is a bug with one of your
|
||||||
The Contribution Guidelines tell you where to find that.]
|
installed third party plugins. Don't open a ticket here!
|
||||||
|
|
||||||
#### Link to contents of terminal tab or serial.log
|
If you can't test this in safe mode, state why.
|
||||||
|
-->
|
||||||
|
|
||||||
[On gist.github.com or pastebin.com. If applicable, always include if unsure or
|
#### Version of OctoPrint
|
||||||
reporting communication issues. Never truncate.
|
|
||||||
|
|
||||||
serial.log is usually not written due to performance reasons and must be
|
<!--
|
||||||
enabled explicitly. Provide at the very least the FULL contents of your
|
Can be found in the lower left corner of the web interface. ALWAYS INCLUDE.
|
||||||
terminal tab at the time of the bug occurrence, even if you do not have
|
-->
|
||||||
a serial.log.]
|
|
||||||
|
|
||||||
#### Link to contents of Javascript console in the browser
|
#### Operating System running OctoPrint
|
||||||
|
|
||||||
[On gist.github.com or pastebin.com or alternatively a screenshot. If applicable -
|
<!--
|
||||||
always include if unsure or reporting UI issues.
|
OctoPi, Linux, Windows, MacOS, something else? With version please.
|
||||||
|
OctoPi's version can be found in /etc/octopi_version or in the lower left
|
||||||
|
corner of the web interface.
|
||||||
|
-->
|
||||||
|
|
||||||
The Contribution Guidelines tell you where to find that.]
|
#### Printer model & used firmware incl. version
|
||||||
|
|
||||||
#### Screenshot(s)/video(s) showing the problem:
|
<!--
|
||||||
|
If applicable, always include if unsure.
|
||||||
|
-->
|
||||||
|
|
||||||
[If applicable. Always include if unsure or reporting UI issues.]
|
#### Browser and version of browser, operating system running browser
|
||||||
|
|
||||||
I have read the FAQ.
|
<!--
|
||||||
|
If applicable, always include if unsure.
|
||||||
|
-->
|
||||||
|
|
||||||
|
#### Link to octoprint.log
|
||||||
|
|
||||||
|
<!--
|
||||||
|
On gist.github.com or pastebin.com. ALWAYS INCLUDE and never truncate.
|
||||||
|
|
||||||
|
The Contribution Guidelines tell you where to find that.
|
||||||
|
-->
|
||||||
|
|
||||||
|
#### Link to contents of terminal tab or serial.log
|
||||||
|
|
||||||
|
<!--
|
||||||
|
On gist.github.com or pastebin.com. If applicable, always include if unsure or
|
||||||
|
reporting communication issues. Never truncate.
|
||||||
|
|
||||||
|
serial.log is usually not written due to performance reasons and must be
|
||||||
|
enabled explicitly. Provide at the very least the FULL contents of your
|
||||||
|
terminal tab at the time of the bug occurrence, even if you do not have
|
||||||
|
a serial.log (which the Contribution Guidelines tell you where to find).
|
||||||
|
-->
|
||||||
|
|
||||||
|
#### Link to contents of Javascript console in the browser
|
||||||
|
|
||||||
|
<!--
|
||||||
|
On gist.github.com or pastebin.com or alternatively a screenshot. If applicable -
|
||||||
|
always include if unsure or reporting UI issues.
|
||||||
|
|
||||||
|
The Contribution Guidelines tell you where to find that.
|
||||||
|
-->
|
||||||
|
|
||||||
|
#### Screenshot(s)/video(s) showing the problem:
|
||||||
|
|
||||||
|
<!--
|
||||||
|
If applicable. Always include if unsure or reporting UI issues.
|
||||||
|
-->
|
||||||
|
|
||||||
|
I have read the FAQ.
|
||||||
|
```
|
||||||
|
|
||||||
Copy-paste this template **completely** (or use the version that gets pre-filled
|
Copy-paste this template **completely** (or use the version that gets pre-filled
|
||||||
into the "new issue" form). Do not skip any lines or the bot *will* complain! Provide
|
into the "new issue" form). Do not skip any lines or the bot *will* complain! Provide
|
||||||
@@ -211,50 +275,11 @@ all requested information or your ticket will be closed.
|
|||||||
|
|
||||||
### Where can I find which version and branch I'm on?
|
### Where can I find which version and branch I'm on?
|
||||||
|
|
||||||
You can find out all of them by taking a look into the lower left corner of the
|
Please refer to [this FAQ entry](https://community.octoprint.org/t/how-can-i-find-out-the-version-of-octoprint-or-octopi-i-am-running/204/1).
|
||||||
OctoPrint UI:
|
|
||||||
|
|
||||||

|
|
||||||
|
|
||||||
If you don't have access to the UI you can find out that information via the
|
|
||||||
command line as well. Either `octoprint --version` or `python setup.py version`
|
|
||||||
in OctoPrint's folder will tell you the version of OctoPrint you are running
|
|
||||||
(note: if it doesn't then you are running a version older than 1.1.0,
|
|
||||||
*upgrade now*). A `git branch` in your OctoPrint installation folder will mark
|
|
||||||
the branch you are on with a little *. `git rev-parse HEAD` will tell you the
|
|
||||||
current commit.
|
|
||||||
|
|
||||||
### Where can I find those log files you keep talking about?
|
### Where can I find those log files you keep talking about?
|
||||||
|
|
||||||
OctoPrint by default provides two log outputs, a third one can be enabled if
|
Please refer to [this FAQ entry](https://community.octoprint.org/t/where-can-i-find-octoprints-and-octopis-log-files/299/1).
|
||||||
more information is needed.
|
|
||||||
|
|
||||||
One is contained in the **"Terminal" tab** within OctoPrint's UI and is a log
|
|
||||||
of the last 300 lines of communication with the printer. Please copy-paste
|
|
||||||
this *completely* somewhere (disable auto scroll to make copying the contents easier) -
|
|
||||||
e.g. http://pastebin.com or http://gist.github.com - and include a link in
|
|
||||||
your bug report.
|
|
||||||
|
|
||||||
There is also **OctoPrint's application log file** or in short `octoprint.log`,
|
|
||||||
which is by default located at `~/.octoprint/logs/octoprint.log` on Linux,
|
|
||||||
`%APPDATA%\OctoPrint\logs\octoprint.log` on Windows and
|
|
||||||
`~/Library/Application Support/OctoPrint/logs/octoprint.log` on MacOS. You can
|
|
||||||
also access it directly through OctoPrint via Settings > Logs. Please
|
|
||||||
copy-paste this *completely* to pastebin or gist as well and include a link in your bug
|
|
||||||
report.
|
|
||||||
|
|
||||||
It might happen that you are asked to provide a more **thorough log of the
|
|
||||||
communication with the printer** if you haven't already done so, the `serial.log`.
|
|
||||||
This is not written by default due to performance reasons, but you can enable
|
|
||||||
it in the settings dialog. After enabling that log, please reproduce the problem
|
|
||||||
again (connect to the printer, do whatever triggers it), then copy-paste
|
|
||||||
`~/.octoprint/logs/serial.log` (Windows: `%APPDATA%\OctoPrint\logs\serial.log`,
|
|
||||||
MacOS: `~/Library/Application Support/OctoPrint/logs/serial.log`) to pastebin
|
|
||||||
or gist and include the link in the bug report.
|
|
||||||
|
|
||||||
You might also be asked to provide a log with an increased log level. You can
|
|
||||||
find information on how to do just that in the
|
|
||||||
[docs](http://docs.octoprint.org/en/master/configuration/logging_yaml.html).
|
|
||||||
|
|
||||||
### Where can I find my browser's error console?
|
### Where can I find my browser's error console?
|
||||||
|
|
||||||
@@ -263,6 +288,8 @@ See [How to open the Javascript Console in different browsers](https://webmaster
|
|||||||
## Setting up a development environment
|
## Setting up a development environment
|
||||||
|
|
||||||
See [the corresponding chapter in the documentation](http://docs.octoprint.org/en/master/development/index.html#setting-up-a-development-environment).
|
See [the corresponding chapter in the documentation](http://docs.octoprint.org/en/master/development/index.html#setting-up-a-development-environment).
|
||||||
|
This also includes information on how to run the test suite and how to build
|
||||||
|
the documentation.
|
||||||
|
|
||||||
## Pull requests
|
## Pull requests
|
||||||
|
|
||||||
@@ -274,7 +301,8 @@ See [the corresponding chapter in the documentation](http://docs.octoprint.org/e
|
|||||||
the discussion going on how best to solve *this* in OctoPrint's plugin
|
the discussion going on how best to solve *this* in OctoPrint's plugin
|
||||||
system - maybe that's the actual PR you have been waiting for to contribute :)
|
system - maybe that's the actual PR you have been waiting for to contribute :)
|
||||||
2. If you plan to make **any large or otherwise disruptive changes to the
|
2. If you plan to make **any large or otherwise disruptive changes to the
|
||||||
code or appearance, please open a "Brainstorming" ticket first** so
|
code or appearance, please get in touch on the
|
||||||
|
[forums](https://community.octoprint.org/c/development)** first so
|
||||||
that we can determine if it's a good time for your specific pull
|
that we can determine if it's a good time for your specific pull
|
||||||
request. It might be that we're currently in the process of making
|
request. It might be that we're currently in the process of making
|
||||||
heavy changes to the code locations you'd target as well, or your
|
heavy changes to the code locations you'd target as well, or your
|
||||||
@@ -284,7 +312,8 @@ See [the corresponding chapter in the documentation](http://docs.octoprint.org/e
|
|||||||
3. Create your pull request **from a custom branch** on your end (e.g.
|
3. Create your pull request **from a custom branch** on your end (e.g.
|
||||||
`dev/myNewFeature`)[1].
|
`dev/myNewFeature`)[1].
|
||||||
4. Create your pull request **only against the `maintenance` or `devel` branch**:
|
4. Create your pull request **only against the `maintenance` or `devel` branch**:
|
||||||
* if it's a bug fix for a bug in the current stable version: `maintenance` branch
|
* if it's a bug fix for a bug in the current stable version, an improvement of existing functionality or a
|
||||||
|
*small* new feature (e.g. a new hook, a new config flag, ...): `maintenance` branch
|
||||||
* otherwise: `devel` branch
|
* otherwise: `devel` branch
|
||||||
5. Create **one pull request per feature/bug fix**.
|
5. Create **one pull request per feature/bug fix**.
|
||||||
6. Make sure there are **only relevant changes** included in your PR. No
|
6. Make sure there are **only relevant changes** included in your PR. No
|
||||||
@@ -303,7 +332,17 @@ See [the corresponding chapter in the documentation](http://docs.octoprint.org/e
|
|||||||
* Make sure you do not add dead code (e.g. commented out left-overs
|
* Make sure you do not add dead code (e.g. commented out left-overs
|
||||||
from experiments).
|
from experiments).
|
||||||
8. Ensure your changes **pass the existing unit tests**. PRs that break
|
8. Ensure your changes **pass the existing unit tests**. PRs that break
|
||||||
those cannot be accepted.
|
those cannot be accepted. You can run the unit tests locally (after
|
||||||
|
[initial development environment setup with "develop" dependencies](http://docs.octoprint.org/en/master/development/index.html#setting-up-a-development-environment))
|
||||||
|
by running
|
||||||
|
|
||||||
|
```
|
||||||
|
nosetests --with-doctest
|
||||||
|
```
|
||||||
|
|
||||||
|
in the OctoPrint checkout folder. A [travis build](https://travis-ci.org/foosel/OctoPrint)
|
||||||
|
is also setup so that if the tests should fail, your PR will be marked
|
||||||
|
accordingly.
|
||||||
9. **Test your changes thoroughly**. That also means testing with usage
|
9. **Test your changes thoroughly**. That also means testing with usage
|
||||||
scenarios you don't normally use, e.g. if you only use access control, test
|
scenarios you don't normally use, e.g. if you only use access control, test
|
||||||
without and vice versa. If you only test with your printer, test with the
|
without and vice versa. If you only test with your printer, test with the
|
||||||
@@ -432,6 +471,12 @@ the local version identifier to allow for an exact determination of the active c
|
|||||||
* 2017-03-10: Reproduce bugs in safe mode to make sure they are really caused
|
* 2017-03-10: Reproduce bugs in safe mode to make sure they are really caused
|
||||||
by OctoPrint itself and not a misbehaving plugin.
|
by OctoPrint itself and not a misbehaving plugin.
|
||||||
* 2017-03-27: Added safe mode section to ticket template.
|
* 2017-03-27: Added safe mode section to ticket template.
|
||||||
|
* 2017-11-22: Added note on how to run the unit tests
|
||||||
|
* 2018-03-15: Link to new community forum and some clarifications re bug
|
||||||
|
reporting
|
||||||
|
* 2018-03-29: "Where to find version numbers" is now located on the FAQ
|
||||||
|
* 2018-10-18: Allow PRs against `maintenance` branch for improvements and small
|
||||||
|
new features, suggest getting in touch on the forum for larger changes
|
||||||
|
|
||||||
## Footnotes
|
## Footnotes
|
||||||
* [1] - If you are wondering why, the problem is that anything that you add
|
* [1] - If you are wondering why, the problem is that anything that you add
|
||||||
|
|||||||
@@ -1,35 +1,47 @@
|
|||||||
# OctoPrint
|
# OctoPrint
|
||||||
|
|
||||||
[](https://badge.fury.io/gh/foosel%2FOctoPrint)
|
|
||||||
|

|
||||||
|
[](https://travis-ci.org/foosel/OctoPrint)
|
||||||
|
[](https://community.octoprint.org)
|
||||||
|
[](https://chat.octoprint.org)
|
||||||
|
[](https://twitter.com/OctoPrint3d)
|
||||||
|
|
||||||
|
|
||||||
OctoPrint provides a snappy web interface for controlling consumer 3D printers. It is Free Software
|
OctoPrint provides a snappy web interface for controlling consumer 3D printers. It is Free Software
|
||||||
and released under the [GNU Affero General Public License V3](http://www.gnu.org/licenses/agpl.html).
|
and released under the [GNU Affero General Public License V3](http://www.gnu.org/licenses/agpl.html).
|
||||||
|
|
||||||
Its website can be found at [octoprint.org](http://octoprint.org).
|
Its website can be found at [octoprint.org](https://octoprint.org/?utm_source=github&utm_medium=readme).
|
||||||
|
|
||||||
|
The community forum is available at [community.octoprint.org](https://community.octoprint.org/?utm_source=github&utm_medium=readme).
|
||||||
|
|
||||||
|
The official IRC channel is [#octoprint on freenode](https://chat.octoprint.org). Its logs can be found [here](https://freenode.logbot.info/octoprint).
|
||||||
|
|
||||||
|
The FAQ can be accessed by following [faq.octoprint.org](https://faq.octoprint.org/?utm_source=github&utm_medium=readme).
|
||||||
|
|
||||||
The documentation is located at [docs.octoprint.org](http://docs.octoprint.org).
|
The documentation is located at [docs.octoprint.org](http://docs.octoprint.org).
|
||||||
|
|
||||||
The official plugin repository can be reached at [plugins.octoprint.org](http://plugins.octoprint.org).
|
The official plugin repository can be reached at [plugins.octoprint.org](https://plugins.octoprint.org/?utm_source=github&utm_medium=readme).
|
||||||
|
|
||||||
OctoPrint's development wouldn't be possible without the [financial support by its community](http://octoprint.org/support-octoprint/).
|
**OctoPrint's development wouldn't be possible without the [financial support by its community](https://octoprint.org/support-octoprint/?utm_source=github&utm_medium=readme).
|
||||||
If you enjoy OctoPrint, please consider becoming a regular supporter!
|
If you enjoy OctoPrint, please consider becoming a regular supporter!**
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
You are currently looking at the source code repository of OctoPrint. If you already installed it
|
You are currently looking at the source code repository of OctoPrint. If you already installed it
|
||||||
(e.g. by using the Raspberry Pi targeted distribution [OctoPi](https://github.com/guysoft/OctoPi)) and only
|
(e.g. by using the Raspberry Pi targeted distribution [OctoPi](https://github.com/guysoft/OctoPi)) and only
|
||||||
want to find out how to use it, [the documentation](http://docs.octoprint.org/) and [the public wiki](https://github.com/foosel/OctoPrint/wiki)
|
want to find out how to use it, [the documentation](http://docs.octoprint.org/) and [the public wiki](https://github.com/foosel/OctoPrint/wiki)
|
||||||
might be of more interest for you. You might also want to subscribe to [the mailing list](https://groups.google.com/group/octoprint)
|
might be of more interest for you. You might also want to subscribe to join
|
||||||
or the [G+ Community](https://plus.google.com/communities/102771308349328485741) where there are other active users who might be
|
[the community forum at community.octoprint.org](https://community.octoprint.org) where there are other active users who might be
|
||||||
able to help you with any questions you might have.
|
able to help you with any questions you might have.
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
Contributions of all kinds are welcome, not only in the form of code but also with regards to the
|
Contributions of all kinds are welcome, not only in the form of code but also with regards to the
|
||||||
[official documentation](http://docs.octoprint.org/) or [the public wiki](https://github.com/foosel/OctoPrint/wiki), support
|
[official documentation](http://docs.octoprint.org/) or [the public wiki](https://github.com/foosel/OctoPrint/wiki), debugging help
|
||||||
of other users in the [bug tracker](https://github.com/foosel/OctoPrint/issues),
|
in the [bug tracker](https://github.com/foosel/OctoPrint/issues), support of other users on
|
||||||
[the Mailinglist](https://groups.google.com/group/octoprint) or
|
[the community forum at community.octoprint.org](https://community.octoprint.org)
|
||||||
[the G+ Community](https://plus.google.com/communities/102771308349328485741) and also [financially](http://octoprint.org/support-octoprint/).
|
and also [financially](https://octoprint.org/support-octoprint/?utm_source=github&utm_medium=readme).
|
||||||
|
|
||||||
If you think something is bad about OctoPrint or its documentation the way it is, please help
|
If you think something is bad about OctoPrint or its documentation the way it is, please help
|
||||||
in any way to make it better instead of just complaining about it -- this is an Open Source Project
|
in any way to make it better instead of just complaining about it -- this is an Open Source Project
|
||||||
@@ -49,38 +61,35 @@ which is a custom SD card image that includes OctoPrint plus dependencies.
|
|||||||
The generic steps that should basically be done regardless of operating system
|
The generic steps that should basically be done regardless of operating system
|
||||||
and runtime environment are the following (as *regular
|
and runtime environment are the following (as *regular
|
||||||
user*, please keep your hands *off* of the `sudo` command here!) - this assumes
|
user*, please keep your hands *off* of the `sudo` command here!) - this assumes
|
||||||
you already have Python 2.7, pip and virtualenv set up on your system:
|
you already have Python 2.7, 3.6 or 3.7, pip and virtualenv set up on your system:
|
||||||
|
|
||||||
1. Checkout OctoPrint: `git clone https://github.com/foosel/OctoPrint.git`
|
1. Checkout OctoPrint: `git clone https://github.com/foosel/OctoPrint.git`
|
||||||
2. Change into the OctoPrint folder: `cd OctoPrint`
|
2. Change into the OctoPrint folder: `cd OctoPrint`
|
||||||
3. Create a user-owned virtual environment therein: `virtualenv venv`
|
3. Create a user-owned virtual environment therein: `virtualenv venv`
|
||||||
4. Install OctoPrint *into that virtual environment*: `./venv/bin/python setup.py install`
|
4. Install OctoPrint *into that virtual environment*: `./venv/bin/pip install .`
|
||||||
|
|
||||||
You may then start the OctoPrint server via `/path/to/OctoPrint/venv/bin/octoprint`, see [Usage](#usage)
|
You may then start the OctoPrint server via `/path/to/OctoPrint/venv/bin/octoprint`, see [Usage](#usage)
|
||||||
for details.
|
for details.
|
||||||
|
|
||||||
After installation, please make sure you follow the first-run wizard and set up
|
After installation, please make sure you follow the first-run wizard and set up
|
||||||
access control as necessary. If you want to not only be notified about new
|
access control as necessary.
|
||||||
releases, but also be able to automatically upgrade to them from within
|
|
||||||
OctoPrint, take a look [at the documentation of the Software Update Plugin](https://github.com/foosel/OctoPrint/wiki/Plugin:-Software-Update#making-octoprint-updateable-on-existing-installations)
|
|
||||||
and at its settings.
|
|
||||||
|
|
||||||
## Dependencies
|
## Dependencies
|
||||||
|
|
||||||
OctoPrint depends on a few python modules to do its job. Those are automatically installed when installing
|
OctoPrint depends on a few python modules to do its job. Those are automatically installed when installing
|
||||||
OctoPrint via `setup.py`:
|
OctoPrint via `pip`:
|
||||||
|
|
||||||
python setup.py install
|
pip install .
|
||||||
|
|
||||||
You should do this every time after pulling from the repository, since the dependencies may have changed.
|
You should do this every time after pulling from the repository, since the dependencies may have changed.
|
||||||
|
|
||||||
OctoPrint currently only supports Python 2.7.
|
OctoPrint currently supports Python 2.7, 3.6 and 3.7.
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
Running the `setup.py` script via
|
Running the pip install via
|
||||||
|
|
||||||
python setup.py install
|
pip install .
|
||||||
|
|
||||||
installs the `octoprint` script in your Python installation's scripts folder
|
installs the `octoprint` script in your Python installation's scripts folder
|
||||||
(which, depending on whether you installed OctoPrint globally or into a virtual env, will be in your `PATH` or not). The
|
(which, depending on whether you installed OctoPrint globally or into a virtual env, will be in your `PATH` or not). The
|
||||||
@@ -133,5 +142,8 @@ be edited from OctoPrint's settings dialog.
|
|||||||
|
|
||||||
## Special Thanks
|
## Special Thanks
|
||||||
|
|
||||||
Cross-browser testing services are kindly provided by [BrowserStack](http://www.browserstack.com/).
|
Cross-browser testing services are kindly provided by [BrowserStack](https://www.browserstack.com/).
|
||||||
Profiling is done with the help of [PyVmMonitor](http://www.pyvmmonitor.com).
|
|
||||||
|
Profiling is done with the help of [PyVmMonitor](https://www.pyvmmonitor.com).
|
||||||
|
|
||||||
|
Error tracking is powered and sponsored by [Sentry](https://sentry.io).
|
||||||
@@ -1,68 +1,57 @@
|
|||||||
# Supporters
|
# Supporters
|
||||||
|
|
||||||
Development of this version of OctoPrint wouldn't have been possible without
|
Development of this version of OctoPrint wouldn't have been possible without
|
||||||
[financial support by the community](http://octoprint.org/support-octoprint/) -
|
[the financial support by the community](https://octoprint.org/support-octoprint/) -
|
||||||
thanks to everyone who contributed!
|
thanks to everyone who contributed!
|
||||||
|
|
||||||
## Patreon Patrons
|
## Patreon Patrons
|
||||||
|
|
||||||
* 3D Moniak
|
* Andre Bubel
|
||||||
* Aleph Objects, Inc.
|
|
||||||
* Andrew Moorby
|
* Andrew Moorby
|
||||||
* Arnljot Arntsen
|
* Arnljot Arntsen
|
||||||
* BEEVERYCREATIVE
|
* Bjorn Breckenridge
|
||||||
* Boris Hussein
|
* Boris Hussein
|
||||||
* Brad Jackson
|
* Brad Jackson
|
||||||
* Brian E. Tyler
|
|
||||||
* Chris Day
|
|
||||||
* Christian Petropolis
|
* Christian Petropolis
|
||||||
* CreativeTools
|
* Christian Wolf
|
||||||
|
* COLLE+McVOY
|
||||||
* D Brian Kimmel
|
* D Brian Kimmel
|
||||||
* DeltaMaker 3D Printers
|
* DeltaMaker 3D Printers
|
||||||
* Doug Johnson
|
* Dorian Gray
|
||||||
* E3D BigBox
|
* E3D BigBox
|
||||||
|
* Eric Betts
|
||||||
* Ernesto Martinez
|
* Ernesto Martinez
|
||||||
* Exovite
|
* Franziska Kunsmann
|
||||||
* F. Kunsmann
|
|
||||||
* Frank Sander
|
|
||||||
* Gary Deen
|
|
||||||
* Gary N McKinney
|
|
||||||
* George Robles
|
* George Robles
|
||||||
* günter weber
|
* jean-claude migneault
|
||||||
* Ivan Krasin
|
* Jeff Renfer
|
||||||
* James Seigel
|
* Jefferson Hunt
|
||||||
* Jamie R McGuigan
|
* Jeremiah Avery
|
||||||
* Jeff Moe
|
* Joseph Payne
|
||||||
* Josh Daniels
|
* Joshua Wills
|
||||||
|
* Justin Kaufman
|
||||||
* Kaile Riser
|
* Kaile Riser
|
||||||
* Kale Stedman
|
* Kale Stedman
|
||||||
* Kazuhiro Ogura
|
* Kazuhiro Ogura
|
||||||
* Lamin Kivelä
|
* LA 3D Printer Repair
|
||||||
|
* LulzBot®
|
||||||
* Makespace Madrid
|
* Makespace Madrid
|
||||||
* Marcus Ackermann
|
|
||||||
* Mark Qvist
|
|
||||||
* Mark Walker
|
* Mark Walker
|
||||||
* Masayoshi Mitsui
|
|
||||||
* Michael Aumock
|
* Michael Aumock
|
||||||
* Miles Flavel
|
* Miles Flavel
|
||||||
* Mohammed khorakiwala
|
* Mosaic Manufacturing
|
||||||
* Noe Ruiz
|
* OMER MEHMET SUTAS
|
||||||
* Patrick McGinnis
|
* Patrick McGinnis
|
||||||
* Peter Grace
|
* Prof Yuh Wen Chen
|
||||||
* Peter Schmehl
|
* Randy C. Will
|
||||||
* PRINT3Dforum.com
|
|
||||||
* Robert Gusek
|
* Robert Gusek
|
||||||
* Roger Strolz
|
|
||||||
* Roy Cortes
|
|
||||||
* Samer Najia
|
* Samer Najia
|
||||||
* SD3D
|
* Shawn Lewis
|
||||||
* SeeMeCNC
|
|
||||||
* Simon Hallam
|
* Simon Hallam
|
||||||
* Stefan Krister
|
* Stefan Krister
|
||||||
* Stephane Schittly
|
|
||||||
* Sven Mueller
|
* Sven Mueller
|
||||||
* Thomas Hatley
|
* TEVO 3D Printers
|
||||||
* Timeshell.ca
|
|
||||||
* Trent Shumay
|
* Trent Shumay
|
||||||
|
* Ulrich Kempken
|
||||||
|
|
||||||
and 1098 more wonderful people pledging on the [Patreon campaign](https://patreon.com/foosel)!
|
and 1544 more wonderful people pledging on the [Patreon campaign](https://patreon.com/foosel)!
|
||||||
@@ -6,9 +6,10 @@
|
|||||||
* [Babel JavaScript Support](https://github.com/mitsuhiko/babel/blob/master/contrib/babel.js): BSD
|
* [Babel JavaScript Support](https://github.com/mitsuhiko/babel/blob/master/contrib/babel.js): BSD
|
||||||
* [Bootstrap](http://getbootstrap.com/): Apache License 2.0
|
* [Bootstrap](http://getbootstrap.com/): Apache License 2.0
|
||||||
* [Bootstrap Modal](http://jschr.github.io/bootstrap-modal/): Apache License 2.0
|
* [Bootstrap Modal](http://jschr.github.io/bootstrap-modal/): Apache License 2.0
|
||||||
* [Bootstrap Slider Knockout Bindings](https://github.com/cosminstefanxp/bootstrap-slider-knockout-binding): MIT
|
* [Bootstrap Slider Knockout Binding](https://github.com/cosminstefanxp/bootstrap-slider-knockout-binding): MIT
|
||||||
* [Bootstrap Slider](http://seiyria.com/bootstrap-slider/): Apache License 2.0
|
* [Bootstrap Slider](http://seiyria.com/bootstrap-slider/): Apache License 2.0
|
||||||
* [Bootstrap Tabdrop](http://www.eyecon.ro/bootstrap-tabdrop): Apache License 2.0
|
* [Bootstrap Tabdrop](http://www.eyecon.ro/bootstrap-tabdrop): Apache License 2.0
|
||||||
|
* [css-element-queries](https://github.com/marcj/css-element-queries): MIT
|
||||||
* [Detect Mobile Browser](http://detectmobilebrowsers.com/): Public Domain
|
* [Detect Mobile Browser](http://detectmobilebrowsers.com/): Public Domain
|
||||||
* [Flot](http://www.flotcharts.org/): MIT
|
* [Flot](http://www.flotcharts.org/): MIT
|
||||||
* [JavaScript MD5](https://github.com/blueimp/JavaScript-MD5): MIT
|
* [JavaScript MD5](https://github.com/blueimp/JavaScript-MD5): MIT
|
||||||
@@ -36,6 +37,7 @@
|
|||||||
* [Awesome-Slugify](https://pypi.python.org/pypi/awesome-slugify): GPLv3
|
* [Awesome-Slugify](https://pypi.python.org/pypi/awesome-slugify): GPLv3
|
||||||
* [chainmap](https://bitbucket.org/jeunice/chainmap): Python
|
* [chainmap](https://bitbucket.org/jeunice/chainmap): Python
|
||||||
* [Click](http://click.pocoo.org/): BSD
|
* [Click](http://click.pocoo.org/): BSD
|
||||||
|
* [emoji](https://github.com/carpedm20/emoji/): BSD
|
||||||
* [feedparser](https://github.com/kurtmckee/feedparser): BSD
|
* [feedparser](https://github.com/kurtmckee/feedparser): BSD
|
||||||
* [Flask](http://flask.pocoo.org/): BSD
|
* [Flask](http://flask.pocoo.org/): BSD
|
||||||
* [Flask-Assets](http://github.com/miracle2k/flask-assets): BSD
|
* [Flask-Assets](http://github.com/miracle2k/flask-assets): BSD
|
||||||
@@ -44,6 +46,8 @@
|
|||||||
* [Flask-Markdown](http://github.com/dcolish/flask-markdown): BSD
|
* [Flask-Markdown](http://github.com/dcolish/flask-markdown): BSD
|
||||||
* [Flask-Principal](http://packages.python.org/Flask-Principal/): MIT
|
* [Flask-Principal](http://packages.python.org/Flask-Principal/): MIT
|
||||||
* [future](https://python-future.org/): MIT
|
* [future](https://python-future.org/): MIT
|
||||||
|
* [futures](https://github.com/agronholm/pythonfutures): Python
|
||||||
|
* [monotonic](https://github.com/atdt/monotonic): Apache License 2.0
|
||||||
* [netaddr](https://github.com/drkjam/netaddr/): BSD
|
* [netaddr](https://github.com/drkjam/netaddr/): BSD
|
||||||
* [netifaces](https://bitbucket.org/al45tair/netifaces): MIT
|
* [netifaces](https://bitbucket.org/al45tair/netifaces): MIT
|
||||||
* [pkginfo](http://pypi.python.org/pypi/pkginfo/): Python
|
* [pkginfo](http://pypi.python.org/pypi/pkginfo/): Python
|
||||||
@@ -60,13 +64,14 @@
|
|||||||
* [Tornado](http://www.tornadoweb.org/): Apache License 2.0
|
* [Tornado](http://www.tornadoweb.org/): Apache License 2.0
|
||||||
* [watchdog](http://github.com/gorakhargosh/watchdog): Apache License 2.0
|
* [watchdog](http://github.com/gorakhargosh/watchdog): Apache License 2.0
|
||||||
* [websocket-client](https://github.com/liris/websocket-client): LGPLv3
|
* [websocket-client](https://github.com/liris/websocket-client): LGPLv3
|
||||||
|
* [wrapt](http://wrapt.readthedocs.org/): BSD
|
||||||
|
|
||||||
## Development (testing, documentation generation, etc)
|
## Development (testing, documentation generation, etc)
|
||||||
|
|
||||||
* [ddt](https://github.com/txels/ddt): MIT
|
* [ddt](https://github.com/txels/ddt): MIT
|
||||||
* [mock](https://github.com/testing-cabal/mock): BSD
|
* [mock](https://github.com/testing-cabal/mock): BSD
|
||||||
* [nose](http://pythonhosted.org/nose/): LGPL
|
* [nose](http://pythonhosted.org/nose/): LGPL
|
||||||
* [pypandoc](https://github.com/bebraw/pypandoc): MIT
|
|
||||||
* [Sphinx](http://sphinx-doc.org/): BSD
|
* [Sphinx](http://sphinx-doc.org/): BSD
|
||||||
* [sphinxcontrib-httpdomain](https://bitbucket.org/birkenfeld/sphinx-contrib/src/default/httpdomain/): BSD
|
* [sphinxcontrib-httpdomain](https://bitbucket.org/birkenfeld/sphinx-contrib/src/default/httpdomain/): BSD
|
||||||
|
* [sphinxcontrib-mermad](https://github.com/mgaitan/sphinxcontrib-mermaid): BSD
|
||||||
* [sphinx_rtd_theme](https://github.com/snide/sphinx_rtd_theme/): BSD
|
* [sphinx_rtd_theme](https://github.com/snide/sphinx_rtd_theme/): BSD
|
||||||
@@ -37,6 +37,11 @@
|
|||||||
vertical-align: 10%;
|
vertical-align: 10%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.rst-content .highlight>pre,
|
||||||
|
.rst-content .linenodiv>pre {
|
||||||
|
line-height: 1.5;
|
||||||
|
}
|
||||||
|
|
||||||
/* make code tags non-red again */
|
/* make code tags non-red again */
|
||||||
code,
|
code,
|
||||||
.rst-content tt {
|
.rst-content tt {
|
||||||
@@ -52,3 +57,4 @@ a:visited code,
|
|||||||
.rst-content a:visited tt {
|
.rst-content a:visited tt {
|
||||||
color: #9B59B6 !important;
|
color: #9B59B6 !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1,170 +0,0 @@
|
|||||||
.. _sec-api-apps:
|
|
||||||
|
|
||||||
****
|
|
||||||
Apps
|
|
||||||
****
|
|
||||||
|
|
||||||
.. contents::
|
|
||||||
|
|
||||||
.. _sec-api-apps-sessionkey:
|
|
||||||
|
|
||||||
Session Keys
|
|
||||||
============
|
|
||||||
|
|
||||||
OctoPrint offers a special API key type for apps to use, the so called App Session Key. These keys have a time based
|
|
||||||
validity and are generated by OctoPrint for requesting apps.
|
|
||||||
|
|
||||||
Obtaining those keys is based on a handshake procedure backed by cryptographic signatures using RSA. OctoPrint needs to
|
|
||||||
be aware of apps and their associated public keys (this can be achieved either via entries in ``config.yaml`` or by
|
|
||||||
installing app specific plugins which implement the ``AppPlugin`` type).
|
|
||||||
|
|
||||||
Apps can be registered within OctoPrint via ``config.yaml`` by adding them to the ``api`` > ``apps`` section, using the
|
|
||||||
application's id concatenated with its version as key, with the public key provided as item ``pubkey`` (stripped of the
|
|
||||||
``BEGIN RSA PUBLIC KEY`` and ``END RSA PUBLIC KEY`` separators and also newlines) and optionally also whether the app is
|
|
||||||
enabled or not (defaults to enabled, so can be left out if it's not to be set to disabled explicitly).
|
|
||||||
|
|
||||||
Example:
|
|
||||||
|
|
||||||
.. sourcecode:: yaml
|
|
||||||
|
|
||||||
api:
|
|
||||||
apps:
|
|
||||||
"com.example.my_octoprint_app:0.9":
|
|
||||||
pubkey: MEgCQQDYkr5Fv/YXK5ZL1uwRN4A61IagZaYLGqJ5JJGFo8wDrmpAMRqE9kK4+5hIDblC5DzfEr5oP7OA3tRO48Rf5yInAgMBAAE=
|
|
||||||
enabled: false
|
|
||||||
"com.example.my_octoprint_app:1.0":
|
|
||||||
pubkey: MEgCQQCIWfi7Nc8bcnfZJJtA6a4RyMC+sKBlMOb25OVNNB4L2v0TiGO72jVKR4osvb4oztlbRW5GkdiY0T2LJcfDYvkJAgMBAAE=
|
|
||||||
|
|
||||||
In the example, the app ``com.example.my_octoprint_app`` in version 0.9 has been disabled (e.g. due to the key having
|
|
||||||
leaked) whereas version 1.0 is fully registered with OctoPrint and may verify app session keys.
|
|
||||||
|
|
||||||
|
|
||||||
.. _sec-api-apps-sessionkey-workflow:
|
|
||||||
|
|
||||||
Workflow
|
|
||||||
--------
|
|
||||||
|
|
||||||
Apps perform the handshake by first requesting a temporary key with very limited validity,
|
|
||||||
then sending a message back to OctoPrint containing their id, version, the temporary key and a signature created with their
|
|
||||||
private key over these three pieces of data. OctoPrint then tries to verify the signature and if successful unlocks the
|
|
||||||
key to be used as a fully recognized API key.
|
|
||||||
|
|
||||||
For performing the handshake a special API exists within OctoPrint for which no API key is needed which is described below.
|
|
||||||
|
|
||||||
.. _sec-api-apps-sessionkey-get:
|
|
||||||
|
|
||||||
Obtaining a temporary session key
|
|
||||||
---------------------------------
|
|
||||||
|
|
||||||
.. http:get:: /apps/auth
|
|
||||||
|
|
||||||
Retrieve a temporary session key with a minimum validity. It can only be used as a proper API key after having been
|
|
||||||
:ref:`verified <sec-api-apps-sessionkey-verify>`.
|
|
||||||
|
|
||||||
Returns the temporary session key and the timestamp until it's valid.
|
|
||||||
|
|
||||||
**Example**:
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
GET /apps/auth HTTP/1.1
|
|
||||||
Host: example.com
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
HTTP/1.1 200 OK
|
|
||||||
Content-Type: application/json
|
|
||||||
|
|
||||||
{
|
|
||||||
"unverifiedKey": "F43A844750F74AD080FE9F438D47B33C",
|
|
||||||
"validUntil": 1416220357.011
|
|
||||||
}
|
|
||||||
|
|
||||||
:statuscode 200: No error
|
|
||||||
|
|
||||||
.. _sec-api-apps-sessionkey-verify:
|
|
||||||
|
|
||||||
Verifying a temporary session key
|
|
||||||
---------------------------------
|
|
||||||
|
|
||||||
.. http:post:: /apps/auth
|
|
||||||
|
|
||||||
Verify a formerly :ref:`retrieved <sec-api-apps-sessionkey-get>` temporary session key by providing credentials and a
|
|
||||||
cryptographic signature over these credentials and the temporary key.
|
|
||||||
|
|
||||||
Returns the now verified session key and the new validity.
|
|
||||||
|
|
||||||
**Example**:
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
POST /apps/auth HTTP/1.1
|
|
||||||
Host: example.com
|
|
||||||
Content-Type: application/json
|
|
||||||
|
|
||||||
{
|
|
||||||
"appid": "com.example.my_octoprint_app",
|
|
||||||
"appversion": "1.0",
|
|
||||||
"key": "F43A844750F74AD080FE9F438D47B33C",
|
|
||||||
"_sig": "LGVCiolQWDc4AVn1DOcWljY0cFQxWF4pldVveUjjmL9JhiL0LnCKBbGwZ/CwKBWswFAxPaxQ0kDusVdOmCUa/w=="
|
|
||||||
}
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
HTTP/1.1 200 OK
|
|
||||||
Content-Type: application/json
|
|
||||||
|
|
||||||
{
|
|
||||||
"key": "F43A844750F74AD080FE9F438D47B33C",
|
|
||||||
"validUntil": 1416227497.011
|
|
||||||
}
|
|
||||||
|
|
||||||
.. _sec-api-apps-sessionkey-signature:
|
|
||||||
|
|
||||||
Creating the signature
|
|
||||||
----------------------
|
|
||||||
|
|
||||||
The signature is created by concatenating the ``appid``, ``appversion`` and ``key`` fields, separated by a ``:`` (colon),
|
|
||||||
signing the result with the app's private key using SHA-1 and then BASE64-encoding the result, stripping newlines.
|
|
||||||
|
|
||||||
Example for signature generation using Python and the `Python RSA library <https://pypi.python.org/pypi/rsa>`_:
|
|
||||||
|
|
||||||
.. sourcecode:: python
|
|
||||||
|
|
||||||
import base64
|
|
||||||
import rsa
|
|
||||||
|
|
||||||
appid = "com.example.my_octoprint_app"
|
|
||||||
version = "1.0"
|
|
||||||
unverified_key = "F43A844750F74AD080FE9F438D47B33C"
|
|
||||||
message_to_sign = appid + ":" + version + ":" + unverified_key
|
|
||||||
// => "com.example.my_octoprint_app:1.0:F43A844750F74AD080FE9F438D47B33C"
|
|
||||||
|
|
||||||
private_key = rsa.PrivateKey.load_pkcs1("...")
|
|
||||||
signature = base64.encodestring(rsa.sign(message_to_sign, private_key, "SHA-1")).replace("\n", "")
|
|
||||||
// => "LGVCiolQWDc4AVn1DOcWljY0cFQxWF4pldVveUjjmL9JhiL0LnCKBbGwZ/CwKBWswFAxPaxQ0kDusVdOmCUa/w=="
|
|
||||||
|
|
||||||
|
|
||||||
.. _sec-api-apps-sessionkey-testing:
|
|
||||||
|
|
||||||
Testing your implementation
|
|
||||||
---------------------------
|
|
||||||
|
|
||||||
If you want to use app session keys, here is the key pair with which the above examples were created, in order for you
|
|
||||||
to verify your signature implementation::
|
|
||||||
|
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIBPQIBAAJBAIhZ+Ls1zxtyd9kkm0DprhHIwL6woGUw5vbk5U00Hgva/ROIY7va
|
|
||||||
NUpHiiy9vijO2VtFbkaR2JjRPYslx8Ni+QkCAwEAAQJARK4lFo+FEcs3yR2iQjEy
|
|
||||||
p+yaAbNQJ4hZXlVvltLAYICzOM3kyKx53/eKU59NjskLz9q6QxfleymYPWAgl4NW
|
|
||||||
fQIjAJVH8MjwNcaAquTM9z2OiFi3OC8WgaKOi5W/T+r2+B70wG8CHwDp08dqOZ/u
|
|
||||||
xcBiy4Wzpcme9bckqoVuS3gWMm+YqgcCIwCMFU07kkY0NyumtzxPdIA4F/7OGSWf
|
|
||||||
IHqWFEfvasAddHlbAh8A5UgkB3Zf7Bt+7aFSBnlvve6FWm/XDPL12xYztYgrAiIa
|
|
||||||
W3miN6FjIm+8TDowrk+nyYXG2GZefeY7QXOjYr6tlDn0
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
|
|
||||||
-----BEGIN RSA PUBLIC KEY-----
|
|
||||||
MEgCQQCIWfi7Nc8bcnfZJJtA6a4RyMC+sKBlMOb25OVNNB4L2v0TiGO72jVKR4os
|
|
||||||
vb4oztlbRW5GkdiY0T2LJcfDYvkJAgMBAAE=
|
|
||||||
-----END RSA PUBLIC KEY-----
|
|
||||||
|
|
||||||
@@ -39,7 +39,7 @@ Get connection settings
|
|||||||
"options": {
|
"options": {
|
||||||
"ports": ["/dev/ttyACM0", "VIRTUAL"],
|
"ports": ["/dev/ttyACM0", "VIRTUAL"],
|
||||||
"baudrates": [250000, 230400, 115200, 57600, 38400, 19200, 9600],
|
"baudrates": [250000, 230400, 115200, 57600, 38400, 19200, 9600],
|
||||||
"printerProfiles": [{"name": "Default", id: "_default"}],
|
"printerProfiles": [{"name": "Default", "id": "_default"}],
|
||||||
"portPreference": "/dev/ttyACM0",
|
"portPreference": "/dev/ttyACM0",
|
||||||
"baudratePreference": 250000,
|
"baudratePreference": 250000,
|
||||||
"printerProfilePreference": "_default",
|
"printerProfilePreference": "_default",
|
||||||
@@ -59,7 +59,7 @@ Issue a connection command
|
|||||||
Issue a connection command. Currently available command are:
|
Issue a connection command. Currently available command are:
|
||||||
|
|
||||||
connect
|
connect
|
||||||
Instructs OctoPrint to connect to the printer. Additional parameters are:
|
Instructs OctoPrint to connect or, if already connected, reconnect to the printer. Additional parameters are:
|
||||||
|
|
||||||
* ``port``: Optional, specific port to connect to. If not set the current ``portPreference`` will be used, or if
|
* ``port``: Optional, specific port to connect to. If not set the current ``portPreference`` will be used, or if
|
||||||
no preference is available auto detection will be attempted.
|
no preference is available auto detection will be attempted.
|
||||||
|
|||||||
@@ -44,6 +44,14 @@ Printer State
|
|||||||
- 1
|
- 1
|
||||||
- Boolean
|
- Boolean
|
||||||
- ``true`` if the printer is currently printing, ``false`` otherwise
|
- ``true`` if the printer is currently printing, ``false`` otherwise
|
||||||
|
* - ``flags.pausing``
|
||||||
|
- 1
|
||||||
|
- Boolean
|
||||||
|
- ``true`` if the printer is currently printing and in the process of pausing, ``false`` otherwise
|
||||||
|
* - ``flags.cancelling``
|
||||||
|
- 1
|
||||||
|
- Boolean
|
||||||
|
- ``true`` if the printer is currently printing and in the process of pausing, ``false`` otherwise
|
||||||
* - ``flags.sdReady``
|
* - ``flags.sdReady``
|
||||||
- 1
|
- 1
|
||||||
- Boolean
|
- Boolean
|
||||||
@@ -232,12 +240,18 @@ File information
|
|||||||
* - ``name``
|
* - ``name``
|
||||||
- 1
|
- 1
|
||||||
- String
|
- String
|
||||||
- The name of the file without path. E.g. "file.gco" for a file "file.gco" located anywhere in the file system.
|
- The name of the file without path. E.g. "file.gco" for a file "file.gco" located anywhere in the file system. Currently
|
||||||
|
this will always fit into ASCII.
|
||||||
|
* - ``display``
|
||||||
|
- 1
|
||||||
|
- String
|
||||||
|
- The name of the file without the path, this time potentially with non-ASCII unicode characters.
|
||||||
|
E.g. "a turtle 🐢.gco" for a file "a_turtle_turtle.gco" located anywhere in the file system.
|
||||||
* - ``path``
|
* - ``path``
|
||||||
- 1
|
- 1
|
||||||
- String
|
- String
|
||||||
- The path to the file within the location. E.g. "folder/subfolder/file.gco" for a file "file.gco" located within
|
- The path to the file within the location. E.g. "folder/subfolder/file.gco" for a file "file.gco" located within
|
||||||
"folder" and "subfolder" relative to the root of the location.
|
"folder" and "subfolder" relative to the root of the location. Currently this will always fit into ASCII.
|
||||||
* - ``type``
|
* - ``type``
|
||||||
- 1
|
- 1
|
||||||
- String
|
- String
|
||||||
@@ -249,8 +263,11 @@ File information
|
|||||||
- Path to type of file in extension tree. E.g. ``["model", "stl"]`` for ``.stl`` files, or ``["machinecode", "gcode"]``
|
- Path to type of file in extension tree. E.g. ``["model", "stl"]`` for ``.stl`` files, or ``["machinecode", "gcode"]``
|
||||||
for ``.gcode`` files. ``["folder"]`` for folders.
|
for ``.gcode`` files. ``["folder"]`` for folders.
|
||||||
|
|
||||||
Additional properties depend on ``type``. For a ``type`` value of ``folder``, see "Folders". For any other value
|
Additional properties depend on ``type``.
|
||||||
see "Files".
|
For a ``type`` value of ``folder``, see :ref:`Folders <sec-api-datamodel-files-folders>`.
|
||||||
|
For any other value see :ref:`Files <sec-api-datamodel-files-files>`.
|
||||||
|
|
||||||
|
.. _sec-api-datamodel-files-folders:
|
||||||
|
|
||||||
Folders
|
Folders
|
||||||
'''''''
|
'''''''
|
||||||
@@ -266,13 +283,14 @@ Folders
|
|||||||
* - ``children``
|
* - ``children``
|
||||||
- 0..*
|
- 0..*
|
||||||
- Array of :ref:`File information items <sec-api-datamodel-files-file>`
|
- Array of :ref:`File information items <sec-api-datamodel-files-file>`
|
||||||
- Contained children for entries of type ``folder``. Will only include children in subfolders in recursive
|
- Contained children for entries of type ``folder``. On non recursive listings only present on first level
|
||||||
listings. Not present in non recursive listings, this might be revisited in the future.
|
sub folders!
|
||||||
* - ``size``
|
* - ``size``
|
||||||
- 0..1
|
- 0..1
|
||||||
- Number
|
- Number
|
||||||
- The size of all files contained in the folder and its subfolders. Not present in non recursive listings, this might
|
- The size of all files contained in the folder and its subfolders. Not present in non recursive listings!
|
||||||
be revisited in the future.
|
|
||||||
|
.. _sec-api-datamodel-files-files:
|
||||||
|
|
||||||
Files
|
Files
|
||||||
'''''
|
'''''
|
||||||
@@ -329,11 +347,17 @@ Abridged file or folder information
|
|||||||
- 1
|
- 1
|
||||||
- String
|
- String
|
||||||
- The name of the file or folder without path. E.g. "file.gco" for a file "file.gco" located anywhere in the file system.
|
- The name of the file or folder without path. E.g. "file.gco" for a file "file.gco" located anywhere in the file system.
|
||||||
|
Currently this will always fit into ASCII.
|
||||||
|
* - ``display``
|
||||||
|
- 1
|
||||||
|
- String
|
||||||
|
- The name of the file without the path, this potentially with non-ASCII unicode characters.
|
||||||
|
E.g. "a turtle 🐢.gco" for a file "a_turtle_turtle.gco" located anywhere in the file system.
|
||||||
* - ``path``
|
* - ``path``
|
||||||
- 1
|
- 1
|
||||||
- String
|
- String
|
||||||
- The path to the file or folder within the location. E.g. "folder/subfolder/file.gco" for a file "file.gco" located within
|
- The path to the file or folder within the location. E.g. "folder/subfolder/file.gco" for a file "file.gco" located within
|
||||||
"folder" and "subfolder" relative to the root of the location.
|
"folder" and "subfolder" relative to the root of the location. Currently this will always fit into ASCII.
|
||||||
* - ``origin``
|
* - ``origin``
|
||||||
- 1
|
- 1
|
||||||
- String, either ``local`` or ``sdcard``
|
- String, either ``local`` or ``sdcard``
|
||||||
@@ -365,14 +389,58 @@ GCODE analysis information
|
|||||||
- 0..1
|
- 0..1
|
||||||
- Object
|
- Object
|
||||||
- The estimated usage of filament
|
- The estimated usage of filament
|
||||||
* - ``filament.length``
|
* - ``filament.tool{n}.length``
|
||||||
- 0..1
|
- 0..1
|
||||||
- Integer
|
- Integer
|
||||||
- The length of filament used, in mm
|
- The length of filament used, in mm
|
||||||
* - ``filament.volume``
|
* - ``filament.tool{n}.volume``
|
||||||
- 0..1
|
- 0..1
|
||||||
- Float
|
- Float
|
||||||
- The volume of filament used, in cm³
|
- The volume of filament used, in cm³
|
||||||
|
* - ``dimensions``
|
||||||
|
- 0..1
|
||||||
|
- Object
|
||||||
|
- Information regarding the size of the printed model
|
||||||
|
* - ``dimensions.depth``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The depth of the printed model, in mm
|
||||||
|
* - ``dimensions.height``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The height of the printed model, in mm
|
||||||
|
* - ``dimensions.width``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The width of the printed model, in mm
|
||||||
|
* - ``printingArea``
|
||||||
|
- 0..1
|
||||||
|
- Object
|
||||||
|
- Information regarding the size of the printing area
|
||||||
|
* - ``printingArea.maxX``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The maximum X coordinate of the printed model, in mm
|
||||||
|
* - ``printingArea.maxY``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The maximum Y coordinate of the printed model, in mm
|
||||||
|
* - ``printingArea.maxZ``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The maximum Z coordinate of the printed model, in mm
|
||||||
|
* - ``printingArea.minX``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The minimum X coordinate of the printed model, in mm
|
||||||
|
* - ``printingArea.minY``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The minimum Y coordinate of the printed model, in mm
|
||||||
|
* - ``printingArea.minZ``
|
||||||
|
- 0..1
|
||||||
|
- Float
|
||||||
|
- The minimum Z coordinate of the printed model, in mm
|
||||||
|
|
||||||
|
|
||||||
.. _sec-api-datamodel-files-ref:
|
.. _sec-api-datamodel-files-ref:
|
||||||
@@ -401,4 +469,3 @@ References
|
|||||||
- URL
|
- URL
|
||||||
- The model from which this file was generated (e.g. an STL, currently not used). Never present for
|
- The model from which this file was generated (e.g. an STL, currently not used). Never present for
|
||||||
folders.
|
folders.
|
||||||
|
|
||||||
@@ -82,8 +82,37 @@ Retrieve all files
|
|||||||
"path": "folderA",
|
"path": "folderA",
|
||||||
"type": "folder",
|
"type": "folder",
|
||||||
"typePath": ["folder"],
|
"typePath": ["folder"],
|
||||||
"children": [],
|
"children": [
|
||||||
"size": 1334
|
{
|
||||||
|
"name": "whistle_v2_copy.gcode",
|
||||||
|
"path": "whistle_v2_copy.gcode",
|
||||||
|
"type": "machinecode",
|
||||||
|
"typePath": ["machinecode", "gcode"],
|
||||||
|
"hash": "...",
|
||||||
|
"size": 1468987,
|
||||||
|
"date": 1378847754,
|
||||||
|
"origin": "local",
|
||||||
|
"refs": {
|
||||||
|
"resource": "http://example.com/api/files/local/folderA/whistle_v2_copy.gcode",
|
||||||
|
"download": "http://example.com/downloads/files/local/folderA/whistle_v2_copy.gcode"
|
||||||
|
},
|
||||||
|
"gcodeAnalysis": {
|
||||||
|
"estimatedPrintTime": 1188,
|
||||||
|
"filament": {
|
||||||
|
"length": 810,
|
||||||
|
"volume": 5.36
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"print": {
|
||||||
|
"failure": 4,
|
||||||
|
"success": 23,
|
||||||
|
"last": {
|
||||||
|
"date": 1387144346,
|
||||||
|
"success": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"free": "3.2GB"
|
"free": "3.2GB"
|
||||||
@@ -192,6 +221,7 @@ Retrieve all files
|
|||||||
"refs": {
|
"refs": {
|
||||||
"resource": "http://example.com/api/files/local/folderA/subfolder",
|
"resource": "http://example.com/api/files/local/folderA/subfolder",
|
||||||
}
|
}
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"size": 1334,
|
"size": 1334,
|
||||||
"refs": {
|
"refs": {
|
||||||
@@ -442,7 +472,7 @@ Upload file or create folder
|
|||||||
:form select: Whether to select the file directly after upload (``true``) or not (``false``). Optional, defaults
|
:form select: Whether to select the file directly after upload (``true``) or not (``false``). Optional, defaults
|
||||||
to ``false``. Ignored when creating a folder.
|
to ``false``. Ignored when creating a folder.
|
||||||
:form print: Whether to start printing the file directly after upload (``true``) or not (``false``). If set, ``select``
|
:form print: Whether to start printing the file directly after upload (``true``) or not (``false``). If set, ``select``
|
||||||
is implicitely ``true`` as well. Optional, defaults to ``false``. Ignored when creating a folder.
|
is implicitly ``true`` as well. Optional, defaults to ``false``. Ignored when creating a folder.
|
||||||
:form userdata: [Optional] An optional string that if specified will be interpreted as JSON and then saved along
|
:form userdata: [Optional] An optional string that if specified will be interpreted as JSON and then saved along
|
||||||
with the file as metadata (metadata key ``userdata``). Ignored when creating a folder.
|
with the file as metadata (metadata key ``userdata``). Ignored when creating a folder.
|
||||||
:form foldername: The name of the folder to create. Ignored when uploading a file.
|
:form foldername: The name of the folder to create. Ignored when uploading a file.
|
||||||
|
|||||||
@@ -11,9 +11,12 @@ General information
|
|||||||
Authorization
|
Authorization
|
||||||
=============
|
=============
|
||||||
|
|
||||||
OctoPrint's API expects an API key to be supplied with each request. This API key can be either the globally
|
If :ref:`Access Control <sec-features-access_control>` is enabled OctoPrint's API expects an API key to be supplied with each request. This API
|
||||||
configured one, a user specific one if "Access Control" is enabled or an ref:`App Session Key <sec-api-apps-sessionkey>`.
|
key can be either the globally configured one, a user specific one or an app and user specific one as generated by the
|
||||||
Users are able to generate and revoke their custom API key via the "Change password" dialog.
|
authorization workflow implemented by the bundled :ref:`Application Keys Plugin <sec-bundledplugins-appkeys>` (since 1.3.10).
|
||||||
|
|
||||||
|
Clients are advised to implement the :ref:`Application Keys Plugin workflow <sec-bundledplugins-appkeys-workflow>` first and
|
||||||
|
fallback on directing the user to manually supply the the user specific API key. The global key should rarely be used.
|
||||||
|
|
||||||
The API key must be supplied in the custom HTTP header ``X-Api-Key``, e.g.
|
The API key must be supplied in the custom HTTP header ``X-Api-Key``, e.g.
|
||||||
|
|
||||||
@@ -23,8 +26,6 @@ The API key must be supplied in the custom HTTP header ``X-Api-Key``, e.g.
|
|||||||
Host: example.com
|
Host: example.com
|
||||||
X-Api-Key: abcdef...
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
If it is missing or included but invalid, OctoPrint will directly return a response with status :http:statuscode:`401`.
|
|
||||||
|
|
||||||
For testing purposes it is also possible to supply the API key via a query parameter ``apikey``, e.g.
|
For testing purposes it is also possible to supply the API key via a query parameter ``apikey``, e.g.
|
||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
@@ -34,6 +35,24 @@ For testing purposes it is also possible to supply the API key via a query param
|
|||||||
|
|
||||||
Please be advised that clients should use the header field variant if at all possible.
|
Please be advised that clients should use the header field variant if at all possible.
|
||||||
|
|
||||||
|
If the key is missing or invalid, OctoPrint will treat the request as it would any unauthenticated anonymous request to the endpoint.
|
||||||
|
Consequently, if the bundled :ref:`ForceLogin plugin <sec-bundledplugins-forcelogin>` is active (which is the default), that means
|
||||||
|
that any requests without or with an invalid API key targeting other API endpoints than :ref:`Login <sec-api-general-login>`
|
||||||
|
will be denied with a :http:statuscode:`403`.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
If :ref:`Access Control <sec-features-access_control>` is disabled, OctoPrint will treat any unauthenticated anonymous requests and thus also requests
|
||||||
|
with an invalid or outright missing API key as requests with full admin rights!
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
The API key requirements changed in 1.3.11. Up to that version, even if Access Control was disabled, all requests needed to
|
||||||
|
be supplied with an API Key. To make the webinterface work under these circumstances, an unauthenticated anonymous API key was injected into the
|
||||||
|
HTML page and also available on the :ref:`Push API <sec-api-push>`. The presence and ready availability of this unauthenticated
|
||||||
|
anonymous "UI API key" caused confusion and false alarm among users and didn't contribute to the security of the platform in a
|
||||||
|
meaningful way, so it was finally abandoned in 1.3.11.
|
||||||
|
|
||||||
.. _fig-api-general-globalapikey:
|
.. _fig-api-general-globalapikey:
|
||||||
.. figure:: ../images/settings-global-api-key.png
|
.. figure:: ../images/settings-global-api-key.png
|
||||||
:align: center
|
:align: center
|
||||||
@@ -55,17 +74,12 @@ Please be advised that clients should use the header field variant if at all pos
|
|||||||
|
|
||||||
The API key options in the "Change password" dialog. Users can generate and revoke their custom API key here.
|
The API key options in the "Change password" dialog. Users can generate and revoke their custom API key here.
|
||||||
|
|
||||||
.. note::
|
|
||||||
OctoPrint's web interface uses a custom API key that is freshly generated on every server start. This key is not
|
|
||||||
intended to be used by any other client and would not be very useful in any case, since it basically represents
|
|
||||||
a completely anonymous client.
|
|
||||||
|
|
||||||
.. _sec-api-general-contenttype:
|
.. _sec-api-general-contenttype:
|
||||||
|
|
||||||
Content Type
|
Content Type
|
||||||
============
|
============
|
||||||
|
|
||||||
If not otherwise stated OctoPrint's API expects request bodies and issues response bodies as ``Content-Type: application/json``.
|
If not otherwise stated, OctoPrint's API expects request bodies and issues response bodies as ``Content-Type: application/json``.
|
||||||
|
|
||||||
.. _sec-api-general-encoding:
|
.. _sec-api-general-encoding:
|
||||||
|
|
||||||
@@ -120,3 +134,94 @@ If CORS is not enabled you will get errors like the following::
|
|||||||
XMLHttpRequest cannot load http://localhost:8081/api/files. No 'Access-Control-Allow-Origin'
|
XMLHttpRequest cannot load http://localhost:8081/api/files. No 'Access-Control-Allow-Origin'
|
||||||
header is present on the requested resource.
|
header is present on the requested resource.
|
||||||
|
|
||||||
|
.. _sec-api-general-login:
|
||||||
|
|
||||||
|
Login
|
||||||
|
=====
|
||||||
|
|
||||||
|
.. http:post:: /api/login
|
||||||
|
|
||||||
|
Creates a login session or retrieves information about the currently existing session ("passive login").
|
||||||
|
|
||||||
|
Can be used in one of two ways: to login a user via username and password and create a persistent session (usually
|
||||||
|
from a UI in the browser), or to retrieve information about the active user (from an existing session or an API key)
|
||||||
|
via the ``passive`` flag.
|
||||||
|
|
||||||
|
Will return a :http:statuscode:`200` with a :ref:`login response <sec-api-general-datamodel-login>` on successful
|
||||||
|
login, whether active or passive. The active (username/password) login may also return a :http:statuscode:`401` in
|
||||||
|
case of a username/password mismatch or unknown user and a :http:statuscode:`403` in case of a deactivated account.
|
||||||
|
|
||||||
|
:json passive: If present, performs a passive login only, returning information about the current user that's
|
||||||
|
active either through an existing session or the used API key
|
||||||
|
:json user: (active login only) Username
|
||||||
|
:json pass: (active login only) Password
|
||||||
|
:json remember: (active login only) Whether to set a "remember me" cookie on the session
|
||||||
|
:status 200: Successful login
|
||||||
|
:status 401: Username/password mismatch or unknown user
|
||||||
|
:status 403: Deactivated account
|
||||||
|
|
||||||
|
.. _sec-api-general-logout:
|
||||||
|
|
||||||
|
Logout
|
||||||
|
======
|
||||||
|
|
||||||
|
.. http:post:: /api/logout
|
||||||
|
|
||||||
|
Ends the current login session of the current user.
|
||||||
|
|
||||||
|
Only makes sense in the context of browser based workflows.
|
||||||
|
|
||||||
|
Will return a :http:statuscode:`204`.
|
||||||
|
|
||||||
|
:status 204: No error
|
||||||
|
|
||||||
|
.. _sec-api-general-datamodel:
|
||||||
|
|
||||||
|
Data model
|
||||||
|
==========
|
||||||
|
|
||||||
|
.. _sec-api-general-datamodel-login:
|
||||||
|
|
||||||
|
Login response
|
||||||
|
--------------
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``name``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- the user's name/id
|
||||||
|
* - ``active``
|
||||||
|
- 1
|
||||||
|
- boolean
|
||||||
|
- Whether the user's account is active or not
|
||||||
|
* - ``admin``
|
||||||
|
- 1
|
||||||
|
- boolean
|
||||||
|
- Whether the user has admin rights or not
|
||||||
|
* - ``user``
|
||||||
|
- 1
|
||||||
|
- boolean
|
||||||
|
- Whether the user has user rights or not (always ``true``)
|
||||||
|
* - ``apikey``
|
||||||
|
- 1
|
||||||
|
- string or None
|
||||||
|
- The user's API key, if set
|
||||||
|
* - ``settings``
|
||||||
|
- 1
|
||||||
|
- dict
|
||||||
|
- The user's settings, if any
|
||||||
|
* - ``session``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- The session key, can be used to authenticate with the ``auth`` message on the :ref:`push API <sec-api-push>`.
|
||||||
|
* - ``_is_external_client``
|
||||||
|
- 1
|
||||||
|
- boolean
|
||||||
|
- Whether the client that made the request got detected as external from the local network or not.
|
||||||
@@ -4,6 +4,9 @@
|
|||||||
Job operations
|
Job operations
|
||||||
**************
|
**************
|
||||||
|
|
||||||
|
Use these operations to query the currently selected file and start/cancel/restart/pause the
|
||||||
|
actual print job.
|
||||||
|
|
||||||
.. contents::
|
.. contents::
|
||||||
|
|
||||||
.. _sec-api-jobs-command:
|
.. _sec-api-jobs-command:
|
||||||
@@ -209,7 +212,8 @@ Retrieve information about the current job
|
|||||||
"filepos": 337942,
|
"filepos": 337942,
|
||||||
"printTime": 276,
|
"printTime": 276,
|
||||||
"printTimeLeft": 912
|
"printTimeLeft": 912
|
||||||
}
|
},
|
||||||
|
"state": "Printing"
|
||||||
}
|
}
|
||||||
|
|
||||||
:statuscode 200: No error
|
:statuscode 200: No error
|
||||||
@@ -240,4 +244,8 @@ Job information response
|
|||||||
- 1
|
- 1
|
||||||
- :ref:`sec-api-datamodel-jobs-progress`
|
- :ref:`sec-api-datamodel-jobs-progress`
|
||||||
- Information regarding the progress of the current print job
|
- Information regarding the progress of the current print job
|
||||||
|
* - ``state``
|
||||||
|
- 1
|
||||||
|
- String
|
||||||
|
- A textual representation of the current state of the job, i.e. "Operational", "Printing", "Pausing", "Paused",
|
||||||
|
"Cancelling", "Error" or "Offline".
|
||||||
@@ -39,9 +39,7 @@ Retrieve installed language packs
|
|||||||
"_core": {
|
"_core": {
|
||||||
"identifier": "_core",
|
"identifier": "_core",
|
||||||
"name": "Core",
|
"name": "Core",
|
||||||
"languages": [
|
"languages": []
|
||||||
...
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"some_plugin": {
|
"some_plugin": {
|
||||||
"identifier": "some_plugin",
|
"identifier": "some_plugin",
|
||||||
@@ -61,7 +59,6 @@ Retrieve installed language packs
|
|||||||
"last_update": 1470859680,
|
"last_update": 1470859680,
|
||||||
"author": "The italian Transifex Team"
|
"author": "The italian Transifex Team"
|
||||||
}
|
}
|
||||||
...
|
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -124,9 +121,7 @@ Delete a language pack
|
|||||||
"_core": {
|
"_core": {
|
||||||
"identifier": "_core",
|
"identifier": "_core",
|
||||||
"name": "Core",
|
"name": "Core",
|
||||||
"languages": [
|
"languages": []
|
||||||
...
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"some_plugin": {
|
"some_plugin": {
|
||||||
"identifier": "some_plugin",
|
"identifier": "some_plugin",
|
||||||
@@ -138,8 +133,7 @@ Delete a language pack
|
|||||||
"locale_english": "German",
|
"locale_english": "German",
|
||||||
"last_update": 1474574597,
|
"last_update": 1474574597,
|
||||||
"author": "Gina Häußge"
|
"author": "Gina Häußge"
|
||||||
},
|
}
|
||||||
...
|
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,172 +4,9 @@
|
|||||||
Log file management
|
Log file management
|
||||||
*******************
|
*******************
|
||||||
|
|
||||||
.. note::
|
Log file management (and logging configuration) was moved into a bundled plugin in OctoPrint 1.3.7. Refer to
|
||||||
|
:ref:`the Logging's plugins API <sec-bundledplugins-logging-api>` for the API documentation.
|
||||||
|
|
||||||
All log file management operations require admin rights.
|
The former endpoints ``/api/logs`` and ``api/logs/<path>`` are marked as deprecated but still work for now. New
|
||||||
|
client implementations should directly use the new endpoints provided by the bundled plugin. Existing implementations
|
||||||
.. contents::
|
should adapt their endpoints as soon as possible.
|
||||||
|
|
||||||
.. _sec-api-logs-list:
|
|
||||||
|
|
||||||
Retrieve a list of available log files
|
|
||||||
======================================
|
|
||||||
|
|
||||||
.. http:get:: /api/logs
|
|
||||||
|
|
||||||
Retrieve information regarding all log files currently available and regarding the disk space still available
|
|
||||||
in the system on the location the log files are being stored.
|
|
||||||
|
|
||||||
Returns a :ref:`Logfile Retrieve response <sec-api-logs-datamodel-retrieveresponse>`.
|
|
||||||
|
|
||||||
**Example**
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
GET /api/logs HTTP/1.1
|
|
||||||
Host: example.com
|
|
||||||
X-Api-Key: abcdef...
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
HTTP/1.1 200 OK
|
|
||||||
Content-Type: application/json
|
|
||||||
|
|
||||||
{
|
|
||||||
"files" : [
|
|
||||||
{
|
|
||||||
"date" : 1393158814,
|
|
||||||
"name" : "octoprint.log",
|
|
||||||
"size" : 43712,
|
|
||||||
"refs": {
|
|
||||||
"resource": "http://example.com/api/logs/octoprint.log",
|
|
||||||
"download": "http://example.com/downloads/logs/octoprint.log"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"date" : 1392628936,
|
|
||||||
"name" : "octoprint.log.2014-02-17",
|
|
||||||
"size" : 13205,
|
|
||||||
"refs": {
|
|
||||||
"resource": "http://example.com/api/logs/octoprint.log.2014-02-17",
|
|
||||||
"download": "http://example.com/downloads/logs/octoprint.log.2014-02-17"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"date" : 1393158814,
|
|
||||||
"name" : "serial.log",
|
|
||||||
"size" : 1798419,
|
|
||||||
"refs": {
|
|
||||||
"resource": "http://example.com/api/logs/serial.log",
|
|
||||||
"download": "http://example.com/downloads/logs/serial.log"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"free": 12237201408
|
|
||||||
}
|
|
||||||
|
|
||||||
:statuscode 200: No error
|
|
||||||
:statuscode 403: If the given API token did not have admin rights associated with it
|
|
||||||
|
|
||||||
.. _sec-api-logs-delete:
|
|
||||||
|
|
||||||
Delete a specific logfile
|
|
||||||
=========================
|
|
||||||
|
|
||||||
.. http:delete:: /api/logs/(path:filename)
|
|
||||||
|
|
||||||
Delete the selected log file with name `filename`.
|
|
||||||
|
|
||||||
Returns a :http:statuscode:`204` after successful deletion.
|
|
||||||
|
|
||||||
**Example Request**
|
|
||||||
|
|
||||||
.. sourcecode:: http
|
|
||||||
|
|
||||||
DELETE /api/logs/octoprint.log.2014-02-17 HTTP/1.1
|
|
||||||
Host: example.com
|
|
||||||
X-Api-Key: abcdef...
|
|
||||||
|
|
||||||
:param filename: The filename of the log file to delete
|
|
||||||
:statuscode 204: No error
|
|
||||||
:statuscode 403: If the given API token did not have admin rights associated with it
|
|
||||||
:statuscode 404: If the file was not found
|
|
||||||
|
|
||||||
.. _sec-api-logs-datamodel:
|
|
||||||
|
|
||||||
Data model
|
|
||||||
==========
|
|
||||||
|
|
||||||
.. _sec-api-logs-datamodel-retrieveresponse:
|
|
||||||
|
|
||||||
Logfile Retrieve Response
|
|
||||||
-------------------------
|
|
||||||
|
|
||||||
.. list-table::
|
|
||||||
:widths: 15 5 10 30
|
|
||||||
:header-rows: 1
|
|
||||||
|
|
||||||
* - Name
|
|
||||||
- Multiplicity
|
|
||||||
- Type
|
|
||||||
- Description
|
|
||||||
* - ``files``
|
|
||||||
- 0..*
|
|
||||||
- Array of :ref:`File information items <sec-api-logs-datamodel-fileinfo>`
|
|
||||||
- The list of requested files. Might be an empty list if no files are available
|
|
||||||
* - ``free``
|
|
||||||
- 1
|
|
||||||
- String
|
|
||||||
- The amount of disk space in bytes available in the local disk space (refers to OctoPrint's ``logs`` folder).
|
|
||||||
|
|
||||||
.. _sec-api-logs-datamodel-fileinfo:
|
|
||||||
|
|
||||||
File information
|
|
||||||
----------------
|
|
||||||
|
|
||||||
.. list-table::
|
|
||||||
:widths: 15 5 10 30
|
|
||||||
:header-rows: 1
|
|
||||||
|
|
||||||
* - Name
|
|
||||||
- Multiplicity
|
|
||||||
- Type
|
|
||||||
- Description
|
|
||||||
* - ``name``
|
|
||||||
- 1
|
|
||||||
- String
|
|
||||||
- The name of the file
|
|
||||||
* - ``size``
|
|
||||||
- 1
|
|
||||||
- Number
|
|
||||||
- The size of the file in bytes.
|
|
||||||
* - ``date``
|
|
||||||
- 1
|
|
||||||
- Unix timestamp
|
|
||||||
- The timestamp when this file was last modified.
|
|
||||||
* - ``refs``
|
|
||||||
- 1
|
|
||||||
- :ref:`sec-api-logs-datamodel-ref`
|
|
||||||
- References relevant to this file
|
|
||||||
|
|
||||||
.. _sec-api-logs-datamodel-ref:
|
|
||||||
|
|
||||||
References
|
|
||||||
----------
|
|
||||||
|
|
||||||
.. list-table::
|
|
||||||
:widths: 15 5 10 30
|
|
||||||
:header-rows: 1
|
|
||||||
|
|
||||||
* - Name
|
|
||||||
- Multiplicity
|
|
||||||
- Type
|
|
||||||
- Description
|
|
||||||
* - ``resource``
|
|
||||||
- 1
|
|
||||||
- URL
|
|
||||||
- The resource that represents the file (e.g. for deleting)
|
|
||||||
* - ``download``
|
|
||||||
- 1
|
|
||||||
- URL
|
|
||||||
- The download URL for the file
|
|
||||||
@@ -22,6 +22,11 @@ Bed
|
|||||||
corresponding resource returns temperature information including an optional history. Note that Bed commands
|
corresponding resource returns temperature information including an optional history. Note that Bed commands
|
||||||
are only available if the currently selected printer profile has a heated bed.
|
are only available if the currently selected printer profile has a heated bed.
|
||||||
See :ref:`sec-api-printer-bedcommand`.
|
See :ref:`sec-api-printer-bedcommand`.
|
||||||
|
Chamber
|
||||||
|
Chamber commands allow setting the temperature and temperature offset for the printer's heated chamber. Querying
|
||||||
|
the corresponding resource returns temperature information including an option history. Note that Chamber commands
|
||||||
|
are only available if the currently selected printer profile has a heated chamber.
|
||||||
|
See :ref:`sec-api-printer-chambercommand`.
|
||||||
SD card
|
SD card
|
||||||
SD commands allow initialization, refresh and release of the printer's SD card (if available). Querying the
|
SD commands allow initialization, refresh and release of the printer's SD card (if available). Querying the
|
||||||
corresponding resource returns the current SD card state.
|
corresponding resource returns the current SD card state.
|
||||||
@@ -37,7 +42,7 @@ Besides that, OctoPrint also provides a :ref:`full state report of the printer <
|
|||||||
OctoPrint's internal webserver is single threaded and can only handle one request at a time. This is
|
OctoPrint's internal webserver is single threaded and can only handle one request at a time. This is
|
||||||
not a problem generally since asynchronous programming allows to just have one request which is waiting for
|
not a problem generally since asynchronous programming allows to just have one request which is waiting for
|
||||||
data from a long running backend operation to sleep while handling other requests. The internal framework
|
data from a long running backend operation to sleep while handling other requests. The internal framework
|
||||||
used for providing the REST API though, Flask, is based on WSGI, which is synchrounous in nature. This means
|
used for providing the REST API though, Flask, is based on WSGI, which is synchronous in nature. This means
|
||||||
that it is impossible to wait in a non blocking wait while handling a request on the REST API. So in order to
|
that it is impossible to wait in a non blocking wait while handling a request on the REST API. So in order to
|
||||||
return the response of a command sent to the printer, the single thread of the webserver would have to be blocked
|
return the response of a command sent to the printer, the single thread of the webserver would have to be blocked
|
||||||
by the API while the response wasn't available yet. Which in turn would mean that the whole web server would
|
by the API while the response wasn't available yet. Which in turn would mean that the whole web server would
|
||||||
@@ -149,6 +154,8 @@ Retrieve the current printer state
|
|||||||
"operational": true,
|
"operational": true,
|
||||||
"paused": false,
|
"paused": false,
|
||||||
"printing": false,
|
"printing": false,
|
||||||
|
"cancelling": false,
|
||||||
|
"pausing": false,
|
||||||
"sdReady": true,
|
"sdReady": true,
|
||||||
"error": false,
|
"error": false,
|
||||||
"ready": true,
|
"ready": true,
|
||||||
@@ -179,6 +186,8 @@ Retrieve the current printer state
|
|||||||
"operational": true,
|
"operational": true,
|
||||||
"paused": false,
|
"paused": false,
|
||||||
"printing": false,
|
"printing": false,
|
||||||
|
"cancelling": false,
|
||||||
|
"pausing": false,
|
||||||
"sdReady": true,
|
"sdReady": true,
|
||||||
"error": false,
|
"error": false,
|
||||||
"ready": true,
|
"ready": true,
|
||||||
@@ -213,9 +222,9 @@ Issue a print head command
|
|||||||
* ``z``: Optional. Amount/coordinate to jog print head on z axis, must be a valid number corresponding to the distance to travel in mm.
|
* ``z``: Optional. Amount/coordinate to jog print head on z axis, must be a valid number corresponding to the distance to travel in mm.
|
||||||
* ``absolute``: Optional. Boolean value specifying whether to move relative to current position (provided
|
* ``absolute``: Optional. Boolean value specifying whether to move relative to current position (provided
|
||||||
axes values are relative amounts) or to absolute position (provided axes values are coordinates)
|
axes values are relative amounts) or to absolute position (provided axes values are coordinates)
|
||||||
* ``speed``: Optiona. Speed at which to move. If not provided, minimum speed for all selected axes from printer
|
* ``speed``: Optional. Speed at which to move. If not provided, minimum speed for all selected axes from printer
|
||||||
profile will be used. If provided but ``false``, no speed parameter will be appended to the command. Otherwise
|
profile will be used. If provided but ``false``, no speed parameter will be appended to the command. Otherwise
|
||||||
interpreted as an integer signifying the speed in mm/s, to append to the command.
|
interpreted as an integer signifying the speed in mm/min, to append to the command.
|
||||||
|
|
||||||
home
|
home
|
||||||
Homes the print head in all of the given axes. Additional parameters are:
|
Homes the print head in all of the given axes. Additional parameters are:
|
||||||
@@ -223,9 +232,9 @@ Issue a print head command
|
|||||||
* ``axes``: A list of axes which to home, valid values are one or more of ``x``, ``y``, ``z``.
|
* ``axes``: A list of axes which to home, valid values are one or more of ``x``, ``y``, ``z``.
|
||||||
|
|
||||||
feedrate
|
feedrate
|
||||||
Changes the feedrate factor to apply to the movement's of the axes.
|
Changes the feedrate factor to apply to the movements of the axes.
|
||||||
|
|
||||||
* ``factor``: The new factor, percentage as integer or float (percentage divided by 100) between 50 and 200%.
|
* ``factor``: The new factor, percentage between 50 and 200% as integer (``50`` to ``200``) or float (``0.5`` to ``2.0``).
|
||||||
|
|
||||||
All of these commands except ``feedrate`` may only be sent if the printer is currently operational and not printing.
|
All of these commands except ``feedrate`` may only be sent if the printer is currently operational and not printing.
|
||||||
Otherwise a :http:statuscode:`409` is returned.
|
Otherwise a :http:statuscode:`409` is returned.
|
||||||
@@ -276,9 +285,9 @@ Issue a print head command
|
|||||||
|
|
||||||
HTTP/1.1 204 No Content
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
**Example feed rate request**
|
**Example feed rate request (1/2)**
|
||||||
|
|
||||||
Set the feed rate factor to 105%.
|
Set the feed rate factor to 105% using an integer argument.
|
||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
|
|
||||||
@@ -296,6 +305,26 @@ Issue a print head command
|
|||||||
|
|
||||||
HTTP/1.1 204 No Content
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
|
**Example feed rate request (2/2)**
|
||||||
|
|
||||||
|
Set the feed rate factor to 105% using a float argument.
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
POST /api/printer/printhead HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
Content-Type: application/json
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "feedrate",
|
||||||
|
"factor": 1.05
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
:json string command: The command to issue, either ``jog`` or ``home``.
|
:json string command: The command to issue, either ``jog`` or ``home``.
|
||||||
:json number x: ``jog`` command: The amount to travel on the X axis in mm.
|
:json number x: ``jog`` command: The amount to travel on the X axis in mm.
|
||||||
:json number y: ``jog`` command: The amount to travel on the Y axis in mm.
|
:json number y: ``jog`` command: The amount to travel on the Y axis in mm.
|
||||||
@@ -338,11 +367,13 @@ Issue a tool command
|
|||||||
Extrudes the given amount of filament from the currently selected tool. Additional parameters:
|
Extrudes the given amount of filament from the currently selected tool. Additional parameters:
|
||||||
|
|
||||||
* ``amount``: The amount of filament to extrude in mm. May be negative to retract.
|
* ``amount``: The amount of filament to extrude in mm. May be negative to retract.
|
||||||
|
* ``speed``: Optional. Speed at which to extrude. If not provided, maximum speed for E axis from printer
|
||||||
|
profile will be used. Otherwise interpreted as an integer signifying the speed in mm/min, to append to the command.
|
||||||
|
|
||||||
flowrate
|
flowrate
|
||||||
Changes the flow rate factor to apply to extrusion of the tool.
|
Changes the flow rate factor to apply to extrusion of the tool.
|
||||||
|
|
||||||
* ``factor``: The new factor, percentage as integer or float (percentage divided by 100) between 75 and 125%.
|
* ``factor``: The new factor, percentage between 75 and 125% as integer (``75`` to ``125``) or float (``0.75`` to ``1.25``).
|
||||||
|
|
||||||
All of these commands may only be sent if the printer is currently operational and -- in case of ``select`` and
|
All of these commands may only be sent if the printer is currently operational and -- in case of ``select`` and
|
||||||
``extrude`` -- not printing. Otherwise a :http:statuscode:`409` is returned.
|
``extrude`` -- not printing. Otherwise a :http:statuscode:`409` is returned.
|
||||||
@@ -457,9 +488,9 @@ Issue a tool command
|
|||||||
|
|
||||||
HTTP/1.1 204 No Content
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
**Example flow rate request**
|
**Example flow rate request (1/2)**
|
||||||
|
|
||||||
Set the flow rate factor to 95%.
|
Set the flow rate factor to 95% using an integer attribute.
|
||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
|
|
||||||
@@ -477,6 +508,26 @@ Issue a tool command
|
|||||||
|
|
||||||
HTTP/1.1 204 No Content
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
|
**Example flow rate request (2/2)**
|
||||||
|
|
||||||
|
Set the flow rate factor to 95% using a float attribute.
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
POST /api/printer/tool HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
Content-Type: application/json
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "flowrate",
|
||||||
|
"factor": 0.95
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
:json string command: The command to issue, either ``target``, ``offset``, ``select`` or ``extrude``.
|
:json string command: The command to issue, either ``target``, ``offset``, ``select`` or ``extrude``.
|
||||||
:json object targets: ``target`` command: The target temperatures to set. Valid properties have to match the format ``tool{n}``.
|
:json object targets: ``target`` command: The target temperatures to set. Valid properties have to match the format ``tool{n}``.
|
||||||
:json object offsets: ``offset`` command: The offset temperature to set. Valid properties have to match the format ``tool{n}``.
|
:json object offsets: ``offset`` command: The offset temperature to set. Valid properties have to match the format ``tool{n}``.
|
||||||
@@ -577,12 +628,12 @@ Issue a bed command
|
|||||||
are:
|
are:
|
||||||
|
|
||||||
target
|
target
|
||||||
Sets the given target temperature on the printer's tools. Additional parameters:
|
Sets the given target temperature on the printer's bed. Additional parameters:
|
||||||
|
|
||||||
* ``target``: Target temperature to set.
|
* ``target``: Target temperature to set.
|
||||||
|
|
||||||
offset
|
offset
|
||||||
Sets the given temperature offset on the printer's tools. Additional parameters:
|
Sets the given temperature offset on the printer's bed. Additional parameters:
|
||||||
|
|
||||||
* ``offset``: Offset to set.
|
* ``offset``: Offset to set.
|
||||||
|
|
||||||
@@ -664,7 +715,7 @@ Retrieve the current bed state
|
|||||||
an :http:statuscode:`409`.
|
an :http:statuscode:`409`.
|
||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
If you want both tool and bed temperature information at the same time, take a look at
|
If you want tool, bed and chamber temperature information at the same time, take a look at
|
||||||
:ref:`Retrieve the current printer state <sec-api-printer-state>`.
|
:ref:`Retrieve the current printer state <sec-api-printer-state>`.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
@@ -714,6 +765,154 @@ Retrieve the current bed state
|
|||||||
:statuscode 409: If the printer is not operational or the selected printer profile
|
:statuscode 409: If the printer is not operational or the selected printer profile
|
||||||
does not have a heated bed.
|
does not have a heated bed.
|
||||||
|
|
||||||
|
.. _sec-api-printer-chambercommand:
|
||||||
|
|
||||||
|
Issue a chamber command
|
||||||
|
=======================
|
||||||
|
|
||||||
|
.. http:post:: /api/printer/bed
|
||||||
|
|
||||||
|
Chamber commands allow setting the temperature and temperature offsets for the printer's heated chamber. Available commands
|
||||||
|
are:
|
||||||
|
|
||||||
|
target
|
||||||
|
Sets the given target temperature on the printer's chamber. Additional parameters:
|
||||||
|
|
||||||
|
* ``target``: Target temperature to set.
|
||||||
|
|
||||||
|
offset
|
||||||
|
Sets the given temperature offset on the printer's chamber. Additional parameters:
|
||||||
|
|
||||||
|
* ``offset``: Offset to set.
|
||||||
|
|
||||||
|
All of these commands may only be sent if the printer is currently operational. Otherwise a :http:statuscode:`409`
|
||||||
|
is returned.
|
||||||
|
|
||||||
|
Upon success, a status code of :http:statuscode:`204` and an empty body is returned.
|
||||||
|
|
||||||
|
If no heated chambed is configured for the currently selected printer profile, the resource will return
|
||||||
|
an :http:statuscode:`409`.
|
||||||
|
|
||||||
|
Requires user rights.
|
||||||
|
|
||||||
|
**Example Target Temperature Request**
|
||||||
|
|
||||||
|
Set the target temperature for the printer's heated chamber to 50°C.
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
POST /api/printer/chamber HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
Content-Type: application/json
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "target",
|
||||||
|
"target": 50
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
|
**Example Offset Temperature Request**
|
||||||
|
|
||||||
|
Set the temperature offset for the heated chamber to -5°C.
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
POST /api/printer/chamber HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
Content-Type: application/json
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "offset",
|
||||||
|
"offset": -5
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
|
:json string command: The command to issue, either ``target`` or ``offset``.
|
||||||
|
:json object target: ``target`` command: The target temperature to set.
|
||||||
|
:json object offset: ``offset`` command: The offset temperature to set.
|
||||||
|
:statuscode 204: No error
|
||||||
|
:statuscode 400: If ``target`` or ``offset`` is not a valid number or outside of the supported range, or if the
|
||||||
|
request is otherwise invalid.
|
||||||
|
:statuscode 409: If the printer is not operational or the selected printer profile
|
||||||
|
does not have a heated chamber.
|
||||||
|
|
||||||
|
.. _sec-api-printer-chamberstate:
|
||||||
|
|
||||||
|
Retrieve the current chamber state
|
||||||
|
==================================
|
||||||
|
|
||||||
|
.. http:get:: /api/printer/chamber
|
||||||
|
|
||||||
|
Retrieves the current temperature data (actual, target and offset) plus optionally a (limited) history (actual, target,
|
||||||
|
timestamp) for the printer's heated chamber.
|
||||||
|
|
||||||
|
It's also possible to retrieve the temperature history by supplying the ``history`` query parameter set to ``true``. The
|
||||||
|
amount of returned history data points can be limited using the ``limit`` query parameter.
|
||||||
|
|
||||||
|
Returns a :http:statuscode:`200` with a Temperature Response in the body upon success.
|
||||||
|
|
||||||
|
If no heated chamber is configured for the currently selected printer profile, the resource will return
|
||||||
|
an :http:statuscode:`409`.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
If you want tool, bed and chamber temperature information at the same time, take a look at
|
||||||
|
:ref:`Retrieve the current printer state <sec-api-printer-state>`.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
Query the chamber temperature data and also include the temperature history but limit it to two entries.
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
GET /api/printer/chamber?history=true&limit=2 HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 200 OK
|
||||||
|
Content-Type: application/json
|
||||||
|
|
||||||
|
{
|
||||||
|
"chamber": {
|
||||||
|
"actual": 50.221,
|
||||||
|
"target": 70.0,
|
||||||
|
"offset": 5
|
||||||
|
},
|
||||||
|
"history": [
|
||||||
|
{
|
||||||
|
"time": 1395651928,
|
||||||
|
"chamber": {
|
||||||
|
"actual": 50.221,
|
||||||
|
"target": 70.0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 1395651926,
|
||||||
|
"chamber": {
|
||||||
|
"actual": 49.1123,
|
||||||
|
"target": 70.0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
:query history: If set to ``true`` (or: ``yes``, ``y``, ``1``), history information will be included in the response
|
||||||
|
too. If no ``limit`` parameter is given, all available temperature history data will be returned.
|
||||||
|
:query limit: If set to an integer (``n``), only the last ``n`` data points from the printer's temperature history
|
||||||
|
will be returned. Will be ignored if ``history`` is not enabled.
|
||||||
|
:statuscode 200: No error
|
||||||
|
:statuscode 409: If the printer is not operational or the selected printer profile
|
||||||
|
does not have a heated chamber.
|
||||||
|
|
||||||
.. _sec-api-printer-sdcommand:
|
.. _sec-api-printer-sdcommand:
|
||||||
|
|
||||||
Issue an SD command
|
Issue an SD command
|
||||||
|
|||||||
@@ -52,6 +52,7 @@ Retrieve all printer profiles
|
|||||||
"height": 200
|
"height": 200
|
||||||
},
|
},
|
||||||
"heatedBed": true,
|
"heatedBed": true,
|
||||||
|
"heatedChamber": false,
|
||||||
"axes": {
|
"axes": {
|
||||||
"x": {
|
"x": {
|
||||||
"speed": 6000,
|
"speed": 6000,
|
||||||
@@ -93,6 +94,7 @@ Retrieve all printer profiles
|
|||||||
"height": 200
|
"height": 200
|
||||||
},
|
},
|
||||||
"heatedBed": true,
|
"heatedBed": true,
|
||||||
|
"heatedChamber": true,
|
||||||
"axes": {
|
"axes": {
|
||||||
"x": {
|
"x": {
|
||||||
"speed": 6000,
|
"speed": 6000,
|
||||||
@@ -184,6 +186,7 @@ Add a new printer profile
|
|||||||
"height": 200
|
"height": 200
|
||||||
},
|
},
|
||||||
"heatedBed": true,
|
"heatedBed": true,
|
||||||
|
"heatedChamber": false,
|
||||||
"axes": {
|
"axes": {
|
||||||
"x": {
|
"x": {
|
||||||
"speed": 6000,
|
"speed": 6000,
|
||||||
@@ -267,6 +270,7 @@ Add a new printer profile
|
|||||||
"height": 300
|
"height": 300
|
||||||
},
|
},
|
||||||
"heatedBed": false,
|
"heatedBed": false,
|
||||||
|
"heatedChamber": false,
|
||||||
"axes": {
|
"axes": {
|
||||||
"x": {
|
"x": {
|
||||||
"speed": 6000,
|
"speed": 6000,
|
||||||
@@ -352,6 +356,7 @@ Update an existing printer profile
|
|||||||
"height": 200
|
"height": 200
|
||||||
},
|
},
|
||||||
"heatedBed": true,
|
"heatedBed": true,
|
||||||
|
"heatedChamber": false,
|
||||||
"axes": {
|
"axes": {
|
||||||
"x": {
|
"x": {
|
||||||
"speed": 6000,
|
"speed": 6000,
|
||||||
@@ -578,10 +583,14 @@ Profile
|
|||||||
- 0..1
|
- 0..1
|
||||||
- ``boolean``
|
- ``boolean``
|
||||||
- Whether the printer has a heated bed (``true``) or not (``false``)
|
- Whether the printer has a heated bed (``true``) or not (``false``)
|
||||||
|
* - ``heatedChamber``
|
||||||
|
- 0..1
|
||||||
|
- ``boolean``
|
||||||
|
- Whether the printer has a heated chamber (``true``) or not (``false``)
|
||||||
* - ``axes``
|
* - ``axes``
|
||||||
- 0..1
|
- 0..1
|
||||||
- Object
|
- Object
|
||||||
- Description of the printer's axes properties, one entry each for ``x``, ``y``, ``z`` and ``e`` holding maxium speed
|
- Description of the printer's axes properties, one entry each for ``x``, ``y``, ``z`` and ``e`` holding maximum speed
|
||||||
and whether this axis is inverted or not.
|
and whether this axis is inverted or not.
|
||||||
* - ``axes.{axis}.speed``
|
* - ``axes.{axis}.speed``
|
||||||
- 0..1
|
- 0..1
|
||||||
|
|||||||
@@ -47,23 +47,41 @@ Clients must ignore any unknown messages.
|
|||||||
|
|
||||||
The data model of the attached payloads is described further below.
|
The data model of the attached payloads is described further below.
|
||||||
|
|
||||||
OctoPrint's SockJS socket also accepts one command from the client to the server,
|
OctoPrint's SockJS socket also accepts two commands from the client to the server.
|
||||||
the ``throttle`` command. Usually, OctoPrint will push the general state update
|
|
||||||
in the ``current`` message twice per second. For some clients that might still
|
|
||||||
be too fast, so they can signal a different factor to OctoPrint utilizing the
|
|
||||||
``throttle`` message. OctoPrint expects a single integer here which represents
|
|
||||||
the multiplier for the base rate limit of one message every 500ms. A value of
|
|
||||||
1 hence will produce the default behaviour of getting every update. A value of
|
|
||||||
2 will set the rate limit to maximally one message every 1s, 3 to maximally one
|
|
||||||
message every 1.5s and so on.
|
|
||||||
|
|
||||||
Example for a ``throttle`` client-server-message:
|
* ``auth`` (since 1.3.10): With the ``auth`` message, clients may associate an
|
||||||
|
existing user session with the socket. That is of special importance to receive
|
||||||
|
any kind of messages if the bundled :ref:`Forcelogin Plugin <sec-bundledplugins-forcelogin>` is enabled
|
||||||
|
(as it is by default), since it will prevent any kind of status messages to be sent to connected unauthenticated
|
||||||
|
clients.
|
||||||
|
|
||||||
.. sourcecode:: javascript
|
The ``auth`` message expects the user id of the user to authenticate followed by ``:`` and a session key to be
|
||||||
|
obtained from the successful payload of a :ref:`(passive or active) login via the API <sec-api-general-login>`.
|
||||||
|
|
||||||
{
|
Example for a ``auth`` client-server-message:
|
||||||
"throttle": 2
|
|
||||||
}
|
.. sourcecode:: javascript
|
||||||
|
|
||||||
|
{
|
||||||
|
"auth": "someuser:LGZ0trf8By"
|
||||||
|
}
|
||||||
|
|
||||||
|
* ``throttle``: Usually, OctoPrint will push the general state update
|
||||||
|
in the ``current`` message twice per second. For some clients that might still
|
||||||
|
be too fast, so they can signal a different factor to OctoPrint utilizing the
|
||||||
|
``throttle`` message. OctoPrint expects a single integer here which represents
|
||||||
|
the multiplier for the base rate limit of one message every 500ms. A value of
|
||||||
|
1 hence will produce the default behaviour of getting every update. A value of
|
||||||
|
2 will set the rate limit to maximally one message every 1s, 3 to maximally one
|
||||||
|
message every 1.5s and so on.
|
||||||
|
|
||||||
|
Example for a ``throttle`` client-server-message:
|
||||||
|
|
||||||
|
.. sourcecode:: javascript
|
||||||
|
|
||||||
|
{
|
||||||
|
"throttle": 2
|
||||||
|
}
|
||||||
|
|
||||||
.. _sec-api-push-datamodel:
|
.. _sec-api-push-datamodel:
|
||||||
|
|
||||||
|
|||||||
@@ -62,10 +62,11 @@ Save settings
|
|||||||
|
|
||||||
{
|
{
|
||||||
"api": {
|
"api": {
|
||||||
"enabled": true,
|
"enabled": true
|
||||||
// ...
|
|
||||||
},
|
},
|
||||||
// ...
|
"appearance": {
|
||||||
|
"color": "black"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.. _sec-api-settings-generateapikey:
|
.. _sec-api-settings-generateapikey:
|
||||||
@@ -85,6 +86,266 @@ Regenerate the system wide API key
|
|||||||
:status 200: No error
|
:status 200: No error
|
||||||
:status 403: No admin rights
|
:status 403: No admin rights
|
||||||
|
|
||||||
|
.. _sec-api-settings-fetchtemplaatedata:
|
||||||
|
|
||||||
|
Fetch template data
|
||||||
|
===================
|
||||||
|
|
||||||
|
.. http:get:: /api/settings/templates
|
||||||
|
|
||||||
|
Fetch data (currently only the sorting order) of all registered template components in the system.
|
||||||
|
|
||||||
|
Use this to get a full list of the identifiers of all UI components provided either by core OctoPrint or any
|
||||||
|
currently active plugins.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
GET /api/settings/templates HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 200 OK
|
||||||
|
Content-Type: application/json
|
||||||
|
|
||||||
|
{
|
||||||
|
"order": {
|
||||||
|
"about": [
|
||||||
|
{
|
||||||
|
"id": "about",
|
||||||
|
"name": "About OctoPrint"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "supporters",
|
||||||
|
"name": "Supporters"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "authors",
|
||||||
|
"name": "Authors"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "changelog",
|
||||||
|
"name": "Changelog"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "license",
|
||||||
|
"name": "OctoPrint License"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "thirdparty",
|
||||||
|
"name": "Third Party Licenses"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_pluginmanager",
|
||||||
|
"name": "Plugin Licenses",
|
||||||
|
"plugin_id": "pluginmanager",
|
||||||
|
"plugin_name": "Plugin Manager"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"generic": [
|
||||||
|
{
|
||||||
|
"id": "plugin_announcements",
|
||||||
|
"name": "plugin_announcements",
|
||||||
|
"plugin_id": "announcements",
|
||||||
|
"plugin_name": "Announcement Plugin"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"navbar": [
|
||||||
|
{
|
||||||
|
"id": "settings",
|
||||||
|
"name": "settings"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "systemmenu",
|
||||||
|
"name": "systemmenu"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_announcements",
|
||||||
|
"name": "plugin_announcements",
|
||||||
|
"plugin_id": "announcements",
|
||||||
|
"plugin_name": "Announcement Plugin"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "login",
|
||||||
|
"name": "login"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"plugin_pluginmanager_about_thirdparty": [],
|
||||||
|
"settings": [
|
||||||
|
{
|
||||||
|
"id": "section_printer",
|
||||||
|
"name": "Printer"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "serial",
|
||||||
|
"name": "Serial Connection"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "printerprofiles",
|
||||||
|
"name": "Printer Profiles"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "temperatures",
|
||||||
|
"name": "Temperatures"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "terminalfilters",
|
||||||
|
"name": "Terminal Filters"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "gcodescripts",
|
||||||
|
"name": "GCODE Scripts"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "section_features",
|
||||||
|
"name": "Features"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "features",
|
||||||
|
"name": "Features"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "webcam",
|
||||||
|
"name": "Webcam & Timelapse"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "accesscontrol",
|
||||||
|
"name": "Access Control"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "gcodevisualizer",
|
||||||
|
"name": "GCODE Visualizer"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "api",
|
||||||
|
"name": "API"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "section_octoprint",
|
||||||
|
"name": "OctoPrint"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "server",
|
||||||
|
"name": "Server"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "folders",
|
||||||
|
"name": "Folders"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "appearance",
|
||||||
|
"name": "Appearance"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_logging",
|
||||||
|
"name": "Logging",
|
||||||
|
"plugin_id": "logging",
|
||||||
|
"plugin_name": "Logging"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_pluginmanager",
|
||||||
|
"name": "Plugin Manager",
|
||||||
|
"plugin_id": "pluginmanager",
|
||||||
|
"plugin_name": "Plugin Manager"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_softwareupdate",
|
||||||
|
"name": "Software Update",
|
||||||
|
"plugin_id": "softwareupdate",
|
||||||
|
"plugin_name": "Software Update"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_announcements",
|
||||||
|
"name": "Announcements",
|
||||||
|
"plugin_id": "announcements",
|
||||||
|
"plugin_name": "Announcement Plugin"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "section_plugins",
|
||||||
|
"name": "Plugins"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_action_command_prompt",
|
||||||
|
"name": "Action Command Prompt",
|
||||||
|
"plugin_id": "action_command_prompt",
|
||||||
|
"plugin_name": "Action Command Prompt Support"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "plugin_curalegacy",
|
||||||
|
"name": "Cura Legacy",
|
||||||
|
"plugin_id": "curalegacy",
|
||||||
|
"plugin_name": "Cura Legacy"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"sidebar": [
|
||||||
|
{
|
||||||
|
"id": "plugin_printer_safety_check",
|
||||||
|
"name": "Printer Safety Warning",
|
||||||
|
"plugin_id": "printer_safety_check",
|
||||||
|
"plugin_name": "Printer Safety Check"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "connection",
|
||||||
|
"name": "Connection"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "state",
|
||||||
|
"name": "State"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "files",
|
||||||
|
"name": "Files"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"tab": [
|
||||||
|
{
|
||||||
|
"id": "temperature",
|
||||||
|
"name": "Temperature"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "control",
|
||||||
|
"name": "Control"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "gcodeviewer",
|
||||||
|
"name": "GCode Viewer"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "terminal",
|
||||||
|
"name": "Terminal"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "timelapse",
|
||||||
|
"name": "Timelapse"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"usersettings": [
|
||||||
|
{
|
||||||
|
"id": "access",
|
||||||
|
"name": "Access"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "interface",
|
||||||
|
"name": "Interface"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"wizard": []
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Requires admin rights.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
This API endpoint is in beta. Things might change. If you happen to want to develop against it, you should drop
|
||||||
|
me an email to make sure I can give you a heads-up when something changes in an backwards incompatible way.
|
||||||
|
|
||||||
|
:status 200: No error
|
||||||
|
:status 403: No admin rights
|
||||||
|
|
||||||
.. _sec-api-settings-datamodel:
|
.. _sec-api-settings-datamodel:
|
||||||
|
|
||||||
Data model
|
Data model
|
||||||
@@ -105,7 +366,7 @@ mapped from the same fields in ``config.yaml`` unless otherwise noted:
|
|||||||
* - ``api.key``
|
* - ``api.key``
|
||||||
- Only maps to ``api.key`` in ``config.yaml`` if request is sent with admin rights, set to ``n/a`` otherwise.
|
- Only maps to ``api.key`` in ``config.yaml`` if request is sent with admin rights, set to ``n/a`` otherwise.
|
||||||
Starting with OctoPrint 1.3.3 setting this field via :ref:`the API <sec-api-settings-save>` is not possible,
|
Starting with OctoPrint 1.3.3 setting this field via :ref:`the API <sec-api-settings-save>` is not possible,
|
||||||
only :ref:`regenerting it <sec-api-settings-generateapikey>` is supported. Setting a custom value is only
|
only :ref:`regenerating it <sec-api-settings-generateapikey>` is supported. Setting a custom value is only
|
||||||
possible through `config.yaml`.
|
possible through `config.yaml`.
|
||||||
* - ``api.allowCrossOrigin``
|
* - ``api.allowCrossOrigin``
|
||||||
-
|
-
|
||||||
@@ -135,7 +396,7 @@ mapped from the same fields in ``config.yaml`` unless otherwise noted:
|
|||||||
-
|
-
|
||||||
* - ``feature.sdSupport``
|
* - ``feature.sdSupport``
|
||||||
-
|
-
|
||||||
* - ``feature.sdReleativePath``
|
* - ``feature.sdRelativePath``
|
||||||
-
|
-
|
||||||
* - ``feature.sdAlwaysAvailable``
|
* - ``feature.sdAlwaysAvailable``
|
||||||
-
|
-
|
||||||
@@ -253,6 +514,8 @@ mapped from the same fields in ``config.yaml`` unless otherwise noted:
|
|||||||
-
|
-
|
||||||
* - ``webcam.ffmpegThreads``
|
* - ``webcam.ffmpegThreads``
|
||||||
-
|
-
|
||||||
|
* - ``webcam.ffmpegVideoCodec``
|
||||||
|
-
|
||||||
* - ``webcam.watermark``
|
* - ``webcam.watermark``
|
||||||
-
|
-
|
||||||
* - ``webcam.flipH``
|
* - ``webcam.flipH``
|
||||||
|
|||||||
@@ -42,27 +42,25 @@ List All Slicers and Slicing Profiles
|
|||||||
Content-Type: application/json
|
Content-Type: application/json
|
||||||
|
|
||||||
{
|
{
|
||||||
"cura": {
|
"curalegacy": {
|
||||||
"key": "cura",
|
"key": "curalegacy",
|
||||||
"displayName": "CuraEngine",
|
"displayName": "Cura Legacy",
|
||||||
"default": true,
|
"default": true,
|
||||||
"profiles": {
|
"profiles": {
|
||||||
"high_quality": {
|
"high_quality": {
|
||||||
"key": "high_quality",
|
"key": "high_quality",
|
||||||
"displayName": "High Quality",
|
"displayName": "High Quality",
|
||||||
"default": false,
|
"default": false,
|
||||||
"resource": "http://example.com/api/slicing/cura/profiles/high_quality"
|
"resource": "http://example.com/api/slicing/curalegacy/profiles/high_quality"
|
||||||
},
|
},
|
||||||
"medium_quality": {
|
"medium_quality": {
|
||||||
"key": "medium_quality",
|
"key": "medium_quality",
|
||||||
"displayName": "Medium Quality",
|
"displayName": "Medium Quality",
|
||||||
"default": true,
|
"default": true,
|
||||||
"resource": "http://example.com/api/slicing/cura/profiles/medium_quality"
|
"resource": "http://example.com/api/slicing/curalegacy/profiles/medium_quality"
|
||||||
},
|
}
|
||||||
...
|
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
...
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:statuscode 200: No error
|
:statuscode 200: No error
|
||||||
@@ -83,7 +81,7 @@ List Slicing Profiles of a Specific Slicer
|
|||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
|
|
||||||
GET /api/slicing/cura/profiles HTTP/1.1
|
GET /api/slicing/curalegacy/profiles HTTP/1.1
|
||||||
Host: example.com
|
Host: example.com
|
||||||
X-Api-Key: abcdef...
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
@@ -97,15 +95,14 @@ List Slicing Profiles of a Specific Slicer
|
|||||||
"key": "high_quality",
|
"key": "high_quality",
|
||||||
"displayName": "High Quality",
|
"displayName": "High Quality",
|
||||||
"default": false,
|
"default": false,
|
||||||
"resource": "http://example.com/api/slicing/cura/profiles/high_quality"
|
"resource": "http://example.com/api/slicing/curalegacy/profiles/high_quality"
|
||||||
},
|
},
|
||||||
"medium_quality": {
|
"medium_quality": {
|
||||||
"key": "medium_quality",
|
"key": "medium_quality",
|
||||||
"displayName": "Medium Quality",
|
"displayName": "Medium Quality",
|
||||||
"default": true,
|
"default": true,
|
||||||
"resource": "http://example.com/api/slicing/cura/profiles/medium_quality"
|
"resource": "http://example.com/api/slicing/curalegacy/profiles/medium_quality"
|
||||||
},
|
}
|
||||||
...
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:param slicer: The identifying key of the slicer for which to list the available profiles.
|
:param slicer: The identifying key of the slicer for which to list the available profiles.
|
||||||
@@ -128,7 +125,7 @@ Retrieve Specific Profile
|
|||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
|
|
||||||
GET /api/slicing/cura/profiles/quick_test HTTP/1.1
|
GET /api/slicing/curalegacy/profiles/quick_test HTTP/1.1
|
||||||
Host: example.com
|
Host: example.com
|
||||||
X-Api-Key: abcdef...
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
@@ -140,15 +137,14 @@ Retrieve Specific Profile
|
|||||||
{
|
{
|
||||||
"displayName": "Just a test",
|
"displayName": "Just a test",
|
||||||
"description": "This is just a test",
|
"description": "This is just a test",
|
||||||
"resource": "http://example.com/api/slicing/cura/profiles/quick_test",
|
"resource": "http://example.com/api/slicing/curalegacy/profiles/quick_test",
|
||||||
"data": {
|
"data": {
|
||||||
"bottom_layer_speed": 20.0,
|
"bottom_layer_speed": 20.0,
|
||||||
"bottom_thickness": 0.3,
|
"bottom_thickness": 0.3,
|
||||||
"brim_line_count": 20,
|
"brim_line_count": 20,
|
||||||
"cool_head_lift": false,
|
"cool_head_lift": false,
|
||||||
"cool_min_feedrate": 10.0,
|
"cool_min_feedrate": 10.0,
|
||||||
"cool_min_layer_time": 5.0,
|
"cool_min_layer_time": 5.0
|
||||||
...
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -178,14 +174,14 @@ Add Slicing Profile
|
|||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
|
|
||||||
PUT /api/slicing/cura/profiles/quick_test HTTP/1.1
|
PUT /api/slicing/curalegacy/profiles/quick_test HTTP/1.1
|
||||||
Host: example.com
|
Host: example.com
|
||||||
X-Api-Key: abcdef...
|
X-Api-Key: abcdef...
|
||||||
Content-Type: application/json
|
Content-Type: application/json
|
||||||
|
|
||||||
{
|
{
|
||||||
"displayName": "Just a test",
|
"displayName": "Just a test",
|
||||||
"description": "This is just a test to show how to create a cura profile with a different layer height and skirt count",
|
"description": "This is just a test to show how to create a curalegacy profile with a different layer height and skirt count",
|
||||||
"data": {
|
"data": {
|
||||||
"layer_height": 0.2,
|
"layer_height": 0.2,
|
||||||
"skirt_line_count": 3
|
"skirt_line_count": 3
|
||||||
@@ -201,8 +197,8 @@ Add Slicing Profile
|
|||||||
|
|
||||||
{
|
{
|
||||||
"displayName": "Just a test",
|
"displayName": "Just a test",
|
||||||
"description": "This is just a test to show how to create a cura profile with a different layer height and skirt count",
|
"description": "This is just a test to show how to create a curalegacy profile with a different layer height and skirt count",
|
||||||
"resource": "http://example.com/api/slicing/cura/profiles/quick_test"
|
"resource": "http://example.com/api/slicing/curalegacy/profiles/quick_test"
|
||||||
}
|
}
|
||||||
|
|
||||||
:param slicer: The identifying key of the slicer for which to add the profile
|
:param slicer: The identifying key of the slicer for which to add the profile
|
||||||
|
|||||||
@@ -38,30 +38,21 @@ List all registered system commands
|
|||||||
{
|
{
|
||||||
"action": "shutdown",
|
"action": "shutdown",
|
||||||
"name": "Shutdown",
|
"name": "Shutdown",
|
||||||
"command": "sudo shutdown -h now",
|
"confirm": "<strong>You are about to shutdown the system.</strong></p><p>This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||||
"confirm": "You are about to shutdown the system.",
|
|
||||||
"async": true,
|
|
||||||
"ignore": true,
|
|
||||||
"source": "core",
|
"source": "core",
|
||||||
"resource": "http://example.com/api/system/commands/core/shutdown"
|
"resource": "http://example.com/api/system/commands/core/shutdown"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"action": "reboot",
|
"action": "reboot",
|
||||||
"name": "Reboot",
|
"name": "Reboot",
|
||||||
"command": "sudo reboot",
|
"confirm": "<strong>You are about to reboot the system.</strong></p><p>This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||||
"confirm": "You are about to reboot the system.",
|
|
||||||
"async": true,
|
|
||||||
"ignore": true,
|
|
||||||
"source": "core",
|
"source": "core",
|
||||||
"resource": "http://example.com/api/system/commands/core/reboot"
|
"resource": "http://example.com/api/system/commands/core/reboot"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"action": "restart",
|
"action": "restart",
|
||||||
"name": "Restart OctoPrint",
|
"name": "Restart OctoPrint",
|
||||||
"command": "sudo service octoprint restart",
|
"confirm": "<strong>You are about to restart the OctoPrint server.</strong></p><p>This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||||
"confirm": "You are about to restart the OctoPrint server.",
|
|
||||||
"async": true,
|
|
||||||
"ignore": true,
|
|
||||||
"source": "core",
|
"source": "core",
|
||||||
"resource": "http://example.com/api/system/commands/core/restart"
|
"resource": "http://example.com/api/system/commands/core/restart"
|
||||||
}
|
}
|
||||||
@@ -99,30 +90,21 @@ List all registered system commands for a source
|
|||||||
{
|
{
|
||||||
"action": "shutdown",
|
"action": "shutdown",
|
||||||
"name": "Shutdown",
|
"name": "Shutdown",
|
||||||
"command": "sudo shutdown -h now",
|
"confirm": "<strong>You are about to shutdown the system.</strong></p><p>This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||||
"confirm": "You are about to shutdown the system.",
|
|
||||||
"async": true,
|
|
||||||
"ignore": true,
|
|
||||||
"source": "core",
|
"source": "core",
|
||||||
"resource": "http://example.com/api/system/commands/core/shutdown"
|
"resource": "http://example.com/api/system/commands/core/shutdown"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"action": "reboot",
|
"action": "reboot",
|
||||||
"name": "Reboot",
|
"name": "Reboot",
|
||||||
"command": "sudo reboot",
|
"confirm": "<strong>You are about to reboot the system.</strong></p><p>This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||||
"confirm": "You are about to reboot the system.",
|
|
||||||
"async": true,
|
|
||||||
"ignore": true,
|
|
||||||
"source": "core",
|
"source": "core",
|
||||||
"resource": "http://example.com/api/system/commands/core/reboot"
|
"resource": "http://example.com/api/system/commands/core/reboot"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"action": "restart",
|
"action": "restart",
|
||||||
"name": "Restart OctoPrint",
|
"name": "Restart OctoPrint",
|
||||||
"command": "sudo service octoprint restart",
|
"confirm": "<strong>You are about to restart the OctoPrint server.</strong></p><p>This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||||
"confirm": "You are about to restart the OctoPrint server.",
|
|
||||||
"async": true,
|
|
||||||
"ignore": true,
|
|
||||||
"source": "core",
|
"source": "core",
|
||||||
"resource": "http://example.com/api/system/commands/core/restart"
|
"resource": "http://example.com/api/system/commands/core/restart"
|
||||||
}
|
}
|
||||||
@@ -139,7 +121,7 @@ Execute a registered system command
|
|||||||
|
|
||||||
.. http:post:: /api/system/commands/(string:source)/(string:action)
|
.. http:post:: /api/system/commands/(string:source)/(string:action)
|
||||||
|
|
||||||
Execute the system command ``action`` on defined in ``source``.
|
Execute the system command ``action`` defined in ``source``.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
|
|
||||||
@@ -154,7 +136,7 @@ Execute a registered system command
|
|||||||
|
|
||||||
.. sourcecode:: http
|
.. sourcecode:: http
|
||||||
|
|
||||||
204 No Content
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
:param source: The source for which to list commands, currently either ``core`` or ``custom``
|
:param source: The source for which to list commands, currently either ``core`` or ``custom``
|
||||||
:param action: The identifier of the command, ``action`` from its definition
|
:param action: The identifier of the command, ``action`` from its definition
|
||||||
@@ -184,18 +166,60 @@ List all response
|
|||||||
- Description
|
- Description
|
||||||
* - ``core``
|
* - ``core``
|
||||||
- 0..n
|
- 0..n
|
||||||
- List of :ref:`command definitions <sec-api-system-commands-definiton>`
|
- List of :ref:`client command definitions <sec-api-client-system-commands-definiton>`
|
||||||
- List of all core commands defined.
|
- List of all core commands defined.
|
||||||
* - ``custom``
|
* - ``custom``
|
||||||
- 0..n
|
- 0..n
|
||||||
- List of :ref:`command definitions <sec-api-system-commands-definiton>`
|
- List of :ref:`client command definitions <sec-api-client-system-commands-definiton>`
|
||||||
- List of all custom commands defined in ``config.yaml``.
|
- List of all custom commands defined in ``config.yaml``.
|
||||||
|
|
||||||
|
.. _sec-api-client-system-commands-definiton:
|
||||||
|
|
||||||
|
Client command definitions
|
||||||
|
--------------------------
|
||||||
|
|
||||||
|
A restricted form of the full :ref:`command definition <sec-api-system-commands-definiton>`.
|
||||||
|
For exposing via the API.
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``name``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- The name of the command to display in the System menu.
|
||||||
|
* - ``action``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- An identifier to refer to the command programmatically. The special ``action`` string
|
||||||
|
``divider`` signifies a divider in the menu.
|
||||||
|
* - ``confirm``
|
||||||
|
- 0..1
|
||||||
|
- string
|
||||||
|
- If present and set, this text will be displayed to the user in a confirmation dialog
|
||||||
|
they have to acknowledge in order to really execute the command.
|
||||||
|
* - ``source``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- Source of the command definition, currently either ``core`` (for system actions defined by
|
||||||
|
OctoPrint itself) or ``custom`` (for custom system commands defined by the user through ``config.yaml``).
|
||||||
|
* - ``resource``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- The URL of the command to use for executing it.
|
||||||
|
|
||||||
.. _sec-api-system-commands-definiton:
|
.. _sec-api-system-commands-definiton:
|
||||||
|
|
||||||
Command definition
|
Command definition
|
||||||
------------------
|
------------------
|
||||||
|
|
||||||
|
The full command definition is not available via the API.
|
||||||
|
|
||||||
.. list-table::
|
.. list-table::
|
||||||
:widths: 15 5 10 30
|
:widths: 15 5 10 30
|
||||||
:header-rows: 1
|
:header-rows: 1
|
||||||
|
|||||||
@@ -128,7 +128,7 @@ Rendered timelapse
|
|||||||
* - ``date``
|
* - ``date``
|
||||||
- 1
|
- 1
|
||||||
- string
|
- string
|
||||||
- Formatted timestamp of the the timelapse creation date
|
- Formatted timestamp of the timelapse creation date
|
||||||
* - ``url``
|
* - ``url``
|
||||||
- 1
|
- 1
|
||||||
- string
|
- string
|
||||||
@@ -162,7 +162,7 @@ Unrendered timelapse
|
|||||||
* - ``date``
|
* - ``date``
|
||||||
- 1
|
- 1
|
||||||
- string
|
- string
|
||||||
- Formatted timestamp of the the timelapse job creation date
|
- Formatted timestamp of the timelapse job creation date
|
||||||
* - ``recording``
|
* - ``recording``
|
||||||
- 1
|
- 1
|
||||||
- bool
|
- bool
|
||||||
|
|||||||
@@ -30,6 +30,14 @@ Test paths or URLs
|
|||||||
existence but also whether it is of the specified type. Optional.
|
existence but also whether it is of the specified type. Optional.
|
||||||
* ``check_access``: A list of any of ``r``, ``w`` and ``x``. If present it will also
|
* ``check_access``: A list of any of ``r``, ``w`` and ``x``. If present it will also
|
||||||
be checked if OctoPrint has read, write, execute permissions on the specified path.
|
be checked if OctoPrint has read, write, execute permissions on the specified path.
|
||||||
|
* ``allow_create_dir``: If ``check_type`` is provided and set to ``dir``, this will allow
|
||||||
|
OctoPrint to create the target ``path`` as a directory if it doesn't yet exist to allow
|
||||||
|
for further tests.
|
||||||
|
* ``check_writable_dir``: If ``check_type`` is provided and set to ``dir``, this will
|
||||||
|
check that the provided ``path`` is a writable directory. OctoPrint not only check if the
|
||||||
|
permissions on the directory allow for writing but also attempt to write (and delete) a
|
||||||
|
small test file ``.testballoon.txt`` to the directory to test if writing is actually
|
||||||
|
possible.
|
||||||
|
|
||||||
The ``path`` command returns a :http:statuscode:`200` with a :ref:`path test result <sec-api-util-datamodel-pathtestresult>`
|
The ``path`` command returns a :http:statuscode:`200` with a :ref:`path test result <sec-api-util-datamodel-pathtestresult>`
|
||||||
when the test could be performed. The status code of the response does NOT reflect the
|
when the test could be performed. The status code of the response does NOT reflect the
|
||||||
@@ -38,13 +46,15 @@ Test paths or URLs
|
|||||||
.. _sec-api-util-test-url:
|
.. _sec-api-util-test-url:
|
||||||
|
|
||||||
url
|
url
|
||||||
Tests whether a provided url responds. Request method and expected status codes can
|
Tests whether a provided URL responds. Request method and expected status codes can
|
||||||
optionally be specified as well. Supported parameters are:
|
optionally be specified as well. Supported parameters are:
|
||||||
|
|
||||||
* ``url``: The url to test. Mandatory.
|
* ``url``: The URL to test. Mandatory.
|
||||||
* ``method``: The request method to use for the test. Optional, defaults to ``HEAD``.
|
* ``method``: The request method to use for the test. Optional, defaults to ``HEAD``.
|
||||||
* ``timeout``: A timeout for the request, in seconds. If no reply from the tested URL has been
|
* ``timeout``: A timeout for the request, in seconds. If no reply from the tested URL has been
|
||||||
received within this time frame, the check will be considered a failure. Optional, defaults to 3 seconds.
|
received within this time frame, the check will be considered a failure. Optional, defaults to 3 seconds.
|
||||||
|
* ``validSsl``: Whether to validate the SSL connection if the ``url`` happens to be an HTTPS URL or not. Optional,
|
||||||
|
defaults to ``True``.
|
||||||
* ``status``: The status code(s) or named status range(s) to test for. Can be either a single
|
* ``status``: The status code(s) or named status range(s) to test for. Can be either a single
|
||||||
value or a list of either HTTP status codes or any of the following named status ranges:
|
value or a list of either HTTP status codes or any of the following named status ranges:
|
||||||
|
|
||||||
@@ -63,11 +73,32 @@ Test paths or URLs
|
|||||||
from the URL check will be returned as part of the check result as well. ``json`` will attempt
|
from the URL check will be returned as part of the check result as well. ``json`` will attempt
|
||||||
to parse the response as json and return the parsed result. ``true`` or ``bytes`` will base64 encode the body
|
to parse the response as json and return the parsed result. ``true`` or ``bytes`` will base64 encode the body
|
||||||
and return that.
|
and return that.
|
||||||
|
* ``content_type_whitelist``: Optional array of supported content types. If set and the URL returns a content
|
||||||
|
type not included in this list, the test will fail. E.g. ``["image/*", "text/plain"]``.
|
||||||
|
* ``content_type_blacklist``: Optional array of unsupported content types. If set and the URL returns a content
|
||||||
|
type included in this list, the test wil fail. E.g. ``["video/*"]``. Can be used together with ``content_type_whitelist``
|
||||||
|
to further limit broader content type definition, e.g. by putting ``image/*`` into the whitelist, but disallowing
|
||||||
|
PNG by including ``image/png`` on the blacklist.
|
||||||
|
|
||||||
The ``url`` command returns :http:statuscode:`200` with a :ref:`URL test result <sec-api-util-datamodel-urltestresult>`
|
The ``url`` command returns :http:statuscode:`200` with a :ref:`URL test result <sec-api-util-datamodel-urltestresult>`
|
||||||
when the test could be performed. The status code of the response does NOT reflect the
|
when the test could be performed. The status code of the response does NOT reflect the
|
||||||
test result!
|
test result!
|
||||||
|
|
||||||
|
.. _sec-api-util-test-server:
|
||||||
|
|
||||||
|
server
|
||||||
|
Tests whether a provided server identified by host and port can be reached. Protocol can optionally be specified
|
||||||
|
as well. Supported parameters are:
|
||||||
|
|
||||||
|
* ``host``: The host to test. IP or host name. Mandatory.
|
||||||
|
* ``port``: The port to test. Integer. Mandatory.
|
||||||
|
* ``protocol``: The protocol to test with. ``tcp`` or ``udp``. Optional, defaults to ``tcp``.
|
||||||
|
* ``timeout``: A timeout for the test, in seconds. If no successful connection to the server could be established
|
||||||
|
within this time frame, the check will be considered a failure. Optional, defaults to 3.05 seconds.
|
||||||
|
|
||||||
|
The ``server`` command returns :http:statuscode:`200` with a :ref:`Server test result <sec-api-util-datamodel-servertestresult>`
|
||||||
|
when the test could be performed. The status code of the response does NOT reflect the test result!
|
||||||
|
|
||||||
Requires admin rights.
|
Requires admin rights.
|
||||||
|
|
||||||
**Example 1**
|
**Example 1**
|
||||||
@@ -226,16 +257,52 @@ Test paths or URLs
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
:json command: The command to execute, currently either ``path`` or ``url``
|
**Example 6**
|
||||||
:json path: ``path`` command only: the path to test
|
|
||||||
:json check_type: ``path`` command only: the type of path to test for, either ``file`` or ``dir``
|
Test whether a server is reachable on a given port via TCP.
|
||||||
:json check_access: ``path`` command only: a list of access permissions to check for
|
|
||||||
:json url: ``url`` command only: the URL to test
|
.. sourcecode:: http
|
||||||
:json status: ``url`` command only: one or more expected status codes
|
|
||||||
:json method: ``url`` command only: the HTTP method to use for the check
|
POST /api/util/test HTTP/1.1
|
||||||
:json timeout: ``url`` command only: the timeout for the HTTP request
|
Host: example.com
|
||||||
:json response: ``url`` command only: whether to include response data and if so in what form
|
X-Api-Key: abcdef...
|
||||||
:statuscode 200: No error occurred
|
Content-Type: application/json
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "server",
|
||||||
|
"host": "8.8.8.8",
|
||||||
|
"port": 53
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 200 OK
|
||||||
|
Content-Type: application/json
|
||||||
|
|
||||||
|
{
|
||||||
|
"host": "8.8.8.8",
|
||||||
|
"port": 53,
|
||||||
|
"protocol": "tcp",
|
||||||
|
"result": true
|
||||||
|
}
|
||||||
|
|
||||||
|
:json command: The command to execute, currently either ``path`` or ``url``
|
||||||
|
:json path: ``path`` command only: the path to test
|
||||||
|
:json check_type: ``path`` command only: the type of path to test for, either ``file`` or ``dir``
|
||||||
|
:json check_access: ``path`` command only: a list of access permissions to check for
|
||||||
|
:json allow_create_dir: ``path`` command and ``checktype`` of ``dir`` only: whether to allow creation of the
|
||||||
|
directory if it doesn't yet exist (``true``) or not (``false``, default)
|
||||||
|
:json check_writable_dir: ``path`` command and ``checktype`` of ``dir`` only: whether to test if the directory
|
||||||
|
is writable by also trying to create a test file in it (``true``) or not (``false``, default)
|
||||||
|
:json url: ``url`` command only: the URL to test
|
||||||
|
:json status: ``url`` command only: one or more expected status codes
|
||||||
|
:json method: ``url`` command only: the HTTP method to use for the check
|
||||||
|
:json timeout: ``url`` and ``server`` commands only: the timeout for the test request
|
||||||
|
:json response: ``url`` command only: whether to include response data and if so in what form
|
||||||
|
:json host: ``server`` command only: the server to test
|
||||||
|
:json port: ``server`` command only: the port to test
|
||||||
|
:json protocol: ``server`` command only: the protocol to test
|
||||||
|
:statuscode 200: No error occurred
|
||||||
|
|
||||||
.. _sec-api-util-datamodel:
|
.. _sec-api-util-datamodel:
|
||||||
|
|
||||||
@@ -244,6 +311,9 @@ Data model
|
|||||||
|
|
||||||
.. _sec-api-util-datamodel-pathtestresult:
|
.. _sec-api-util-datamodel-pathtestresult:
|
||||||
|
|
||||||
|
Path test result
|
||||||
|
----------------
|
||||||
|
|
||||||
.. list-table::
|
.. list-table::
|
||||||
:widths: 15 5 10 30
|
:widths: 15 5 10 30
|
||||||
:header-rows: 1
|
:header-rows: 1
|
||||||
@@ -275,6 +345,9 @@ Data model
|
|||||||
|
|
||||||
.. _sec-api-util-datamodel-urltestresult:
|
.. _sec-api-util-datamodel-urltestresult:
|
||||||
|
|
||||||
|
URL test result
|
||||||
|
---------------
|
||||||
|
|
||||||
.. list-table::
|
.. list-table::
|
||||||
:widths: 15 5 10 30
|
:widths: 15 5 10 30
|
||||||
:header-rows: 1
|
:header-rows: 1
|
||||||
@@ -306,3 +379,33 @@ Data model
|
|||||||
- object
|
- object
|
||||||
- A dictionary with all headers of the checked URL's response. Only present if ``response`` in the
|
- A dictionary with all headers of the checked URL's response. Only present if ``response`` in the
|
||||||
request was set.
|
request was set.
|
||||||
|
|
||||||
|
.. _sec-api-util-datamodel-servertestresult:
|
||||||
|
|
||||||
|
Server test result
|
||||||
|
------------------
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``host``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- The host that was tested.
|
||||||
|
* - ``port``
|
||||||
|
- 1
|
||||||
|
- int
|
||||||
|
- The port that was tested
|
||||||
|
* - ``protocol``
|
||||||
|
- 1
|
||||||
|
- string
|
||||||
|
- The protocol that was tested, ``tcp`` or ``udp``
|
||||||
|
* - ``result``
|
||||||
|
- 1
|
||||||
|
- bool
|
||||||
|
- ``true`` if the check passed.
|
||||||
@@ -7,7 +7,8 @@ Version information
|
|||||||
.. http:get:: /api/version
|
.. http:get:: /api/version
|
||||||
|
|
||||||
Retrieve information regarding server and API version. Returns a JSON object with two keys, ``api`` containing
|
Retrieve information regarding server and API version. Returns a JSON object with two keys, ``api`` containing
|
||||||
the API version, ``server`` containing the server version.
|
the API version, ``server`` containing the server version, ``text`` containing the server version including
|
||||||
|
the prefix ``OctoPrint `` (to determine that this is indeed a genuine OctoPrint instance).
|
||||||
|
|
||||||
**Example Request**
|
**Example Request**
|
||||||
|
|
||||||
@@ -26,7 +27,8 @@ Version information
|
|||||||
|
|
||||||
{
|
{
|
||||||
"api": "0.1",
|
"api": "0.1",
|
||||||
"server": "1.1.0"
|
"server": "1.3.10",
|
||||||
|
"text": "OctoPrint 1.3.10"
|
||||||
}
|
}
|
||||||
|
|
||||||
:statuscode 200: No error
|
:statuscode 200: No error
|
||||||
@@ -0,0 +1,110 @@
|
|||||||
|
.. _sec-bundledplugins-action_command_prompt:
|
||||||
|
|
||||||
|
Action Command Prompt support
|
||||||
|
=============================
|
||||||
|
|
||||||
|
The OctoPrint Action Command Prompt Support Plugin comes bundled with OctoPrint (starting with 1.3.9).
|
||||||
|
|
||||||
|
It allows firmware to trigger dialog prompts for logged in users using :ref:`action commands <sec-features-action_commands>`, e.g. to wait
|
||||||
|
for user acknowledgement or allow the user to choose between options, and also to close the dialog again
|
||||||
|
in case its no longer needed, e.g. due to the user proceeding on the printer's own controller.
|
||||||
|
|
||||||
|
The choice of the user can be communicated back to the firmware via a configurable GCODE command with a
|
||||||
|
placeholder for the selected option's index.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-action_command_prompt-example:
|
||||||
|
.. figure:: ../images/bundledplugins-action_command_prompt-example.png
|
||||||
|
:align: center
|
||||||
|
:alt: Simple prompt example
|
||||||
|
|
||||||
|
A simple dialog example triggered by the firmware
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-action_command_prompt-firststeps:
|
||||||
|
|
||||||
|
First Steps
|
||||||
|
-----------
|
||||||
|
|
||||||
|
In order for this plugin to work, you'll need to configure it with the command your firmware uses to accept
|
||||||
|
dialog selections. You can do that in the settings dialog.
|
||||||
|
|
||||||
|
Currently there is no agreed upon command for this since no firmware has yet made use of this feature, so OctoPrint
|
||||||
|
ships with an empty value here.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-action_command_prompt-configuration:
|
||||||
|
|
||||||
|
Configuring the plugin
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
The plugin supports the following configuration keys:
|
||||||
|
|
||||||
|
* ``selection_command``: The command to send to the firmware on choice, including the ``{choice}`` placeholder, e.g. ``M876 S{choice}``.
|
||||||
|
|
||||||
|
You can modify them either through the plugin's configuration dialog under Settings, or by directly editing ``config.yaml``.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-action_command_prompt-action_commands:
|
||||||
|
|
||||||
|
Supported action commands
|
||||||
|
-------------------------
|
||||||
|
|
||||||
|
prompt_begin <message>
|
||||||
|
Starts the definition of a prompt dialog. ``<message>`` is the message to display to the user. Will be ignored
|
||||||
|
if a dialog is already defined.
|
||||||
|
|
||||||
|
prompt_choice <text>
|
||||||
|
Defines a choice with the associated ``<text>``. Will be ignored if no dialog has been defined yet.
|
||||||
|
|
||||||
|
prompt_button <text>
|
||||||
|
Same as ``prompt_choice``.
|
||||||
|
|
||||||
|
prompt_show
|
||||||
|
Tells OctoPrint that the dialog is now fully defined and to prompt the user. Will be ignored if no dialog is
|
||||||
|
defined yet.
|
||||||
|
|
||||||
|
prompt_end
|
||||||
|
Tells OctoPrint that the dialog should now be closed (e.g. the user made the choice on the printer directly instead
|
||||||
|
of through OctoPrint). Will be ignored if no dialog is defined yet.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-action_command_prompt-example:
|
||||||
|
|
||||||
|
Example communication with the firmware
|
||||||
|
---------------------------------------
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-action_command_prompt-sourcecode:
|
||||||
|
|
||||||
|
To display the :ref:`above dialog <fig-bundledplugins-action_command_prompt-example>` the firmware sent these action commands:
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
//action:prompt_begin Filament unloaded, swap then proceed
|
||||||
|
//action:prompt_choice Filament swapped
|
||||||
|
//action:prompt_show
|
||||||
|
|
||||||
|
If the user clicks the button, assuming a ``selection_command`` of ``M876 S{choice}`` is configured, OctoPrint
|
||||||
|
will send back ``M876 S0`` (0-based index).
|
||||||
|
|
||||||
|
A more complicated example with three options would be the following:
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
//action:prompt_begin Filament runout detected. Please choose how to proceed:
|
||||||
|
//action:prompt_choice Swap filament
|
||||||
|
//action:prompt_choice Home X/Y and pause print
|
||||||
|
//action:prompt_choice Abort print
|
||||||
|
//action:prompt_show
|
||||||
|
|
||||||
|
This would produce the following output:
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-action_command_prompt-example2:
|
||||||
|
.. figure:: ../images/bundledplugins-action_command_prompt-example2.png
|
||||||
|
:align: center
|
||||||
|
:alt: Another prompt example
|
||||||
|
|
||||||
|
Another dialog example triggered by the firmware
|
||||||
|
|
||||||
|
If the user selects "Abort print", OctoPrint will send ``2`` as selected choice.
|
||||||
|
|
||||||
|
Source code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Action Command Prompt Support plugin is bundled with OctoPrint and can be found in
|
||||||
|
its source repository under ``src/octoprint/plugins/action_command_prompt``.
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
.. _sec-bundledplugins-announcements:
|
||||||
|
|
||||||
|
Announcement Plugin
|
||||||
|
===================
|
||||||
|
|
||||||
|
The OctoPrint Announcement Plugin comes bundled with OctoPrint (starting with 1.2.11).
|
||||||
|
|
||||||
|
It displays announcements fetched from OctoPrint's websites, such as important updates, release announcements, new
|
||||||
|
plugins and similar. Through some manual configuration via ``config.yaml`` it also allows adding additional channels
|
||||||
|
via RSS or Atom feed URLs.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-announcements-example1:
|
||||||
|
.. figure:: ../images/bundledplugins-announcements-example1.png
|
||||||
|
:align: center
|
||||||
|
:alt: Example notification
|
||||||
|
|
||||||
|
An example notification from the Announcement Plugin.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-announcements-example2:
|
||||||
|
.. figure:: ../images/bundledplugins-announcements-example2.png
|
||||||
|
:align: center
|
||||||
|
:alt: Announcement reader
|
||||||
|
|
||||||
|
The Announcement Plugin's reader dialog.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-announcements-settings:
|
||||||
|
.. figure:: ../images/bundledplugins-announcements-settings.png
|
||||||
|
:align: center
|
||||||
|
:alt: Announcement settings
|
||||||
|
|
||||||
|
The Announcement Plugin's settings dialog.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-announcements-configuration:
|
||||||
|
|
||||||
|
Configuring the plugin
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
The plugin allows enabling and disabling the preconfigured announcement channels via its settings dialog.
|
||||||
|
|
||||||
|
On top of that it's possible to add additional announcement channels (as RSS or Atom feed URLs) or change the
|
||||||
|
configuration of the existing channels through ``config.yaml``.
|
||||||
|
|
||||||
|
The available configuration keys are:
|
||||||
|
|
||||||
|
* ``channels``: Configured announcement channels. A mapping from a unique identifier to a configuration structure
|
||||||
|
that follows this format:
|
||||||
|
|
||||||
|
* ``name``: Name of the channel, used e.g. in the title of the displayed notifications.
|
||||||
|
* ``description``: Description of the channel.
|
||||||
|
* ``priority``: ``1`` for high priority announcements (red notification), ``2`` for regular ones (yellow notification).
|
||||||
|
* ``type``: Currently unused.
|
||||||
|
* ``url``: URL for the feed acting as notification source, must be RSS or Atom format.
|
||||||
|
|
||||||
|
* ``enabled_channels``: List of identifiers of enabled channels.
|
||||||
|
* ``forced_channels``: List of identifiers of channels that cannot be disabled (currently only ``_important`` which is used sparingly).
|
||||||
|
* ``channel_order``: List of channel identifiers in the order they should appear in the UI.
|
||||||
|
* ``ttl``: Time to live of the channel cache in minutes (default: 6 hours).
|
||||||
|
* ``display_limit``: Limit of items to display per channel (default: 3).
|
||||||
|
* ``summary_limit``: Limit of characters to display from each channel entry (default: 300).
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-announcements-sourcecode:
|
||||||
|
|
||||||
|
Source code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Announcement plugin is bundled with OctoPrint and can be found in
|
||||||
|
its source repository under ``src/octoprint/plugins/announcements``.
|
||||||
@@ -0,0 +1,543 @@
|
|||||||
|
.. _sec-bundledplugins-appkeys:
|
||||||
|
|
||||||
|
Application Keys Plugin
|
||||||
|
=======================
|
||||||
|
|
||||||
|
The OctoPrint Application Keys Plugin comes bundled with OctoPrint (starting with version 1.3.10).
|
||||||
|
|
||||||
|
It implements a workflow for third party apps or clients to obtain an application specific API key from OctoPrint to interact with it
|
||||||
|
on a user's behalf, via confirmation of the user through OctoPrint's web interface. Existing keys can be managed
|
||||||
|
on a per-user base as well as globally by administrators.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-appkeys-confirmation:
|
||||||
|
.. figure:: ../images/bundledplugins-appkeys-confirmation_prompt.png
|
||||||
|
:align: center
|
||||||
|
:alt: Confirmation
|
||||||
|
|
||||||
|
The plugin's confirmation generated for a new application key request.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-appkeys-user_settings:
|
||||||
|
.. figure:: ../images/bundledplugins-appkeys-user_settings.png
|
||||||
|
:align: center
|
||||||
|
:alt: Key management via user settings
|
||||||
|
|
||||||
|
Users can manage the application specific API keys registered to their account via their user settings.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-appkeys-settings:
|
||||||
|
.. figure:: ../images/bundledplugins-appkeys-settings.png
|
||||||
|
:align: center
|
||||||
|
:alt: Global key management via settings
|
||||||
|
|
||||||
|
Administrators can manage all application specific API keys registered to any user.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-workflow:
|
||||||
|
|
||||||
|
Workflow
|
||||||
|
--------
|
||||||
|
|
||||||
|
The workflow to receive an API key for a third party client/an app via the Application Keys Plugin should consist
|
||||||
|
of the following steps:
|
||||||
|
|
||||||
|
1. The User opens the App and gets prompted to enter or select an instance URL. Optionally (recommended!) the User also
|
||||||
|
enters their username which is also their user ID into the App.
|
||||||
|
2. The App :ref:`probes for workflow support <sec-bundledplugins-appkeys-api-probe>` on the Server. If this request
|
||||||
|
doesn't get an HTTP :http:statuscode:`204` the App needs to direct the user to an alternative manual workflow
|
||||||
|
(copy-paste API key) and abort this one. Otherwise it proceeds to the next step.
|
||||||
|
3. The App sends a :ref:`key request <sec-bundledplugins-appkey-datamodel-keyrequest>` to the Server to start the
|
||||||
|
authorization process.
|
||||||
|
4. The Server triggers a confirmation dialog for the User on the Webinterface and returns an endpoint to the
|
||||||
|
App to poll for a decision in the ``Location`` header of an HTTP :http:statuscode:`201`.
|
||||||
|
5. The App uses the obtained request specific endpoint to poll for a decision every second. An HTTP :http:statuscode:`202`
|
||||||
|
signals that no decision has been made yet.
|
||||||
|
6. The User either accepts or denies the access request which makes the Webinterface send a
|
||||||
|
:ref:`decision request <sec-bundledplugins-appkey-datamodel-decisionrequest>` to the Server.
|
||||||
|
7. If the User accepted the request, the App receives an HTTP :http:statuscode:`200` with an attached
|
||||||
|
:ref:`API key response <sec-bundledplugins-appkey-datamodel-keyresponse>`. If they deny it, the App will receive
|
||||||
|
an HTTP :http:statuscode:`404`.
|
||||||
|
|
||||||
|
|
||||||
|
.. mermaid::
|
||||||
|
|
||||||
|
sequenceDiagram
|
||||||
|
participant User
|
||||||
|
participant App
|
||||||
|
participant Webinterface
|
||||||
|
participant Server
|
||||||
|
|
||||||
|
note over User, Server: Step 1, 2 & 3
|
||||||
|
|
||||||
|
User->>App: enters URL of instance to connect to and optional user_id
|
||||||
|
|
||||||
|
App->>Server: GET /plugin/appkeys/probe
|
||||||
|
|
||||||
|
alt Workflow unsupported
|
||||||
|
|
||||||
|
Server->>App: 404
|
||||||
|
App->>User: alternative workflow, copy-paste key manually
|
||||||
|
|
||||||
|
else Workflow supported
|
||||||
|
|
||||||
|
App->>Server: POST /plugin/appkeys/request, (app_name, user_id)
|
||||||
|
|
||||||
|
note over User, Server: Step 4
|
||||||
|
|
||||||
|
Server-->>Webinterface: plugin message for "appkeys" w/ (app_name, user_token, user_id)
|
||||||
|
Webinterface-->>User: Display confirmation dialog
|
||||||
|
Server->>App: 201, Location: /plugin/appkeys/request/<app_token>
|
||||||
|
|
||||||
|
note over User, Server: Step 5
|
||||||
|
|
||||||
|
loop Poll for decision
|
||||||
|
App->>Server: GET /plugin/appkeys/request/<app_token>
|
||||||
|
Server->>App: 202
|
||||||
|
end
|
||||||
|
|
||||||
|
note over User, Server: Step 6 & 7
|
||||||
|
|
||||||
|
alt User accepts
|
||||||
|
|
||||||
|
User-->>Webinterface: Allow access
|
||||||
|
Webinterface->>Server: POST /plugin/appkeys/decision/<user_token>, (True)
|
||||||
|
Server->>Webinterface: 204
|
||||||
|
App->>Server: GET /plugin/appkeys/request/<app_token>
|
||||||
|
Server->>App: 200, api_key
|
||||||
|
|
||||||
|
else User denies
|
||||||
|
|
||||||
|
User-->>Webinterface: Deny access
|
||||||
|
Webinterface->>Server: POST /plugin/appkeys/decision/<user_token>, (False)
|
||||||
|
Server->>Webinterface: 204
|
||||||
|
App->>Server: GET /plugin/appkeys/request/<app_token>
|
||||||
|
Server->>App: 404
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api:
|
||||||
|
|
||||||
|
API
|
||||||
|
---
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api-probe:
|
||||||
|
|
||||||
|
Probe for workflow support
|
||||||
|
..........................
|
||||||
|
|
||||||
|
.. http:get:: /plugin/appkeys/probe
|
||||||
|
|
||||||
|
Probes for support of the workflow.
|
||||||
|
|
||||||
|
Normally returns an HTTP :http:statuscode:`204`, indicating workflow availability. If a different status code is returned
|
||||||
|
(usually an HTTP :http:statuscode:`404`), the plugin is disabled or not installed. Fall back to manual api key exchange.
|
||||||
|
|
||||||
|
:status 204: the workflow is supported
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api-startauthprocess:
|
||||||
|
|
||||||
|
Start authorization process
|
||||||
|
...........................
|
||||||
|
|
||||||
|
.. http:post:: /plugin/appkeys/request
|
||||||
|
|
||||||
|
Starts the authorization process.
|
||||||
|
|
||||||
|
Expects a :ref:`Key request <sec-bundledplugins-appkey-datamodel-keyrequest>` as request body.
|
||||||
|
|
||||||
|
The ``app`` parameter should be a human readable identifier to use
|
||||||
|
for the application requesting access. It will be displayed to the user. Internally it will be used case insensitively,
|
||||||
|
so ``My App`` and ``my APP`` are considered the same application identifiers.
|
||||||
|
|
||||||
|
The optional ``user`` parameter should be used to limit the authorization process to a specified user. If the parameter
|
||||||
|
is left unset, any user will be able to complete the authorization process and grant access to the app with their
|
||||||
|
account. E.g. if a user ``me`` starts the process in an app, the app should request that name from the user and use
|
||||||
|
it in the ``user`` parameter. OctoPrint will then only display the authorization request on browsers the user ``me``
|
||||||
|
is logged in on.
|
||||||
|
|
||||||
|
:json app: application identifier to use for the request, case insensitive
|
||||||
|
:json user: optional user id to restrict the decision to the specified user
|
||||||
|
:status 201: authorization process started, polling URL to query can be found in ``Location`` header
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api-polldecision:
|
||||||
|
|
||||||
|
Poll for decision on existing request
|
||||||
|
.....................................
|
||||||
|
|
||||||
|
.. http:get:: /plugin/appkeys/request/<str:app_token>
|
||||||
|
|
||||||
|
Endpoint generated per authorization request to poll for the result.
|
||||||
|
|
||||||
|
Returns an HTTP :http:statuscode:`202` while no decision has been made yet, an HTTP :http:statuscode:`200` and
|
||||||
|
a :ref:`Key response <sec-bundledplugins-appkey-datamodel-keyresponse>` if access has been granted and an
|
||||||
|
HTTP :http:statuscode:`404` if the request has been denied or timed out.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
The request will be considered stale and deleted internally if the polling endpoint for it isn't called
|
||||||
|
for more than 5s.
|
||||||
|
|
||||||
|
:status 200: access granted, API key in response body
|
||||||
|
:status 202: no decision has been made yet, continue polling
|
||||||
|
:status 404: access denied or request timed out
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api-decide:
|
||||||
|
|
||||||
|
Decide on existing request
|
||||||
|
..........................
|
||||||
|
|
||||||
|
.. http:post:: /plugin/appkeys/decision/<str:user_token>
|
||||||
|
|
||||||
|
Endpoint to decide on the authorization request.
|
||||||
|
|
||||||
|
Expects a :ref:`Decision request <sec-bundledplugins-appkey-datamodel-decisionrequest>` as request body.
|
||||||
|
|
||||||
|
Returns an HTTP :http:statuscode:`204` on success.
|
||||||
|
|
||||||
|
:json decision: boolean value to indicate whether to confirm (``True``) or deny (``False``) access
|
||||||
|
:status 204: success
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api-fetchlist:
|
||||||
|
|
||||||
|
Fetch list of existing application keys
|
||||||
|
.......................................
|
||||||
|
|
||||||
|
.. http:get:: /api/plugin/appkeys
|
||||||
|
|
||||||
|
Fetches a list of existing application keys and pending requests registered in the system for the current user.
|
||||||
|
|
||||||
|
If the additional optional parameter ``all`` is provided and the user has administrator rights, fetches a list
|
||||||
|
of *all** application keys and pending requests registered in the system for any user.
|
||||||
|
|
||||||
|
Returns a :http:statuscode:`200` with a :ref:`List response <sec-bundledplugins-appkey-datamodel-listreponse>` in the
|
||||||
|
body upon success.
|
||||||
|
|
||||||
|
:query all: Fetch all application keys and pending requests from all users. Requires administrator rights.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-api-issuecommand:
|
||||||
|
|
||||||
|
Issue an application key command
|
||||||
|
................................
|
||||||
|
|
||||||
|
.. http:post:: /api/plugin/appkeys
|
||||||
|
|
||||||
|
Application key commands allow revoking existing application keys and manually generating new ones. The available
|
||||||
|
commands are:
|
||||||
|
|
||||||
|
revoke
|
||||||
|
Revokes an existing application key. Must belong to the user issuing the command, unless the user has admin rights
|
||||||
|
in which case they make revoke any application key in the system. Expects the key in question as parameter ``key``.
|
||||||
|
|
||||||
|
generate
|
||||||
|
Generates a new application key for the user, using the application identifier provided as parameter ``app``.
|
||||||
|
|
||||||
|
Upon success, a status code of :http:statuscode:`204` and an empty body is returned.
|
||||||
|
|
||||||
|
Requires user rights.
|
||||||
|
|
||||||
|
**Example revoke request**
|
||||||
|
|
||||||
|
Revokes the (fictional) key ``aabbccddeeff112233445566``.
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
POST /api/plugin/appkeys HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
Content-Type: application/json
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "revoke",
|
||||||
|
"key": "aabbccddeeff112233445566"
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
|
**Example generate request**
|
||||||
|
|
||||||
|
Generates a new key for application identifier "My awesome application 1.0".
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
POST /api/plugin/appkeys HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
Content-Type: application/json
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
{
|
||||||
|
"command": "generate",
|
||||||
|
"key": "My awesome application 1.0"
|
||||||
|
}
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 204 No Content
|
||||||
|
|
||||||
|
:json string command: The command to issue, either ``revoke`` or ``generate``
|
||||||
|
:json string key: ``revoke`` command: The key to revoke
|
||||||
|
:json string app: ``generate`` command: Application identifier for which to generate a key
|
||||||
|
:statuscode 204: No error
|
||||||
|
:statuscode 400: Invalid or missing parameter
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel:
|
||||||
|
|
||||||
|
Data model
|
||||||
|
----------
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel-keyrequest:
|
||||||
|
|
||||||
|
Key request
|
||||||
|
...........
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``app``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- Application identifier to use for the request
|
||||||
|
* - ``user``
|
||||||
|
- 0..1
|
||||||
|
- str
|
||||||
|
- User identifier/name to restrict the request to
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel-keyresponse:
|
||||||
|
|
||||||
|
Key response
|
||||||
|
............
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``apikey``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- the API key generated for the application
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel-decisionrequest:
|
||||||
|
|
||||||
|
Decision request
|
||||||
|
................
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``decision``
|
||||||
|
- 1
|
||||||
|
- boolean
|
||||||
|
- ``True`` if the access request it to be granted, ``False`` otherwise
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel-listreponse:
|
||||||
|
|
||||||
|
List response
|
||||||
|
.............
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``keys``
|
||||||
|
- 1
|
||||||
|
- list of :ref:`key list entries <sec-bundledplugins-appkey-datamodel-keylistentry>`
|
||||||
|
- Keys registered in the system
|
||||||
|
* - ``pending``
|
||||||
|
- 1
|
||||||
|
- list of :ref:`pending list entries <sec-bundledplugins-appkey-datamodel-pendinglistentry>`
|
||||||
|
- Currently pending authorization requests
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel-keylistentry:
|
||||||
|
|
||||||
|
Key list entry
|
||||||
|
..............
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``api_key``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- API key
|
||||||
|
* - ``app_id``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- Application identifier
|
||||||
|
* - ``user_id``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- User ID of the key's owner
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkey-datamodel-pendinglistentry:
|
||||||
|
|
||||||
|
Pending list entry
|
||||||
|
..................
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``app_id``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- Application identifier
|
||||||
|
* - ``user_id``
|
||||||
|
- 0..1
|
||||||
|
- str
|
||||||
|
- optional: User ID of user who can grant or deny request
|
||||||
|
* - ``user_token``
|
||||||
|
- 1
|
||||||
|
- str
|
||||||
|
- Token to grant or deny request
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-jsclientlib:
|
||||||
|
|
||||||
|
JavaScript Client Library
|
||||||
|
-------------------------
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.getKeys(opts)
|
||||||
|
|
||||||
|
Retrieves registered keys and pending requests for the current user.
|
||||||
|
|
||||||
|
See :ref:`Fetch list of existing application keys <sec-bundledplugins-appkeys-api-fetchlist>` for more details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.getAllKeys(opts)
|
||||||
|
|
||||||
|
Retrieves registered keys and pending requests for all users.
|
||||||
|
|
||||||
|
Needs administrator rights.
|
||||||
|
|
||||||
|
See :ref:`Fetch list of existing application keys <sec-bundledplugins-appkeys-api-fetchlist>` for more details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.generateKey(app, opts)
|
||||||
|
|
||||||
|
Generates a key for the given ``app`` and the current user.
|
||||||
|
|
||||||
|
See :ref:`Issue an application key command <sec-bundledplugins-appkeys-api-issuecommand>` for details.
|
||||||
|
|
||||||
|
:param string app: Application identifier
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.revokeKey(key, opts)
|
||||||
|
|
||||||
|
Revokes the given ``key``. The key must belong to the current user, or the current user must have administrator
|
||||||
|
rights.
|
||||||
|
|
||||||
|
See :ref:`Issue an application key command <sec-bundledplugins-appkeys-api-issuecommand>` for details.
|
||||||
|
|
||||||
|
:param string key: Key to revoke
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.decide(token, decision, opts)
|
||||||
|
|
||||||
|
Decides on an existing authorization request.
|
||||||
|
|
||||||
|
See :ref:`Decide on existing request <sec-bundledplugins-appkeys-api-decide>` for more details.
|
||||||
|
|
||||||
|
:param string token: User token for which to make the decision, as pushed to the client via the socket.
|
||||||
|
:param boolean decision: Whether to grant access (``true``) or not (``false``).
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.probe(opts)
|
||||||
|
|
||||||
|
Probes for workflow support.
|
||||||
|
|
||||||
|
See :ref:`Probe for workflow support <sec-bundledplugins-appkeys-api-probe>` for more details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.request(app, opts)
|
||||||
|
|
||||||
|
Starts a new authorization request for the provided ``app`` identifier.
|
||||||
|
|
||||||
|
See :ref:`Start authorization process <sec-bundledplugins-appkeys-api-startauthprocess>` for more details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.requestForUser(app, user, opts)
|
||||||
|
|
||||||
|
Starts a new authorization request for the provided ``app`` and ``user`` identifiers.
|
||||||
|
|
||||||
|
See :ref:`Start authorization process <sec-bundledplugins-appkeys-api-startauthprocess>` for more details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.checkDecision(token, opts)
|
||||||
|
|
||||||
|
Polls for a decision on an existing authorization request identified by ``token``.
|
||||||
|
|
||||||
|
See :ref:`Poll for decision on existing request <sec-bundledplugins-appkeys-api-polldecision>` for more details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.appkeys.authenticate(app, user, opts)
|
||||||
|
|
||||||
|
Convenience function that probes for support, issues a request and then automatically starts polling for a decision
|
||||||
|
on the returned polling endpoint every 1s, until either a positive or negative decision is returned. On success the
|
||||||
|
returned promise is resolved with the generated API key as argument. If anything goes wrong or there is no support
|
||||||
|
for the workflow, the promise is rejected.
|
||||||
|
|
||||||
|
**Example usage**
|
||||||
|
|
||||||
|
.. sourcecode:: javascript
|
||||||
|
|
||||||
|
OctoPrint.plugins.appkeys.authenticate("My App", "some_user")
|
||||||
|
.done(function(api_key) {
|
||||||
|
console.log("Got our API key:", api_key);
|
||||||
|
})
|
||||||
|
.fail(function() {
|
||||||
|
console.log("No API key for us");
|
||||||
|
})
|
||||||
|
|
||||||
|
:param string app: Application identifier
|
||||||
|
:param string user: Optional user identifier
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-appkeys-sourcecode:
|
||||||
|
|
||||||
|
Source code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Application Keys plugin is bundled with OctoPrint and can be found in
|
||||||
|
its source repository under ``src/octoprint/plugins/appkeys``.
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
.. _sec-bundledplugins-backup:
|
||||||
|
|
||||||
|
Backup Plugin
|
||||||
|
=============
|
||||||
|
|
||||||
|
The OctoPrint Backup Plugin comes bundled with OctoPrint (starting with 1.3.10).
|
||||||
|
|
||||||
|
It allows the creation and restoration of backups of OctoPrint's settings, data and installed plugins [#]_.
|
||||||
|
|
||||||
|
This allows easy migration
|
||||||
|
to newly setup instances as well as making regular backups to prevent data loss.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-backup-settings:
|
||||||
|
.. figure:: ../images/bundledplugins-backup-settings.png
|
||||||
|
:align: center
|
||||||
|
:alt: OctoPrint Backup Plugin
|
||||||
|
|
||||||
|
The plugin's settings panel with existing backups, the backup creation and restore sections.
|
||||||
|
|
||||||
|
As long as plugins adhere to the standard of storing their data and settings in OctoPrint's plugin data folders, their
|
||||||
|
data will be part of the backup. Note that the backups made by the Backup Plugin will *not* be part of any backups -
|
||||||
|
you'll need to persist the resulting zip files yourself!
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-backup-cli:
|
||||||
|
|
||||||
|
Command line usage
|
||||||
|
------------------
|
||||||
|
|
||||||
|
The Backup Plugin implements a command line interface that allows creation and restoration of backups.
|
||||||
|
It adds two new commands, ``backup:backup`` and ``backup_restore``.
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
$ octoprint plugins backup:backup --help
|
||||||
|
Initializing settings & plugin subsystem...
|
||||||
|
Usage: octoprint plugins backup:backup [OPTIONS]
|
||||||
|
|
||||||
|
Creates a new backup.
|
||||||
|
|
||||||
|
Options:
|
||||||
|
--exclude TEXT Identifiers of data folders to exclude, e.g. 'uploads' to
|
||||||
|
exclude uploads or 'timelapse' to exclude timelapses.
|
||||||
|
--help Show this message and exit.
|
||||||
|
|
||||||
|
$ octoprint plugins backup:restore --help
|
||||||
|
Initializing settings & plugin subsystem...
|
||||||
|
Usage: octoprint plugins backup:restore [OPTIONS] PATH
|
||||||
|
|
||||||
|
Restores an existing backup from the backup zip provided as argument.
|
||||||
|
|
||||||
|
OctoPrint does not need to run for this to proceed.
|
||||||
|
|
||||||
|
Options:
|
||||||
|
--help Show this message and exit.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
The ``backup:backup`` command can be useful in combination with a cronjob to create backups in regular intervals.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-backup-sourcecode:
|
||||||
|
|
||||||
|
Source code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Backup plugin is bundled with OctoPrint and can be found in
|
||||||
|
its source repository under ``src/octoprint/plugins/backup``.
|
||||||
|
|
||||||
|
.. [#] Note that only those plugins that are available on `OctoPrint's official plugin repository <https://plugins.octoprint.org>`_
|
||||||
|
can be automatically restored. If you have plugins installed that are not available on there you'll get their
|
||||||
|
names and - if available - homepage URL displayed after restore in order to be able to manually reinstall them.
|
||||||
@@ -1,138 +0,0 @@
|
|||||||
.. _sec-bundledplugins_cura:
|
|
||||||
|
|
||||||
Cura
|
|
||||||
====
|
|
||||||
|
|
||||||
The Cura Plugin allows slicing of STL files uploaded to OctoPrint directly via
|
|
||||||
the `CuraEngine <http://github.com/Ultimaker/CuraEngine>`_ **up to and
|
|
||||||
including version 15.04.x** and supersedes the slicing support integrated into
|
|
||||||
OctoPrint so far. It comes bundled with OctoPrint starting with version 1.2.0.
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
Versions of CuraEngine later than 15.04.x have changed their calling
|
|
||||||
parameters in such a way that the current implementation of OctoPrint's Cura plugin
|
|
||||||
is not compatible to it. For this reason, please use only CuraEngine versions up to
|
|
||||||
and including 15.04 for now, as available in the ``legacy`` branch of the CuraEngine
|
|
||||||
repository on Github.
|
|
||||||
|
|
||||||
The plugin offers a settings module that allows configuring the path to the
|
|
||||||
CuraEngine executable to use, as well as importing and managing slicing
|
|
||||||
profiles to be used. Please note that the Cura Plugin will use the printer
|
|
||||||
parameters you configured within OctoPrint (meaning bed size and extruder
|
|
||||||
count and offsets) for slicing.
|
|
||||||
|
|
||||||
.. _sec-bundledplugins-cura-firststeps:
|
|
||||||
|
|
||||||
First Steps
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Before you can slice from within OctoPrint, you'll need to
|
|
||||||
|
|
||||||
#. :ref:`Install CuraEngine <sec-bundledplugins-cura-installing>`
|
|
||||||
#. :ref:`Configure the path to CuraEngine within OctoPrint <sec-bundledplugins-cura-configuring>`
|
|
||||||
#. :ref:`Export a slicing profile from Cura and import it within OctoPrint <sec-bundledplugins-cura-profiles>`
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
OctoPi 0.12.0 and later ships with steps 1 and 2 already done, you only need to
|
|
||||||
supply one or more slicing profiles to get going :)
|
|
||||||
|
|
||||||
.. _sec-bundledplugins-cura-installing:
|
|
||||||
|
|
||||||
Installing CuraEngine
|
|
||||||
---------------------
|
|
||||||
|
|
||||||
You'll need a build of ``legacy`` branch of `CuraEngine <http://github.com/Ultimaker/CuraEngine>`_
|
|
||||||
in order to be able to use the Cura OctoPrint plugin. You can find the ``legacy`` branch
|
|
||||||
`here <https://github.com/ultimaker/curaengine/tree/legacy>`_.
|
|
||||||
|
|
||||||
If you previously used the `old variant of the Cura integration <https://github.com/foosel/OctoPrint/wiki/Cura-Integration>`_,
|
|
||||||
you probably still have a fully functional binary lying around in the
|
|
||||||
installation folder of the full install of Cura you used then -- just put the
|
|
||||||
path to that in the plugin settings.
|
|
||||||
|
|
||||||
.. _sec-bundledplugins-cura-installing-raspbian:
|
|
||||||
|
|
||||||
Compiling for Raspbian
|
|
||||||
++++++++++++++++++++++
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
A binary of CuraEngine 15.04.06 precompiled on Raspbian Jessie Lite 2016-03-18 is available
|
|
||||||
`here <http://bit.ly/octopi_cura_engine_150406>`_. Don't forget to make it
|
|
||||||
executable after copying it to your preferred destination on your Pi
|
|
||||||
(suggestion: ``/usr/local/bin``) with ``chmod +x cura_engine``. Use at your
|
|
||||||
own risk.
|
|
||||||
|
|
||||||
Raspbian Jessie
|
|
||||||
~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
Building on Raspbian Jessie is as easy as::
|
|
||||||
|
|
||||||
sudo apt-get -y install gcc-4.7 g++-4.7
|
|
||||||
git clone -b legacy https://github.com/Ultimaker/CuraEngine.git
|
|
||||||
cd CuraEngine
|
|
||||||
make
|
|
||||||
|
|
||||||
After this has completed, you'll find your shiny new build of CuraEngine in
|
|
||||||
the `build` folder (full path for above example:
|
|
||||||
``~/CuraEngine/build/CuraEngine``).
|
|
||||||
|
|
||||||
Raspbian Wheezy
|
|
||||||
~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
You'll need to install a new version of gcc and g++ and patch CuraEngine's
|
|
||||||
Makefile (see `this post <http://umforum.ultimaker.com/index.php?/topic/5943-recent-build-of-curaengine-wont-compile-on-raspberry-pi/#entry58539>`_)
|
|
||||||
in order for the compilation to work on current Raspbian builds (e.g. OctoPi)::
|
|
||||||
|
|
||||||
sudo apt-get -y install gcc-4.7 g++-4.7
|
|
||||||
git clone -b legacy https://github.com/Ultimaker/CuraEngine.git
|
|
||||||
cd CuraEngine
|
|
||||||
wget http://bit.ly/curaengine_makefile_patch -O CuraEngine.patch
|
|
||||||
patch < CuraEngine.patch
|
|
||||||
make CXX=g++-4.7
|
|
||||||
|
|
||||||
After this has completed, you'll find your shiny new build of CuraEngine in
|
|
||||||
the `build` folder (full path for above example:
|
|
||||||
``~/CuraEngine/build/CuraEngine``).
|
|
||||||
|
|
||||||
.. _sec-bundledplugins-cura-configuring:
|
|
||||||
|
|
||||||
Configuring the plugin
|
|
||||||
----------------------
|
|
||||||
|
|
||||||
The Cura plugin needs to be configured with the full path to your copy of the
|
|
||||||
CuraEngine executable that it's supposed to use. You can do this either via
|
|
||||||
the Cura plugin settings dialog or by manually configuring the path to the
|
|
||||||
executable via ``config.yaml``, example:
|
|
||||||
|
|
||||||
.. code-block:: yaml
|
|
||||||
|
|
||||||
plugins:
|
|
||||||
cura:
|
|
||||||
cura_engine: /path/to/CuraEngine
|
|
||||||
|
|
||||||
.. _sec-bundledplugins-cura-profiles:
|
|
||||||
|
|
||||||
Using Cura Profiles
|
|
||||||
-------------------
|
|
||||||
|
|
||||||
The Cura Plugin supports importing your existing profiles for Cura **up to and
|
|
||||||
including Cura 15.04.x**. Newer Cura releases (e.g. 15.06 or 2.x) use a different
|
|
||||||
internal format that will *not* work with the current version of the Cura Plugin.
|
|
||||||
|
|
||||||
You can find downloads of Cura 15.04.x for Windows, Mac and Linux `on Ultimaker's download page <https://ultimaker.com/en/products/cura-software/list>`_.
|
|
||||||
|
|
||||||
In order to export a slicing profile from the Cura desktop UI, open it,
|
|
||||||
set up your profile, then click on "File" and there on "Save Profile". You can
|
|
||||||
import the .ini-file this creates via the "Import Profile" button in the
|
|
||||||
Cura Settings within OctoPrint.
|
|
||||||
|
|
||||||
.. _sec-bundledplugins-cura-sourcecode:
|
|
||||||
|
|
||||||
Source code
|
|
||||||
-----------
|
|
||||||
|
|
||||||
The source of the Cura plugin is bundled with OctoPrint and can be found in
|
|
||||||
its source repository under ``src/octoprint/plugins/cura``.
|
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
.. _sec-bundledplugins-errortracking:
|
||||||
|
|
||||||
|
Error Tracking Plugin
|
||||||
|
=====================
|
||||||
|
|
||||||
|
The Error Tracking plugin will cause any logged exceptions in the server and the browser interface to be sent to
|
||||||
|
OctoPrint's `Sentry instance <https://sentry.io/>`_.
|
||||||
|
|
||||||
|
By enabling it you help to gather detailed information on the cause of bugs or other issues. This is especially
|
||||||
|
valuable on release candidates, which is why this plugin will also prompt you to enable error tracking if it detects
|
||||||
|
that you are subscribed to an RC release channel.
|
||||||
|
|
||||||
|
By default, even when enabled it will only be active if you are running a released OctoPrint version, so either a stable
|
||||||
|
release or a release candidate.
|
||||||
|
|
||||||
|
The Error Tracking plugin is using a Sentry instance kindly provided by `sentry.io <https://sentry.io/>`_. For information on their service
|
||||||
|
please refer to their `Security & Compliance documentation <https://sentry.io/security/>`_
|
||||||
|
and their `Privacy Policy <https://sentry.io/privacy/>`_.
|
||||||
|
|
||||||
|
The Error Tracking plugin has been bundled with OctoPrint since version 1.3.11.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-errortracking-configuration:
|
||||||
|
|
||||||
|
Configuring the plugin
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
The plugin supports the following configuration keys:
|
||||||
|
|
||||||
|
* ``enabled``: Whether to enable error tracking. Defaults to ``false``.
|
||||||
|
* ``enabled_unreleased``: Whether to also enable tracking on unreleased OctoPrint versions (anything not stable releases
|
||||||
|
or release candidates). Defaults to ``false``.
|
||||||
|
* ``unique_id``: Unique instance identifier, auto generated on first activation
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-errortracking-sourcecode:
|
||||||
|
|
||||||
|
Source Code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Error Tracking plugin is bundled with OctoPrint and can be
|
||||||
|
found in its source repository under ``src/octoprint/plugins/errortracking``.
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
.. _sec-bundledplugins-forcelogin:
|
||||||
|
|
||||||
|
ForceLogin Plugin
|
||||||
|
=================
|
||||||
|
|
||||||
|
The ForceLogin Plugin comes bundled with OctoPrint (starting with version 1.3.10). It removes the anonymous
|
||||||
|
read-only access that up until 1.3.10 was standard when accessing OctoPrint instances without being logged in and
|
||||||
|
instead forces users to log in if they want to get any kind of information from OctoPrint.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-forcelogin:
|
||||||
|
.. figure:: ../images/bundledplugins-forcelogin-dialog.png
|
||||||
|
:align: center
|
||||||
|
:alt: Forced login dialog
|
||||||
|
|
||||||
|
OctoPrint's new forced login dialog.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Keep in mind that **OctoPrint does not manage your webcam**, it merely embeds it. If you have a webcam,
|
||||||
|
it will still be accessible to users who are not logged in under its (guessable) URL. If you need to restrict
|
||||||
|
access to your webcam, you'll need to find a way to do so directly on the webcam server which - again -
|
||||||
|
is not OctoPrint itself.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
If you want back the old behaviour of allowing anonymous read-only access to your OctoPrint instance, disable
|
||||||
|
the ForceLogin Plugin in OctoPrint's plugin manager.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-forcelogin-sourcecode:
|
||||||
|
|
||||||
|
Source code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the ForceLogin plugin is bundled with OctoPrint and can be found in
|
||||||
|
its source repository under ``src/octoprint/plugins/forcelogin``.
|
||||||
@@ -7,7 +7,15 @@ Bundled Plugins
|
|||||||
.. toctree::
|
.. toctree::
|
||||||
:maxdepth: 2
|
:maxdepth: 2
|
||||||
|
|
||||||
cura.rst
|
action_command_prompt.rst
|
||||||
|
announcements.rst
|
||||||
|
tracking.rst
|
||||||
|
appkeys.rst
|
||||||
|
backup.rst
|
||||||
discovery.rst
|
discovery.rst
|
||||||
|
errortracking.rst
|
||||||
|
forcelogin.rst
|
||||||
|
logging.rst
|
||||||
pluginmanager.rst
|
pluginmanager.rst
|
||||||
|
printer_safety_check.rst
|
||||||
softwareupdate.rst
|
softwareupdate.rst
|
||||||
@@ -0,0 +1,238 @@
|
|||||||
|
.. _sec-bundledplugins-logging:
|
||||||
|
|
||||||
|
Logging
|
||||||
|
=======
|
||||||
|
|
||||||
|
The OctoPrint Logging plugin comes bundled with OctoPrint starting with version 1.3.7.
|
||||||
|
|
||||||
|
It implements the log management functionality that was formerly part of the core application and adds features to
|
||||||
|
configure logging levels for sub modules through the included settings dialog.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-logging-settings:
|
||||||
|
.. figure:: ../images/bundledplugins-logging-settings.png
|
||||||
|
:align: center
|
||||||
|
:alt: Logging plugin
|
||||||
|
|
||||||
|
The settings dialog of the Logging plugin
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api:
|
||||||
|
|
||||||
|
API
|
||||||
|
---
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
All log file management operations require admin rights.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api-list_logs:
|
||||||
|
|
||||||
|
Retrieve a list of available log files
|
||||||
|
++++++++++++++++++++++++++++++++++++++
|
||||||
|
|
||||||
|
.. http:get:: /plugin/logging/logs
|
||||||
|
|
||||||
|
Retrieve information regarding all log files currently available and regarding the disk space still available
|
||||||
|
in the system on the location the log files are being stored.
|
||||||
|
|
||||||
|
Returns a :ref:`Logfile Retrieve response <sec-bundledplugins-logging-api-datamodel-retrieveresponse>`.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
GET /plugin/logging/logs HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
HTTP/1.1 200 OK
|
||||||
|
Content-Type: application/json
|
||||||
|
|
||||||
|
{
|
||||||
|
"files" : [
|
||||||
|
{
|
||||||
|
"date" : 1393158814,
|
||||||
|
"name" : "octoprint.log",
|
||||||
|
"size" : 43712,
|
||||||
|
"refs": {
|
||||||
|
"resource": "http://example.com/plugin/logging/logs/octoprint.log",
|
||||||
|
"download": "http://example.com/downloads/logs/octoprint.log"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"date" : 1392628936,
|
||||||
|
"name" : "octoprint.log.2014-02-17",
|
||||||
|
"size" : 13205,
|
||||||
|
"refs": {
|
||||||
|
"resource": "http://example.com/plugin/logging/logs/octoprint.log.2014-02-17",
|
||||||
|
"download": "http://example.com/downloads/logs/octoprint.log.2014-02-17"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"date" : 1393158814,
|
||||||
|
"name" : "serial.log",
|
||||||
|
"size" : 1798419,
|
||||||
|
"refs": {
|
||||||
|
"resource": "http://example.com/plugin/logging/logs/serial.log",
|
||||||
|
"download": "http://example.com/downloads/logs/serial.log"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"free": 12237201408
|
||||||
|
}
|
||||||
|
|
||||||
|
:statuscode 200: No error
|
||||||
|
:statuscode 403: If the given API token did not have admin rights associated with it
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api-delete_logs:
|
||||||
|
|
||||||
|
Delete a specific logfile
|
||||||
|
+++++++++++++++++++++++++
|
||||||
|
|
||||||
|
.. http:delete:: /plugin/logging/logs/(path:filename)
|
||||||
|
|
||||||
|
Delete the selected log file with name `filename`.
|
||||||
|
|
||||||
|
Returns a :http:statuscode:`204` after successful deletion.
|
||||||
|
|
||||||
|
**Example Request**
|
||||||
|
|
||||||
|
.. sourcecode:: http
|
||||||
|
|
||||||
|
DELETE /plugin/logging/logs/octoprint.log.2014-02-17 HTTP/1.1
|
||||||
|
Host: example.com
|
||||||
|
X-Api-Key: abcdef...
|
||||||
|
|
||||||
|
:param filename: The filename of the log file to delete
|
||||||
|
:statuscode 204: No error
|
||||||
|
:statuscode 403: If the given API token did not have admin rights associated with it
|
||||||
|
:statuscode 404: If the file was not found
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api-datamodel:
|
||||||
|
|
||||||
|
Data model
|
||||||
|
++++++++++
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api-datamodel-retrieveresponse:
|
||||||
|
|
||||||
|
Logfile Retrieve Response
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``files``
|
||||||
|
- 0..*
|
||||||
|
- Array of :ref:`File information items <sec-bundledplugins-logging-api-datamodel-fileinfo>`
|
||||||
|
- The list of requested files. Might be an empty list if no files are available
|
||||||
|
* - ``free``
|
||||||
|
- 1
|
||||||
|
- String
|
||||||
|
- The amount of disk space in bytes available in the local disk space (refers to OctoPrint's ``logs`` folder).
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api-datamodel-fileinfo:
|
||||||
|
|
||||||
|
File information
|
||||||
|
~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``name``
|
||||||
|
- 1
|
||||||
|
- String
|
||||||
|
- The name of the file
|
||||||
|
* - ``size``
|
||||||
|
- 1
|
||||||
|
- Number
|
||||||
|
- The size of the file in bytes.
|
||||||
|
* - ``date``
|
||||||
|
- 1
|
||||||
|
- Unix timestamp
|
||||||
|
- The timestamp when this file was last modified.
|
||||||
|
* - ``refs``
|
||||||
|
- 1
|
||||||
|
- :ref:`References <sec-bundledplugins-logging-api-datamodel-ref>`
|
||||||
|
- References relevant to this file
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-api-datamodel-ref:
|
||||||
|
|
||||||
|
References
|
||||||
|
~~~~~~~~~~
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:widths: 15 5 10 30
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Name
|
||||||
|
- Multiplicity
|
||||||
|
- Type
|
||||||
|
- Description
|
||||||
|
* - ``resource``
|
||||||
|
- 1
|
||||||
|
- URL
|
||||||
|
- The resource that represents the file (e.g. for deleting)
|
||||||
|
* - ``download``
|
||||||
|
- 1
|
||||||
|
- URL
|
||||||
|
- The download URL for the file
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-jsclientlib:
|
||||||
|
|
||||||
|
JS Client Library
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
:mod:`OctoPrintClient.plugins.logging`
|
||||||
|
--------------------------------------
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
All methods here require that the used API token or the existing browser session
|
||||||
|
has admin rights.
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.logging.listLogs(opts)
|
||||||
|
|
||||||
|
Retrieves a list of log files.
|
||||||
|
|
||||||
|
See :ref:`Retrieve a list of available log files <sec-bundledplugins-logging-api-list_logs>` for details.
|
||||||
|
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.logging.deleteLog(path, opts)
|
||||||
|
|
||||||
|
Deletes the specified log ``path``.
|
||||||
|
|
||||||
|
See :ref:`Delete a specific log file <sec-bundledplugins-logging-api-delete_logs>` for details.
|
||||||
|
|
||||||
|
:param string path: The path to the log file to delete
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.plugins.logging.downloadLog(path, opts)
|
||||||
|
|
||||||
|
Downloads the specified log ``file``.
|
||||||
|
|
||||||
|
See :js:func:`OctoPrint.download` for more details on the underlying library download mechanism.
|
||||||
|
|
||||||
|
:param string path: The path to the log file to download
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-logging-sourcecode:
|
||||||
|
|
||||||
|
Source Code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Logging plugin is bundled with OctoPrint and can be found in its source repository under ``src/octoprint/plugins/logging``.
|
||||||
@@ -54,6 +54,12 @@ under Settings > Plugin Manager, or by directly editing ``config.yaml``:
|
|||||||
# Time to live for the repository cache
|
# Time to live for the repository cache
|
||||||
repository_ttl: 1440
|
repository_ttl: 1440
|
||||||
|
|
||||||
|
# The URL of the plugin notices feed to use
|
||||||
|
notices: http://plugins.octoprint.org/notices.json
|
||||||
|
|
||||||
|
# Time to live for the notices feed cache
|
||||||
|
notices_ttl: 360
|
||||||
|
|
||||||
# Additional arguments to use with pip. Defaults to unset,
|
# Additional arguments to use with pip. Defaults to unset,
|
||||||
# you normally shouldn't need to modify this
|
# you normally shouldn't need to modify this
|
||||||
pip_args: --some --additional --pip --arguments
|
pip_args: --some --additional --pip --arguments
|
||||||
@@ -76,6 +82,75 @@ under Settings > Plugin Manager, or by directly editing ``config.yaml``:
|
|||||||
- hidden
|
- hidden
|
||||||
- plugins
|
- plugins
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-pluginmanager-events:
|
||||||
|
|
||||||
|
Events
|
||||||
|
------
|
||||||
|
|
||||||
|
plugin_pluginmanager_install_plugin
|
||||||
|
A plugin was installed.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``id``: the identifier of the installed plugin
|
||||||
|
* ``version``: the version of the installed plugin
|
||||||
|
* ``source``: source from which the plugin was installed, can be an URL or a path in the local file system
|
||||||
|
* ``source_type``: type of source from which the plugin was installed, can be ``url`` or ``path``
|
||||||
|
|
||||||
|
plugin_pluginmanager_uninstall_plugin
|
||||||
|
A plugin was uninstalled.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``id``: the identifier of the uninstalled plugin
|
||||||
|
* ``version``: the version of the uninstalled plugin
|
||||||
|
|
||||||
|
plugin_pluginmanager_enable_plugin
|
||||||
|
A plugin was enabled.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``id``: the identifier of the enabled plugin
|
||||||
|
* ``version``: the version of the enabled plugin
|
||||||
|
|
||||||
|
plugin_pluginmanager_disabled_plugin
|
||||||
|
A plugin was disabled.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``id``: the identifier of the disabled plugin
|
||||||
|
* ``version``: the version of the disabled plugin
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-pluginmanager-hooks:
|
||||||
|
|
||||||
|
Hooks
|
||||||
|
-----
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-pluginmanager-hooks-reconnect_hooks:
|
||||||
|
|
||||||
|
octoprint.plugin.pluginmanager.reconnect_hooks
|
||||||
|
++++++++++++++++++++++++++++++++++++++++++++++
|
||||||
|
|
||||||
|
.. py:function:: reconnect_hooks_hook(*args, **kwargs)
|
||||||
|
|
||||||
|
Returns additional hooks defined by the plugin for which the plugin manager
|
||||||
|
should display the "You should reconnect to your printer" message on plugin
|
||||||
|
install/uninstall/enabling/disabling.
|
||||||
|
|
||||||
|
Handlers should return a Python list containing the affected hook names.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
def reconnect_hooks_hook(*args, **kwargs):
|
||||||
|
return ["octoprint.plugin.exampleplugin.some_custom_hook",
|
||||||
|
"octoprint.plugin.exampleplugin.some_other_custom_hook"]
|
||||||
|
|
||||||
|
__plugin_hooks__ = {
|
||||||
|
"octoprint.plugin.pluginmanager.reconnect_hooks": reconnect_hooks_hook
|
||||||
|
}
|
||||||
|
|
||||||
.. _sec-bundledplugins-pluginmanager-sourcecode:
|
.. _sec-bundledplugins-pluginmanager-sourcecode:
|
||||||
|
|
||||||
Source Code
|
Source Code
|
||||||
|
|||||||
@@ -0,0 +1,52 @@
|
|||||||
|
.. _sec-bundledplugins-printer_safety_check:
|
||||||
|
|
||||||
|
Printer Safety Check
|
||||||
|
====================
|
||||||
|
|
||||||
|
The Printer Safety Check plugin comes bundled with OctoPrint starting with version 1.3.7.
|
||||||
|
|
||||||
|
It tries to identify printers or rather printer firmwares with known safety issues, such as
|
||||||
|
disabled thermal runaway protection, and displays a warning box to logged in users on
|
||||||
|
such identification.
|
||||||
|
|
||||||
|
.. _fig-bundledplugins-printer_safety_check-example:
|
||||||
|
.. figure:: ../images/bundledplugins-printer_safety_check-example.png
|
||||||
|
:align: center
|
||||||
|
:alt: Printer Safety Check warning example
|
||||||
|
|
||||||
|
An example of a warning generated by the Printer Safety Check
|
||||||
|
|
||||||
|
Please refer to the `entry on the "unsafe firmware" warning in OctoPrint's FAQ <https://faq.octoprint.org/warning-firmware-unsafe>`_
|
||||||
|
for a list of currently identified printers.
|
||||||
|
|
||||||
|
If you know of further printers/printer firmwares that need to be added here, please
|
||||||
|
`get in touch on the forum and provide their response to an M115 <https://faq.octoprint.org/warning-firmware-unsafe>`_.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
Feel free to disable the plugin in OctoPrint's Plugin Manager if you feel like it is unnecessary. Be advised though
|
||||||
|
that even if your printer might be running totally fine with a known unsafe configuration, that might change
|
||||||
|
unexpectedly and with `catastrophic <https://www.thissmarthouse.net/dont-burn-your-house-down-3d-printing-a-cautionary-tale/>`_
|
||||||
|
`results <https://www.reddit.com/r/3Dprinting/comments/6cekgk/house_fire_thanks_to_cheap_printer_from_china/>`_.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-printer_safety_check-events:
|
||||||
|
|
||||||
|
Events
|
||||||
|
------
|
||||||
|
|
||||||
|
warning
|
||||||
|
A printer safety warning was triggered.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``check_type``: type of check that was triggered (e.g. ``m115``, ``received`` or ``cap``)
|
||||||
|
* ``check_name``: name of check that was triggered (e.g. ``aneta8``)
|
||||||
|
* ``warning_type``: type of warning that was triggered (e.g. ``firmware-unsafe``)
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-printer_safety_check-source:
|
||||||
|
|
||||||
|
Source Code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Printer Safety Check plugin is bundled with OctoPrint and can be
|
||||||
|
found in its source repository under ``src/octoprint/plugins/printer_safety_check``.
|
||||||
@@ -14,14 +14,14 @@ First Steps
|
|||||||
|
|
||||||
Out of the box the Software Update Plugin will be able to notify you of any
|
Out of the box the Software Update Plugin will be able to notify you of any
|
||||||
updates that might be available for your OctoPrint installation or any plugins
|
updates that might be available for your OctoPrint installation or any plugins
|
||||||
that registered themselves with it. In order to also be able to update
|
that registered themselves with it. In order for automatic restarts after updates
|
||||||
your OctoPrint installation, you'll need to configure
|
to work, you should configure the restart commands for OctoPrint and the whole server.
|
||||||
at least OctoPrint's checkout folder, and you also should
|
|
||||||
configure the restart commands for OctoPrint and the whole server.
|
|
||||||
|
|
||||||
For configuring the plugin you'll need to go into OctoPrint's Settings Dialog, navigate to the
|
Out of the box the plugin should already be ready to update your OctoPrint installation to current
|
||||||
Software Upda.. _section therein and once you are there click on the little wrench icon in the
|
stable release versions, but you can also switch to one of the available release candidate channels
|
||||||
upper right corner.
|
or outright git commit tracking via the plugin's configuration dialog. To open this dialog, fire up OctoPrint's
|
||||||
|
Settings Dialog, navigate to the Software Update section therein and once you are there click on the little
|
||||||
|
wrench icon in the upper right corner.
|
||||||
|
|
||||||
.. _fig-bundledplugins-softwareupdate-plugin-configuration:
|
.. _fig-bundledplugins-softwareupdate-plugin-configuration:
|
||||||
.. figure:: ../images/bundledplugins-softwareupdate-plugin-configuration.png
|
.. figure:: ../images/bundledplugins-softwareupdate-plugin-configuration.png
|
||||||
@@ -32,36 +32,21 @@ upper right corner.
|
|||||||
|
|
||||||
There you can adjust the following settings:
|
There you can adjust the following settings:
|
||||||
|
|
||||||
* **OctoPrint checkout folder**: This should be the path to OctoPrint's git checkout folder (``/home/pi/OctoPrint``
|
|
||||||
for OctoPi or `manual installs following the Raspberry Pi setup guide <https://github.com/foosel/OctoPrint/wiki/Setup-on-a-Raspberry-Pi-running-Raspbian>`_).
|
|
||||||
This must be set to allow updating from within OctoPrint
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
OctoPi releases 0.12.0 and later ship with this already setup for you.
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
**OctoPi 0.11.0 users**: Please also take a look at
|
|
||||||
`the note at the very end of this FAQ entry <https://github.com/foosel/OctoPrint/wiki/FAQ#how-can-i-update-the-octoprint-installation-on-my-octopi-image>`_.
|
|
||||||
Due to a little issue in that OctoPi release 0.11.0 you might have to fix
|
|
||||||
the URL your OctoPrint checkout is using for updating. This can easily be
|
|
||||||
done by SSHing into your OctoPi instance and doing this::
|
|
||||||
|
|
||||||
cd ~/OctoPrint
|
|
||||||
git remote set-url origin https://github.com/foosel/OctoPrint.git
|
|
||||||
|
|
||||||
* **OctoPrint version tracking**: Whether you want to track OctoPrint *releases* or every *commit*. Usually you want to
|
* **OctoPrint version tracking**: Whether you want to track OctoPrint *releases* or every *commit*. Usually you want to
|
||||||
select "Release" here which is also the default, unless you are a developer.
|
select "Release" here which is also the default, unless you are a developer.
|
||||||
* **OctoPrint Release Channel**: The release channel of OctoPrint to track for updates. If you only want stable versions,
|
* **OctoPrint Release Channel** (if tracking releases): The release channel of OctoPrint to track for updates. If you only want stable versions,
|
||||||
select "Stable" here which is also the default. "Maintenance RCs" will also allow you to update to maintenance release
|
select "Stable" here which is also the default. "Maintenance RCs" will also allow you to update to maintenance release
|
||||||
candidates, "Devel RCs" will also allow you to update to development release candidates. If in doubt, leave it at
|
candidates, "Devel RCs" will also allow you to update to development release candidates. If in doubt, leave it at
|
||||||
"Stable". `Read more about Release Channels here <https://github.com/foosel/OctoPrint/wiki/Using-Release-Channels>`_.
|
"Stable". `Read more about Release Channels here <https://github.com/foosel/OctoPrint/wiki/Using-Release-Channels>`_.
|
||||||
|
* **OctoPrint checkout folder** (if tracking git commits): This must be the path to OctoPrint's git checkout folder
|
||||||
|
(``/home/pi/OctoPrint`` for OctoPi or `manual installs following the Raspberry Pi setup guide <https://github.com/foosel/OctoPrint/wiki/Setup-on-a-Raspberry-Pi-running-Raspbian>`_).
|
||||||
|
Note that since OctoPrint 1.3.6 you will no longer need to set this to be able to update to releases, only if you
|
||||||
|
want to be able to update against some bleeding edge git branch.
|
||||||
* **Version cache TTL**: The "time to live" of the cache OctoPrint will use to temporarily persist the version information
|
* **Version cache TTL**: The "time to live" of the cache OctoPrint will use to temporarily persist the version information
|
||||||
for the various components registered with the plugin, so that they don't have to be queried from the internet every time
|
for the various components registered with the plugin, so that they don't have to be queried from the internet every time
|
||||||
you load the page. Defaults to 24h, you usually shouldn't need to change that value.
|
you load the page. Defaults to 24h, you usually shouldn't need to change that value.
|
||||||
|
|
||||||
More settings are available by :ref:`editing the correspondi.. _section in config.yaml <sec-bundledplugins-softwareupdate-configuration>`.
|
More settings are available by :ref:`editing the corresponding section in config.yaml <sec-bundledplugins-softwareupdate-configuration>`.
|
||||||
|
|
||||||
That restart commands for OctoPrint and the whole server can be configured under Settings > Server.
|
That restart commands for OctoPrint and the whole server can be configured under Settings > Server.
|
||||||
|
|
||||||
@@ -71,9 +56,9 @@ Command line usage
|
|||||||
------------------
|
------------------
|
||||||
|
|
||||||
The functionality of the Software Update Plugin is also available on OctoPrint's command line interface under the
|
The functionality of the Software Update Plugin is also available on OctoPrint's command line interface under the
|
||||||
``plugins`` sub command. It's is possible to check for updates via ``octoprint plugins softwareupdate:check``
|
``plugins`` sub command. It's possible to check for updates via ``octoprint plugins softwareupdate:check``
|
||||||
and to apply available updates via ``octoprint plugins softwareupdate:update``. Please the corresponding
|
and to apply available updates via ``octoprint plugins softwareupdate:update``. Please see the corresponding
|
||||||
``--help`` pages on details:
|
``--help`` pages for details:
|
||||||
|
|
||||||
.. code-block:: none
|
.. code-block:: none
|
||||||
|
|
||||||
@@ -132,30 +117,29 @@ Configuring the Plugin
|
|||||||
|
|
||||||
.. code-block:: yaml
|
.. code-block:: yaml
|
||||||
|
|
||||||
plugins:
|
plugins:
|
||||||
softwareupdate:
|
softwareupdate:
|
||||||
# the time-to-live of the version cache, in minutes
|
# the time-to-live of the version cache, in minutes
|
||||||
cache_ttl: 60
|
cache_ttl: 60
|
||||||
|
|
||||||
# configured version check and update methods
|
# configured version check and update methods
|
||||||
checks:
|
checks:
|
||||||
# "octoprint" is reserved for OctoPrint
|
# "octoprint" is reserved for OctoPrint
|
||||||
octoprint:
|
octoprint:
|
||||||
# this defines an version check that will check against releases
|
# this defines a version check that will check against releases
|
||||||
# published on OctoPrint's Github repository and an update method
|
# published on OctoPrint's Github repository and pip as update method
|
||||||
# utilizing an (included) update script that will be run on
|
# against the release archives on Github - this is the default
|
||||||
# OctoPrint's checkout folder
|
type: github_release
|
||||||
type: github_release
|
user: foosel
|
||||||
user: foosel
|
repo: OctoPrint
|
||||||
repo: OctoPrint
|
method: pip
|
||||||
update_script: '{python} "/path/to/octoprint-update.py" --python="{python}" "{folder}" "{target}"'
|
pip: 'https://github.com/foosel/OctoPrint/archive/{target_version}.zip'
|
||||||
update_folder: /path/to/octoprint/checkout/folder
|
|
||||||
|
|
||||||
# further checks may be define here
|
# further checks may be defined here
|
||||||
|
|
||||||
# pip command, if another one than the automatically detected one should be
|
# pip command, if another one than the automatically detected one should be
|
||||||
# used - should normally NOT be necessary and hence set
|
# used - should normally NOT be necessary and hence set
|
||||||
pip_command: /path/to/pip
|
pip_command: /path/to/pip
|
||||||
|
|
||||||
.. _sec-bundledplugins-softwareupdate-configuration-versionchecks:
|
.. _sec-bundledplugins-softwareupdate-configuration-versionchecks:
|
||||||
|
|
||||||
@@ -198,6 +182,13 @@ Version checks
|
|||||||
* ``branch``: Branch of the Bitbucket repository to check, defaults to
|
* ``branch``: Branch of the Bitbucket repository to check, defaults to
|
||||||
``master`` if not set.
|
``master`` if not set.
|
||||||
* ``current``: Current commit hash. Will be updated automatically.
|
* ``current``: Current commit hash. Will be updated automatically.
|
||||||
|
* ``api_user``: (mandatory only for private repositories) Bitbucket user name (not email address).
|
||||||
|
Requires ``api_password`` to be set. Hint: This is used for the check only. For the actual
|
||||||
|
download you might register your public SSH key as access key for the according repo and
|
||||||
|
configure this as pip URL in ``config.yaml``: ``git+ssh://git@bitbucket.org/my_user/my_repo.git@{target_version}``
|
||||||
|
* ``api_password``: (mandatory only for private repositories) App password. Requires
|
||||||
|
``api_user`` to be set. **Important**: Never use your actual Bitbucket login password. Generate
|
||||||
|
a new app password. App passwords are user specific on Bitbucket.
|
||||||
|
|
||||||
* ``git_commit``: Checks a local git repository for new commits on its
|
* ``git_commit``: Checks a local git repository for new commits on its
|
||||||
configured remote. Additional config parameters:
|
configured remote. Additional config parameters:
|
||||||
@@ -218,10 +209,21 @@ Version checks
|
|||||||
:ref:`hook <sec-bundledplugins-softwareupdate-hooks>`. Additional config
|
:ref:`hook <sec-bundledplugins-softwareupdate-hooks>`. Additional config
|
||||||
parameters:
|
parameters:
|
||||||
|
|
||||||
* ``python_checker``: (mandatory) A python callable which returns version
|
* ``python_checker``: (mandatory) A Python callable which returns version
|
||||||
information and whether the current version is up-to-date or not, see
|
information and whether the current version is up-to-date or not, see
|
||||||
below for details.
|
below for details.
|
||||||
|
|
||||||
|
* ``always_current``: Always reports that no update is necessary. Useful for debugging
|
||||||
|
software update mechanisms during development. Additional config parameters:
|
||||||
|
|
||||||
|
* ``current_version``: Version to report for both local and remote version.
|
||||||
|
|
||||||
|
* ``never_current``: Always reports that an update is necessary. Useful for debugging
|
||||||
|
software update mechanisms during development. Additional config parameters:
|
||||||
|
|
||||||
|
* ``local_version``: Current local version. Defaults to ``1.0.0``.
|
||||||
|
* ``remote_version``: Remote version to offer update to. Defaults to ``1.0.1``.
|
||||||
|
|
||||||
.. _sec-bundledplugins-softwareupdate-configuration-updatemethods:
|
.. _sec-bundledplugins-softwareupdate-configuration-updatemethods:
|
||||||
|
|
||||||
Update methods
|
Update methods
|
||||||
@@ -239,8 +241,37 @@ Update methods
|
|||||||
``update_folder`` setting or if the ``git_commit`` check is used its
|
``update_folder`` setting or if the ``git_commit`` check is used its
|
||||||
``checkout_folder`` setting.
|
``checkout_folder`` setting.
|
||||||
* ``python_updater``: Can only be specified by plugins through the
|
* ``python_updater``: Can only be specified by plugins through the
|
||||||
:ref:`hook <sec-bundledplugins-softwareupdate-hooks>`. A python callable
|
:ref:`hook <sec-bundledplugins-softwareupdate-hooks>`. A Python callable
|
||||||
which performs the update, see below for details.
|
which performs the update, see below for details.
|
||||||
|
* ``sleep_a_bit``: Does nothing but block for a configurable ``duration`` and log
|
||||||
|
a countdown in the meantime. Useful for debugging software update mechanisms
|
||||||
|
during development.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
To allow default configurations for multiple update methods, if more than one of
|
||||||
|
the above update method specific settings is set the one to use can be selected
|
||||||
|
by setting the property ``method`` to the method specific setting in question.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
The following example defines both ``pip`` and ``update_script``. By setting to
|
||||||
|
``method`` to ``pip``, the Software Update plugin is instructed to use that as
|
||||||
|
update method.
|
||||||
|
|
||||||
|
.. code-block:: yaml
|
||||||
|
|
||||||
|
plugins:
|
||||||
|
softwareupdate:
|
||||||
|
checks:
|
||||||
|
octoprint:
|
||||||
|
type: github_release
|
||||||
|
user: foosel
|
||||||
|
repo: OctoPrint
|
||||||
|
method: pip
|
||||||
|
pip: 'https://github.com/foosel/OctoPrint/archive/{target_version}.zip'
|
||||||
|
update_script: '{python} "/path/to/octoprint-update.py" --python="{python}" "{folder}" "{target}"'
|
||||||
|
checkout_folder: /path/to/octoprint/checkout/folder
|
||||||
|
|
||||||
.. _sec-bundledplugins-softwareupdate-configuration-patterns:
|
.. _sec-bundledplugins-softwareupdate-configuration-patterns:
|
||||||
|
|
||||||
@@ -261,6 +292,7 @@ plugin itself):
|
|||||||
user: foosel
|
user: foosel
|
||||||
repo: OctoPrint
|
repo: OctoPrint
|
||||||
branch: devel
|
branch: devel
|
||||||
|
method: update_script
|
||||||
update_folder: /home/pi/OctoPrint
|
update_folder: /home/pi/OctoPrint
|
||||||
|
|
||||||
Plugin installed via pip and hosted on Github under
|
Plugin installed via pip and hosted on Github under
|
||||||
@@ -293,6 +325,29 @@ The same, but tracking all commits pushed to branch ``devel`` (thus allowing
|
|||||||
branch: devel
|
branch: devel
|
||||||
pip: 'https://github.com/someUser/OctoPrint-SomePlugin/archive/{target}.zip'
|
pip: 'https://github.com/someUser/OctoPrint-SomePlugin/archive/{target}.zip'
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-softwareupdate-events:
|
||||||
|
|
||||||
|
Events
|
||||||
|
------
|
||||||
|
|
||||||
|
plugin_softwareupdate_update_succeeded
|
||||||
|
An update succeeded.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``target``: update target
|
||||||
|
* ``from_version``: version from which was updated
|
||||||
|
* ``to_version``: version to which was updated
|
||||||
|
|
||||||
|
plugin_softwareupdate_update_failed
|
||||||
|
An update failed.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``target``: update target
|
||||||
|
* ``from_version``: version from which was updated
|
||||||
|
* ``to_version``: version to which was updated
|
||||||
|
|
||||||
.. _sec-bundledplugins-softwareupdate-hooks:
|
.. _sec-bundledplugins-softwareupdate-hooks:
|
||||||
|
|
||||||
Hooks
|
Hooks
|
||||||
@@ -330,8 +385,8 @@ octoprint.plugin.softwareupdate.check_config
|
|||||||
|
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
def get_update_information(*args, **kwargs):
|
def get_update_information(*args, **kwargs):
|
||||||
return dict(
|
return dict(
|
||||||
|
|||||||
@@ -0,0 +1,45 @@
|
|||||||
|
.. _sec-bundledplugins-tracking:
|
||||||
|
|
||||||
|
Anonymous Usage Tracking Plugin
|
||||||
|
===============================
|
||||||
|
|
||||||
|
The Anonymous Usage Tracking plugin provides valuable insights into how many instances running what versions of
|
||||||
|
OctoPrint are out there, whether they are successfully completing print jobs and various other metrics.
|
||||||
|
|
||||||
|
By enabling it you help to identify problems with new releases and release candidates early on, and to better tailor
|
||||||
|
OctoPrint's future development to actual use.
|
||||||
|
|
||||||
|
For details on what gets tracked, please refer to `tracking.octoprint.org <https://tracking.octoprint.org>`_
|
||||||
|
and also the `Privacy Policy at tracking.octoprint.org <https://tracking.octoprint.org/privacy>`_.
|
||||||
|
|
||||||
|
The Anonymous Usage Tracking plugin has been bundled with OctoPrint since version 1.3.10.
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-tracking-configuration:
|
||||||
|
|
||||||
|
Configuring the plugin
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
The plugin supports the following configuration keys:
|
||||||
|
|
||||||
|
* ``enabled``: Whether to enable usage tracking. Defaults to ``false``.
|
||||||
|
* ``unique_id``: Unique instance identifier, auto generated on first activation
|
||||||
|
* ``server``: The tracking server to track against. Defaults to a tracking endpoint on ``https://tracking.octoprint.org``.
|
||||||
|
* ``ping``: How often to send a ``ping`` tracking event, in seconds. Defaults to a 15min interval.
|
||||||
|
* ``events``: Granular configuration of enabled tracking events. All default to ``true``.
|
||||||
|
|
||||||
|
* ``startup``: Whether to track startup/shutdown events
|
||||||
|
* ``printjob``: Whether to track print job related events (start, completion, cancel, ...)
|
||||||
|
* ``commerror``: Whether to track communication errors with the printer
|
||||||
|
* ``plugin``: Whether to track plugin related events (install, uninstall, ...)
|
||||||
|
* ``update``: Whether to track update related events (update successful or not, ...)
|
||||||
|
* ``printer``: Whether to track printer related events (connected, firmware, ...)
|
||||||
|
* ``printer_safety_check``: Whether to track warnings of the :ref:`Printer Safety Check <sec-bundledplugins-printer_safety_check>`
|
||||||
|
* ``throttled``: Whether to track throttle events detected on the underlying system
|
||||||
|
|
||||||
|
.. _sec-bundledplugins-tracking-sourcecode:
|
||||||
|
|
||||||
|
Source Code
|
||||||
|
-----------
|
||||||
|
|
||||||
|
The source of the Anonymous Usage Tracking plugin is bundled with OctoPrint and can be
|
||||||
|
found in its source repository under ``src/octoprint/plugins/tracking``.
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
from __future__ import absolute_import, division, print_function, unicode_literals
|
||||||
|
|
||||||
#
|
#
|
||||||
# OctoPrint documentation build configuration file, created by
|
# OctoPrint documentation build configuration file, created by
|
||||||
# sphinx-quickstart on Mon Dec 02 17:08:50 2013.
|
# sphinx-quickstart on Mon Dec 02 17:08:50 2013.
|
||||||
@@ -33,7 +35,7 @@ needs_sphinx = '1.3'
|
|||||||
# Add any Sphinx extension module names here, as strings. They can be extensions
|
# Add any Sphinx extension module names here, as strings. They can be extensions
|
||||||
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
|
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
|
||||||
extensions = ['codeblockext', 'onlineinclude', 'sphinx.ext.todo', 'sphinx.ext.autodoc', 'sphinxcontrib.httpdomain',
|
extensions = ['codeblockext', 'onlineinclude', 'sphinx.ext.todo', 'sphinx.ext.autodoc', 'sphinxcontrib.httpdomain',
|
||||||
'sphinx.ext.napoleon']
|
'sphinx.ext.napoleon', 'sphinxcontrib.mermaid']
|
||||||
todo_include_todos = True
|
todo_include_todos = True
|
||||||
|
|
||||||
# Add any paths that contain templates here, relative to this directory.
|
# Add any paths that contain templates here, relative to this directory.
|
||||||
@@ -49,8 +51,8 @@ source_suffix = '.rst'
|
|||||||
master_doc = 'index'
|
master_doc = 'index'
|
||||||
|
|
||||||
# General information about the project.
|
# General information about the project.
|
||||||
project = u'OctoPrint'
|
project = 'OctoPrint'
|
||||||
copyright = u'%d-%d, Gina Häußge' % (year_since, year_current) if year_current > year_since else u'%d, Gina Häußge' % year_since
|
copyright = '%d-%d, Gina Häußge' % (year_since, year_current) if year_current > year_since else '%d, Gina Häußge' % year_since
|
||||||
|
|
||||||
# The version info for the project you're documenting, acts as replacement for
|
# The version info for the project you're documenting, acts as replacement for
|
||||||
# |version| and |release|, also used in various other places throughout the
|
# |version| and |release|, also used in various other places throughout the
|
||||||
@@ -207,8 +209,8 @@ htmlhelp_basename = 'OctoPrintdoc'
|
|||||||
# Grouping the document tree into LaTeX files. List of tuples
|
# Grouping the document tree into LaTeX files. List of tuples
|
||||||
# (source start file, target name, title, author, documentclass [howto/manual]).
|
# (source start file, target name, title, author, documentclass [howto/manual]).
|
||||||
#latex_documents = [
|
#latex_documents = [
|
||||||
# ('index', 'OctoPrint.tex', u'OctoPrint Documentation',
|
# ('index', 'OctoPrint.tex', 'OctoPrint Documentation',
|
||||||
# u'Gina Häußge', 'manual'),
|
# 'Gina Häußge', 'manual'),
|
||||||
#]
|
#]
|
||||||
|
|
||||||
# The name of an image file (relative to this directory) to place at the top of
|
# The name of an image file (relative to this directory) to place at the top of
|
||||||
@@ -237,8 +239,8 @@ htmlhelp_basename = 'OctoPrintdoc'
|
|||||||
# One entry per manual page. List of tuples
|
# One entry per manual page. List of tuples
|
||||||
# (source start file, name, description, authors, manual section).
|
# (source start file, name, description, authors, manual section).
|
||||||
man_pages = [
|
man_pages = [
|
||||||
('index', 'octoprint', u'OctoPrint Documentation',
|
('index', 'octoprint', 'OctoPrint Documentation',
|
||||||
[u'Gina Häußge'], 1)
|
['Gina Häußge'], 1)
|
||||||
]
|
]
|
||||||
|
|
||||||
# If true, show URL addresses after external links.
|
# If true, show URL addresses after external links.
|
||||||
@@ -251,8 +253,8 @@ man_pages = [
|
|||||||
# (source start file, target name, title, author,
|
# (source start file, target name, title, author,
|
||||||
# dir menu entry, description, category)
|
# dir menu entry, description, category)
|
||||||
texinfo_documents = [
|
texinfo_documents = [
|
||||||
('index', 'OctoPrint', u'OctoPrint Documentation',
|
('index', 'OctoPrint', 'OctoPrint Documentation',
|
||||||
u'Gina Häußge', 'OctoPrint', 'One line description of project.',
|
'Gina Häußge', 'OctoPrint', 'One line description of project.',
|
||||||
'Miscellaneous'),
|
'Miscellaneous'),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|||||||
@@ -29,14 +29,14 @@ Use the following settings to enable access control:
|
|||||||
# The user manager implementation to use for accessing user information. Currently only a filebased
|
# The user manager implementation to use for accessing user information. Currently only a filebased
|
||||||
# user manager is implemented which stores configured accounts in a YAML file (Default: users.yaml
|
# user manager is implemented which stores configured accounts in a YAML file (Default: users.yaml
|
||||||
# in the default configuration folder, see below)
|
# in the default configuration folder, see below)
|
||||||
userManager: octoprint.users.FilebasedUserManager
|
userManager: octoprint.access.users.FilebasedUserManager
|
||||||
|
|
||||||
# The YAML user file to use. If left out defaults to users.yaml in the default configuration folder.
|
# The YAML user file to use. If left out defaults to users.yaml in the default configuration folder.
|
||||||
userFile: /path/to/users.yaml
|
userFile: /path/to/users.yaml
|
||||||
|
|
||||||
# If set to true, will automatically log on clients originating from any of the networks defined in
|
# If set to true, will automatically log on clients originating from any of the networks defined in
|
||||||
# "localNetworks" as the user defined in "autologinAs". Defaults to false.
|
# "localNetworks" as the user defined in "autologinAs". Defaults to false.
|
||||||
autologinLocal: true
|
autologinLocal: false
|
||||||
|
|
||||||
# The name of the user to automatically log on clients originating from "localNetworks" as. Must
|
# The name of the user to automatically log on clients originating from "localNetworks" as. Must
|
||||||
# be the name of one of your configured users.
|
# be the name of one of your configured users.
|
||||||
@@ -51,6 +51,29 @@ Use the following settings to enable access control:
|
|||||||
- 127.0.0.0/8
|
- 127.0.0.0/8
|
||||||
- 192.168.1.0/24
|
- 192.168.1.0/24
|
||||||
|
|
||||||
|
# Whether to trust Basic Authentication headers. If you have setup Basic Authentication in front of
|
||||||
|
# OctoPrint and the user names you use there match OctoPrint accounts, by setting this to true users will
|
||||||
|
# be logged into OctoPrint as the user user during Basic Authentication. Your should ONLY ENABLE THIS if your
|
||||||
|
# OctoPrint instance is only accessible through a connection locked down through Basic Authentication!
|
||||||
|
trustBasicAuthentication: false
|
||||||
|
|
||||||
|
# Whether to also check the password provided through Basic Authentication if the Basic Authentication
|
||||||
|
# header is to be trusted. Disabling this will only match the user name in the Basic Authentication
|
||||||
|
# header and login the user without further checks. Use with caution.
|
||||||
|
checkBasicAuthenticationPassword: true
|
||||||
|
|
||||||
|
# Whether to trust remote user headers. If you have setup authentication in front of
|
||||||
|
# OctoPrint and the user names you use there match OctoPrint accounts, by setting this to true users will
|
||||||
|
# be logged into OctoPrint as the user provided in the header. Your should ONLY ENABLE THIS if your
|
||||||
|
# OctoPrint instance is only accessible through a connection locked down through an authenticating reverse proxy!
|
||||||
|
trustRemoteUser: false
|
||||||
|
|
||||||
|
# Header used by the reverse proxy to convey the authenticated user.
|
||||||
|
remoteUserHeader: REMOTE_USER
|
||||||
|
|
||||||
|
# If a remote user is not found, add them. Use this only if all users from the remote system can use OctoPrint.
|
||||||
|
addRemoteUsers: false
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-api:
|
.. _sec-configuration-config_yaml-api:
|
||||||
|
|
||||||
API
|
API
|
||||||
@@ -70,7 +93,8 @@ Settings for the REST API:
|
|||||||
# Whether to allow cross origin access to the API or not
|
# Whether to allow cross origin access to the API or not
|
||||||
allowCrossOrigin: false
|
allowCrossOrigin: false
|
||||||
|
|
||||||
# Additional app api keys, see REST API > Apps in the docs
|
# Additional app api keys, see REST API > Apps in the docs.
|
||||||
|
# Deprecated since 1.3.11, to be removed in 1.4.0!
|
||||||
apps:
|
apps:
|
||||||
"some.app.identifier:some_version":
|
"some.app.identifier:some_version":
|
||||||
pubkey: <RSA pubkey>
|
pubkey: <RSA pubkey>
|
||||||
@@ -140,7 +164,7 @@ appearance or to modify the order and presence of the various UI components:
|
|||||||
|
|
||||||
# order of settings, if settings plugins are registered gets extended internally by
|
# order of settings, if settings plugins are registered gets extended internally by
|
||||||
# section_plugins and all settings plugins
|
# section_plugins and all settings plugins
|
||||||
settings
|
settings:
|
||||||
- section_printer
|
- section_printer
|
||||||
- serial
|
- serial
|
||||||
- printerprofiles
|
- printerprofiles
|
||||||
@@ -198,7 +222,7 @@ appearance or to modify the order and presence of the various UI components:
|
|||||||
tab:
|
tab:
|
||||||
- plugin_helloworld
|
- plugin_helloworld
|
||||||
|
|
||||||
OctoPrint will then turn this into the order ``plugin_helloworld``, ``temperature``, ``control``, ``gcodeviewer``,
|
OctoPrint will then display the tabs in the order ``plugin_helloworld``, ``temperature``, ``control``, ``gcodeviewer``,
|
||||||
``terminal``, ``timelapse`` plus any other plugins.
|
``terminal``, ``timelapse`` plus any other plugins.
|
||||||
|
|
||||||
|
|
||||||
@@ -285,9 +309,13 @@ The following settings are only relevant to you if you want to do OctoPrint deve
|
|||||||
# to false.
|
# to false.
|
||||||
okWithLinenumber: false
|
okWithLinenumber: false
|
||||||
|
|
||||||
# Number of extruders to simulate on the virtual printer.
|
# Number of extruders to simulate on the virtual printer. Map from tool id (0, 1, ...) to temperature
|
||||||
|
# in °C
|
||||||
numExtruders: 1
|
numExtruders: 1
|
||||||
|
|
||||||
|
# Allows pinning certain hotends to a fixed temperature
|
||||||
|
pinnedExtruders: null
|
||||||
|
|
||||||
# Whether to include the current tool temperature in the M105 output as separate T segment or not.
|
# Whether to include the current tool temperature in the M105 output as separate T segment or not.
|
||||||
#
|
#
|
||||||
# True: > M105
|
# True: > M105
|
||||||
@@ -304,16 +332,12 @@ The following settings are only relevant to you if you want to do OctoPrint deve
|
|||||||
# > File opened
|
# > File opened
|
||||||
includeFilenameInOpened: true
|
includeFilenameInOpened: true
|
||||||
|
|
||||||
# The maximum movement speeds of the simulated printer's axes, in mm/s
|
|
||||||
movementSpeed:
|
|
||||||
x: 6000
|
|
||||||
y: 6000
|
|
||||||
z: 200
|
|
||||||
e: 300
|
|
||||||
|
|
||||||
# Whether the simulated printer should also simulate a heated bed or not
|
# Whether the simulated printer should also simulate a heated bed or not
|
||||||
hasBed: true
|
hasBed: true
|
||||||
|
|
||||||
|
# Whether the simulated printer should also simulate a heated chamber or not
|
||||||
|
hasChamber: false
|
||||||
|
|
||||||
# If enabled, reports the set target temperatures as separate messages from the firmware
|
# If enabled, reports the set target temperatures as separate messages from the firmware
|
||||||
#
|
#
|
||||||
# True: > M109 S220.0
|
# True: > M109 S220.0
|
||||||
@@ -331,6 +355,18 @@ The following settings are only relevant to you if you want to do OctoPrint deve
|
|||||||
# to make sure nothing gets lost on the line
|
# to make sure nothing gets lost on the line
|
||||||
repetierStyleResends: false
|
repetierStyleResends: false
|
||||||
|
|
||||||
|
# If enabled, ok will be sent before a commands output, otherwise after or inline (M105)
|
||||||
|
#
|
||||||
|
# True: > M20
|
||||||
|
# < ok
|
||||||
|
# < Begin file list
|
||||||
|
# < End file list
|
||||||
|
# False: > M20
|
||||||
|
# < Begin file list
|
||||||
|
# < End file list
|
||||||
|
# < ok
|
||||||
|
okBeforeCommandOutput: false
|
||||||
|
|
||||||
# If enabled, reports the first extruder in M105 responses as T instead of T0
|
# If enabled, reports the first extruder in M105 responses as T instead of T0
|
||||||
#
|
#
|
||||||
# True: > M105
|
# True: > M105
|
||||||
@@ -358,7 +394,8 @@ The following settings are only relevant to you if you want to do OctoPrint deve
|
|||||||
# side will block
|
# side will block
|
||||||
rxBuffer: 64
|
rxBuffer: 64
|
||||||
|
|
||||||
# Size of simulated command buffer
|
# Size of simulated command buffer, number of commands. If full, buffered commands will block
|
||||||
|
# until a slot frees up
|
||||||
commandBuffer: 4
|
commandBuffer: 4
|
||||||
|
|
||||||
# Whether to support the M112 command with simulated kill
|
# Whether to support the M112 command with simulated kill
|
||||||
@@ -370,6 +407,58 @@ The following settings are only relevant to you if you want to do OctoPrint deve
|
|||||||
# Whether to simulate broken M29 behaviour (missing ok after response)
|
# Whether to simulate broken M29 behaviour (missing ok after response)
|
||||||
brokenM29: true
|
brokenM29: true
|
||||||
|
|
||||||
|
# Whether F is supported as individual command
|
||||||
|
supportF: false
|
||||||
|
|
||||||
|
# Firmware name to report (useful for testing firmware detection)
|
||||||
|
firmwareName: Virtual Marlin 1.0
|
||||||
|
|
||||||
|
# Simulate a shared nozzle
|
||||||
|
sharedNozzle: false
|
||||||
|
|
||||||
|
# Send "busy" messages if busy processing something
|
||||||
|
sendBusy: false
|
||||||
|
|
||||||
|
# Simulate a reset on connect
|
||||||
|
simulateReset: true
|
||||||
|
|
||||||
|
# Lines to send on simulated reset
|
||||||
|
resetLines:
|
||||||
|
- start
|
||||||
|
- Marlin: Virtual Marlin!
|
||||||
|
- "\x80"
|
||||||
|
- "SD card ok"
|
||||||
|
|
||||||
|
# Initial set of prepared oks to use instead of regular ok (e.g. to simulate
|
||||||
|
# mis-sent oks). Can also be filled at runtime via the debug command prepare_ok
|
||||||
|
preparedOks: []
|
||||||
|
|
||||||
|
# Format string for ok response.
|
||||||
|
#
|
||||||
|
# Placeholders:
|
||||||
|
# - lastN: last acknowledged line number
|
||||||
|
# - buffer: empty slots in internal command buffer
|
||||||
|
#
|
||||||
|
# Example format string for "extended" ok format:
|
||||||
|
# ok N{lastN} P{buffer}
|
||||||
|
okFormatString: ok
|
||||||
|
|
||||||
|
# Format string for M115 output.
|
||||||
|
#
|
||||||
|
# Placeholders:
|
||||||
|
# - firmare_name: The firmware name as defined in firmwareName
|
||||||
|
m115FormatString: "FIRMWARE_NAME: {firmware_name} PROTOCOL_VERSION:1.0"
|
||||||
|
|
||||||
|
# Whether to include capability report in M115 output
|
||||||
|
m115ReportCapabilites: false
|
||||||
|
|
||||||
|
# Capabilities to report if capability report is enabled
|
||||||
|
capabilities:
|
||||||
|
AUTOREPORT_TEMP: true
|
||||||
|
|
||||||
|
# Simulated ambient temperature in °C
|
||||||
|
ambientTemperature: 21.3
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-estimation:
|
.. _sec-configuration-config_yaml-estimation:
|
||||||
|
|
||||||
Estimation
|
Estimation
|
||||||
@@ -381,7 +470,7 @@ the estimation of the left print time during an active job utilizes this section
|
|||||||
.. code-block:: yaml
|
.. code-block:: yaml
|
||||||
|
|
||||||
estimation:
|
estimation:
|
||||||
# Parameters for the print time estmation during an ongoing print job
|
# Parameters for the print time estimation during an ongoing print job
|
||||||
printTime:
|
printTime:
|
||||||
# Until which percentage to do a weighted mixture of statistical duration (analysis or
|
# Until which percentage to do a weighted mixture of statistical duration (analysis or
|
||||||
# past prints) with the result from the calculated estimate if that's already available.
|
# past prints) with the result from the calculated estimate if that's already available.
|
||||||
@@ -460,52 +549,16 @@ Use the following settings to enable or disable OctoPrint features:
|
|||||||
.. code-block:: yaml
|
.. code-block:: yaml
|
||||||
|
|
||||||
feature:
|
feature:
|
||||||
|
|
||||||
# Whether to enable the gcode viewer in the UI or not
|
# Whether to enable the gcode viewer in the UI or not
|
||||||
gCodeVisualizer: true
|
gCodeVisualizer: true
|
||||||
|
|
||||||
# Whether to enable the temperature graph in the UI or not
|
# Whether to enable the temperature graph in the UI or not
|
||||||
temperatureGraph: true
|
temperatureGraph: true
|
||||||
|
|
||||||
# Specifies whether OctoPrint should wait for the start response from the printer before trying to send commands
|
|
||||||
# during connect.
|
|
||||||
waitForStartOnConnect: false
|
|
||||||
|
|
||||||
# Specifies whether OctoPrint should send linenumber + checksum with every printer command. Needed for
|
|
||||||
# successful communication with Repetier firmware
|
|
||||||
alwaysSendChecksum: false
|
|
||||||
|
|
||||||
# Specifies whether OctoPrint should also send linenumber + checksum with commands that are *not*
|
|
||||||
# detected as valid GCODE (as in, they do not match the regular expression "^\s*([GM]\d+|T)").
|
|
||||||
sendChecksumWithUnknownCommands: false
|
|
||||||
|
|
||||||
# Specifies whether OctoPrint should also use up acknowledgments ("ok") for commands that are *not*
|
|
||||||
# detected as valid GCODE (as in, they do not match the regular expression "^\s*([GM]\d+|T)").
|
|
||||||
unknownCommandsNeedAck: false
|
|
||||||
|
|
||||||
# Whether to ignore the first ok after a resend response. Needed for successful communication with
|
|
||||||
# Repetier firmware
|
|
||||||
swallowOkAfterResend: false
|
|
||||||
|
|
||||||
# Specifies whether support for SD printing and file management should be enabled
|
# Specifies whether support for SD printing and file management should be enabled
|
||||||
sdSupport: true
|
sdSupport: true
|
||||||
|
|
||||||
# Specifies whether firmware expects relative paths for selecting SD files
|
|
||||||
sdRelativePath: false
|
|
||||||
|
|
||||||
# Whether to always assume that an SD card is present in the printer.
|
|
||||||
# Needed by some firmwares which don't report the SD card status properly.
|
|
||||||
sdAlwaysAvailable: false
|
|
||||||
|
|
||||||
# Whether the printer sends repetier style target temperatures in the format
|
|
||||||
# TargetExtr0:<temperature>
|
|
||||||
# instead of attaching that information to the regular M105 responses
|
|
||||||
repetierTargetTemp: false
|
|
||||||
|
|
||||||
# Whether to enable external heatup detection (to detect heatup triggered e.g. through the printer's LCD panel or
|
|
||||||
# while printing from SD) or not. Causes issues with Repetier's "first ok then response" approach to
|
|
||||||
# communication, so disable for printers running Repetier firmware.
|
|
||||||
externalHeatupDetection: true
|
|
||||||
|
|
||||||
# Whether to enable the keyboard control feature in the control tab
|
# Whether to enable the keyboard control feature in the control tab
|
||||||
keyboardControl: true
|
keyboardControl: true
|
||||||
|
|
||||||
@@ -513,28 +566,20 @@ Use the following settings to enable or disable OctoPrint features:
|
|||||||
# notifications instead (false)
|
# notifications instead (false)
|
||||||
pollWatched: false
|
pollWatched: false
|
||||||
|
|
||||||
# Whether to ignore identical resends from the printer (true, repetier) or not (false)
|
|
||||||
ignoreIdenticalResends: false
|
|
||||||
|
|
||||||
# If ignoredIdenticalResends is true, how many consecutive identical resends to ignore
|
|
||||||
identicalResendsCount: 7
|
|
||||||
|
|
||||||
# Whether to support F on its own as a valid GCODE command (true) or not (false)
|
|
||||||
supportFAsCommand: false
|
|
||||||
|
|
||||||
# Whether to enable model size detection and warning (true) or not (false)
|
# Whether to enable model size detection and warning (true) or not (false)
|
||||||
modelSizeDetection: true
|
modelSizeDetection: true
|
||||||
|
|
||||||
# Whether to attempt to auto detect the firmware of the printer and adjust settings
|
|
||||||
# accordingly (true) or not and rely on manual configuration (false)
|
|
||||||
firmwareDetection: true
|
|
||||||
|
|
||||||
# Whether to show a confirmation on print cancelling (true) or not (false)
|
# Whether to show a confirmation on print cancelling (true) or not (false)
|
||||||
printCancelConfirmation: true
|
printCancelConfirmation: true
|
||||||
|
|
||||||
# Whether to block all sending to the printer while a G4 (dwell) command is active (true, repetier)
|
# Commands that should never be auto-uppercased when sent to the printer through the Terminal tab.
|
||||||
# or not (false)
|
# Defaults to only M117.
|
||||||
blockWhileDwelling: false
|
autoUppercaseBlacklist:
|
||||||
|
- M117
|
||||||
|
- M118
|
||||||
|
|
||||||
|
# whether G90/G91 also influence absolute/relative mode of extruders
|
||||||
|
g90InfluencesExtruder: false
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-folder:
|
.. _sec-configuration-config_yaml-folder:
|
||||||
|
|
||||||
@@ -591,15 +636,16 @@ Settings pertaining to the server side GCODE analysis implementation.
|
|||||||
|
|
||||||
.. code-block:: yaml
|
.. code-block:: yaml
|
||||||
|
|
||||||
# Maximum number of extruders to support/to sanity check for
|
gcodeAnalysis:
|
||||||
maxExtruders: 10
|
# Maximum number of extruders to support/to sanity check for
|
||||||
|
maxExtruders: 10
|
||||||
|
|
||||||
# Pause between each processed GCODE line in normal priority mode, seconds
|
# Pause between each processed GCODE line in normal priority mode, seconds
|
||||||
throttle_normalprio: 0.01
|
throttle_normalprio: 0.01
|
||||||
|
|
||||||
# Pause between each processed GCODE line in high priority mode (e.g. on fresh
|
# Pause between each processed GCODE line in high priority mode (e.g. on fresh
|
||||||
# uploads), seconds
|
# uploads), seconds
|
||||||
throttle_highprio: 0.0
|
throttle_highprio: 0.0
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-gcodeviewer:
|
.. _sec-configuration-config_yaml-gcodeviewer:
|
||||||
|
|
||||||
@@ -610,16 +656,17 @@ Settings pertaining to the built in GCODE Viewer.
|
|||||||
|
|
||||||
.. code-block:: yaml
|
.. code-block:: yaml
|
||||||
|
|
||||||
# Whether to enable the GCODE viewer in the UI
|
gcodeViewer:
|
||||||
enabled: true
|
# Whether to enable the GCODE viewer in the UI
|
||||||
|
enabled: true
|
||||||
|
|
||||||
# Maximum size a GCODE file may have on mobile devices to automatically be loaded
|
# Maximum size a GCODE file may have on mobile devices to automatically be loaded
|
||||||
# into the viewer, defaults to 2MB
|
# into the viewer, defaults to 2MB
|
||||||
mobileSizeThreshold: 2097152
|
mobileSizeThreshold: 2097152
|
||||||
|
|
||||||
# Maximum size a GCODE file may have to automatically be loaded into the viewer,
|
# Maximum size a GCODE file may have to automatically be loaded into the viewer,
|
||||||
# defaults to 20MB
|
# defaults to 20MB
|
||||||
sizeThreshold: 20971520
|
sizeThreshold: 20971520
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-plugins:
|
.. _sec-configuration-config_yaml-plugins:
|
||||||
|
|
||||||
@@ -638,6 +685,11 @@ plugins are tracked:
|
|||||||
_disabled:
|
_disabled:
|
||||||
- ...
|
- ...
|
||||||
|
|
||||||
|
# Identifiers of plugins for which python compatibility information will be ignored and
|
||||||
|
# the plugin considered compatible in any case. Only for development, do NOT use in production.
|
||||||
|
_forcedCompatible:
|
||||||
|
- ...
|
||||||
|
|
||||||
# The rest are individual plugin settings, each tracked by their identifier, e.g.:
|
# The rest are individual plugin settings, each tracked by their identifier, e.g.:
|
||||||
some_plugin:
|
some_plugin:
|
||||||
some_setting: true
|
some_setting: true
|
||||||
@@ -738,6 +790,10 @@ Use the following settings to configure the serial connection to the printer:
|
|||||||
# Defaults to 30 sec
|
# Defaults to 30 sec
|
||||||
communication: 30
|
communication: 30
|
||||||
|
|
||||||
|
# Timeout during serial communication when busy protocol support is detected, in seconds.
|
||||||
|
# Defaults to 3 sec
|
||||||
|
communicationBusy: 3
|
||||||
|
|
||||||
# Timeout after which to query temperature when no target is set
|
# Timeout after which to query temperature when no target is set
|
||||||
temperature: 5
|
temperature: 5
|
||||||
|
|
||||||
@@ -762,7 +818,7 @@ Use the following settings to configure the serial connection to the printer:
|
|||||||
|
|
||||||
# Maximum number of write attempts to serial during which nothing can be written before the communication
|
# Maximum number of write attempts to serial during which nothing can be written before the communication
|
||||||
# with the printer is considered dead and OctoPrint will disconnect with an error
|
# with the printer is considered dead and OctoPrint will disconnect with an error
|
||||||
maxWritePasses:
|
maxWritePasses: 5
|
||||||
|
|
||||||
# Use this to define additional patterns to consider for serial port listing. Must be a valid
|
# Use this to define additional patterns to consider for serial port listing. Must be a valid
|
||||||
# "glob" pattern (see http://docs.python.org/2/library/glob.html). Defaults to not set.
|
# "glob" pattern (see http://docs.python.org/2/library/glob.html). Defaults to not set.
|
||||||
@@ -774,6 +830,19 @@ Use the following settings to configure the serial connection to the printer:
|
|||||||
additionalBaudrates:
|
additionalBaudrates:
|
||||||
- 123456
|
- 123456
|
||||||
|
|
||||||
|
# Commands which should not be sent to the printer, e.g. because they are known to block serial
|
||||||
|
# communication until physical interaction with the printer as is the case on most firmwares with
|
||||||
|
# the default M0 and M1.
|
||||||
|
blockedCommands:
|
||||||
|
- M0
|
||||||
|
- M1
|
||||||
|
|
||||||
|
# Commands which should cause OctoPrint to pause any ongoing prints.
|
||||||
|
pausingCommands:
|
||||||
|
- M0
|
||||||
|
- M1
|
||||||
|
- M25
|
||||||
|
|
||||||
# Commands which are known to take a long time to be acknowledged by the firmware. E.g.
|
# Commands which are known to take a long time to be acknowledged by the firmware. E.g.
|
||||||
# homing, dwelling, auto leveling etc. Defaults to the below commands.
|
# homing, dwelling, auto leveling etc. Defaults to the below commands.
|
||||||
longRunningCommands:
|
longRunningCommands:
|
||||||
@@ -793,7 +862,8 @@ Use the following settings to configure the serial connection to the printer:
|
|||||||
# Command to send in order to initiate a handshake with the printer.
|
# Command to send in order to initiate a handshake with the printer.
|
||||||
# Defaults to "M110 N0" which simply resets the line numbers in the firmware and which
|
# Defaults to "M110 N0" which simply resets the line numbers in the firmware and which
|
||||||
# should be acknowledged with a simple "ok".
|
# should be acknowledged with a simple "ok".
|
||||||
helloCommand: M110 N0
|
helloCommand:
|
||||||
|
- M110 N0
|
||||||
|
|
||||||
# Whether to disconnect on errors or not
|
# Whether to disconnect on errors or not
|
||||||
disconnectOnErrors: true
|
disconnectOnErrors: true
|
||||||
@@ -805,13 +875,75 @@ Use the following settings to configure the serial connection to the printer:
|
|||||||
# impact, leave on if possible please
|
# impact, leave on if possible please
|
||||||
logResends: true
|
logResends: true
|
||||||
|
|
||||||
|
# Specifies whether OctoPrint should wait for the start response from the printer before trying to send commands
|
||||||
|
# during connect.
|
||||||
|
waitForStartOnConnect: false
|
||||||
|
|
||||||
|
# Specifies whether OctoPrint should send linenumber + checksum with every printer command. Needed for
|
||||||
|
# successful communication with Repetier firmware
|
||||||
|
alwaysSendChecksum: false
|
||||||
|
|
||||||
|
# Specifies whether OctoPrint should also send linenumber + checksum with commands that are *not*
|
||||||
|
# detected as valid GCODE (as in, they do not match the regular expression "^\s*([GM]\d+|T)").
|
||||||
|
sendChecksumWithUnknownCommands: false
|
||||||
|
|
||||||
|
# Specifies whether OctoPrint should also use up acknowledgments ("ok") for commands that are *not*
|
||||||
|
# detected as valid GCODE (as in, they do not match the regular expression "^\s*([GM]\d+|T)").
|
||||||
|
unknownCommandsNeedAck: false
|
||||||
|
|
||||||
|
# Whether to ignore the first ok after a resend response. Needed for successful communication with
|
||||||
|
# Repetier firmware
|
||||||
|
swallowOkAfterResend: false
|
||||||
|
|
||||||
|
# Specifies whether firmware expects relative paths for selecting SD files
|
||||||
|
sdRelativePath: false
|
||||||
|
|
||||||
|
# Whether to always assume that an SD card is present in the printer.
|
||||||
|
# Needed by some firmwares which don't report the SD card status properly.
|
||||||
|
sdAlwaysAvailable: false
|
||||||
|
|
||||||
|
# Whether the printer sends repetier style target temperatures in the format
|
||||||
|
# TargetExtr0:<temperature>
|
||||||
|
# instead of attaching that information to the regular M105 responses
|
||||||
|
repetierTargetTemp: false
|
||||||
|
|
||||||
|
# Whether to enable external heatup detection (to detect heatup triggered e.g. through the printer's LCD panel or
|
||||||
|
# while printing from SD) or not. Causes issues with Repetier's "first ok then response" approach to
|
||||||
|
# communication, so disable for printers running Repetier firmware.
|
||||||
|
externalHeatupDetection: true
|
||||||
|
|
||||||
|
# Whether to ignore identical resends from the printer (true, repetier) or not (false)
|
||||||
|
ignoreIdenticalResends: false
|
||||||
|
|
||||||
|
# If ignoredIdenticalResends is true, how many consecutive identical resends to ignore
|
||||||
|
identicalResendsCount: 7
|
||||||
|
|
||||||
|
# Whether to support F on its own as a valid GCODE command (true) or not (false)
|
||||||
|
supportFAsCommand: false
|
||||||
|
|
||||||
|
# Whether to attempt to auto detect the firmware of the printer and adjust settings
|
||||||
|
# accordingly (true) or not and rely on manual configuration (false)
|
||||||
|
firmwareDetection: true
|
||||||
|
|
||||||
|
# Whether to block all sending to the printer while a G4 (dwell) command is active (true, repetier)
|
||||||
|
# or not (false)
|
||||||
|
blockWhileDwelling: false
|
||||||
|
|
||||||
# Whether to support resends without follow-up ok or not
|
# Whether to support resends without follow-up ok or not
|
||||||
supportResendsWithoutOk: false
|
supportResendsWithoutOk: false
|
||||||
|
|
||||||
# Whether to "manually" trigger an ok for M29 (a lot of versions of this command are buggy and
|
# Whether to "manually" trigger an ok for M29 (a lot of versions of this command are buggy and
|
||||||
# the responds skips on the ok)
|
# the response skips on the ok)
|
||||||
triggerOkForM29: true
|
triggerOkForM29: true
|
||||||
|
|
||||||
|
capabilities:
|
||||||
|
|
||||||
|
# Whether to enable temperature autoreport in the firmware if its support is detected
|
||||||
|
autoreport_temp: true
|
||||||
|
|
||||||
|
# Whether to shorten the communication timeout if the firmware seems to support the busy protocol
|
||||||
|
busy_protocol: true
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-server:
|
.. _sec-configuration-config_yaml-server:
|
||||||
|
|
||||||
Server
|
Server
|
||||||
@@ -837,12 +969,19 @@ Use the following settings to configure the server:
|
|||||||
# reset the setting to false
|
# reset the setting to false
|
||||||
startOnceInSafeMode: false
|
startOnceInSafeMode: false
|
||||||
|
|
||||||
|
# Signals to OctoPrint that the last startup was incomplete. OctoPrint will then startup
|
||||||
|
# in safe mode
|
||||||
|
incompleteStartup: false
|
||||||
|
|
||||||
|
# Set this to true to make OctoPrint ignore incomplete startups. Helpful for development.
|
||||||
|
ignoreIncompleteStartup: false
|
||||||
|
|
||||||
# Secret key for encrypting cookies and such, randomly generated on first run
|
# Secret key for encrypting cookies and such, randomly generated on first run
|
||||||
secretKey: someSecretKey
|
secretKey: someSecretKey
|
||||||
|
|
||||||
# Settings if OctoPrint is running behind a reverse proxy (haproxy, nginx, apache, ...).
|
# Settings if OctoPrint is running behind a reverse proxy (haproxy, nginx, apache, ...).
|
||||||
# These are necessary in order to make OctoPrint generate correct external URLs so
|
# These are necessary in order to make OctoPrint generate correct external URLs so
|
||||||
# that AJAX requests and download URLs work.
|
# that AJAX requests and download URLs work, and so that client IPs are read correctly.
|
||||||
reverseProxy:
|
reverseProxy:
|
||||||
|
|
||||||
# The request header from which to determine the URL prefix under which OctoPrint
|
# The request header from which to determine the URL prefix under which OctoPrint
|
||||||
@@ -876,6 +1015,14 @@ Use the following settings to configure the server:
|
|||||||
# (X-Forwarded-Host by default, see above) with forwarded requests.
|
# (X-Forwarded-Host by default, see above) with forwarded requests.
|
||||||
hostFallback:
|
hostFallback:
|
||||||
|
|
||||||
|
# List of trusted downstream servers for which to ignore the IP address when trying to determine
|
||||||
|
# the connecting client's IP address. If you have OctoPrint behind more than one reverse proxy
|
||||||
|
# you should add their IPs here so that they won't be interpreted as the client's IP. One reverse
|
||||||
|
# proxy will be handled correctly by default.
|
||||||
|
trustedDownstream:
|
||||||
|
- 192.168.1.254
|
||||||
|
- 192.168.23.42
|
||||||
|
|
||||||
# Settings for file uploads to OctoPrint, such as maximum allowed file size and
|
# Settings for file uploads to OctoPrint, such as maximum allowed file size and
|
||||||
# header suffixes to use for streaming uploads. OctoPrint does some nifty things internally in
|
# header suffixes to use for streaming uploads. OctoPrint does some nifty things internally in
|
||||||
# order to allow streaming of large file uploads to the application rather than just storing
|
# order to allow streaming of large file uploads to the application rather than just storing
|
||||||
@@ -909,6 +1056,31 @@ Use the following settings to configure the server:
|
|||||||
# Command to shut down the system OctoPrint is running on, defaults to being unset
|
# Command to shut down the system OctoPrint is running on, defaults to being unset
|
||||||
systemShutdownCommand: sudo shutdown -h now
|
systemShutdownCommand: sudo shutdown -h now
|
||||||
|
|
||||||
|
# Configuration of the regular online connectivity check
|
||||||
|
onlineCheck:
|
||||||
|
# whether the online check is enabled, defaults to false due to valid privacy concerns
|
||||||
|
enabled: false
|
||||||
|
|
||||||
|
# interval in which to check for online connectivity (in seconds)
|
||||||
|
interval: 300
|
||||||
|
|
||||||
|
# DNS host against which to check (default: 8.8.8.8 aka Google's DNS)
|
||||||
|
host: 8.8.8.8
|
||||||
|
|
||||||
|
# DNS port against which to check (default: 53 - the default DNS port)
|
||||||
|
port: 53
|
||||||
|
|
||||||
|
# Configuration of the plugin blacklist
|
||||||
|
pluginBlacklist:
|
||||||
|
# whether use of the blacklist is enabled, defaults to false
|
||||||
|
enabled: false
|
||||||
|
|
||||||
|
# the URL from which to fetch the blacklist
|
||||||
|
url: http://plugins.octoprint.org/blacklist.json
|
||||||
|
|
||||||
|
# time to live of the cached blacklist, in seconds (default: 15 minutes)
|
||||||
|
ttl: 15 * 60
|
||||||
|
|
||||||
# Settings of when to display what disk space warning
|
# Settings of when to display what disk space warning
|
||||||
diskspace:
|
diskspace:
|
||||||
|
|
||||||
@@ -930,6 +1102,15 @@ Use the following settings to configure the server:
|
|||||||
# How many days to leave unused entries in the preemptive cache config
|
# How many days to leave unused entries in the preemptive cache config
|
||||||
until: 7
|
until: 7
|
||||||
|
|
||||||
|
# Configuration of the client IP check to warn about connections from external networks
|
||||||
|
ipCheck:
|
||||||
|
|
||||||
|
# whether to enable the check, defaults to true
|
||||||
|
enabled: true
|
||||||
|
|
||||||
|
# additional non-local subnets to consider trusted, in CIDR notation, e.g. "192.168.1.0/24"
|
||||||
|
trustedSubnets: []
|
||||||
|
|
||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
@@ -959,14 +1140,14 @@ Settings for the built-in slicing support:
|
|||||||
slicing:
|
slicing:
|
||||||
|
|
||||||
# Whether to enable slicing support or not
|
# Whether to enable slicing support or not
|
||||||
enabled:
|
enabled: true
|
||||||
|
|
||||||
# Default slicer to use
|
# Default slicer to use
|
||||||
defaultSlicer: cura
|
defaultSlicer: null
|
||||||
|
|
||||||
# Default slicing profiles per slicer
|
# Default slicing profiles per slicer
|
||||||
defaultProfiles:
|
defaultProfiles:
|
||||||
cura: ...
|
curalegacy: ...
|
||||||
|
|
||||||
.. _sec-configuration-config_yaml-system:
|
.. _sec-configuration-config_yaml-system:
|
||||||
|
|
||||||
@@ -975,7 +1156,12 @@ System
|
|||||||
|
|
||||||
Use the following settings to add custom system commands to the "System" dropdown within OctoPrint's top bar.
|
Use the following settings to add custom system commands to the "System" dropdown within OctoPrint's top bar.
|
||||||
|
|
||||||
Commands consist of a name, an action identifier, the commandline to execute and an optional confirmation message to
|
Commands consist of a ``name`` shown to the user, an ``action`` identifier used by the code and the actual
|
||||||
|
``command`` including any argument needed for its execution.
|
||||||
|
By default OctoPrint blocks until the command has returned so that the exit code can be used to show a success
|
||||||
|
or failure message; use the flag ``async: true`` for commands that don't return.
|
||||||
|
|
||||||
|
Optionally you can add a confirmation message to
|
||||||
display before actually executing the command (should be set to False if a confirmation dialog is not desired).
|
display before actually executing the command (should be set to False if a confirmation dialog is not desired).
|
||||||
|
|
||||||
The following example defines a command for shutting down the system under Linux. It assumes that the user under which
|
The following example defines a command for shutting down the system under Linux. It assumes that the user under which
|
||||||
@@ -990,7 +1176,7 @@ OctoPrint is running is allowed to do this without password entry:
|
|||||||
command: sudo shutdown -h now
|
command: sudo shutdown -h now
|
||||||
confirm: You are about to shutdown the system.
|
confirm: You are about to shutdown the system.
|
||||||
|
|
||||||
You can also add an divider by setting action to divider like this:
|
You can also add a divider by setting action to divider like this:
|
||||||
|
|
||||||
.. code-block:: yaml
|
.. code-block:: yaml
|
||||||
|
|
||||||
@@ -1032,7 +1218,7 @@ Use `Javascript regular expressions <https://developer.mozilla.org/en/docs/Web/J
|
|||||||
# A list of filters to display in the terminal tab. Defaults to the filters shown below
|
# A list of filters to display in the terminal tab. Defaults to the filters shown below
|
||||||
terminalFilters:
|
terminalFilters:
|
||||||
- name: Suppress temperature messages
|
- name: Suppress temperature messages
|
||||||
regex: '(Send: (N\d+\s+)?M105)|(Recv: ok T:)'
|
regex: '(Send: (N\d+\s+)?M105)|(Recv:\s+(ok\s+)?.*(B|T\d*):\d+)'
|
||||||
- name: Suppress SD status messages
|
- name: Suppress SD status messages
|
||||||
regex: '(Send: (N\d+\s+)?M27)|(Recv: SD printing byte)'
|
regex: '(Send: (N\d+\s+)?M27)|(Recv: SD printing byte)'
|
||||||
- name: Suppress wait responses
|
- name: Suppress wait responses
|
||||||
@@ -1064,6 +1250,9 @@ Use the following settings to configure webcam support:
|
|||||||
# Should be left at 1 for RPi1.
|
# Should be left at 1 for RPi1.
|
||||||
ffmpegThreads: 1
|
ffmpegThreads: 1
|
||||||
|
|
||||||
|
# Videocodec to be used for encoding. Defaults to mpeg2video.
|
||||||
|
ffmpegVideoCodec: mpeg2video
|
||||||
|
|
||||||
# The bitrate to use for rendering the timelapse video. This gets directly passed to ffmpeg.
|
# The bitrate to use for rendering the timelapse video. This gets directly passed to ffmpeg.
|
||||||
bitrate: 5000k
|
bitrate: 5000k
|
||||||
|
|
||||||
|
|||||||
@@ -39,8 +39,8 @@ A list of important components for which an increase in logging might be interes
|
|||||||
* ``octoprint.filemanager``: the file management layer
|
* ``octoprint.filemanager``: the file management layer
|
||||||
* ``octoprint.plugin``: the plugin sub system
|
* ``octoprint.plugin``: the plugin sub system
|
||||||
* ``octoprint.plugins.<plugin>``: the plugin ``<plugin>``, e.g. ``octoprint.plugins.discovery`` to change the log level of
|
* ``octoprint.plugins.<plugin>``: the plugin ``<plugin>``, e.g. ``octoprint.plugins.discovery`` to change the log level of
|
||||||
the `Discovery plugin <https://github.com/foosel/OctoPrint/wiki/Plugin:-Discovery>`_ or ``octoprint.plugins.cura``
|
the :ref:`Discovery plugin <sec-bundledplugins-discovery>` or ``octoprint.plugins.backup``
|
||||||
to change the log level of the `Cura plugin <https://github.com/foosel/OctoPrint/wiki/Plugin:-Cura>`_.
|
to change the log level of the :ref:`Backup plugin <sec-bundledplugins-backup>`.
|
||||||
* ``octoprint.slicing``: the slicing sub system
|
* ``octoprint.slicing``: the slicing sub system
|
||||||
|
|
||||||
This list will be expanded when deemed necessary.
|
This list will be expanded when deemed necessary.
|
||||||
|
|||||||
@@ -0,0 +1,245 @@
|
|||||||
|
.. _sec-development-environment:
|
||||||
|
|
||||||
|
Setting up a Development environment
|
||||||
|
====================================
|
||||||
|
|
||||||
|
.. _sec-development-environment-source:
|
||||||
|
|
||||||
|
Obtaining, building and running the source
|
||||||
|
------------------------------------------
|
||||||
|
|
||||||
|
This describes the general steps in obtaining, building and running. OS specific instructions can be found
|
||||||
|
below.
|
||||||
|
|
||||||
|
* Prerequisites:
|
||||||
|
|
||||||
|
* `Python 2.7 <https://python.org>`_ including ``pip``, ``setuptools`` and ``virtualenv``
|
||||||
|
* `Python 3.7 <https://python.org>`_ including ``pip``, ``setuptools`` and ``virtualenv``
|
||||||
|
* `Git <https://git-scm.com>`_
|
||||||
|
|
||||||
|
* Checkout the OctoPrint sources from their Git repository:
|
||||||
|
* ``git clone -b devel https://github.com/foosel/OctoPrint.git``
|
||||||
|
* Enter the checked out source folder: ``cd OctoPrint``
|
||||||
|
* Create virtual environments in the checked out source folder for both Python 2.7 and Python 3.7 to use for
|
||||||
|
installing and running OctoPrint and its dependencies (this avoids potential versioning issues for the dependencies
|
||||||
|
with system wide installed instances):
|
||||||
|
* PY2: ``virtualenv --python=python2 venv2``
|
||||||
|
* PY3: ``virtualenv --python=python3 venv3``
|
||||||
|
* Activate one of the virtual environments:
|
||||||
|
* PY2: ``source venv2/bin/activate`` (Linux, MacOS) or ``source venv2/Scripts/activate`` (Git Bash under Windows, see below)
|
||||||
|
* PY3: ``source venv3/bin/activate`` (Linux, MacOS) or ``source venv3/Scripts/activate`` (Git Bash under Windows, see below)
|
||||||
|
* Update ``pip`` in the virtual environment:
|
||||||
|
* ``pip install --upgrade pip``
|
||||||
|
* Install OctoPrint in `"editable" mode <https://pip.pypa.io/en/stable/reference/pip_install/#editable-installs>`_,
|
||||||
|
including its regular *and* development and plugin development dependencies:
|
||||||
|
* ``pip install -e .[develop,plugins]``
|
||||||
|
|
||||||
|
When the virtual environment is activated you can then:
|
||||||
|
|
||||||
|
* run the OctoPrint server via ``octoprint serve``
|
||||||
|
* run the test suite from the checked out source folder via ``nosetests --with-doctest``
|
||||||
|
* build the documentation from the ``docs`` sub folder of the checked out sources via ``sphinx-build -b html . _build``
|
||||||
|
|
||||||
|
To switch the activated virtual environment, simply activate the new environment as described above.
|
||||||
|
|
||||||
|
To deactivate the virtual environment and return to the system's default Python: ``deactivate``.
|
||||||
|
|
||||||
|
.. _sec-development-environment-source-linux:
|
||||||
|
|
||||||
|
Linux
|
||||||
|
.....
|
||||||
|
|
||||||
|
.. todo::
|
||||||
|
|
||||||
|
This guide is not yet adapted to the concurrent use of Python 2.7 and 3.7 environments during development.
|
||||||
|
|
||||||
|
This assumes you'll host your OctoPrint development checkout at ``~/devel/OctoPrint``. If you want to use a different
|
||||||
|
location, please substitute accordingly.
|
||||||
|
|
||||||
|
First make sure you have python including its header files, pip, setuptools, virtualenv, git and some build requirements
|
||||||
|
installed:
|
||||||
|
|
||||||
|
* On apt based distributions (e.g. Debian, Ubuntu, ...):
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
sudo apt-get install python python-pip python-dev python-setuptools python-virtualenv git libyaml-dev build-essential
|
||||||
|
|
||||||
|
* On zypper based distributions (example below for SLES 12 SP2):
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
sudo zypper ar https://download.opensuse.org/repositories/devel:/languages:/python/SLE_12_SP2/ python_devel
|
||||||
|
sudo zypper ref
|
||||||
|
sudo zypper in python python-pip python-devel python-setuptools python-virtualenv git libyaml-devel
|
||||||
|
sudo zypper in -t pattern Basis-Devel
|
||||||
|
|
||||||
|
.. todo::
|
||||||
|
|
||||||
|
Using a Linux distribution that doesn't use ``apt`` or ``zypper``? Please send a
|
||||||
|
`Pull Request <https://github.com/foosel/OctoPrint/blob/master/CONTRIBUTING.md#pull-requests>`_ to get the necessary
|
||||||
|
steps into this guide!
|
||||||
|
|
||||||
|
Then:
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
cd ~/devel
|
||||||
|
git clone -b devel https://github.com/foosel/OctoPrint.git
|
||||||
|
cd OctoPrint
|
||||||
|
virtualenv venv
|
||||||
|
source ./venv/bin/activate
|
||||||
|
pip install --upgrade pip
|
||||||
|
pip install -e .[develop,plugins]
|
||||||
|
|
||||||
|
You can then start OctoPrint via ``~/devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual
|
||||||
|
environment.
|
||||||
|
|
||||||
|
.. _sec-development-environment-windows:
|
||||||
|
|
||||||
|
Windows
|
||||||
|
.......
|
||||||
|
|
||||||
|
.. todo::
|
||||||
|
|
||||||
|
This guide is not yet adapted to the concurrent use of Python 2.7 and 3.7 environments during development.
|
||||||
|
|
||||||
|
This assumes you'll host your OctoPrint development checkout at ``C:\Devel\OctoPrint``. If you want to use a different
|
||||||
|
location, please substitute accordingly.
|
||||||
|
|
||||||
|
First download & install:
|
||||||
|
|
||||||
|
* `Python 2.7.15 Windows x86 MSI installer <https://www.python.org/downloads/release/python-2715/>`_
|
||||||
|
|
||||||
|
* make sure to have the installer add Python to the ``PATH`` and have it install ``pip`` too
|
||||||
|
|
||||||
|
* `Microsoft Visual C++ Compiler for Python 2.7 <http://www.microsoft.com/en-us/download/details.aspx?id=44266>`_
|
||||||
|
* `Git for Windows <https://git-for-windows.github.io/>`_
|
||||||
|
|
||||||
|
Open the Git Bash you just installed and in that:
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
pip install virtualenv
|
||||||
|
cd /c/Devel
|
||||||
|
git clone https://github.com/foosel/OctoPrint.git
|
||||||
|
cd OctoPrint
|
||||||
|
virtualenv venv
|
||||||
|
source ./venv/Scripts/activate
|
||||||
|
pip install --upgrade pip
|
||||||
|
pip install -e .[develop,plugins]
|
||||||
|
|
||||||
|
.. _sec-development-environment-mac:
|
||||||
|
|
||||||
|
Mac OS X
|
||||||
|
........
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
This guide is based on the `Setup Guide for Mac OS X on OctoPrint's wiki <https://github.com/foosel/OctoPrint/wiki/Setup-on-Mac/>`_.
|
||||||
|
Please report back if it works for you, due to lack of access to a Mac I cannot test it myself. Thanks.
|
||||||
|
|
||||||
|
.. todo::
|
||||||
|
|
||||||
|
This guide is not yet adapted to the concurrent use of Python 2.7 and 3.7 environments during development.
|
||||||
|
|
||||||
|
This assumes you'll host your OctoPrint development checkout at ``~/devel/OctoPrint``. If you want to use a different
|
||||||
|
location, please substitute accordingly.
|
||||||
|
|
||||||
|
You'll need a user account with administrator privileges.
|
||||||
|
|
||||||
|
* Install the latest version of Xcode suitable for your OS. For example, OS X 10.11 (El Capitan) requires Xcode 7.
|
||||||
|
* Install Xcode's command line tools:
|
||||||
|
|
||||||
|
* ``xcode-select --install``
|
||||||
|
* ``sudo xcodebuild`` (ensure the license was accepted)
|
||||||
|
* If you have more than one Xcode installed: ``sudo xcode-select -s /Applications/Xcode.app/Contents/Developer``
|
||||||
|
|
||||||
|
* Install Homebrew and use that to install Python:
|
||||||
|
|
||||||
|
* ``ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"``
|
||||||
|
* ``brew install python``
|
||||||
|
|
||||||
|
* Install `virtualenv <https://virtualenv.pypa.io/>`_
|
||||||
|
|
||||||
|
* ``pip install virtualenv``
|
||||||
|
|
||||||
|
* Install OctoPrint
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
cd ~/devel
|
||||||
|
git clone https://github.com/foosel/OctoPrint.git
|
||||||
|
cd OctoPrint
|
||||||
|
virtualenv venv
|
||||||
|
source venv/bin/activate
|
||||||
|
pip install --upgrade pip
|
||||||
|
pip install -e .[develop,plugins]
|
||||||
|
|
||||||
|
.. _sec-development-environment-ides:
|
||||||
|
|
||||||
|
IDE Setup
|
||||||
|
---------
|
||||||
|
|
||||||
|
.. todo::
|
||||||
|
|
||||||
|
This guide is not yet adapted to the concurrent use of Python 2.7 and 3.7 environments during development.
|
||||||
|
|
||||||
|
.. todo::
|
||||||
|
|
||||||
|
Using another IDE than the ones below? Please send a
|
||||||
|
`Pull Request <https://github.com/foosel/OctoPrint/blob/master/CONTRIBUTING.md#pull-requests>`_ to get the necessary
|
||||||
|
steps into this guide!
|
||||||
|
|
||||||
|
.. _sec-development-environment-ides-pycharm:
|
||||||
|
|
||||||
|
PyCharm
|
||||||
|
.......
|
||||||
|
|
||||||
|
- "File" > "Open ...", select OctoPrint checkout folder (e.g. ``~/devel/OctoPrint`` or ``C:\Devel\OctoPrint``)
|
||||||
|
- "File" > "Settings ..." > "Project: OctoPrint" > "Project Interpreter" > "Add local ...", select OctoPrint venv
|
||||||
|
folder (e.g. ``~/devel/OctoPrint/venv`` or ``C:\Devel\OctoPrint\venv``)
|
||||||
|
- Right click "src" in project tree, mark as source folder
|
||||||
|
- Add Run/Debug Configuration, select "Python":
|
||||||
|
|
||||||
|
* Name: OctoPrint server
|
||||||
|
* Script: path to ``run`` in the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint/run`` or ``C:\Devel\OctoPrint\run``)
|
||||||
|
* Script parameters: ``serve --debug``
|
||||||
|
* Project: ``OctoPrint``
|
||||||
|
* Python interpreter: the ``venv`` local virtual environment
|
||||||
|
* Working directory: the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint`` or ``C:\Devel\OctoPrint``)
|
||||||
|
* If you want dependencies to auto-update on run if necessary: "Before Launch" > "+" > "Run external tool" > "+"
|
||||||
|
|
||||||
|
* Name: Update OctoPrint dependencies
|
||||||
|
* Program: ``$PyInterpreterDirectory$/pip`` (or ``$PyInterpreterDirectory$/pip.exe`` on Windows)
|
||||||
|
* Parameters: ``install -e .[develop,plugins]``
|
||||||
|
* Working directory: ``$ProjectFileDir$``
|
||||||
|
|
||||||
|
- Add Run/Debug Configuration, select "Python tests" and therein "Nosetests":
|
||||||
|
|
||||||
|
* Name: OctoPrint nosetests
|
||||||
|
* Target: Path, ``.``
|
||||||
|
* Project: ``OctoPrint``
|
||||||
|
* Python interpreter: the ``venv`` local virtual environment
|
||||||
|
* Working directory: the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint`` or ``C:\Devel\OctoPrint``)
|
||||||
|
* Just like with the run configuration for the server you can also have the dependencies auto-update on run of
|
||||||
|
the tests, see above on how to set this up.
|
||||||
|
|
||||||
|
- Add Run/Debug Configuration, select "Python docs" and therein "Sphinx task"
|
||||||
|
|
||||||
|
* Name: OctoPrint docs
|
||||||
|
* Command: ``html``
|
||||||
|
* Input: the ``docs`` folder in the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint/docs`` or
|
||||||
|
``C:\Devel\OctoPrint\docs``)
|
||||||
|
* Output: the ``docs/_build`` folder in the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint/docs/_build`` or
|
||||||
|
``C:\Devel\OctoPrint\docs\_build``)
|
||||||
|
* Project: ``OctoPrint``
|
||||||
|
* Python interpreter: the ``venv`` local virtual environment
|
||||||
|
* Just like with the run configuration for the server you can also have the dependencies auto-update when building
|
||||||
|
the documentation, see above on how to set this up.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
Make sure you are running a PyCharm version of 2016.1 or later, or manually fix
|
||||||
|
`a debugger bug contained in earlier versions <https://youtrack.jetbrains.com/issue/PY-18365>`_ or plugin management
|
||||||
|
will not work in your developer install when running OctoPrint from PyCharm in debug mode.
|
||||||
@@ -4,183 +4,8 @@
|
|||||||
Development
|
Development
|
||||||
###########
|
###########
|
||||||
|
|
||||||
.. contents::
|
.. toctree::
|
||||||
:local:
|
:maxdepth: 3
|
||||||
|
|
||||||
.. _sec-development-environment:
|
environment.rst
|
||||||
|
virtual_printer.rst
|
||||||
Setting up a Development environment
|
|
||||||
====================================
|
|
||||||
|
|
||||||
.. _sec-development-environment-source:
|
|
||||||
|
|
||||||
Obtaining, building and running the source
|
|
||||||
------------------------------------------
|
|
||||||
|
|
||||||
This describes the general steps in obtaining, building and running. OS specific instructions can be found
|
|
||||||
below.
|
|
||||||
|
|
||||||
* Prerequisites:
|
|
||||||
|
|
||||||
* `Python 2.7 <https://python.org>`_ including ``pip``, ``setuptools`` and ``virtualenv``
|
|
||||||
* `Git <https://git-scm.com>`_
|
|
||||||
|
|
||||||
* Checkout the OctoPrint sources from their Git repository: ``git clone https://github.com/foosel/OctoPrint.git``
|
|
||||||
* Create a virtual environment in the checkout folder to use for installing and running OctoPrint and its
|
|
||||||
dependencies (this avoids potential versioning issues for the dependencies with system wide installed
|
|
||||||
instances): ``virtualenv venv``
|
|
||||||
* Activate the virtual environment: ``source venv/bin/activate`` (might differ per your platform/OS)
|
|
||||||
* Update ``pip`` in the virtual environment: ``pip install --upgrade pip``
|
|
||||||
* Install OctoPrint in `"editable" mode <https://pip.pypa.io/en/stable/reference/pip_install/#editable-installs>`_,
|
|
||||||
including its regular *and* development dependencies: ``pip install -e .[develop]``
|
|
||||||
|
|
||||||
.. _sec-development-environment-source-linux:
|
|
||||||
|
|
||||||
Linux
|
|
||||||
.....
|
|
||||||
|
|
||||||
This assumes you'll host your OctoPrint development checkout at ``~/devel/OctoPrint``. If you want to use a different
|
|
||||||
location, please substitute accordingly.
|
|
||||||
|
|
||||||
First make sure you have python including its header files, pip, setuptools, virtualenv, git and some build requirements
|
|
||||||
installed:
|
|
||||||
|
|
||||||
* On apt based distributions (e.g. Debian, Ubuntu, ...):
|
|
||||||
|
|
||||||
.. code-block:: none
|
|
||||||
|
|
||||||
sudo apt-get install python python-pip python-dev python-setuptools python-virtualenv git libyaml-dev build-essential
|
|
||||||
|
|
||||||
.. todo::
|
|
||||||
|
|
||||||
Using a Linux distribution that doesn't use ``apt``? Please send a
|
|
||||||
`Pull Request <https://github.com/foosel/OctoPrint/blob/master/CONTRIBUTING.md#pull-requests>`_ to get the necessary
|
|
||||||
steps into this guide!
|
|
||||||
|
|
||||||
Then:
|
|
||||||
|
|
||||||
.. code-block:: none
|
|
||||||
|
|
||||||
cd ~/devel
|
|
||||||
git clone https://github.com/foosel/OctoPrint.git
|
|
||||||
cd OctoPrint
|
|
||||||
virtualenv venv
|
|
||||||
source ./venv/bin/activate
|
|
||||||
pip install --upgrade pip
|
|
||||||
pip install -e .[develop]
|
|
||||||
|
|
||||||
You can then start OctoPrint via ``~/devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual
|
|
||||||
environment.
|
|
||||||
|
|
||||||
.. _sec-development-environment-windows:
|
|
||||||
|
|
||||||
Windows
|
|
||||||
.......
|
|
||||||
|
|
||||||
This assumes you'll host your OctoPrint development checkout at ``C:\Devel\OctoPrint``. If you want to use a different
|
|
||||||
location, please substitute accordingly.
|
|
||||||
|
|
||||||
First download & install:
|
|
||||||
|
|
||||||
* `Python 2.7.12 Windows x86 MSI installer <https://www.python.org/downloads/release/python-2712/>`_
|
|
||||||
|
|
||||||
* make sure to have the installer add Python to the ``PATH`` and have it install ``pip`` too
|
|
||||||
|
|
||||||
* `Microsoft Visual C++ Compiler for Python 2.7 <http://www.microsoft.com/en-us/download/details.aspx?id=44266>`_
|
|
||||||
* `Git for Windows <https://git-for-windows.github.io/>`_
|
|
||||||
|
|
||||||
Open the Git Bash you just installed and in that:
|
|
||||||
|
|
||||||
.. code-block:: none
|
|
||||||
|
|
||||||
pip install virtualenv
|
|
||||||
cd /c/Devel
|
|
||||||
git clone https://github.com/foosel/OctoPrint.git
|
|
||||||
cd OctoPrint
|
|
||||||
virtualenv venv
|
|
||||||
source ./venv/bin/activate
|
|
||||||
pip install --upgrade pip
|
|
||||||
pip install -e .[develop]
|
|
||||||
|
|
||||||
You can then start OctoPrint via ``/c/Devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual
|
|
||||||
environment.
|
|
||||||
|
|
||||||
.. _sec-development-environment-mac:
|
|
||||||
|
|
||||||
Mac OS X
|
|
||||||
........
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
This guide is based on the `Setup Guide for Mac OS X on OctoPrint's wiki <https://github.com/foosel/OctoPrint/wiki/Setup-on-Mac/>`_.
|
|
||||||
Please report back if it works for you, due to lack of access to a Mac I cannot test it myself. Thanks.
|
|
||||||
|
|
||||||
This assumes you'll host your OctoPrint development checkout at ``~/devel/OctoPrint``. If you want to use a different
|
|
||||||
location, please substitute accordingly.
|
|
||||||
|
|
||||||
You'll need a user account with administrator privileges.
|
|
||||||
|
|
||||||
* Install the latest version of Xcode suitable for your OS. For example, OS X 10.11 (El Capitan) requires Xcode 7.
|
|
||||||
* Install Xcode's command line tools:
|
|
||||||
|
|
||||||
* ``xcode-select --install``
|
|
||||||
* ``sudo xcodebuild`` (ensure the license was accepted)
|
|
||||||
* If you have more than one Xcode installed: ``sudo xcode-select -s /Applications/Xcode.app/Contents/Developer``
|
|
||||||
|
|
||||||
* Install Homebrew and use that to install Python:
|
|
||||||
|
|
||||||
* ``ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"``
|
|
||||||
* ``brew install python``
|
|
||||||
|
|
||||||
* Install `virtualenv <https://virtualenv.pypa.io/>`_
|
|
||||||
|
|
||||||
* ``pip install virtualenv``
|
|
||||||
|
|
||||||
* Install OctoPrint
|
|
||||||
|
|
||||||
.. code-block:: none
|
|
||||||
|
|
||||||
cd ~/devel
|
|
||||||
git clone https://github.com/foosel/OctoPrint.git
|
|
||||||
cd OctoPrint
|
|
||||||
virtualenv venv
|
|
||||||
source venv/bin/activate
|
|
||||||
pip install -e .[develop]
|
|
||||||
|
|
||||||
You can then start OctoPrint via ``~/devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual
|
|
||||||
environment.
|
|
||||||
|
|
||||||
.. _sec-development-environment-ides:
|
|
||||||
|
|
||||||
IDE Setup
|
|
||||||
---------
|
|
||||||
|
|
||||||
.. todo::
|
|
||||||
|
|
||||||
Using another IDE than the ones below? Please send a
|
|
||||||
`Pull Request <https://github.com/foosel/OctoPrint/blob/master/CONTRIBUTING.md#pull-requests>`_ to get the necessary
|
|
||||||
steps into this guide!
|
|
||||||
|
|
||||||
.. _sec-development-environment-ides-pycharm:
|
|
||||||
|
|
||||||
PyCharm
|
|
||||||
.......
|
|
||||||
|
|
||||||
- "File" > "Open ...", select OctoPrint checkout folder (e.g. ``~/devel/OctoPrint`` or ``C:\Devel\OctoPrint``)
|
|
||||||
- "File" > "Settings ..." > "Project: OctoPrint" > "Project Interpreter" > "Add local ...", select OctoPrint venv
|
|
||||||
folder (e.g. ``~/devel/OctoPrint/venv`` or ``C:\Devel\OctoPrint\venv``)
|
|
||||||
- Right click "src" in project tree, mark as source folder
|
|
||||||
- Add Run/Debug Configuration, select "Python":
|
|
||||||
|
|
||||||
* Name: OctoPrint server
|
|
||||||
* Script: path to ``run`` in the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint/run`` or ``C:\Devel\OctoPrint\run``)
|
|
||||||
* Script parameters: ``--debug``
|
|
||||||
* Project: ``OctoPrint``
|
|
||||||
* Python interpreter: the ``venv`` local virtual environment
|
|
||||||
* Working directory: the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint`` or ``C:\Devel\OctoPrint``)
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
Make sure you are running a PyCharm version of 2016.1 or later, or manually fix
|
|
||||||
`a debugger bug contained in earlier versions <https://youtrack.jetbrains.com/issue/PY-18365>`_ or plugin management
|
|
||||||
will not work in your developer install when running OctoPrint from PyCharm in debug mode.
|
|
||||||
@@ -0,0 +1,127 @@
|
|||||||
|
.. _sec-development-virtual-printer:
|
||||||
|
|
||||||
|
Setting up the virtual printer for debugging
|
||||||
|
============================================
|
||||||
|
|
||||||
|
OctoPrint includes, by default, a virtual printer plugin. This plugin allows you to debug OctoPrint's serial
|
||||||
|
communication without connecting to an actual printer. Furthermore, it is possible to create certain edge conditions
|
||||||
|
that may be hard to reproduce with a real printer.
|
||||||
|
|
||||||
|
.. _sec-development-virtual-printer-enable:
|
||||||
|
|
||||||
|
Enabling the virtual printer
|
||||||
|
----------------------------
|
||||||
|
|
||||||
|
The virtual printer is enabled by editing OctoPrint's config.yaml file. Details on the configuration file can
|
||||||
|
be found in the full :ref:`config.yaml documentation <sec-configuration-config_yaml>`.
|
||||||
|
|
||||||
|
The steps to take are as follows:
|
||||||
|
|
||||||
|
* Find config.yaml in the OctoPrint settings folder. Usually in ``~/.octoprint`` on Linux, in ``%APPDATA%/OctoPrint`` on Windows and in ``~/Library/Application Support/OctoPrint`` on MacOS.
|
||||||
|
* Add or extend the ``devel`` section with:
|
||||||
|
|
||||||
|
.. code-block:: yaml
|
||||||
|
|
||||||
|
devel:
|
||||||
|
virtualPrinter:
|
||||||
|
enabled: true
|
||||||
|
|
||||||
|
* Restart OctoPrint.
|
||||||
|
* In the connection panel, a new option will appear in the Serial Port dropdown labeled ``VIRTUAL``.
|
||||||
|
* Select this option and click ``connect``.
|
||||||
|
* The virtual printer is now active.
|
||||||
|
|
||||||
|
.. _sec-development-virtual-printer-config:
|
||||||
|
|
||||||
|
Virtual printer configuration options
|
||||||
|
-------------------------------------
|
||||||
|
|
||||||
|
The config.yaml file has many configuration options for the virtual printer that allow you to fine-tune its behavior.
|
||||||
|
|
||||||
|
Please see the relevant :ref:`config.yaml section <sec-configuration-config_yaml-devel>` for the full details.
|
||||||
|
|
||||||
|
.. _sec-development-virtual-printer-log:
|
||||||
|
|
||||||
|
Log file
|
||||||
|
--------
|
||||||
|
|
||||||
|
Once activated, the virtual printer will log all serial communication in the ``plugin_virtual_printer_serial.log`` file
|
||||||
|
that can be found in the OctoPrint settings folder.
|
||||||
|
|
||||||
|
.. _sec-development-virtual-printer-debug:
|
||||||
|
|
||||||
|
Debug commands
|
||||||
|
--------------
|
||||||
|
|
||||||
|
You can simulate certain conditions and communications through the terminal tab in OctoPrint's interface.
|
||||||
|
|
||||||
|
All commands start with ``!!DEBUG:`` and are followed by the command you want to execute. For instance, sending
|
||||||
|
``!!DEBUG:action_disconnect`` will disconnect the printer. Sending ``!!DEBUG`` without command will show a help
|
||||||
|
message with all the available commands:
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
OctoPrint Virtual Printer debug commands
|
||||||
|
|
||||||
|
help
|
||||||
|
?
|
||||||
|
| This help.
|
||||||
|
|
||||||
|
# Action Triggers
|
||||||
|
|
||||||
|
action_pause
|
||||||
|
| Sends a "// action:pause" action trigger to the host.
|
||||||
|
action_resume
|
||||||
|
| Sends a "// action:resume" action trigger to the host.
|
||||||
|
action_disconnect
|
||||||
|
| Sends a "// action:disconnect" action trigger to the
|
||||||
|
| host.
|
||||||
|
action_custom <action>[ <parameters>]
|
||||||
|
| Sends a custom "// action:<action> <parameters>"
|
||||||
|
| action trigger to the host.
|
||||||
|
|
||||||
|
# Communication Errors
|
||||||
|
|
||||||
|
dont_answer
|
||||||
|
| Will not acknowledge the next command.
|
||||||
|
go_awol
|
||||||
|
| Will completely stop replying
|
||||||
|
trigger_resend_lineno
|
||||||
|
| Triggers a resend error with a line number mismatch
|
||||||
|
trigger_resend_checksum
|
||||||
|
| Triggers a resend error with a checksum mismatch
|
||||||
|
trigger_missing_checksum
|
||||||
|
| Triggers a resend error with a missing checksum
|
||||||
|
trigger_missing_lineno
|
||||||
|
| Triggers a "no line number with checksum" error w/o resend request
|
||||||
|
drop_connection
|
||||||
|
| Drops the serial connection
|
||||||
|
prepare_ok <broken ok>
|
||||||
|
| Will cause <broken ok> to be enqueued for use,
|
||||||
|
| will be used instead of actual "ok"
|
||||||
|
|
||||||
|
# Reply Timing / Sleeping
|
||||||
|
|
||||||
|
sleep <int:seconds>
|
||||||
|
| Sleep <seconds> s
|
||||||
|
sleep_after <str:command> <int:seconds>
|
||||||
|
| Sleeps <seconds> s after each execution of <command>
|
||||||
|
sleep_after_next <str:command> <int:seconds>
|
||||||
|
| Sleeps <seconds> s after execution of next <command>
|
||||||
|
|
||||||
|
# SD printing
|
||||||
|
|
||||||
|
start_sd <str:file>
|
||||||
|
| Select and start printing file <file> from SD
|
||||||
|
select_sd <str:file>
|
||||||
|
| Select file <file> from SD, don't start printing it yet. Use
|
||||||
|
| start_sd to start the print
|
||||||
|
cancel_sd
|
||||||
|
| Cancels an ongoing SD print
|
||||||
|
|
||||||
|
# Misc
|
||||||
|
|
||||||
|
send <str:message>
|
||||||
|
| Sends back <message>
|
||||||
|
reset
|
||||||
|
| Simulates a reset. Internal state will be lost.
|
||||||
@@ -6,15 +6,6 @@ Events
|
|||||||
|
|
||||||
.. contents::
|
.. contents::
|
||||||
|
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
With release of OctoPrint 1.1.0, the payload data has been harmonized, it is now a key-value-map for all events.
|
|
||||||
Additionally, the format of the placeholders in both system command and gcode command triggers has been changed to
|
|
||||||
accommodate for this new format. Last but not least, the way of specifying event hooks has changed, OctoPrint no longer
|
|
||||||
separates hooks into two sections (gcodeCommandTrigger and systemCommandTrigger) but instead event hooks are now typed
|
|
||||||
to indicate what to do with the command contained.
|
|
||||||
|
|
||||||
.. _sec-events-configuration:
|
.. _sec-events-configuration:
|
||||||
|
|
||||||
Configuration
|
Configuration
|
||||||
@@ -47,6 +38,13 @@ Example
|
|||||||
- event: PrintDone
|
- event: PrintDone
|
||||||
command: python ~/growl.py -t mygrowlserver -d "Completed {file}" -a OctoPrint -i http://raspi/Octoprint_logo.png
|
command: python ~/growl.py -t mygrowlserver -d "Completed {file}" -a OctoPrint -i http://raspi/Octoprint_logo.png
|
||||||
type: system
|
type: system
|
||||||
|
- event:
|
||||||
|
- PrintStarted
|
||||||
|
- PrintFailed
|
||||||
|
- PrintDone
|
||||||
|
- PrintCancelled
|
||||||
|
command: python ~/growl.py -t mygrowlserver -d "Event {__eventname} ({name})" -a OctoPrint -i http://raspi/Octoprint_logo.png
|
||||||
|
type: system
|
||||||
- event: Connected
|
- event: Connected
|
||||||
command:
|
command:
|
||||||
- M115
|
- M115
|
||||||
@@ -62,6 +60,7 @@ Placeholders
|
|||||||
You can use the following generic placeholders in your event hooks:
|
You can use the following generic placeholders in your event hooks:
|
||||||
|
|
||||||
* ``{__currentZ}``: the current Z position of the head if known, -1 if not available
|
* ``{__currentZ}``: the current Z position of the head if known, -1 if not available
|
||||||
|
* ``{__eventname}`` : the name of the event hook being triggered
|
||||||
* ``{__filename}`` : name of currently selected file, or ``NO FILE`` if no file is selected
|
* ``{__filename}`` : name of currently selected file, or ``NO FILE`` if no file is selected
|
||||||
* ``{__filepath}`` : path in origin location of currently selected file, or ``NO FILE`` if no file is selected
|
* ``{__filepath}`` : path in origin location of currently selected file, or ``NO FILE`` if no file is selected
|
||||||
* ``{__fileorigin}`` : origin of currently selected file, or ``NO FILE`` if no file is selected
|
* ``{__fileorigin}`` : origin of currently selected file, or ``NO FILE`` if no file is selected
|
||||||
@@ -85,6 +84,12 @@ and its origin via the placeholder ``{origin}``.
|
|||||||
Available Events
|
Available Events
|
||||||
================
|
================
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
Plugins may add additional events via the :ref:`octoprint.events.register_custom_events hook <sec-plugins-hook-events-register_custom_events>`.
|
||||||
|
|
||||||
|
.. _sec-events-available_events-server:
|
||||||
|
|
||||||
Server
|
Server
|
||||||
------
|
------
|
||||||
|
|
||||||
@@ -110,6 +115,16 @@ ClientClosed
|
|||||||
|
|
||||||
* ``remoteAddress``: the remote address (IP) of the client that disconnected
|
* ``remoteAddress``: the remote address (IP) of the client that disconnected
|
||||||
|
|
||||||
|
ConnectivityChanged
|
||||||
|
The server's internet connectivity changed
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``old``: Old connectivity value (true for online, false for offline)
|
||||||
|
* ``new``: New connectivity value (true for online, false for offline)
|
||||||
|
|
||||||
|
.. _sec-events-available_events-printer_commmunication:
|
||||||
|
|
||||||
Printer communication
|
Printer communication
|
||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
@@ -133,7 +148,8 @@ Disconnected
|
|||||||
The server has disconnected from the printer
|
The server has disconnected from the printer
|
||||||
|
|
||||||
Error
|
Error
|
||||||
An error has occurred in the printer communication.
|
An unrecoverable error has been encountered, either as reported by the firmware (e.g. a thermal runaway) or
|
||||||
|
on the connection.
|
||||||
|
|
||||||
Payload:
|
Payload:
|
||||||
|
|
||||||
@@ -148,6 +164,8 @@ PrinterStateChanged
|
|||||||
:func:`~octoprint.printer.PrinterInterface.get_state_id` for possible values.
|
:func:`~octoprint.printer.PrinterInterface.get_state_id` for possible values.
|
||||||
* ``state_string``: Text representation of the new state.
|
* ``state_string``: Text representation of the new state.
|
||||||
|
|
||||||
|
.. _sec-events-available_events-file_handling:
|
||||||
|
|
||||||
File handling
|
File handling
|
||||||
-------------
|
-------------
|
||||||
|
|
||||||
@@ -161,9 +179,7 @@ Upload
|
|||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's path within its storage location
|
* ``file``: the file's path within its storage location. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
FileAdded
|
FileAdded
|
||||||
A file has been added to a storage.
|
A file has been added to a storage.
|
||||||
@@ -199,8 +215,8 @@ FolderAdded
|
|||||||
|
|
||||||
Payload:
|
Payload:
|
||||||
* ``storage``: the storage's identifier
|
* ``storage``: the storage's identifier
|
||||||
* ``path``: the folders's path within its storage location
|
* ``path``: the folder's path within its storage location
|
||||||
* ``name``: the folders's name
|
* ``name``: the folder's name
|
||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
@@ -212,8 +228,8 @@ FolderRemoved
|
|||||||
|
|
||||||
Payload:
|
Payload:
|
||||||
* ``storage``: the storage's identifier
|
* ``storage``: the storage's identifier
|
||||||
* ``path``: the folders's path within its storage location
|
* ``path``: the folder's path within its storage location
|
||||||
* ``name``: the folders's name
|
* ``name``: the folder's name
|
||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
@@ -229,7 +245,7 @@ UpdatedFiles
|
|||||||
|
|
||||||
.. deprecated:: 1.2.0
|
.. deprecated:: 1.2.0
|
||||||
|
|
||||||
The ``gcode`` modification type has been superceeded by ``printables``. It is currently still available for
|
The ``gcode`` modification type has been superseded by ``printables``. It is currently still available for
|
||||||
reasons of backwards compatibility and will also be sent on modification of ``printables``. It will however
|
reasons of backwards compatibility and will also be sent on modification of ``printables``. It will however
|
||||||
be removed with 1.4.0.
|
be removed with 1.4.0.
|
||||||
|
|
||||||
@@ -245,9 +261,7 @@ MetadataAnalysisStarted
|
|||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's path within its storage location
|
* ``file``: the file's path within its storage location. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
MetadataAnalysisFinished
|
MetadataAnalysisFinished
|
||||||
The metadata analysis of a file has finished.
|
The metadata analysis of a file has finished.
|
||||||
@@ -257,13 +271,11 @@ MetadataAnalysisFinished
|
|||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the file's origin storage location
|
* ``origin``: the file's origin storage location
|
||||||
* ``result``: the analysis result -- this is a python object currently only available for internal use
|
* ``result``: the analysis result -- this is a Python object currently only available for internal use
|
||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's path within its storage location
|
* ``file``: the file's path within its storage location. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
FileSelected
|
FileSelected
|
||||||
A file has been selected for printing.
|
A file has been selected for printing.
|
||||||
@@ -276,10 +288,8 @@ FileSelected
|
|||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
FileDeselected
|
FileDeselected
|
||||||
No file is selected any more for printing.
|
No file is selected any more for printing.
|
||||||
@@ -303,6 +313,8 @@ TransferDone
|
|||||||
* ``local``: the file's name as stored locally
|
* ``local``: the file's name as stored locally
|
||||||
* ``remote``: the file's name as stored on SD
|
* ``remote``: the file's name as stored on SD
|
||||||
|
|
||||||
|
.. _sec-events-available_events-printing:
|
||||||
|
|
||||||
Printing
|
Printing
|
||||||
--------
|
--------
|
||||||
|
|
||||||
@@ -314,13 +326,14 @@ PrintStarted
|
|||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
|
* ``user``: the user who started the print job (if available)
|
||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
PrintFailed
|
PrintFailed
|
||||||
A print failed.
|
A print failed.
|
||||||
@@ -330,13 +343,15 @@ PrintFailed
|
|||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
|
* ``time``: the elapsed time of the print when it failed, in seconds (float)
|
||||||
|
* ``reason``: the reason the print failed, either ``cancelled`` or ``error``
|
||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
PrintDone
|
PrintDone
|
||||||
A print completed successfully.
|
A print completed successfully.
|
||||||
@@ -346,24 +361,42 @@ PrintDone
|
|||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
* ``time``: the time needed for the print, in seconds (float)
|
* ``time``: the time needed for the print, in seconds (float)
|
||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
PrintCancelling
|
||||||
|
The print is about to be cancelled.
|
||||||
PrintCancelled
|
|
||||||
The print has been cancelled via the cancel button.
|
|
||||||
|
|
||||||
Payload:
|
Payload:
|
||||||
|
|
||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
* ``position``: the print head position at the time of cancelling, if available
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
|
* ``user``: the user who cancelled the print job (if available)
|
||||||
|
* ``firmwareError``: the firmware error that caused cancelling the print job, if any
|
||||||
|
|
||||||
|
PrintCancelled
|
||||||
|
The print has been cancelled.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``name``: the file's name
|
||||||
|
* ``path``: the file's path within its storage location
|
||||||
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
|
* ``time``: the elapsed time of the print when it was cancelled, in seconds (float)
|
||||||
|
* ``user``: the user who cancelled the print job (if available)
|
||||||
|
* ``position``: the print head position at the time of cancelling (if available, not available if recording of the
|
||||||
|
position on cancel is disabled)
|
||||||
* ``position.x``: x coordinate, as reported back from the firmware through `M114`
|
* ``position.x``: x coordinate, as reported back from the firmware through `M114`
|
||||||
* ``position.y``: y coordinate, as reported back from the firmware through `M114`
|
* ``position.y``: y coordinate, as reported back from the firmware through `M114`
|
||||||
* ``position.z``: z coordinate, as reported back from the firmware through `M114`
|
* ``position.z``: z coordinate, as reported back from the firmware through `M114`
|
||||||
@@ -377,10 +410,8 @@ PrintCancelled
|
|||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
PrintPaused
|
PrintPaused
|
||||||
The print has been paused.
|
The print has been paused.
|
||||||
@@ -390,7 +421,11 @@ PrintPaused
|
|||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
* ``position``: the print head position at the time of pausing, if available
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
|
* ``user``: the user who paused the print job (if available)
|
||||||
|
* ``position``: the print head position at the time of pausing (if available, not available if the recording of
|
||||||
|
the position on pause is disabled or the pause is completely handled by the printer's firmware)
|
||||||
* ``position.x``: x coordinate, as reported back from the firmware through `M114`
|
* ``position.x``: x coordinate, as reported back from the firmware through `M114`
|
||||||
* ``position.y``: y coordinate, as reported back from the firmware through `M114`
|
* ``position.y``: y coordinate, as reported back from the firmware through `M114`
|
||||||
* ``position.z``: z coordinate, as reported back from the firmware through `M114`
|
* ``position.z``: z coordinate, as reported back from the firmware through `M114`
|
||||||
@@ -404,10 +439,8 @@ PrintPaused
|
|||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
|
||||||
|
|
||||||
PrintResumed
|
PrintResumed
|
||||||
The print has been resumed.
|
The print has been resumed.
|
||||||
@@ -417,13 +450,16 @@ PrintResumed
|
|||||||
* ``name``: the file's name
|
* ``name``: the file's name
|
||||||
* ``path``: the file's path within its storage location
|
* ``path``: the file's path within its storage location
|
||||||
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
* ``origin``: the origin storage location of the file, either ``local`` or ``sdcard``
|
||||||
|
* ``size``: the file's size in bytes (if available)
|
||||||
|
* ``owner``: the user who started the print job (if available)
|
||||||
|
* ``user``: the user who resumed the print job (if available)
|
||||||
|
|
||||||
.. deprecated:: 1.3.0
|
.. deprecated:: 1.3.0
|
||||||
|
|
||||||
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``)
|
* ``file``: the file's full path on disk (``local``) or within its storage (``sdcard``). To be removed in 1.4.0.
|
||||||
* ``filename``: the file's name
|
* ``filename``: the file's name. To be removed in 1.4.0.
|
||||||
|
|
||||||
Still available for reasons of backwards compatibility. Will be removed with 1.4.0.
|
.. _sec-events-available_events-gcode_processing:
|
||||||
|
|
||||||
GCODE processing
|
GCODE processing
|
||||||
----------------
|
----------------
|
||||||
@@ -477,6 +513,17 @@ PositionUpdate
|
|||||||
* ``t``: last tool selected *through OctoPrint*
|
* ``t``: last tool selected *through OctoPrint*
|
||||||
* ``f``: last feedrate for move commands ``G0``, ``G1`` or ``G28`` sent *through OctoPrint*
|
* ``f``: last feedrate for move commands ``G0``, ``G1`` or ``G28`` sent *through OctoPrint*
|
||||||
|
|
||||||
|
ToolChange
|
||||||
|
A tool change command was sent to the printer. The payload contains the former current tool index and the
|
||||||
|
new current tool index.
|
||||||
|
|
||||||
|
Payload:
|
||||||
|
|
||||||
|
* ``old``: old tool index
|
||||||
|
* ``new``: new tool index
|
||||||
|
|
||||||
|
.. _sec-events-available_events-timelapses:
|
||||||
|
|
||||||
Timelapses
|
Timelapses
|
||||||
----------
|
----------
|
||||||
|
|
||||||
@@ -531,6 +578,8 @@ MovieFailed
|
|||||||
returned a non-0 return code, ``no_frames`` if no frames were captured that could be rendered
|
returned a non-0 return code, ``no_frames`` if no frames were captured that could be rendered
|
||||||
to a timelapse, or ``unknown`` for any other reason of failure to render.
|
to a timelapse, or ``unknown`` for any other reason of failure to render.
|
||||||
|
|
||||||
|
.. _sec-events-available_events-slicing:
|
||||||
|
|
||||||
Slicing
|
Slicing
|
||||||
-------
|
-------
|
||||||
|
|
||||||
@@ -602,8 +651,13 @@ SlicingProfileDeleted
|
|||||||
* ``slicer``: the slicer for which the profile was deleted
|
* ``slicer``: the slicer for which the profile was deleted
|
||||||
* ``profile``: the profile that was deleted
|
* ``profile``: the profile that was deleted
|
||||||
|
|
||||||
|
.. _sec-events-available_events-settings:
|
||||||
|
|
||||||
Settings
|
Settings
|
||||||
--------
|
--------
|
||||||
|
|
||||||
SettingsUpdated
|
SettingsUpdated
|
||||||
The internal settings were updated.
|
The settings were updated via the REST API.
|
||||||
|
|
||||||
|
This event may also be triggered if calling code of :py:class:`octoprint.settings.Settings.save` or
|
||||||
|
:py:class:`octoprint.plugin.PluginSettings.save` sets the ``trigger_event`` parameter to ``True``.
|
||||||
@@ -21,17 +21,23 @@ Commands, which are admin-only.
|
|||||||
|
|
||||||
If Access Control is disabled, everything is directly accessible. **That also
|
If Access Control is disabled, everything is directly accessible. **That also
|
||||||
includes all administrative functionality as well as full control over the
|
includes all administrative functionality as well as full control over the
|
||||||
printer!**
|
printer**, and without the need for an :ref:`API key <sec-api-general-authorization>`!
|
||||||
|
|
||||||
Upon first start a configuration wizard is provided which allows configuration
|
Upon first start a configuration wizard is provided which allows configuration
|
||||||
of the first administrator account or alternatively disabling Access Control
|
of the first administrator account or alternatively disabling Access Control
|
||||||
(which is **NOT** recommended for systems that are directly accessible via the
|
(which is **NOT** recommended for systems that are directly accessible via the
|
||||||
Internet!).
|
internet or other untrusted networks!).
|
||||||
|
|
||||||
.. hint::
|
.. hint::
|
||||||
|
|
||||||
If you plan to have your OctoPrint instance accessible over the internet,
|
If you plan to have your OctoPrint instance accessible over the internet,
|
||||||
**always enable Access Control**.
|
**always enable Access Control** and ideally **don't make it accessible to
|
||||||
|
everyone over the internet but instead use a VPN** or at the very least
|
||||||
|
HTTP basic authentication on a layer above OctoPrint.
|
||||||
|
|
||||||
|
A physical device that includes heaters and stepper motors really should not be
|
||||||
|
publicly reachable by everyone with an internet connection, even with access
|
||||||
|
control enabled.
|
||||||
|
|
||||||
.. _sec-features-access_control-rerunning_wizard:
|
.. _sec-features-access_control-rerunning_wizard:
|
||||||
|
|
||||||
@@ -39,7 +45,7 @@ Rerunning the wizard
|
|||||||
--------------------
|
--------------------
|
||||||
|
|
||||||
In case Access Control was disabled in the configuration wizard, it is
|
In case Access Control was disabled in the configuration wizard, it is
|
||||||
possibly to re-run it by editing ``config.yaml`` [#f1]_ and setting ``firstRun``
|
possible to re-run it by editing ``config.yaml`` [#f1]_ and setting ``firstRun``
|
||||||
in the ``server`` section and ``enabled`` in the ``accessControl`` section to
|
in the ``server`` section and ``enabled`` in the ``accessControl`` section to
|
||||||
``true``:
|
``true``:
|
||||||
|
|
||||||
|
|||||||
@@ -21,16 +21,35 @@ Action commands are a feature defined for the GCODE based RepRap communication p
|
|||||||
|
|
||||||
OctoPrint out of the box supports handling of the above mentioned commands:
|
OctoPrint out of the box supports handling of the above mentioned commands:
|
||||||
|
|
||||||
|
cancel
|
||||||
|
When this command is received from the printer, OctoPrint will cancel a current print job like if the
|
||||||
|
"Cancel" button had been clicked.
|
||||||
|
|
||||||
pause
|
pause
|
||||||
When this command is received from the printer, OctoPrint will pause streaming of a current print job just like if the
|
When this command is received from the printer, OctoPrint will pause a current print job just like if the
|
||||||
"Pause" button had been clicked.
|
"Pause" button had been clicked.
|
||||||
|
|
||||||
|
paused
|
||||||
|
When this command is received from the printer, OctoPrint will pause a current print job but *without* triggering
|
||||||
|
any GCODE scripts or sending SD print control commands to the printer. This might be interesting for firmware
|
||||||
|
that wants to signal to OctoPrint that a print should be paused but without any control interference from
|
||||||
|
OctoPrint, e.g. in case of a filament change fully managed by the firmware.
|
||||||
|
|
||||||
resume
|
resume
|
||||||
When this command is received from the printer, OctoPrint will resume streaming of a current print job just like if
|
When this command is received from the printer, OctoPrint will resume a current print job just like if
|
||||||
the "Resume" button had been clicked.
|
the "Resume" button had been clicked.
|
||||||
|
|
||||||
|
resumed
|
||||||
|
When this command is received from the printer, OctoPrint will resume a current print job but *without* triggering
|
||||||
|
any GCODE scripts or sending SD print control commands to the printer. This might be interesting for firmware
|
||||||
|
that wants to signal to OctoPrint that a print should be resumed but without any control interference from
|
||||||
|
OctoPrint, e.g. in case of a filament change fully managed by the firmware.
|
||||||
|
|
||||||
disconnect
|
disconnect
|
||||||
When this command is Received from the printer, OctoPrint will immediately disconnect from it.
|
When this command is received from the printer, OctoPrint will immediately disconnect from it.
|
||||||
|
|
||||||
|
If the bundled :ref:`Action Command Prompt Support Plugin <sec-bundledplugins-action_command_prompt>` is enabled (which
|
||||||
|
should be the case by default), OctoPrint will also interactive dialog creation through its :ref:`supported commands <sec-bundledplugins-action_command_prompt-action_commands>`.
|
||||||
|
|
||||||
Support for additional commands may be added by plugins by implementing a handler for the
|
Support for additional commands may be added by plugins by implementing a handler for the
|
||||||
:ref:`octoprint.comm.protocol.action <sec-plugins-hook-comm-protocol-action>` hook.
|
:ref:`octoprint.comm.protocol.action <sec-plugins-hook-comm-protocol-action>` hook.
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
.. _sec-features-atcommands:
|
||||||
|
|
||||||
|
@ Commands
|
||||||
|
==========
|
||||||
|
|
||||||
|
@ commands (also known as host commands elsewhere) are special commands you may include in GCODE files streamed
|
||||||
|
through OctoPrint to your printer or send as part of GCODE scripts, through the Terminal Tab, the API or plugins.
|
||||||
|
Contrary to other commands they will never be sent to the printer but instead trigger functions inside OctoPrint.
|
||||||
|
|
||||||
|
They are always of the form ``@<command>[ <parameters>]``, e.g. ``@pause`` or ``@custom_command with some parameters``.
|
||||||
|
|
||||||
|
Out of the box OctoPrint supports handling of these commands starting with version 1.3.7:
|
||||||
|
|
||||||
|
@cancel
|
||||||
|
OctoPrint will cancel the current print job like if the "Cancel" button had been clicked. This command doesn't
|
||||||
|
take any parameters.
|
||||||
|
|
||||||
|
@abort
|
||||||
|
Same as ``cancel``.
|
||||||
|
|
||||||
|
@pause
|
||||||
|
OctoPrint will pause the current print job just like if the "Pause" button had been clicked. This command doesn't
|
||||||
|
take any parameters.
|
||||||
|
|
||||||
|
@resume
|
||||||
|
OctoPrint will resume the current print job just like if the "Resume" button had been clicked. This command doesn't
|
||||||
|
take any parameters.
|
||||||
|
|
||||||
|
Support for additional commands may be added by plugins by implementing a handler for one of the
|
||||||
|
:ref:`octoprint.comm.protocol.atcommand <sec-plugins-hook-comm-protocol-atcommand-phase>` hooks.
|
||||||
@@ -166,6 +166,10 @@ Controls
|
|||||||
clicked. This allows to override the direct sending of the command or commands to the printer with more
|
clicked. This allows to override the direct sending of the command or commands to the printer with more
|
||||||
sophisticated behaviour. The JavaScript snippet is ``eval``'d and processed in a context where the control
|
sophisticated behaviour. The JavaScript snippet is ``eval``'d and processed in a context where the control
|
||||||
it is part of is provided as local variable ``data`` and the ``ControlViewModel`` is available as ``self``.
|
it is part of is provided as local variable ``data`` and the ``ControlViewModel`` is available as ``self``.
|
||||||
|
* - ``additionalClasses``
|
||||||
|
- (Optional) Additional classes to apply to the button of a ``command``, ``commands``, ``script`` or ``javascript``
|
||||||
|
control, other than the default ``btn``. Can be used to visually style the button, e.g. set to ``btn-danger`` to
|
||||||
|
turn the button red.
|
||||||
* - ``enabled``
|
* - ``enabled``
|
||||||
- (Optional) A JavaScript snippet returning either ``true`` or ``false`` determining whether the control
|
- (Optional) A JavaScript snippet returning either ``true`` or ``false`` determining whether the control
|
||||||
should be enabled or not. This allow to override the default logic for this (disabled if printer is offline
|
should be enabled or not. This allow to override the default logic for this (disabled if printer is offline
|
||||||
|
|||||||
@@ -66,27 +66,44 @@ Context
|
|||||||
|
|
||||||
All GCODE scripts have access to the following template variables through the template context:
|
All GCODE scripts have access to the following template variables through the template context:
|
||||||
|
|
||||||
* ``printer_profile``: The currently selected Printer Profile, including
|
* ``printer_profile``: The currently selected :ref:`Printer Profile <sec-modules-printer-profile>`, including
|
||||||
information such as the extruder count, the build volume size, the filament diameter etc.
|
information such as the extruder count, the build volume size, the filament diameter etc.
|
||||||
* ``last_position``: Last position reported by the printer via `M114` (might be unset if no `M114` was sent so far!)
|
* ``last_position``: Last position reported by the printer via `M114` (might be unset if no `M114` was sent so far!).
|
||||||
|
Consists of ``x``, ``y``, ``z`` and ``e`` coordinates as received by the printer and tracked values for ``f`` and
|
||||||
|
current tool ``t`` taken from commands sent through OctoPrint. All of these coordinates might be ``None`` if no
|
||||||
|
position could be retrieved from the printer or the values could not be tracked (in case of ``f`` and ``t``)!
|
||||||
|
* ``last_temperature``: Last actual and target temperature reported for all available tools and if available the
|
||||||
|
heated bed. This is a dictionary of key-value pairs. The keys are the indices of the available tools (``0``, ``1``,
|
||||||
|
...) and ``b`` for the heated bed. The values are a dictionary consisting of ``actual`` and ``target`` keys mapped
|
||||||
|
to the corresponding temperature in degrees Celsius. Note that not all tools your printer has must necessarily be
|
||||||
|
present here, neither must the heated bed - it depends on whether OctoPrint has values for a tool or the bed. Also
|
||||||
|
note that ``actual`` and ``target`` might be ``None``.
|
||||||
* ``script``: An object wrapping the script's type (``gcode``) and name (e.g. ``afterPrintCancelled``) as ``script.type``
|
* ``script``: An object wrapping the script's type (``gcode``) and name (e.g. ``afterPrintCancelled``) as ``script.type``
|
||||||
and ``script.name`` respectively.
|
and ``script.name`` respectively.
|
||||||
|
* ``plugins``: An object containing variables provided by plugins (e.g ``plugins.myplugin.myvariable``)
|
||||||
|
|
||||||
There are a few additional template variables available for the following specific scripts:
|
There are a few additional template variables available for the following specific scripts:
|
||||||
|
|
||||||
* ``afterPrintPaused`` and ``beforePrintResumed``
|
* ``afterPrintPaused`` and ``beforePrintResumed``
|
||||||
|
|
||||||
* ``pause_position``: Position reported by the printer via ``M114`` immediately before the print was paused. Consists
|
* ``pause_position``: Position reported by the printer via ``M114`` immediately before the print was paused. See
|
||||||
of ``x``, ``y``, ``z`` and ``e`` coordinates as received by the printer and tracked values for ``f`` and current tool
|
``last_position`` above for the structure to expect here.
|
||||||
``t`` taken from commands sent through OctoPrint. All of these coordinates might be ``None`` if no position could be
|
|
||||||
retrieved from the printer or the values could not be tracked (in case of ``f`` and ``t``)!
|
**Please note:** This will not be available if you disable
|
||||||
|
"Log position on pause" under Settings > Serial > Advanced options!
|
||||||
|
* ``pause_temperature``: Last known temperature values when the print was paused. See ``last_temperature`` above
|
||||||
|
for the structure to expect here.
|
||||||
|
|
||||||
* ``afterPrintCancelled``
|
* ``afterPrintCancelled``
|
||||||
|
|
||||||
* ``cancel_position``: Position reported by the printer via ``M114`` immediately before the print was cancelled.
|
* ``cancel_position``: Position reported by the printer via ``M114`` immediately before the print was cancelled.
|
||||||
Consists of ``x``, ``y``, ``z`` and ``e`` coordinates as received by the printer and tracked values for ``f`` and
|
See ``last_position`` above for the structure to expect here.
|
||||||
current tool ``t`` taken from commands sent through OctoPrint. All of these coordinates might be ``None`` if no
|
|
||||||
position could be retrieved from the printer or the values could not be tracked (in case of ``f`` and ``t``)!
|
**Please note:** This will not be available if you disable
|
||||||
|
"Log position on cancel" under Settings > Serial > Advanced options!
|
||||||
|
* ``cancel_temperature``: Last known temperature values when the print was cancelled. See ``last_temperature`` above
|
||||||
|
for the structure to expect here.
|
||||||
|
|
||||||
|
|
||||||
.. warning::
|
.. warning::
|
||||||
|
|
||||||
@@ -130,7 +147,7 @@ Out of the box, OctoPrint defaults to the following script setup for ``afterPrin
|
|||||||
|
|
||||||
;disable all heaters
|
;disable all heaters
|
||||||
{% snippet 'disable_hotends' %}
|
{% snippet 'disable_hotends' %}
|
||||||
[% snippet 'disable_bed' %}
|
{% snippet 'disable_bed' %}
|
||||||
|
|
||||||
;disable fan
|
;disable fan
|
||||||
M106 S0
|
M106 S0
|
||||||
@@ -140,9 +157,13 @@ The ``disable_hotends`` snippet is defined as follows:
|
|||||||
.. code-block:: jinja
|
.. code-block:: jinja
|
||||||
:caption: Default ``disable_hotends`` snippet
|
:caption: Default ``disable_hotends`` snippet
|
||||||
|
|
||||||
|
{% if printer_profile.extruder.sharedNozzle %}
|
||||||
|
M104 T0 S0
|
||||||
|
{% else %}
|
||||||
{% for tool in range(printer_profile.extruder.count) %}
|
{% for tool in range(printer_profile.extruder.count) %}
|
||||||
M104 T{{ tool }} S0
|
M104 T{{ tool }} S0
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
The ``disable_bed`` snippet is defined as follows:
|
The ``disable_bed`` snippet is defined as follows:
|
||||||
|
|
||||||
@@ -158,6 +179,75 @@ As you can see, the ``disable_hotends`` and ``disable_bed`` snippets utilize the
|
|||||||
extruders and set their temperature to 0, and to also set the bed temperature
|
extruders and set their temperature to 0, and to also set the bed temperature
|
||||||
to 0 if a heated bed is configured.
|
to 0 if a heated bed is configured.
|
||||||
|
|
||||||
|
.. _sec-features-gcode_scripts-examples:
|
||||||
|
|
||||||
|
Examples
|
||||||
|
--------
|
||||||
|
|
||||||
|
.. _sec-features-gcode_scripts-examples-more_nifty_pause_and_resume:
|
||||||
|
|
||||||
|
More nifty pause and resume
|
||||||
|
...........................
|
||||||
|
|
||||||
|
If you do not have a multi-extruder setup, aren't printing from SD and have "Log position on pause" enabled under
|
||||||
|
Settings > Serial > Advanced options, the following ``afterPrintPaused`` and
|
||||||
|
``beforePrintResumed`` scripts might be interesting for you. With something like them in place, OctoPrint will move your print head
|
||||||
|
out of the way to a safe rest position (here ``G1 X0 Y0``, you might want to adjust that) on pause and move it back
|
||||||
|
to the persisted pause position on resume, making sure to also reset the extruder and feedrate.
|
||||||
|
|
||||||
|
.. code-block:: jinja
|
||||||
|
:caption: ``afterPrintPaused`` script
|
||||||
|
|
||||||
|
{% if pause_position.x is not none %}
|
||||||
|
; relative XYZE
|
||||||
|
G91
|
||||||
|
M83
|
||||||
|
|
||||||
|
; retract filament, move Z slightly upwards
|
||||||
|
G1 Z+5 E-5 F4500
|
||||||
|
|
||||||
|
; absolute XYZE
|
||||||
|
M82
|
||||||
|
G90
|
||||||
|
|
||||||
|
; move to a safe rest position, adjust as necessary
|
||||||
|
G1 X0 Y0
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
.. code-block:: jinja
|
||||||
|
:caption: ``beforePrintResumed`` script
|
||||||
|
|
||||||
|
{% if pause_position.x is not none %}
|
||||||
|
; relative extruder
|
||||||
|
M83
|
||||||
|
|
||||||
|
; prime nozzle
|
||||||
|
G1 E-5 F4500
|
||||||
|
G1 E5 F4500
|
||||||
|
G1 E5 F4500
|
||||||
|
|
||||||
|
; absolute E
|
||||||
|
M82
|
||||||
|
|
||||||
|
; absolute XYZ
|
||||||
|
G90
|
||||||
|
|
||||||
|
; reset E
|
||||||
|
G92 E{{ pause_position.e }}
|
||||||
|
|
||||||
|
; move back to pause position XYZ
|
||||||
|
G1 X{{ pause_position.x }} Y{{ pause_position.y }} Z{{ pause_position.z }} F4500
|
||||||
|
|
||||||
|
; reset to feed rate before pause if available
|
||||||
|
{% if pause_position.f is not none %}G1 F{{ pause_position.f }}{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
As mentioned in the warning above and the description of the example itself, this will *only* work if you are
|
||||||
|
not printing from SD and not using multiple extruders since OctoPrint will only then be able to track the
|
||||||
|
necessary position data and print parameters due to firmware limitations.
|
||||||
|
|
||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
`Jinja Template Designer Documentation <http://jinja.octoprint.org/templates.html>`_
|
`Jinja Template Designer Documentation <http://jinja.octoprint.org/templates.html>`_
|
||||||
|
|||||||
@@ -15,5 +15,6 @@ Features
|
|||||||
custom_controls.rst
|
custom_controls.rst
|
||||||
gcode_scripts.rst
|
gcode_scripts.rst
|
||||||
action_commands.rst
|
action_commands.rst
|
||||||
|
atcommands.rst
|
||||||
plugins.rst
|
plugins.rst
|
||||||
safemode.rst
|
safemode.rst
|
||||||
@@ -46,7 +46,7 @@ Manual Installation
|
|||||||
|
|
||||||
If you don't want or can't use the Plugin Manager, plugins may also be installed manually either by copying and
|
If you don't want or can't use the Plugin Manager, plugins may also be installed manually either by copying and
|
||||||
unpacking them into one of the configured plugin folders (regularly those are ``<octoprint source root>/plugins`` and
|
unpacking them into one of the configured plugin folders (regularly those are ``<octoprint source root>/plugins`` and
|
||||||
``<octoprint config folder>/plugins`` [#f1]_ or by installing them as regular python modules via ``pip`` [#f2]_.
|
``<octoprint config folder>/plugins`` [#f1]_ or by installing them as regular Python modules via ``pip`` [#f2]_.
|
||||||
|
|
||||||
For a plugin available on the Python Package Index (PyPi), the process is as simple as issuing a
|
For a plugin available on the Python Package Index (PyPi), the process is as simple as issuing a
|
||||||
|
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ Additionally, OctoPrint allows uninstalling plugins in this mode, allowing recov
|
|||||||
a third party plugin causes the server to not start up or the web interface to not render or function
|
a third party plugin causes the server to not start up or the web interface to not render or function
|
||||||
correctly anymore.
|
correctly anymore.
|
||||||
|
|
||||||
|
Whenever reporting an issue with OctoPrint, please always attempt to reproduce it in safe mode as well to
|
||||||
|
ensure it really is an issue in OctoPrint itself and now caused by one of your installed third party plugins.
|
||||||
|
|
||||||
.. _sec-features-safemode-how:
|
.. _sec-features-safemode-how:
|
||||||
|
|
||||||
How to start OctoPrint in safe mode
|
How to start OctoPrint in safe mode
|
||||||
@@ -23,15 +26,37 @@ How to start OctoPrint in safe mode
|
|||||||
|
|
||||||
There exist three ways to start OctoPrint in safe mode:
|
There exist three ways to start OctoPrint in safe mode:
|
||||||
|
|
||||||
* since OctoPrint 1.3.2: by selecting "Restart OctoPrint in safe mode" from the "System" menu,
|
* by selecting "Restart OctoPrint in safe mode" from the "System" menu,
|
||||||
if the "Restart OctoPrint" server command has been correctly configured (see :numref:`fig-features-safemode-systemmenu`).
|
if the "Restart OctoPrint" server command has been correctly configured (since OctoPrint 1.3.2,
|
||||||
* by starting OctoPrint with the command line parameter ``--safe``, e.g. ``octoprint serve --safe``
|
see :numref:`fig-features-safemode-systemmenu`)
|
||||||
* by setting the option ``server.startOnceInSafeMode`` in :ref:`config.yaml <sec-configuration-config_yaml>`
|
* by setting the flag ``server.startOnceInSafeMode`` in :ref:`config.yaml <sec-configuration-config_yaml>`
|
||||||
to ``true`` and restarting
|
to ``true`` and restarting. To set this flag you have the following options:
|
||||||
|
|
||||||
|
* from command line run ``octoprint safemode`` (since OctoPrint 1.3.6)
|
||||||
|
* from command line run ``octoprint config set --bool server.startOnceInSafeMode true`` (fixed in OctoPrint 1.3.6)
|
||||||
|
* use the `Yamlpatcher Plugin <http://plugins.octoprint.org/plugins/yamlpatcher/>`_ and enter & apply the patch
|
||||||
|
``[["set", "server.startOnceInSafeMode", true]]``
|
||||||
|
* edit ``config.yaml`` manually with a text editor, locate the ``server`` block if it already exists or create it
|
||||||
|
if it doesn't and add ``startOnceInSafeMode: true`` to it:
|
||||||
|
|
||||||
|
.. code-block:: yaml
|
||||||
|
|
||||||
|
# ...
|
||||||
|
server:
|
||||||
|
startOnceInSafeMode: true
|
||||||
|
# ...
|
||||||
|
|
||||||
|
Please also refer to the :ref:`YAML primer <sec-configuration-yaml>`.
|
||||||
|
* by starting OctoPrint with the command line parameter ``--safe``, e.g. ``octoprint serve --safe`` (don't forget to
|
||||||
|
shutdown OctoPrint first before doing this)
|
||||||
|
|
||||||
The last two options will have OctoPrint enable safe mode only for the next server start - once you
|
The last two options will have OctoPrint enable safe mode only for the next server start - once you
|
||||||
restart OctoPrint again, safe mode will be disabled again.
|
restart OctoPrint again, safe mode will be disabled again.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
**OctoPi users**: For you that's ``~/oprint/bin/octoprint`` wherever it says just ``octoprint``.
|
||||||
|
|
||||||
.. _fig-features-safemode-systemmenu:
|
.. _fig-features-safemode-systemmenu:
|
||||||
.. figure:: ../images/features-safemode-systemmenu.png
|
.. figure:: ../images/features-safemode-systemmenu.png
|
||||||
:align: center
|
:align: center
|
||||||
|
|||||||
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 73 KiB |
|
After Width: | Height: | Size: 62 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 45 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
After Width: | Height: | Size: 66 KiB |
|
After Width: | Height: | Size: 9.6 KiB |
|
After Width: | Height: | Size: 68 KiB |
|
After Width: | Height: | Size: 6.5 KiB |
|
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 24 KiB |
@@ -6,9 +6,24 @@ Welcome to OctoPrint's documentation!
|
|||||||
:alt: The OctoPrint Logo
|
:alt: The OctoPrint Logo
|
||||||
:align: right
|
:align: right
|
||||||
|
|
||||||
This documentation is still in the process of being migrated from
|
OctoPrint provides a snappy web interface for controlling consumer 3D printers. It is Free Software
|
||||||
`OctoPrint's wiki <https://github.com/foosel/OctoPrint/wiki>`_, so also take
|
and released under the `GNU Affero General Public License V3 <http://www.gnu.org/licenses/agpl.html>`_.
|
||||||
a look there!
|
|
||||||
|
Its website can be found at `octoprint.org <https://octoprint.org/>`_.
|
||||||
|
|
||||||
|
The community forum is available at `community.octoprint.org <https://community.octoprint.org/>`_.
|
||||||
|
|
||||||
|
The FAQ can be accessed by following `faq.octoprint.org <https://faq.octoprint.org/>`_.
|
||||||
|
|
||||||
|
The official plugin repository can be reached at `plugins.octoprint.org <https://plugins.octoprint.org/>`_.
|
||||||
|
|
||||||
|
OctoPrint's development wouldn't be possible without the `financial support by its community <https://octoprint.org/support-octoprint/>`_.
|
||||||
|
If you enjoy OctoPrint, please consider becoming a regular supporter!
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
This documentation currently focuses primarily on developers and less on end users. If you are interested in
|
||||||
|
helping to change this, please get in touch `on the forum <https://community.octoprint.org/>`_!
|
||||||
|
|
||||||
Contents
|
Contents
|
||||||
========
|
========
|
||||||
|
|||||||
@@ -119,7 +119,7 @@
|
|||||||
:param string method: The HTTP method to use for the request (optional)
|
:param string method: The HTTP method to use for the request (optional)
|
||||||
:param string url: The URL to perform the request against (optional)
|
:param string url: The URL to perform the request against (optional)
|
||||||
:param object data: The data to send in the request body (optional)
|
:param object data: The data to send in the request body (optional)
|
||||||
:param object opts: Additonal options to use for the request (optional)
|
:param object opts: Additional options to use for the request (optional)
|
||||||
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.get(url, opts)
|
.. js:function:: OctoPrintClient.get(url, opts)
|
||||||
@@ -417,7 +417,7 @@
|
|||||||
|
|
||||||
Creates a custom exception class. ``name`` may be either a function in which case it will be used
|
Creates a custom exception class. ``name`` may be either a function in which case it will be used
|
||||||
as constructor for the new exception class, or a string, in which case a constructor with proper
|
as constructor for the new exception class, or a string, in which case a constructor with proper
|
||||||
``name``, ``message`` and ``stack`` attributes will be created. The class hierarchy will be propery
|
``name``, ``message`` and ``stack`` attributes will be created. The class hierarchy will be properly
|
||||||
setup to subclass ``Error``.
|
setup to subclass ``Error``.
|
||||||
|
|
||||||
**Example:**
|
**Example:**
|
||||||
|
|||||||
@@ -189,7 +189,7 @@
|
|||||||
A boolean value, specifies whether to immediately start printing the file after the upload
|
A boolean value, specifies whether to immediately start printing the file after the upload
|
||||||
completes (true) or not (false, default)
|
completes (true) or not (false, default)
|
||||||
userdata
|
userdata
|
||||||
An optional object or a serialized JSON string of additional user supplised data to associate with
|
An optional object or a serialized JSON string of additional user supplied data to associate with
|
||||||
the uploaded file.
|
the uploaded file.
|
||||||
|
|
||||||
See :ref:`Upload file or create folder <sec-api-fileops-uploadfile>` for more details on the file upload API and
|
See :ref:`Upload file or create folder <sec-api-fileops-uploadfile>` for more details on the file upload API and
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ If you are using it from a web page hosted on OctoPrint as a Jinja2 template, yo
|
|||||||
methods to embed it instead of manually entering the URL, in order to have OctoPrint take care of setting the
|
methods to embed it instead of manually entering the URL, in order to have OctoPrint take care of setting the
|
||||||
correct URL prefix:
|
correct URL prefix:
|
||||||
|
|
||||||
.. code-block:: html
|
.. code-block:: html+jinja
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
full client library or all individual files, depending
|
full client library or all individual files, depending
|
||||||
@@ -32,10 +32,10 @@ correct URL prefix:
|
|||||||
-->
|
-->
|
||||||
<script type="text/javascript" src="{{ url_for("static", filename="js/app/client/<component>.js") }}"></script>
|
<script type="text/javascript" src="{{ url_for("static", filename="js/app/client/<component>.js") }}"></script>
|
||||||
|
|
||||||
Regardless of which way you use to include the library, you'll also need to make sure you included JQuery and lodash,
|
Regardless of which way you use to include the library, you'll also need to make sure you included jQuery and lodash,
|
||||||
because the library depends on those to be available (as ``$`` and ``_``). You can embed those like this:
|
because the library depends on those to be available (as ``$`` and ``_``). You can embed those like this:
|
||||||
|
|
||||||
.. code-block:: html
|
.. code-block:: html+jinja
|
||||||
|
|
||||||
<script src="{{ url_for("static", filename="js/lib/jquery/jquery.min.js") }}"></script>
|
<script src="{{ url_for("static", filename="js/lib/jquery/jquery.min.js") }}"></script>
|
||||||
<script src="{{ url_for("static", filename="js/lib/lodash.min.js") }}"></script>
|
<script src="{{ url_for("static", filename="js/lib/lodash.min.js") }}"></script>
|
||||||
@@ -45,7 +45,7 @@ number of components, make sure to at the very least include that one to be able
|
|||||||
|
|
||||||
When you import the client library as described above, a global variable ``OctoPrint`` will become available, which is
|
When you import the client library as described above, a global variable ``OctoPrint`` will become available, which is
|
||||||
a prepared instance of the ``OctoPrintClient`` class the library assembles from registered components. You can directly
|
a prepared instance of the ``OctoPrintClient`` class the library assembles from registered components. You can directly
|
||||||
used that singular ``OctoPrint`` instance if you only need to talk to one OctoPrint server:
|
use that singular ``OctoPrint`` instance if you only need to talk to one OctoPrint server:
|
||||||
|
|
||||||
.. code-block:: javascript
|
.. code-block:: javascript
|
||||||
|
|
||||||
@@ -80,9 +80,13 @@ connection options (``baseurl`` and ``apikey``) directly in the constructor or s
|
|||||||
|
|
||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
`OctoPrint-ForceLogin <https://github.com/OctoPrint/OctoPrint-ForceLogin>`_
|
:ref:`Application Key Plugin <sec-bundledplugins-appkeys>`
|
||||||
A plugin that disables anonymous access to the regular OctoPrint UI by implementing a custom UI. Utilizes the
|
A bundled plugin that implements an authorization workflow for third party clients. It adds various additional
|
||||||
client library's :ref:`browser component <sec-jsclientlib-browser>` to login the user.
|
methods to the JS Client Library.
|
||||||
|
:ref:`ForceLogin Plugin <sec-bundledplugins-forcelogin>`
|
||||||
|
A bundled plugin that disables anonymous access to the regular OctoPrint UI by implementing a custom UI and
|
||||||
|
various hooks. Utilizes the client library's :ref:`browser component <sec-jsclientlib-browser>` to login the
|
||||||
|
user.
|
||||||
|
|
||||||
.. toctree::
|
.. toctree::
|
||||||
:maxdepth: 3
|
:maxdepth: 3
|
||||||
|
|||||||
@@ -64,7 +64,7 @@
|
|||||||
|
|
||||||
.. js:function:: OctoPrintClient.job.resume(opts)
|
.. js:function:: OctoPrintClient.job.resume(opts)
|
||||||
|
|
||||||
Resumes the current job if it's currently pause, does nothing if it's running.
|
Resumes the current job if it's currently paused, does nothing if it's running.
|
||||||
|
|
||||||
See :ref:`Issue a job command <sec-api-jobs-command>` for details.
|
See :ref:`Issue a job command <sec-api-jobs-command>` for details.
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
All methods here require that the used API token or a the existing browser session
|
All methods here require that the used API token or the existing browser session
|
||||||
has admin rights.
|
has admin rights.
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.languages.list(opts)
|
.. js:function:: OctoPrintClient.languages.list(opts)
|
||||||
|
|||||||
@@ -3,37 +3,9 @@
|
|||||||
:mod:`OctoPrintClient.logs`
|
:mod:`OctoPrintClient.logs`
|
||||||
---------------------------
|
---------------------------
|
||||||
|
|
||||||
.. note::
|
Log file management (and logging configuration) was moved into a bundled plugin in OctoPrint 1.3.7. Refer to
|
||||||
|
:ref:`the Logging's plugins JS Client Library <sec-bundledplugins-logging-jsclientlib>` for the JS Client documentation.
|
||||||
All methods here require that the used API token or a the existing browser session
|
|
||||||
has admin rights.
|
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.logs.list(opts)
|
|
||||||
|
|
||||||
Retrieves a list of log files.
|
|
||||||
|
|
||||||
See :ref:`Retrieve a list of available log files <sec-api-logs-list>` for details.
|
|
||||||
|
|
||||||
:param object opts: Additional options for the request
|
|
||||||
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.logs.delete(path, opts)
|
|
||||||
|
|
||||||
Deletes the specified log ``path``.
|
|
||||||
|
|
||||||
See :ref:`Delete a specific log file <sec-api-logs-delete>` for details.
|
|
||||||
|
|
||||||
:param string path: The path to the log file to delete
|
|
||||||
:param object opts: Additional options for the request
|
|
||||||
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.logs.download(path, opts)
|
|
||||||
|
|
||||||
Downloads the specified log ``file``.
|
|
||||||
|
|
||||||
See :js:func:`OctoPrint.download` for more details on the underlying library download mechanism.
|
|
||||||
|
|
||||||
:param string path: The path to the log file to download
|
|
||||||
:param object opts: Additional options for the request
|
|
||||||
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
|
||||||
|
|
||||||
|
The former module ``OctoPrintClient.logs`` and its methods are marked as deprecated but still work for now. New
|
||||||
|
client implementations should directly use the new module provided by the bundled plugin. Existing implementations
|
||||||
|
should adapt their used module as soon as possible.
|
||||||
@@ -174,7 +174,7 @@
|
|||||||
|
|
||||||
Sets the given temperature on the printer's heated bed (if available).
|
Sets the given temperature on the printer's heated bed (if available).
|
||||||
|
|
||||||
``target`` is expected to be a the target temperature as a float value.
|
``target`` is expected to be the target temperature as a float value.
|
||||||
|
|
||||||
**Example:**
|
**Example:**
|
||||||
|
|
||||||
@@ -210,6 +210,64 @@
|
|||||||
:param object opts: Additional options for the request
|
:param object opts: Additional options for the request
|
||||||
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.printer.getChamberState(data, opts)
|
||||||
|
|
||||||
|
Retrieves the current printer chamber state/temperature information, and optionally also the temperature
|
||||||
|
history.
|
||||||
|
|
||||||
|
The ``flags`` object can be used to specify the data to retrieve further via the following
|
||||||
|
properties:
|
||||||
|
|
||||||
|
* ``history``: a boolean value to specify whether the temperature history should be included (``true``)
|
||||||
|
or not (``false``), defaults to it not being included
|
||||||
|
* ``limit``: an integer value to specify how many history entries to include
|
||||||
|
|
||||||
|
See :ref:`Retrieve the current bed state <sec-api-printer-chamberstate>` for more details.
|
||||||
|
|
||||||
|
:param object flags: Flags that further specify which data to retrieve, see above for details
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.printer.setChamberTargetTemperature(target, opts)
|
||||||
|
|
||||||
|
Sets the given temperature on the printer's heated chamber (if available).
|
||||||
|
|
||||||
|
``target`` is expected to be the target temperature as a float value.
|
||||||
|
|
||||||
|
**Example:**
|
||||||
|
|
||||||
|
Set the chamber to 50°C.
|
||||||
|
|
||||||
|
.. code-block:: javascript
|
||||||
|
|
||||||
|
OctoPrint.printer.setChamberTargetTemperature(50.0);
|
||||||
|
|
||||||
|
See the ``target`` command in :ref:`Issue a chamber command <sec-api-printer-chambercommand>` for more details.
|
||||||
|
|
||||||
|
:param float target: The target to set
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.printer.setChamberTemperatureOffset(offset, opts)
|
||||||
|
|
||||||
|
Sets the given temperature offset for the printer's heated chamber (if available).
|
||||||
|
|
||||||
|
``offset`` is expected to be the temperature offset to set.
|
||||||
|
|
||||||
|
**Example:**
|
||||||
|
|
||||||
|
Set the offset for the chamber to -5°C.
|
||||||
|
|
||||||
|
.. code-block:: javascript
|
||||||
|
|
||||||
|
OctoPrint.printer.setChamberTemperatureOffset(-5);
|
||||||
|
|
||||||
|
See the ``offset`` command in :ref:`Issue a chamber command <sec-api-printer-chambercommand>` for more details.
|
||||||
|
|
||||||
|
:param object offsets: The offsets to set
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.printer.jog(amounts, opts)
|
.. js:function:: OctoPrintClient.printer.jog(amounts, opts)
|
||||||
|
|
||||||
Jogs the specified axes by the specified ``amounts``.
|
Jogs the specified axes by the specified ``amounts``.
|
||||||
|
|||||||
@@ -85,7 +85,7 @@
|
|||||||
.. js:function:: OctoPrintClient.socket.onRateTooHigh(measured, maximum)
|
.. js:function:: OctoPrintClient.socket.onRateTooHigh(measured, maximum)
|
||||||
|
|
||||||
Called by the socket client when the last measured round trip time was higher than the
|
Called by the socket client when the last measured round trip time was higher than the
|
||||||
current upper procesisng limit, indicating that the messages are now processed slower than
|
current upper processing limit, indicating that the messages are now processed slower than
|
||||||
the current rate requires and a slower rate might be necessary.
|
the current rate requires and a slower rate might be necessary.
|
||||||
|
|
||||||
Can be overwritten with custom handler methods. The default implementation will call
|
Can be overwritten with custom handler methods. The default implementation will call
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
All methods here require that the used API token or a the existing browser session
|
All methods here require that the used API token or the existing browser session
|
||||||
has admin rights.
|
has admin rights.
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.system.getCommands(opts)
|
.. js:function:: OctoPrintClient.system.getCommands(opts)
|
||||||
@@ -35,4 +35,4 @@
|
|||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
:ref:`System API <sec-api-system>`
|
:ref:`System API <sec-api-system>`
|
||||||
Documentation of the underlying system API
|
Documentation of the underlying system API.
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
.. js:function:: OctoPrintClient.timelapse.list(opts)
|
.. js:function:: OctoPrintClient.timelapse.list(opts)
|
||||||
|
|
||||||
Get the lists of rendered and unrendered timelapses. The returned promis
|
Get the lists of rendered and unrendered timelapses. The returned promise
|
||||||
will be resolved with an object containing the properties ``rendered``
|
will be resolved with an object containing the properties ``rendered``
|
||||||
which will have the list of rendered timelapses, and ``unrendered`` which
|
which will have the list of rendered timelapses, and ``unrendered`` which
|
||||||
will have the list of unrendered timelapses.
|
will have the list of unrendered timelapses.
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
Most methods here require that the used API token or a the existing browser session
|
Most methods here require that the used API token or the existing browser session
|
||||||
has admin rights *or* corresponds to the user to be modified. Some methods
|
has admin rights *or* corresponds to the user to be modified. Some methods
|
||||||
definitely require admin rights.
|
definitely require admin rights.
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
All methods here require that the used API token or a the existing browser session
|
All methods here require that the used API token or the existing browser session
|
||||||
has admin rights.
|
has admin rights.
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.util.test(command, parameters, opts)
|
.. js:function:: OctoPrintClient.util.test(command, parameters, opts)
|
||||||
@@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
.. js:function:: OctoPrintClient.util.testPath(path, additional, opts)
|
.. js:function:: OctoPrintClient.util.testPath(path, additional, opts)
|
||||||
|
|
||||||
Test the provided ``path`` for existance. More test criteria supported by the :ref:`path test command <sec-api-util-test-path>`
|
Test the provided ``path`` for existence. More test criteria supported by the :ref:`path test command <sec-api-util-test-path>`
|
||||||
can be provided via the ``additional`` object.
|
can be provided via the ``additional`` object.
|
||||||
|
|
||||||
**Example 1**
|
**Example 1**
|
||||||
@@ -126,8 +126,16 @@
|
|||||||
.done(function(response) {
|
.done(function(response) {
|
||||||
if (response.result) {
|
if (response.result) {
|
||||||
// check passed
|
// check passed
|
||||||
|
var content = response.response.content;
|
||||||
|
var mimeType = "image/jpeg";
|
||||||
|
|
||||||
|
var headers = response.response.headers;
|
||||||
|
if (headers && headers["content-type"]) {
|
||||||
|
mimeType = headers["content-type"].split(";")[0];
|
||||||
|
}
|
||||||
|
|
||||||
var image = $("#someimage");
|
var image = $("#someimage");
|
||||||
image.
|
image.src = "data:" + mimeType + ";base64," + content;
|
||||||
} else {
|
} else {
|
||||||
// check failed
|
// check failed
|
||||||
}
|
}
|
||||||
@@ -153,7 +161,49 @@
|
|||||||
:param object opts: Additional options for the request
|
:param object opts: Additional options for the request
|
||||||
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
|
.. js:function:: OctoPrintClient.util.testServer(host, port, additional, opts)
|
||||||
|
|
||||||
|
Test if a server is reachable. More options supported by the :ref:`server test command <sec-api-util-test-server>`
|
||||||
|
can be provided via the ``additional`` object.
|
||||||
|
|
||||||
|
**Example 1**
|
||||||
|
|
||||||
|
Test if ``8.8.8.8`` is reachable on port 53 within the default timeout.
|
||||||
|
|
||||||
|
.. code-block:: javascript
|
||||||
|
|
||||||
|
OctoPrint.util.testServer("8.8.8.8", 53)
|
||||||
|
.done(function(response) {
|
||||||
|
if (response.result) {
|
||||||
|
// check passed
|
||||||
|
} else {
|
||||||
|
// check failed
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
**Example 2**
|
||||||
|
|
||||||
|
Test if ``127.0.0.1`` is reachable on port 1234 and UDP.
|
||||||
|
|
||||||
|
.. code-block:: javascript
|
||||||
|
|
||||||
|
OctoPrint.util.testUrl("127.0.0.1", 1234, {"protocol": "udp"})
|
||||||
|
.done(function(response) {
|
||||||
|
if (response.result) {
|
||||||
|
// check passed
|
||||||
|
} else {
|
||||||
|
// check failed
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
:param string url: Host to test
|
||||||
|
:param int port: Port to test
|
||||||
|
:param object additional: Additional parameters for the test command
|
||||||
|
:param object opts: Additional options for the request
|
||||||
|
:returns Promise: A `jQuery Promise <http://api.jquery.com/Types/#Promise>`_ for the request's response
|
||||||
|
|
||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
:ref:`Util API <sec-api-util>`
|
:ref:`Util API <sec-api-util>`
|
||||||
Documentation of the underlying util API
|
Documentation of the underlying util API.
|
||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
All methods here require that the used API token or a the existing browser session
|
All methods here require that the used API token or the existing browser session
|
||||||
has admin rights.
|
has admin rights.
|
||||||
|
|
||||||
.. js:function:: OctoPrintClient.wizard.get(opts)
|
.. js:function:: OctoPrintClient.wizard.get(opts)
|
||||||
|
|||||||
@@ -14,4 +14,5 @@ Internal Modules
|
|||||||
server.rst
|
server.rst
|
||||||
settings.rst
|
settings.rst
|
||||||
slicing.rst
|
slicing.rst
|
||||||
|
users.rst
|
||||||
util.rst
|
util.rst
|
||||||
@@ -4,3 +4,10 @@ octoprint.printer
|
|||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
.. automodule:: octoprint.printer
|
.. automodule:: octoprint.printer
|
||||||
|
|
||||||
|
.. _sec-modules-printer-profile:
|
||||||
|
|
||||||
|
octoprint.printer.profile
|
||||||
|
-------------------------
|
||||||
|
|
||||||
|
.. automodule:: octoprint.printer.profile
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
.. _sec-modules-users:
|
||||||
|
|
||||||
|
octoprint.access.users
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
.. automodule:: octoprint.access.users
|
||||||
|
:members:
|
||||||
|
|
||||||
|
|
||||||
@@ -6,4 +6,10 @@ octoprint.util
|
|||||||
.. automodule:: octoprint.util
|
.. automodule:: octoprint.util
|
||||||
:members:
|
:members:
|
||||||
|
|
||||||
|
.. _sec-modules-util-commandline:
|
||||||
|
|
||||||
|
octoprint.util.commandline
|
||||||
|
--------------------------
|
||||||
|
|
||||||
|
.. automodule:: octoprint.util.commandline
|
||||||
|
:members:
|
||||||
@@ -23,9 +23,9 @@ Lifecycle
|
|||||||
|
|
||||||
There are three sources of installed plugins that OctoPrint will check during start up:
|
There are three sources of installed plugins that OctoPrint will check during start up:
|
||||||
|
|
||||||
* it's own ``octoprint/plugins`` folder (this is where the bundled plugins reside),
|
* its own ``octoprint/plugins`` folder (this is where the bundled plugins reside),
|
||||||
* the ``plugins`` folder in its configuration directory (e.g. ``~/.octoprint/plugins`` on Linux),
|
* the ``plugins`` folder in its configuration directory (e.g. ``~/.octoprint/plugins`` on Linux),
|
||||||
* any python packages registered for the entry point ``octoprint.plugin``.
|
* any Python packages registered for the entry point ``octoprint.plugin``.
|
||||||
|
|
||||||
Each plugin that OctoPrint finds it will first load, then enable. On enabling a plugin, OctoPrint will
|
Each plugin that OctoPrint finds it will first load, then enable. On enabling a plugin, OctoPrint will
|
||||||
register its declared :ref:`hook handlers <sec-plugins-hooks>` and :ref:`helpers <sec-plugins-helpers>`, apply
|
register its declared :ref:`hook handlers <sec-plugins-hooks>` and :ref:`helpers <sec-plugins-helpers>`, apply
|
||||||
@@ -36,7 +36,7 @@ any :ref:`settings overlays <sec-plugins-controlproperties-plugin_settings_overl
|
|||||||
On disabling a plugin, its hook handlers, helpers, mixin implementations and settings overlays will be de-registered again.
|
On disabling a plugin, its hook handlers, helpers, mixin implementations and settings overlays will be de-registered again.
|
||||||
|
|
||||||
Some plugin types require a reload of the frontend or a restart of OctoPrint for enabling/disabling them. You
|
Some plugin types require a reload of the frontend or a restart of OctoPrint for enabling/disabling them. You
|
||||||
can recognized such plugins by their implementations implementing :class:`~octoprint.plugin.ReloadNeedingPlugin` or
|
can recognize such plugins by their implementations implementing :class:`~octoprint.plugin.ReloadNeedingPlugin` or
|
||||||
:class:`~octoprint.plugin.RestartNeedingPlugin` or providing handlers for one of the hooks marked correspondingly.
|
:class:`~octoprint.plugin.RestartNeedingPlugin` or providing handlers for one of the hooks marked correspondingly.
|
||||||
|
|
||||||
.. image:: ../images/plugins_lifecycle.png
|
.. image:: ../images/plugins_lifecycle.png
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ plugin subsystem about themselves. These are simple package attributes defined i
|
|||||||
# ...
|
# ...
|
||||||
|
|
||||||
__plugin_name__ = "My Plugin"
|
__plugin_name__ = "My Plugin"
|
||||||
|
__plugin_pythoncompat__ = ">=2.7,<4"
|
||||||
def __plugin_load__():
|
def __plugin_load__():
|
||||||
# whatever you need to do to load your plugin, if anything at all
|
# whatever you need to do to load your plugin, if anything at all
|
||||||
pass
|
pass
|
||||||
@@ -52,6 +53,20 @@ The following properties are recognized:
|
|||||||
``__plugin_license__``
|
``__plugin_license__``
|
||||||
License of your plugin, optional, overrides the license specified in ``setup.py`` if provided.
|
License of your plugin, optional, overrides the license specified in ``setup.py`` if provided.
|
||||||
|
|
||||||
|
.. _sec-plugins-controlproperties-plugin_pythoncompat:
|
||||||
|
|
||||||
|
``__plugin_pythoncompat__``
|
||||||
|
Python compatibility string of your plugin, optional, defaults to ``>=2.7,<3`` if not set and thus Python 2 but no
|
||||||
|
Python 3 compatibility.
|
||||||
|
|
||||||
|
If your plugin is compatible to Python 3, you should set this to ``>=2.7,<4``, otherwise your plugin will not load
|
||||||
|
on OctoPrint instances installed under Python 3.
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
__plugin_pythoncompat__ = ">=2.7,<4"
|
||||||
|
|
||||||
|
|
||||||
.. _sec-plugins-controlproperties-plugin_implementation:
|
.. _sec-plugins-controlproperties-plugin_implementation:
|
||||||
|
|
||||||
``__plugin_implementation__``
|
``__plugin_implementation__``
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ development environment::
|
|||||||
$ virtualenv venv
|
$ virtualenv venv
|
||||||
[...]
|
[...]
|
||||||
$ source venv/bin/activate
|
$ source venv/bin/activate
|
||||||
(venv) $ pip install -e .[develop]
|
(venv) $ pip install -e .[develop,plugins]
|
||||||
[...]
|
[...]
|
||||||
(venv) $ octoprint --help
|
(venv) $ octoprint --help
|
||||||
Usage: octoprint [OPTIONS] COMMAND [ARGS]...
|
Usage: octoprint [OPTIONS] COMMAND [ARGS]...
|
||||||
@@ -54,8 +54,8 @@ We'll start at the most basic form a plugin can take - just a few simple lines o
|
|||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
__plugin_name__ = "Hello World"
|
__plugin_name__ = "Hello World"
|
||||||
__plugin_version__ = "1.0.0"
|
__plugin_version__ = "1.0.0"
|
||||||
@@ -89,8 +89,8 @@ Apart from being discovered by OctoPrint, our plugin does nothing yet. We want t
|
|||||||
:emphasize-lines: 4-8,13
|
:emphasize-lines: 4-8,13
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -134,14 +134,15 @@ as a simple python file following the naming convention ``<plugin identifier>.py
|
|||||||
``~/.octoprint/plugins`` folder. You already know how that works. But let's say you have more than just a simple plugin
|
``~/.octoprint/plugins`` folder. You already know how that works. But let's say you have more than just a simple plugin
|
||||||
that can be done in one file. Distributing multiple files and getting your users to install them in the right way
|
that can be done in one file. Distributing multiple files and getting your users to install them in the right way
|
||||||
so that OctoPrint will be able to actually find and load them is certainly not impossible, but we want to do it in the
|
so that OctoPrint will be able to actually find and load them is certainly not impossible, but we want to do it in the
|
||||||
best way possible, meaning we want to make our plugin a fully installable python module that your users will be able to
|
best way possible, meaning we want to make our plugin a fully installable Python module that your users will be able to
|
||||||
install directly via `OctoPrint's built-in Plugin Manager <https://github.com/foosel/OctoPrint/wiki/Plugin:-Plugin-Manager>`_
|
install directly via `OctoPrint's built-in Plugin Manager <https://github.com/foosel/OctoPrint/wiki/Plugin:-Plugin-Manager>`_
|
||||||
or alternatively manually utilizing Python's standard package manager ``pip`` directly.
|
or alternatively manually utilizing Python's standard package manager ``pip`` directly.
|
||||||
|
|
||||||
So let's begin. We'll use the `cookiecutter <https://github.com/audreyr/cookiecutter>`_ template for OctoPrint plugins here,
|
So let's begin. We'll use the `cookiecutter <https://github.com/audreyr/cookiecutter>`_ template for OctoPrint plugins
|
||||||
so we'll first need to install that::
|
here. This should already be installed if you used the ``plugins`` extra while installing OctoPrint. However,
|
||||||
|
you may install it with::
|
||||||
|
|
||||||
(venv) $ pip install cookiecutter
|
(venv) $ pip install "cookiecutter>=1.4,<1.7"
|
||||||
|
|
||||||
Then we can use the ``octoprint dev plugin:new`` command [#f1]_ to generate a new OctoPrint plugin skeleton for us::
|
Then we can use the ``octoprint dev plugin:new`` command [#f1]_ to generate a new OctoPrint plugin skeleton for us::
|
||||||
|
|
||||||
@@ -281,15 +282,15 @@ of information now defined twice:
|
|||||||
plugin_version = "1.0.0"
|
plugin_version = "1.0.0"
|
||||||
plugin_description = "A quick \"Hello World\" example plugin for OctoPrint"
|
plugin_description = "A quick \"Hello World\" example plugin for OctoPrint"
|
||||||
|
|
||||||
The nice thing about our plugin now being a proper python package is that OctoPrint can and will access the metadata defined
|
The nice thing about our plugin now being a proper Python package is that OctoPrint can and will access the metadata defined
|
||||||
within ``setup.py``! So, we don't really need to define all this data twice. Remove ``__plugin_name__``, ``__plugin_version__``
|
within ``setup.py``! So, we don't really need to define all this data twice. Remove ``__plugin_name__``, ``__plugin_version__``
|
||||||
and ``__plugin_description__`` from ``__init__.py``:
|
and ``__plugin_description__`` from ``__init__.py``:
|
||||||
|
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -313,8 +314,8 @@ Our "Hello World" Plugin still gets detected fine, but it's now listed under the
|
|||||||
:emphasize-lines: 10
|
:emphasize-lines: 10
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -361,8 +362,8 @@ add the :class:`TemplatePlugin` to our ``HelloWorldPlugin`` class:
|
|||||||
:emphasize-lines: 7
|
:emphasize-lines: 7
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -409,8 +410,8 @@ Now look at that!
|
|||||||
Settings Galore: How to make parts of your plugin user adjustable
|
Settings Galore: How to make parts of your plugin user adjustable
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
|
|
||||||
Remember that Wikipedia link we added to our little link in the navigation bar? It links to the english Wikipedia. But
|
Remember that Wikipedia link we added to our little link in the navigation bar? It links to the English Wikipedia. But
|
||||||
what if we want to allow our users to adjust that according to their wishes, e.g. to link to the german language node
|
what if we want to allow our users to adjust that according to their wishes, e.g. to link to the German language node
|
||||||
about "Hello World" programs instead?
|
about "Hello World" programs instead?
|
||||||
|
|
||||||
To allow your users to customized the behaviour of your plugin you'll need to implement the :class:`~octoprint.plugin.SettingsPlugin`
|
To allow your users to customized the behaviour of your plugin you'll need to implement the :class:`~octoprint.plugin.SettingsPlugin`
|
||||||
@@ -427,8 +428,8 @@ Let's take a look at how all that would look in our plugin's ``__init__.py``:
|
|||||||
:emphasize-lines: 8, 10, 12-13
|
:emphasize-lines: 8, 10, 12-13
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -461,8 +462,8 @@ Adjust your plugin's ``__init__.py`` like this:
|
|||||||
:emphasize-lines: 15-16
|
:emphasize-lines: 15-16
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -508,7 +509,7 @@ section doesn't yet exist in the file, create it):
|
|||||||
# [...]
|
# [...]
|
||||||
|
|
||||||
Restart OctoPrint. Not only should the URL displayed in the log file have changed, but also the link should now (after
|
Restart OctoPrint. Not only should the URL displayed in the log file have changed, but also the link should now (after
|
||||||
a proper shift-reload) point to the german Wikipedia node about "Hello World" programs::
|
a proper shift-reload) point to the German Wikipedia node about "Hello World" programs::
|
||||||
|
|
||||||
2015-01-30 11:47:18,634 - octoprint.plugins.helloworld - INFO - Hello World! (more: https://de.wikipedia.org/wiki/Hallo-Welt-Programm)
|
2015-01-30 11:47:18,634 - octoprint.plugins.helloworld - INFO - Hello World! (more: https://de.wikipedia.org/wiki/Hallo-Welt-Programm)
|
||||||
|
|
||||||
@@ -568,8 +569,8 @@ again since we don't use that anymore:
|
|||||||
:emphasize-lines: 15-19
|
:emphasize-lines: 15-19
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -665,8 +666,8 @@ like so:
|
|||||||
:emphasize-lines: 9,22-25
|
:emphasize-lines: 9,22-25
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -819,12 +820,10 @@ Put something like the following into ``helloworld.css``:
|
|||||||
.. code-block:: css
|
.. code-block:: css
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
#tab_plugin_helloworld {
|
#tab_plugin_helloworld iframe {
|
||||||
iframe {
|
width: 100%;
|
||||||
width: 100%;
|
height: 600px;
|
||||||
height: 600px;
|
border: 1px solid #808080;
|
||||||
border: 1px solid #808080;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Don't forget to remove the ``style`` attribute from the ``iframe`` tag in ``helloworld_tab.jinja2``:
|
Don't forget to remove the ``style`` attribute from the ``iframe`` tag in ``helloworld_tab.jinja2``:
|
||||||
@@ -847,8 +846,8 @@ a reference to our CSS file:
|
|||||||
:emphasize-lines: 26
|
:emphasize-lines: 26
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
@@ -932,8 +931,8 @@ Then adjust our returned assets to include our LESS file as well:
|
|||||||
:emphasize-lines: 27
|
:emphasize-lines: 27
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, unicode_literals
|
||||||
|
|
||||||
import octoprint.plugin
|
import octoprint.plugin
|
||||||
|
|
||||||
|
|||||||
@@ -3,12 +3,12 @@
|
|||||||
Helpers
|
Helpers
|
||||||
=======
|
=======
|
||||||
|
|
||||||
Helpers are methods that plugin can exposed to other plugins in order to make common functionality available on the
|
Helpers are methods that plugins can expose to other plugins in order to make common functionality available on the
|
||||||
system. They are registered with the OctoPrint plugin system through the use of the control property ``__plugin_helpers__``.
|
system. They are registered with the OctoPrint plugin system through the use of the control property ``__plugin_helpers__``.
|
||||||
|
|
||||||
An example for providing some helper functions to the system can be found in the
|
An example for providing some helper functions to the system can be found in the
|
||||||
`Discovery Plugin <https://github.com/foosel/OctoPrint/wiki/Plugin:-Discovery>`_,
|
`Discovery Plugin <https://github.com/foosel/OctoPrint/wiki/Plugin:-Discovery>`_,
|
||||||
which provides it's SSDP browsing and Zeroconf browsing and publishing functions as helper methods.
|
which provides its SSDP browsing and Zeroconf browsing and publishing functions as helper methods.
|
||||||
|
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ or as ``postfix`` (after the existing lines).
|
|||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
|
from past import basestring
|
||||||
self._gcode_hooks = self._pluginManager.get_hooks("octoprint.comm.protocol.scripts")
|
self._gcode_hooks = self._pluginManager.get_hooks("octoprint.comm.protocol.scripts")
|
||||||
|
|
||||||
# ...
|
# ...
|
||||||
@@ -35,7 +36,7 @@ or as ``postfix`` (after the existing lines).
|
|||||||
for hook in self._gcodescript_hooks:
|
for hook in self._gcodescript_hooks:
|
||||||
try:
|
try:
|
||||||
retval = self._gcodescript_hooks[hook](self, "gcode", scriptName)
|
retval = self._gcodescript_hooks[hook](self, "gcode", scriptName)
|
||||||
except:
|
except Exception:
|
||||||
self._logger.exception("Error while processing gcodescript hook %s" % hook)
|
self._logger.exception("Error while processing gcodescript hook %s" % hook)
|
||||||
else:
|
else:
|
||||||
if retval is None:
|
if retval is None:
|
||||||
@@ -44,10 +45,8 @@ or as ``postfix`` (after the existing lines).
|
|||||||
continue
|
continue
|
||||||
|
|
||||||
def to_list(data):
|
def to_list(data):
|
||||||
if isinstance(data, str):
|
if isinstance(data, basestring):
|
||||||
data = map(str.strip, data.split("\n"))
|
data = map(x.strip() for x in data.split("\n"))
|
||||||
elif isinstance(data, unicode):
|
|
||||||
data = map(unicode.strip, data.split("\n"))
|
|
||||||
|
|
||||||
if isinstance(data, (list, tuple)):
|
if isinstance(data, (list, tuple)):
|
||||||
return list(data)
|
return list(data)
|
||||||
@@ -66,7 +65,7 @@ the general type of script for which to look for additions ("gcode") and the scr
|
|||||||
return a 2-tuple of prefix and postfix if has something for either of those, otherwise ``None``. OctoPrint will then take
|
return a 2-tuple of prefix and postfix if has something for either of those, otherwise ``None``. OctoPrint will then take
|
||||||
care to add prefix and suffix as necessary after a small round of preprocessing.
|
care to add prefix and suffix as necessary after a small round of preprocessing.
|
||||||
|
|
||||||
Plugins can easily add their own hooks too. For example, the `Software Update Plugin <https://github.com/OctoPrint/OctoPrint-SoftwareUpdate>`_
|
Plugins can easily add their own hooks too. For example, the `Software Update Plugin <https://github.com/foosel/OctoPrint/tree/master/src/octoprint/plugins/softwareupdate>`_
|
||||||
declares a custom hook "octoprint.plugin.softwareupdate.check_config" which other plugins can add handlers for in order
|
declares a custom hook "octoprint.plugin.softwareupdate.check_config" which other plugins can add handlers for in order
|
||||||
to register themselves with the Software Update Plugin by returning their own update check configuration.
|
to register themselves with the Software Update Plugin by returning their own update check configuration.
|
||||||
|
|
||||||
@@ -79,7 +78,7 @@ property instead, manually instantiate your implementation instance and then add
|
|||||||
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/custom_action_command.py
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/custom_action_command.py
|
||||||
:linenos:
|
:linenos:
|
||||||
:tab-width: 4
|
:tab-width: 4
|
||||||
:caption: `custom_action_command.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/custom_action_command.py>`_
|
:caption: `custom_action_command.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/custom_action_command.py>`__
|
||||||
:name: sec-plugin-concepts-hooks-example
|
:name: sec-plugin-concepts-hooks-example
|
||||||
|
|
||||||
.. _sec-plugins-hooks-ordering:
|
.. _sec-plugins-hooks-ordering:
|
||||||
@@ -201,30 +200,36 @@ Available plugin hooks
|
|||||||
.. contents::
|
.. contents::
|
||||||
:local:
|
:local:
|
||||||
|
|
||||||
.. _sec-plugins-hook-accesscontrol-appkey:
|
.. _sec-plugins-hook-accesscontrol-keyvalidator:
|
||||||
|
|
||||||
octoprint.accesscontrol.appkey
|
octoprint.accesscontrol.keyvalidator
|
||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
.. py:function:: acl_appkey_hook(*args, **kwargs)
|
.. py:function:: acl_keyvalidator_hook(apikey, *args, **kwargs)
|
||||||
|
|
||||||
By handling this hook plugins may register additional :ref:`App session key providers <sec-api-apps-sessionkey>`
|
Via this hook plugins may validate their own customized API keys to be used to access OctoPrint's API.
|
||||||
within the system.
|
|
||||||
|
|
||||||
Overrides this to return your additional app information to be used for validating app session keys. You'll
|
``apikey`` will be the API key as read from the request headers.
|
||||||
need to return a list of 3-tuples of the format (id, version, public key).
|
|
||||||
|
|
||||||
The ``id`` should be the (unique) identifier of the app. Using a domain prefix might make sense here, e.g.
|
Hook handlers are expected to return a :class:`~octoprint.access.users.User` instance here that will then be considered that
|
||||||
``org.octoprint.example.MyApp``.
|
user making the request. By returning ``None`` or nothing at all, hook handlers signal that they do not handle the
|
||||||
|
provided key.
|
||||||
|
|
||||||
``version`` should be a string specifying the version of the app for which the public key is valid. You can
|
**Example:**
|
||||||
provide the string ``any`` here, in which case the provided public key will be valid for all versions of the
|
|
||||||
app for which no specific public key is defined.
|
|
||||||
|
|
||||||
Finally, the public key is expected to be provided as a PKCS1 string without newlines.
|
Allows using a user's id as their API key (for obvious reasons this is NOT recommended in production environments
|
||||||
|
and merely provided for educational purposes):
|
||||||
|
|
||||||
:return: A list of 3-tuples as described above
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/custom_keyvalidator.py
|
||||||
:rtype: list
|
:linenos:
|
||||||
|
:tab-width: 4
|
||||||
|
:caption: `custom_keyvalidator.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/custom_keyvalidator.py>`_
|
||||||
|
|
||||||
|
.. versionadded:: 1.3.6
|
||||||
|
|
||||||
|
:param str apikey: The API key to validate
|
||||||
|
:return: The user in whose name the request will be processed further
|
||||||
|
:rtype: :class:`~octoprint.access.users.User`
|
||||||
|
|
||||||
.. _sec-plugins-hook-cli-commands:
|
.. _sec-plugins-hook-cli-commands:
|
||||||
|
|
||||||
@@ -349,6 +354,66 @@ octoprint.cli.commands
|
|||||||
OctoPrint's CLI.
|
OctoPrint's CLI.
|
||||||
:rtype: list
|
:rtype: list
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-comm-protocol-firmware-info:
|
||||||
|
|
||||||
|
octoprint.comm.protocol.firmware.info
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: firmware_info_hook(comm_instance, firmware_name, firmware_data, *args, **kwargs)
|
||||||
|
|
||||||
|
Be notified of firmware information received from the printer following an ``M115``.
|
||||||
|
|
||||||
|
Hook handlers may use this to react/adjust behaviour based on reported firmware data. OctoPrint parses the received
|
||||||
|
report line and provides the parsed ``firmware_name`` and additional ``firmware_data`` contained therein. A
|
||||||
|
response line ``FIRMWARE_NAME:Some Firmware Name FIRMWARE_VERSION:1.2.3 PROTOCOL_VERSION:1.0`` for example will
|
||||||
|
be turned into a ``dict`` looking like this:
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
dict(FIRMWARE_NAME="Some Firmware Name",
|
||||||
|
FIRMWARE_VERSION="1.2.3",
|
||||||
|
PROTOCOL_VERSION="1.0")
|
||||||
|
|
||||||
|
``firmware_name`` will be ``Some Firmware Name`` in this case.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within these handlers as
|
||||||
|
you will effectively block the receive loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
|
:param object comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
||||||
|
:param str firmware_name: The name of the parsed capability
|
||||||
|
:param dict firmware_data: All data contained in the ``M115`` report
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-comm-protocol-firmware-capabilities:
|
||||||
|
|
||||||
|
octoprint.comm.firmware.protocol.capabilities
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: firmware_capability_hook(comm_instance, capability, enabled, already_defined, *args, **kwargs)
|
||||||
|
|
||||||
|
Be notified of capability report entries received from the printer.
|
||||||
|
|
||||||
|
Hook handlers may use this to react to custom firmware capabilities. OctoPrint parses the received capability
|
||||||
|
line and provides the parsed ``capability`` and whether it's ``enabled`` to the handler. Additionally all already
|
||||||
|
parsed capabilities will also be provided.
|
||||||
|
|
||||||
|
Note that hook handlers will be called once per received capability line.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within these handlers as
|
||||||
|
you will effectively block the receive loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
|
:param object comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
||||||
|
:param str capability: The name of the parsed capability
|
||||||
|
:param bool enabled: Whether the capability is reported as enabled or disabled
|
||||||
|
:param dict already_defined: Already defined capabilities (capability name mapped to enabled flag)
|
||||||
|
|
||||||
.. _sec-plugins-hook-comm-protocol-action:
|
.. _sec-plugins-hook-comm-protocol-action:
|
||||||
|
|
||||||
octoprint.comm.protocol.action
|
octoprint.comm.protocol.action
|
||||||
@@ -358,11 +423,18 @@ octoprint.comm.protocol.action
|
|||||||
|
|
||||||
React to a :ref:`action command <sec-features-action_commands>` received from the printer.
|
React to a :ref:`action command <sec-features-action_commands>` received from the printer.
|
||||||
|
|
||||||
Hook handlers may use this to react to react to custom firmware messages. OctoPrint parses the received action
|
Hook handlers may use this to react to custom firmware messages. OctoPrint parses the received action
|
||||||
command ``line`` and provides the parsed ``action`` (so anything after ``// action:``) to the hook handler.
|
command ``line`` and provides the parsed ``action`` (so anything after ``// action:``) to the hook handler.
|
||||||
|
|
||||||
No returned value is expected.
|
No returned value is expected.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within your handlers as
|
||||||
|
you will effectively block the receive loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
**Example:**
|
**Example:**
|
||||||
|
|
||||||
Logs if the ``custom`` action (``// action:custom``) is received from the printer's firmware.
|
Logs if the ``custom`` action (``// action:custom``) is received from the printer's firmware.
|
||||||
@@ -370,13 +442,59 @@ octoprint.comm.protocol.action
|
|||||||
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/custom_action_command.py
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/custom_action_command.py
|
||||||
:linenos:
|
:linenos:
|
||||||
:tab-width: 4
|
:tab-width: 4
|
||||||
:caption: `custom_action_command.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/custom_action_command.py>`_
|
:caption: `custom_action_command.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/custom_action_command.py>`__
|
||||||
|
|
||||||
:param object comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
:param object comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
||||||
:param str line: The complete line as received from the printer, format ``// action:<command>``
|
:param str line: The complete line as received from the printer, format ``// action:<command>``
|
||||||
:param str action: The parsed out action command, so for a ``line`` like ``// action:some_command`` this will be
|
:param str action: The parsed out action command, so for a ``line`` like ``// action:some_command`` this will be
|
||||||
``some_command``
|
``some_command``
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-comm-protocol-atcommand-phase:
|
||||||
|
|
||||||
|
octoprint.comm.protocol.atcommand.<phase>
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
This describes actually two hooks:
|
||||||
|
|
||||||
|
* ``octoprint.comm.protocol.atcommand.queuing``
|
||||||
|
* ``octoprint.comm.protocol.atcommand.sending``
|
||||||
|
|
||||||
|
.. py:function:: protocol_atcommandphase_hook(comm_instance, phase, command, parameters, tags=None, *args, **kwargs)
|
||||||
|
|
||||||
|
Trigger on :ref:`@ commands <sec-features-atcommands>` as they progress through the ``queuing`` and ``sending``
|
||||||
|
phases of the comm layer. See :ref:`the gcode phase hook <sec-plugins-hook-comm-protocol-gcode-phase>` for a
|
||||||
|
detailed description of each of these phases.
|
||||||
|
|
||||||
|
Hook handlers may use this to react to arbitrary :ref:`@ commands <sec-features-atcommands>` included in GCODE files
|
||||||
|
streamed to the printer or sent as part of GCODE scripts, through the API or plugins.
|
||||||
|
|
||||||
|
Please note that these hooks do not allow to rewrite, suppress or expand @ commands, they are merely callbacks to
|
||||||
|
trigger the *actual execution* of whatever functionality lies behind a given @ command, similar to
|
||||||
|
:ref:`the action command hook <sec-plugins-hook-comm-protocol-action>`.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within your handlers as
|
||||||
|
you will effectively block the send/receive loops, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
Pause the print on ``@wait`` (this mirrors the implementation of the built-in ``@pause`` command, just with a
|
||||||
|
different name).
|
||||||
|
|
||||||
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/custom_atcommand.py
|
||||||
|
:linenos:
|
||||||
|
:tab-width: 4
|
||||||
|
:caption: `custom_action_command.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/custom_atcommand.py>`__
|
||||||
|
|
||||||
|
:param object comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
||||||
|
:param str phase: The current phase in the command progression, either ``queuing`` or ``sending``. Will always
|
||||||
|
match the ``<phase>`` of the hook.
|
||||||
|
:param str cmd: The @ command without the leading @
|
||||||
|
:param str parameters: Any parameters provided to the @ command. If none were provided this will be an empty string.
|
||||||
|
|
||||||
.. _sec-plugins-hook-comm-protocol-gcode-phase:
|
.. _sec-plugins-hook-comm-protocol-gcode-phase:
|
||||||
|
|
||||||
octoprint.comm.protocol.gcode.<phase>
|
octoprint.comm.protocol.gcode.<phase>
|
||||||
@@ -389,14 +507,15 @@ This describes actually four hooks:
|
|||||||
* ``octoprint.comm.protocol.gcode.sending``
|
* ``octoprint.comm.protocol.gcode.sending``
|
||||||
* ``octoprint.comm.protocol.gcode.sent``
|
* ``octoprint.comm.protocol.gcode.sent``
|
||||||
|
|
||||||
.. py:function:: protocol_gcodephase_hook(comm_instance, phase, cmd, cmd_type, gcode, *args, **kwargs)
|
.. py:function:: protocol_gcodephase_hook(comm_instance, phase, cmd, cmd_type, gcode, subcode=None, tags=None, *args, **kwargs)
|
||||||
|
|
||||||
Pre- and postprocess commands as they progress through the various phases of being sent to the printer. The phases
|
Pre- and postprocess commands as they progress through the various phases of being sent to the printer. The phases
|
||||||
are the following:
|
are the following:
|
||||||
|
|
||||||
* ``queuing``: This phase is triggered just before the command is added to the send queue of the communication layer. This
|
* ``queuing``: This phase is triggered just before the command is added to the send queue of the communication layer. This
|
||||||
corresponds to the moment a command is being read from a file that is currently being printed. Handlers
|
corresponds to the moment a command is being read from a file that is currently being printed. Handlers
|
||||||
may suppress or change commands or their command type here.
|
may suppress or change commands or their command type here. This is the only phase that supports multi command
|
||||||
|
expansion by having the handler return a list, see below for details.
|
||||||
* ``queued``: This phase is triggered just after the command was added to the send queue of the communication layer.
|
* ``queued``: This phase is triggered just after the command was added to the send queue of the communication layer.
|
||||||
No manipulation is possible here anymore (returned values will be ignored).
|
No manipulation is possible here anymore (returned values will be ignored).
|
||||||
* ``sending``: This phase is triggered just before the command is actually being sent to the printer. Right afterwards
|
* ``sending``: This phase is triggered just before the command is actually being sent to the printer. Right afterwards
|
||||||
@@ -411,7 +530,39 @@ This describes actually four hooks:
|
|||||||
the communication layer or before they are actually sent over the serial port, or to react to the queuing or sending
|
the communication layer or before they are actually sent over the serial port, or to react to the queuing or sending
|
||||||
of commands after the fact. The hook handler will be called with the processing ``phase``, the ``cmd`` to be sent to
|
of commands after the fact. The hook handler will be called with the processing ``phase``, the ``cmd`` to be sent to
|
||||||
the printer as well as the ``cmd_type`` parameter used for enqueuing (OctoPrint will make sure that the send queue
|
the printer as well as the ``cmd_type`` parameter used for enqueuing (OctoPrint will make sure that the send queue
|
||||||
will never contain more than one line with the same ``cmd_type``) and the detected gcode command (if it is one).
|
will never contain more than one line with the same ``cmd_type``) and the detected ``gcode`` command (if it is one)
|
||||||
|
as well as its ``subcode`` (if it has one). OctoPrint will also provide any ``tags`` attached to the command throughout
|
||||||
|
its lifecycle.
|
||||||
|
|
||||||
|
Tags are arbitrary strings that can be attached to a command as it moves through the various phases and can be used to e.g.
|
||||||
|
distinguish between commands that originated in a printed file (``source:file``) vs. a configured GCODE script
|
||||||
|
(``source:script``) vs. an API call (``source:api``) vs. a plugin (``source:plugin`` or ``source:rewrite`` and
|
||||||
|
``plugin:<plugin identifier>``). If during development you want to get an idea of the various possible tags, set
|
||||||
|
the logger ``octoprint.util.comm.command_phases`` to ``DEBUG``, connect to a printer (real or virtual) and take a
|
||||||
|
look at your ``octoprint.log`` during serial traffic:
|
||||||
|
|
||||||
|
.. code-block:: none
|
||||||
|
|
||||||
|
2018-02-16 18:20:31,213 - octoprint.util.comm.command_phases - DEBUG - phase: queuing | command: T0 | gcode: T | tags: [ api:printer.command, source:api, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,216 - octoprint.util.comm.command_phases - DEBUG - phase: queued | command: M117 Before T! | gcode: M117 | tags: [ api:printer.command, phase:queuing, plugin:multi_gcode_test, source:api, source:rewrite, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,217 - octoprint.util.comm.command_phases - DEBUG - phase: sending | command: M117 Before T! | gcode: M117 | tags: [ api:printer.command, phase:queuing, plugin:multi_gcode_test, source:api, source:rewrite, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,217 - octoprint.util.comm.command_phases - DEBUG - phase: queued | command: T0 | gcode: T | tags: [ api:printer.command, source:api, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,219 - octoprint.util.comm.command_phases - DEBUG - phase: queued | command: M117 After T! | gcode: M117 | tags: [ api:printer.command, phase:queuing, plugin:multi_gcode_test, source:api, source:rewrite, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,220 - octoprint.util.comm.command_phases - DEBUG - phase: sent | command: M117 Before T! | gcode: M117 | tags: [ api:printer.command, phase:queuing, plugin:multi_gcode_test, source:api, source:rewrite, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,230 - tornado.access - INFO - 204 POST /api/printer/command (127.0.0.1) 23.00ms
|
||||||
|
2018-02-16 18:20:31,232 - tornado.access - INFO - 200 POST /api/printer/command (127.0.0.1) 25.00ms
|
||||||
|
2018-02-16 18:20:31,232 - octoprint.util.comm.command_phases - DEBUG - phase: sending | command: T0 | gcode: T | tags: [ api:printer.command, source:api, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,234 - octoprint.util.comm.command_phases - DEBUG - phase: sent | command: T0 | gcode: T | tags: [ api:printer.command, source:api, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,242 - octoprint.util.comm.command_phases - DEBUG - phase: sending | command: M117 After T! | gcode: M117 | tags: [ api:printer.command, phase:queuing, plugin:multi_gcode_test, source:api, source:rewrite, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:31,243 - octoprint.util.comm.command_phases - DEBUG - phase: sent | command: M117 After T! | gcode: M117 | tags: [ api:printer.command, phase:queuing, plugin:multi_gcode_test, source:api, source:rewrite, trigger:printer.commands ]
|
||||||
|
2018-02-16 18:20:38,552 - octoprint.util.comm.command_phases - DEBUG - phase: queuing | command: G91 | gcode: G91 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,552 - octoprint.util.comm.command_phases - DEBUG - phase: queued | command: G91 | gcode: G91 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,553 - octoprint.util.comm.command_phases - DEBUG - phase: sending | command: G91 | gcode: G91 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,553 - octoprint.util.comm.command_phases - DEBUG - phase: queuing | command: G1 X10 F6000 | gcode: G1 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,555 - octoprint.util.comm.command_phases - DEBUG - phase: queued | command: G1 X10 F6000 | gcode: G1 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,556 - octoprint.util.comm.command_phases - DEBUG - phase: sent | command: G91 | gcode: G91 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,556 - octoprint.util.comm.command_phases - DEBUG - phase: queuing | command: G90 | gcode: G90 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
2018-02-16 18:20:38,558 - octoprint.util.comm.command_phases - DEBUG - phase: queued | command: G90 | gcode: G90 | tags: [ api:printer.printhead, source:api, trigger:printer.commands, trigger:printer.jog ]
|
||||||
|
|
||||||
Defining a ``cmd_type`` other than None will make sure OctoPrint takes care of only having one command of that type
|
Defining a ``cmd_type`` other than None will make sure OctoPrint takes care of only having one command of that type
|
||||||
in its sending queue. Predefined types are ``temperature_poll`` for temperature polling via ``M105`` and
|
in its sending queue. Predefined types are ``temperature_poll`` for temperature polling via ``M105`` and
|
||||||
@@ -425,7 +576,7 @@ This describes actually four hooks:
|
|||||||
|
|
||||||
* ``None``: Don't change anything. Note that Python functions will also automatically return ``None`` if
|
* ``None``: Don't change anything. Note that Python functions will also automatically return ``None`` if
|
||||||
an empty ``return`` statement is used or just nothing is returned explicitly from the handler. Hence, the following
|
an empty ``return`` statement is used or just nothing is returned explicitly from the handler. Hence, the following
|
||||||
examples are all falling into this category:
|
examples are all falling into this category and equivalent:
|
||||||
|
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
|
|
||||||
@@ -450,6 +601,36 @@ This describes actually four hooks:
|
|||||||
should use this option.
|
should use this option.
|
||||||
* A 2-tuple consisting of a rewritten version of the ``cmd`` and the ``cmd_type``, e.g. ``return "M105", "temperature_poll"``.
|
* A 2-tuple consisting of a rewritten version of the ``cmd`` and the ``cmd_type``, e.g. ``return "M105", "temperature_poll"``.
|
||||||
Handlers which wish to rewrite both the command and the command type should use this option.
|
Handlers which wish to rewrite both the command and the command type should use this option.
|
||||||
|
* A 3-tuple consisting of a rewritten version of the ``cmd``, the ``cmd_type`` and any additional ``tags`` you might
|
||||||
|
want to attach to the lifecycle of the command in a set, e.g. ``return "M105", "temperature_poll", {"my_custom_tag"}``
|
||||||
|
* **"queuing" phase only**: A list of any of the above to allow for expanding one command into
|
||||||
|
many. The following example shows how any queued command could be turned into a sequence of a temperature query,
|
||||||
|
line number reset, display of the ``gcode`` on the printer's display and finally the actual command (this example
|
||||||
|
does not make a lot of sense to be quite honest):
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
def rewrite_foo(self, comm_instance, phase, cmd, cmd_type, gcode, subcode=None, tags=None *args, **kwargs):
|
||||||
|
if gcode or not cmd.startswith("@foo"):
|
||||||
|
return
|
||||||
|
|
||||||
|
return [("M105", "temperature_poll"), # 2-tuple, command & command type
|
||||||
|
("M110",), # 1-tuple, just the command
|
||||||
|
"M117 echo foo: {}".format(cmd)] # string, just the command
|
||||||
|
|
||||||
|
__plugin_hooks__ = {
|
||||||
|
"octoprint.comm.protocol.gcode.queuing": rewrite_foo
|
||||||
|
}
|
||||||
|
|
||||||
|
Note: Only one command of a given ``cmd_type`` (other than None) may be queued at a time. Trying to rewrite the ``cmd_type``
|
||||||
|
to one already in the queue will give an error.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within these handlers as
|
||||||
|
you will effectively block the send loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
|
|
||||||
@@ -469,6 +650,9 @@ This describes actually four hooks:
|
|||||||
:param str cmd_type: Type of command, e.g. ``temperature_poll`` for temperature polling or ``sd_status_poll`` for SD
|
:param str cmd_type: Type of command, e.g. ``temperature_poll`` for temperature polling or ``sd_status_poll`` for SD
|
||||||
printing status polling.
|
printing status polling.
|
||||||
:param str gcode: Parsed GCODE command, e.g. ``G0`` or ``M110``, may also be None if no known command could be parsed
|
:param str gcode: Parsed GCODE command, e.g. ``G0`` or ``M110``, may also be None if no known command could be parsed
|
||||||
|
:param str subcode: Parsed subcode of the GCODE command, e.g. ``1`` for ``M80.1``. Will be None if no subcode was provided
|
||||||
|
or no command could be parsed.
|
||||||
|
:param tags: Tags attached to the command
|
||||||
:return: None, 1-tuple, 2-tuple or string, see the description above for details.
|
:return: None, 1-tuple, 2-tuple or string, see the description above for details.
|
||||||
|
|
||||||
.. _sec-plugins-hook-comm-protocol-gcode-received:
|
.. _sec-plugins-hook-comm-protocol-gcode-received:
|
||||||
@@ -479,10 +663,17 @@ octoprint.comm.protocol.gcode.received
|
|||||||
.. py:function:: gcode_received_hook(comm_instance, line, *args, **kwargs)
|
.. py:function:: gcode_received_hook(comm_instance, line, *args, **kwargs)
|
||||||
|
|
||||||
Get the returned lines sent by the printer. Handlers should return the received line or in any case, the modified
|
Get the returned lines sent by the printer. Handlers should return the received line or in any case, the modified
|
||||||
version of it. If the the handler returns None, processing will be aborted and the communication layer will get an
|
version of it. If the handler returns None, processing will be aborted and the communication layer will get an
|
||||||
empty string as the received line. Note that Python functions will also automatically return ``None`` if an empty
|
empty string as the received line. Note that Python functions will also automatically return ``None`` if an empty
|
||||||
``return`` statement is used or just nothing is returned explicitly from the handler.
|
``return`` statement is used or just nothing is returned explicitly from the handler.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within these handlers as
|
||||||
|
you will effectively block the receive loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
**Example:**
|
**Example:**
|
||||||
|
|
||||||
Looks for the response of an ``M115``, which contains information about the ``MACHINE_TYPE``, among other things.
|
Looks for the response of an ``M115``, which contains information about the ``MACHINE_TYPE``, among other things.
|
||||||
@@ -497,6 +688,43 @@ octoprint.comm.protocol.gcode.received
|
|||||||
:return: The received line or in any case, a modified version of it.
|
:return: The received line or in any case, a modified version of it.
|
||||||
:rtype: str
|
:rtype: str
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-comm-protocol-gcode-error:
|
||||||
|
|
||||||
|
octoprint.comm.protocol.gcode.error
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: gcode_error_hook(comm_instance, error_message, *args, **kwargs)
|
||||||
|
|
||||||
|
Get the messages of any errors messages sent by the printer, with the leading ``Error:`` or ``!!`` already
|
||||||
|
stripped. Handlers should return True if they handled that error internally and it should not be processed by
|
||||||
|
the system further. Normal processing of these kinds of errors - depending on the configuration of error
|
||||||
|
handling - involves canceling the ongoing print and possibly also disconnecting.
|
||||||
|
|
||||||
|
Plugins might utilize this hook to handle errors generated by the printer that are recoverable in one way or
|
||||||
|
the other and should not trigger the normal handling that assumes the worst.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within these handlers as
|
||||||
|
you will effectively block the receive loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
|
**Example:**
|
||||||
|
|
||||||
|
Looks for error messages containing "fan error" or "bed missing" (ignoring case) and marks them as handled by the
|
||||||
|
plugin.
|
||||||
|
|
||||||
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/comm_error_handler_test.py
|
||||||
|
:linenos:
|
||||||
|
:tab-width: 4
|
||||||
|
:caption: `comm_error_handler_test.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/comm_error_handler_test.py>`_
|
||||||
|
|
||||||
|
:param MachineCom comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
||||||
|
:param str error_message: The error message received from the printer.
|
||||||
|
:return: True if the error was handled in the plugin and should not be processed further, False (or None) otherwise.
|
||||||
|
:rtype: bool
|
||||||
|
|
||||||
.. _sec-plugins-hook-comm-protocol-scripts:
|
.. _sec-plugins-hook-comm-protocol-scripts:
|
||||||
|
|
||||||
octoprint.comm.protocol.scripts
|
octoprint.comm.protocol.scripts
|
||||||
@@ -504,19 +732,20 @@ octoprint.comm.protocol.scripts
|
|||||||
|
|
||||||
.. py:function:: protocol_scripts_hook(comm_instance, script_type, script_name, *args, **kwargs)
|
.. py:function:: protocol_scripts_hook(comm_instance, script_type, script_name, *args, **kwargs)
|
||||||
|
|
||||||
Return a prefix to prepend and a postfix to append to the script ``script_name`` of type ``type``. Handlers should
|
Return a prefix to prepend, postfix to append, and optionally a dictionary of variables to provide to the script ``script_name`` of type ``type``. Handlers should
|
||||||
make sure to only proceed with returning additional scripts if the ``script_type`` and ``script_name`` match
|
make sure to only proceed with returning additional scripts if the ``script_type`` and ``script_name`` match
|
||||||
handled scripts. If not, None should be returned directly.
|
handled scripts. If not, None should be returned directly.
|
||||||
|
|
||||||
If the hook handler has something to add to the specified script, it may return a 2-tuple, with the first entry
|
If the hook handler has something to add to the specified script, it may return a 2-tuple, a 3-tuple or a 4-tuple with the first entry
|
||||||
defining the prefix (what to *prepend* to the script in question) and the last entry defining the postfix (what to
|
defining the prefix (what to *prepend* to the script in question), the second entry defining the postfix (what to
|
||||||
*append* to the script in question). Both prefix and postfix can be None to signify that nothing should be prepended
|
*append* to the script in question), and finally if desired a dictionary of variables to be made available to the script on third and additional tags to set on the
|
||||||
|
commands on fourth position. Both prefix and postfix can be None to signify that nothing should be prepended
|
||||||
respectively appended.
|
respectively appended.
|
||||||
|
|
||||||
The returned entries may be either iterables of script lines or a string including newlines of the script lines (which
|
The returned prefix and postfix entries may be either iterables of script lines or a string including newlines of the script lines (which
|
||||||
will be split by the caller if necessary).
|
will be split by the caller if necessary).
|
||||||
|
|
||||||
**Example:**
|
**Example 1:**
|
||||||
|
|
||||||
Appends an ``M117 OctoPrint connected`` to the configured ``afterPrinterConnected`` GCODE script.
|
Appends an ``M117 OctoPrint connected`` to the configured ``afterPrinterConnected`` GCODE script.
|
||||||
|
|
||||||
@@ -525,12 +754,54 @@ octoprint.comm.protocol.scripts
|
|||||||
:tab-width: 4
|
:tab-width: 4
|
||||||
:caption: `message_on_connect.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/message_on_connect.py>`_
|
:caption: `message_on_connect.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/message_on_connect.py>`_
|
||||||
|
|
||||||
|
**Example 2:**
|
||||||
|
|
||||||
|
Provides the variable ``myvariable`` to the configured ``beforePrintStarted`` GCODE script.
|
||||||
|
|
||||||
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/gcode_script_variables.py
|
||||||
|
:linenos:
|
||||||
|
:tab-width: 4
|
||||||
|
:caption: `gcode_script_variables.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/gcode_script_variables.py>`_
|
||||||
|
|
||||||
:param MachineCom comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
:param MachineCom comm_instance: The :class:`~octoprint.util.comm.MachineCom` instance which triggered the hook.
|
||||||
:param str script_type: The type of the script for which the hook was called, currently only "gcode" is supported here.
|
:param str script_type: The type of the script for which the hook was called, currently only "gcode" is supported here.
|
||||||
:param str script_name: The name of the script for which the hook was called.
|
:param str script_name: The name of the script for which the hook was called.
|
||||||
:return: A 2-tuple in the form ``(prefix, postfix)`` or None
|
:return: A 2-tuple in the form ``(prefix, postfix)``, 3-tuple in the form ``(prefix, postfix, variables)``, or None
|
||||||
:rtype: tuple or None
|
:rtype: tuple or None
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-comm-protocol-temperatures-received:
|
||||||
|
|
||||||
|
octoprint.comm.protocol.temperatures.received
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: protocol_temperatures_received_hook(comm_instance, parsed_temperatures, *args, **kwargs)
|
||||||
|
|
||||||
|
Get the parsed temperatures returned by the printer, allowing handlers to modify them prior to handing them off
|
||||||
|
to the system. Handlers are expected to either return ``parsed_temperatures`` as-is or a modified copy thereof.
|
||||||
|
|
||||||
|
``parsed_temperatures`` is a dictionary mapping from tool/bed identifier (``B``, ``T0``, ``T1``) to a 2-tuple of
|
||||||
|
actual and target temperature, e.g. ``{'B': (45.2, 50.0), 'T0': (178.9, 210.0), 'T1': (21.3, 0.0)}``.
|
||||||
|
|
||||||
|
This hook can be useful in cases where a printer e.g. is prone to returning garbage data from time to time, allowing
|
||||||
|
additional sanity checking to be applied and invalid values to be filtered out. If a handler returns an empty
|
||||||
|
dictionary or ``None``, no further processing will take place.
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
Make sure to not perform any computationally expensive or otherwise long running actions within these handlers as
|
||||||
|
you will effectively block the receive loop, causing the communication with the printer to stall.
|
||||||
|
|
||||||
|
This includes I/O of any kind.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
The following example shows how to filter out actual temperatures that are outside a sane range of 1°C to 300°C.
|
||||||
|
|
||||||
|
.. onlineinclude:: https://raw.githubusercontent.com/OctoPrint/Plugin-Examples/master/sanitize_temperatures.py
|
||||||
|
:linenos:
|
||||||
|
:tab-width: 4
|
||||||
|
:caption: `sanitize_temperatures.py <https://github.com/OctoPrint/Plugin-Examples/blob/master/sanitize_temperatures.py>`_
|
||||||
|
|
||||||
.. _sec-plugins-hook-comm-transport-serial-factory:
|
.. _sec-plugins-hook-comm-transport-serial-factory:
|
||||||
|
|
||||||
octoprint.comm.transport.serial.factory
|
octoprint.comm.transport.serial.factory
|
||||||
@@ -607,6 +878,72 @@ octoprint.comm.transport.serial.factory
|
|||||||
:rtype: A serial instance implementing implementing the methods ``readline(...)``, ``write(...)``, ``close()`` and
|
:rtype: A serial instance implementing implementing the methods ``readline(...)``, ``write(...)``, ``close()`` and
|
||||||
optionally ``baudrate`` and ``timeout`` attributes as described above.
|
optionally ``baudrate`` and ``timeout`` attributes as described above.
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-events-register_custom_events:
|
||||||
|
|
||||||
|
octoprint.events.register_custom_events
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: register_custom_events_hook(*args, **kwargs)
|
||||||
|
|
||||||
|
Return a list of custom :ref:`events <sec-events>` to register in the system for your plugin.
|
||||||
|
|
||||||
|
Should return a list of strings which represent the custom events. Their name on the `octoprint.events.Events` object
|
||||||
|
will be the returned value transformed into upper case ``CAMEL_CASE`` and prefixed with ``PLUGIN_<IDENTIFIER>``. Their
|
||||||
|
value will be prefixed with ``plugin_<identifier>_``.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
Consider the following hook part of a plugin with the identifier ``myplugin``. It will register two custom events
|
||||||
|
in the system, ``octoprint.events.Events.PLUGIN_MYPLUGIN_MY_CUSTOM_EVENT`` with value ``plugin_myplugin_my_custom_event``
|
||||||
|
and ``octoprint.events.Events.PLUGIN_MYPLUGIN_MY_OTHER_CUSTOM_EVENT`` with value ``plugin_myplugin_my_other_custom_event``.
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
:linenos:
|
||||||
|
|
||||||
|
def register_custom_events(*args, **kwargs):
|
||||||
|
return ["my_custom_event", "my_other_custom_event"]
|
||||||
|
|
||||||
|
:return: A list of custom events to register
|
||||||
|
:rtype: list
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-filemanager-analysis-factory:
|
||||||
|
|
||||||
|
octoprint.filemanager.analysis.factory
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: analysis_queue_factory_hook(*args, **kwargs)
|
||||||
|
|
||||||
|
Return additional (or replacement) analysis queue factories used for analysing uploaded files.
|
||||||
|
|
||||||
|
Should return a dictionary to merge with the existing dictionary of factories, mapping from extension tree leaf
|
||||||
|
to analysis queue factory. Analysis queue factories are expected to be :class:`~octoprint.filemanager.analysis.AbstractAnalysisQueue`
|
||||||
|
subclasses or factory methods taking one argument (the finish callback to be used by the queue implementation
|
||||||
|
to signal that an analysis has been finished to the system). See the source of :class:`~octoprint.filemanager.analysis.GcodeAnalysisQueue`
|
||||||
|
for an example.
|
||||||
|
|
||||||
|
By default, only one analysis queue factory is registered in the system, for file type ``gcode``: :class:`~octoprint.filemanager.analysis.GcodeAnalysisQueue`.
|
||||||
|
This can be replaced by plugins using this hook, allowing other approaches to file analysis.
|
||||||
|
|
||||||
|
This is useful for plugins wishing to provide (alternative) methods of metadata analysis for printable files.
|
||||||
|
|
||||||
|
**Example:**
|
||||||
|
|
||||||
|
The following handler would replace the existing analysis queue for ``gcode`` files with a custom implementation:
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
:linenos:
|
||||||
|
|
||||||
|
from octoprint.filemanager.analysis import AbstractAnalysisQueue
|
||||||
|
|
||||||
|
class MyCustomGcodeAnalysisQueue(AbstractAnalysisQueue):
|
||||||
|
# ... custom implementation here ...
|
||||||
|
|
||||||
|
def custom_gcode_analysis_queue(*args, **kwargs):
|
||||||
|
return dict(gcode=MyCustomGcodeAnalysisQueue)
|
||||||
|
|
||||||
|
:return: A dictionary of analysis queue factories, mapped by their targeted file type.
|
||||||
|
:rtype: dict
|
||||||
|
|
||||||
.. _sec-plugins-hook-filemanager-extensiontree:
|
.. _sec-plugins-hook-filemanager-extensiontree:
|
||||||
|
|
||||||
octoprint.filemanager.extension_tree
|
octoprint.filemanager.extension_tree
|
||||||
@@ -657,7 +994,7 @@ octoprint.filemanager.preprocessor
|
|||||||
|
|
||||||
``file_object`` will be a subclass of :class:`~octoprint.filemanager.util.AbstractFileWrapper`. Handlers may
|
``file_object`` will be a subclass of :class:`~octoprint.filemanager.util.AbstractFileWrapper`. Handlers may
|
||||||
access the raw data of the file via :func:`~octoprint.filemanager.util.AbstractFileWrapper.stream`, e.g.
|
access the raw data of the file via :func:`~octoprint.filemanager.util.AbstractFileWrapper.stream`, e.g.
|
||||||
to wrap it further. Handlers which do not wish to handle the `file_object`
|
to wrap it further. Handlers which do not wish to handle the `file_object` should just return it untouched.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
|
|
||||||
@@ -695,20 +1032,198 @@ octoprint.printer.factory
|
|||||||
* ``analysis_queue``: The :class:`~octoprint.filemanager.analysis.AnalysisQueue`
|
* ``analysis_queue``: The :class:`~octoprint.filemanager.analysis.AnalysisQueue`
|
||||||
* ``slicing_manager``: The :class:`~octoprint.slicing.SlicingManager`
|
* ``slicing_manager``: The :class:`~octoprint.slicing.SlicingManager`
|
||||||
* ``file_manager``: The :class:`~octoprint.filemanager.FileManager`
|
* ``file_manager``: The :class:`~octoprint.filemanager.FileManager`
|
||||||
* ``app_session_manager``: The :class:`~octoprint.server.util.flask.AppSessionManager`
|
|
||||||
* ``plugin_lifecycle_manager``: The :class:`~octoprint.server.LifecycleManager`
|
* ``plugin_lifecycle_manager``: The :class:`~octoprint.server.LifecycleManager`
|
||||||
* ``user_manager``: The :class:`~octoprint.users.UserManager`
|
* ``user_manager``: The :class:`~octoprint.access.users.UserManager`
|
||||||
* ``preemptive_cache``: The :class:`~octoprint.server.util.flask.PreemptiveCache`
|
* ``preemptive_cache``: The :class:`~octoprint.server.util.flask.PreemptiveCache`
|
||||||
|
|
||||||
If the factory returns anything but ``None``, it will be assigned to the global ``printer`` instance.
|
If the factory returns anything but ``None``, it will be assigned to the global ``printer`` instance.
|
||||||
|
|
||||||
If no of the registered factories return a printer instance, the default :class:`~octoprint.printer.standard.Printer`
|
If none of the registered factories return a printer instance, the default :class:`~octoprint.printer.standard.Printer`
|
||||||
class will be instantiated.
|
class will be instantiated.
|
||||||
|
|
||||||
:param dict components: System components to use for printer instance initialization
|
:param dict components: System components to use for printer instance initialization
|
||||||
:return: The ``printer`` instance to use globally.
|
:return: The ``printer`` instance to use globally.
|
||||||
:rtype: PrinterInterface subclass or None
|
:rtype: PrinterInterface subclass or None
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-printer-estimation-factory:
|
||||||
|
|
||||||
|
octoprint.printer.estimation.factory
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: print_time_estimator_factory(*args, **kwargs)
|
||||||
|
|
||||||
|
Return a :class:`~octoprint.printer.estimation.PrintTimeEstimator` subclass (or factory) to use for print time
|
||||||
|
estimation. This will be called on each start of a print or streaming job with a single parameter ``job_type``
|
||||||
|
denoting the type of job that was just started: ``local`` meaning a print of a local file through the serial connection,
|
||||||
|
``sdcard`` a print of a file stored on the printer's SD card, ``stream`` the streaming of a local file to the
|
||||||
|
printer's SD card.
|
||||||
|
|
||||||
|
This is useful for plugins wishing to provide alternative methods of live print time estimation.
|
||||||
|
|
||||||
|
If none of the registered factories return a ``PrintTimeEstimator`` subclass, the default :class:`~octoprint.printer.estimation.PrintTimeEstimator`
|
||||||
|
will be used.
|
||||||
|
|
||||||
|
**Example:**
|
||||||
|
|
||||||
|
The following example would replace the stock print time estimator with (a nonsensical) one that always estimates
|
||||||
|
two hours of print time left:
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
from octoprint.printer.estimation import PrintTimeEstimator
|
||||||
|
|
||||||
|
class CustomPrintTimeEstimator(PrintTimeEstimator):
|
||||||
|
def __init__(self, job_type):
|
||||||
|
pass
|
||||||
|
|
||||||
|
def estimate(self, progress, printTime, cleanedPrintTime, statisticalTotalPrintTime, statisticalTotalPrintTimeType):
|
||||||
|
# always reports 2h as printTimeLeft
|
||||||
|
return 2 * 60 * 60, "estimate"
|
||||||
|
|
||||||
|
def create_estimator_factory(*args, **kwargs):
|
||||||
|
return CustomPrintTimeEstimator
|
||||||
|
|
||||||
|
__plugin_hooks__ = {
|
||||||
|
"octoprint.printer.estimation.factory": create_estimator_factory
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
:return: The :class:`~octoprint.printer.estimation.PrintTimeEstimator` class to use, or a factory method
|
||||||
|
:rtype: class or function
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-octoprint-printer-sdcardupload:
|
||||||
|
|
||||||
|
octoprint.printer.sdcardupload
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: sd_card_upload_hook(printer, filename, path, start_callback, success_callback, failure_callback, *args, **kwargs)
|
||||||
|
|
||||||
|
Via this hook plugins can change the way files are being uploaded to the sd card of the printer.
|
||||||
|
|
||||||
|
Implementations **must** call the provided ``start_callback`` on start of the file transfer and either the ``success_callback``
|
||||||
|
or ``failure_callback`` on the end of the file transfer, depending on whether it was successful or not.
|
||||||
|
|
||||||
|
The ``start_callback`` has the following signature:
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
def start_callback(local_filename, remote_filename):
|
||||||
|
# ...
|
||||||
|
|
||||||
|
``local_filename`` must be the name of the file on the ``local`` storage, ``remote_filename`` the name of the file
|
||||||
|
to be created on the ``sdcard`` storage.
|
||||||
|
|
||||||
|
``success_callback`` and ``failure_callback`` both have the following signature:
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
def success_or_failure_callback(local_filename, remote_filename, elapsed):
|
||||||
|
# ...
|
||||||
|
|
||||||
|
``local_filename`` must be the name of the file on the ``local`` storage, ``remote_filename`` the name of the file
|
||||||
|
to be created on the ``sdcard`` storage. ``elapsed`` is the elapsed time in seconds.
|
||||||
|
|
||||||
|
If the hook is going to handle the upload, it must return the (future) remote filename of the file on the ``sdcard``
|
||||||
|
storage. If it returns ``None`` (or an otherwise falsy value), OctoPrint will interpret this as the hook not going to
|
||||||
|
handle the file upload, in which case the next hook or - if no other hook is registered - the default implementation
|
||||||
|
will be called.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
The following example creates a dummy SD card uploader that does nothing but sleep for ten seconds when a file
|
||||||
|
is supposed to be uploaded. Note that the long running process of sleeping for ten seconds is extracted into its
|
||||||
|
own thread, which is important in order to not block the main application!
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
import threading
|
||||||
|
import logging
|
||||||
|
import time
|
||||||
|
|
||||||
|
def nop_upload_to_sd(printer, filename, path, sd_upload_started, sd_upload_succeeded, sd_upload_failed, *args, **kwargs):
|
||||||
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
remote_name = printer._get_free_remote_name(filename)
|
||||||
|
logger.info("Starting dummy SDCard upload from {} to {}".format(filename, remote_name))
|
||||||
|
|
||||||
|
sd_upload_started(filename, remote_name)
|
||||||
|
|
||||||
|
def process():
|
||||||
|
logger.info("Sleeping 10s...")
|
||||||
|
time.sleep(10)
|
||||||
|
logger.info("And done!")
|
||||||
|
sd_upload_succeeded(filename, remote_name, 10)
|
||||||
|
|
||||||
|
thread = threading.Thread(target=process)
|
||||||
|
thread.daemon = True
|
||||||
|
thread.start()
|
||||||
|
|
||||||
|
return remote_name
|
||||||
|
|
||||||
|
__plugin_name__ = "No-op SDCard Upload Test"
|
||||||
|
__plugin_hooks__ = {
|
||||||
|
"octoprint.printer.sdcardupload": nop_upload_to_sd
|
||||||
|
}
|
||||||
|
|
||||||
|
.. versionadded:: 1.3.11
|
||||||
|
|
||||||
|
:param object printer: the :py:class:`~octoprint.printer.PrinterInterface` instance the hook was called from
|
||||||
|
:param str filename: filename on the ``local`` storage
|
||||||
|
:param str path: path of the file in the local file system
|
||||||
|
:param function sd_upload_started: callback for when the upload started
|
||||||
|
:param function sd_upload_success: callback for successful finish of upload
|
||||||
|
:param function sd_upload_failure: callback for failure of upload
|
||||||
|
:return: the name of the file on the ``sdcard`` storage or ``None``
|
||||||
|
:rtype: string or ``None``
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-server-http-after_request:
|
||||||
|
|
||||||
|
octoprint.server.api.after_request
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: after_request_handlers_hook(*args, **kwargs)
|
||||||
|
|
||||||
|
Allows adding additional after-request-handlers to API endpoints defined by OctoPrint itself and installed plugins.
|
||||||
|
|
||||||
|
Your plugin might need this to further restrict access to API methods. See the bundled "Force Login" plugin for a
|
||||||
|
usage example.
|
||||||
|
|
||||||
|
.. important::
|
||||||
|
|
||||||
|
Implementing this hook will make your plugin require a restart of OctoPrint for enabling/disabling it fully.
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-server-http-before_request:
|
||||||
|
|
||||||
|
octoprint.server.api.before_request
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: after_request_handlers_hook(*args, **kwargs)
|
||||||
|
|
||||||
|
Allows adding additional before-request-handlers to API endpoints defined by OctoPrint itself and installed plugins.
|
||||||
|
|
||||||
|
Your plugin might need this to further restrict access to API methods. See the bundled "Force Login" plugin for a
|
||||||
|
usage example.
|
||||||
|
|
||||||
|
.. important::
|
||||||
|
|
||||||
|
Implementing this hook will make your plugin require a restart of OctoPrint for enabling/disabling it fully.
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-server-http-access_validator:
|
||||||
|
|
||||||
|
octoprint.server.http.access_validator
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: access_validator_hook(request, *args, **kwargs)
|
||||||
|
|
||||||
|
Allows adding additional access validators to the default tornado routers.
|
||||||
|
|
||||||
|
Your plugin might need to this to restrict acccess to downloads and webcam snapshots further. See the bundled
|
||||||
|
"Force Login" plugin for a usage example.
|
||||||
|
|
||||||
|
.. important::
|
||||||
|
|
||||||
|
Implementing this hook will make your plugin require a restart of OctoPrint for enabling/disabling it fully.
|
||||||
|
|
||||||
.. _sec-plugins-hook-server-http-bodysize:
|
.. _sec-plugins-hook-server-http-bodysize:
|
||||||
|
|
||||||
octoprint.server.http.bodysize
|
octoprint.server.http.bodysize
|
||||||
@@ -783,6 +1298,14 @@ octoprint.server.http.routes
|
|||||||
view of the blueprint will thus not be reachable since processing of the request will directly be handed over
|
view of the blueprint will thus not be reachable since processing of the request will directly be handed over
|
||||||
to your defined handler class.
|
to your defined handler class.
|
||||||
|
|
||||||
|
.. important::
|
||||||
|
|
||||||
|
If you want your route to support CORS if it's enabled in OctoPrint, your `RequestHandler <http://tornado.readthedocs.org/en/branch4.0/web.html#request-handlers>`_
|
||||||
|
needs to implement the :class:`~octoprint.server.util.tornado.CorsSupportMixin` for this to work. Note that all of
|
||||||
|
:class:`~octoprint.server.util.tornado.LargeResponseHandler`, :class:`~octoprint.server.util.tornado.UrlProxyHandler`,
|
||||||
|
:class:`~octoprint.server.util.tornado.StaticDataHandler` and :class:`~octoprint.server.util.tornado.DeprecatedEndpointHandler`
|
||||||
|
already implement this mixin.
|
||||||
|
|
||||||
.. important::
|
.. important::
|
||||||
|
|
||||||
Implementing this hook will make your plugin require a restart of OctoPrint for enabling/disabling it fully.
|
Implementing this hook will make your plugin require a restart of OctoPrint for enabling/disabling it fully.
|
||||||
@@ -804,12 +1327,91 @@ octoprint.server.http.routes
|
|||||||
that allows delivery of the requested resource as attachment and access validation through an optional callback.
|
that allows delivery of the requested resource as attachment and access validation through an optional callback.
|
||||||
:class:`~octoprint.server.util.tornado.UrlForwardHandler`
|
:class:`~octoprint.server.util.tornado.UrlForwardHandler`
|
||||||
`tornado.web.RequestHandler <http://tornado.readthedocs.org/en/branch4.0/web.html#request-handlers>`_ that proxies
|
`tornado.web.RequestHandler <http://tornado.readthedocs.org/en/branch4.0/web.html#request-handlers>`_ that proxies
|
||||||
requests to a preconfigured url and returns the response.
|
requests to a preconfigured URL and returns the response.
|
||||||
|
|
||||||
:param list server_routes: read-only list of the currently configured server routes
|
:param list server_routes: read-only list of the currently configured server routes
|
||||||
:return: a list of 3-tuples with additional routes as defined above
|
:return: a list of 3-tuples with additional routes as defined above
|
||||||
:rtype: list
|
:rtype: list
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-server-sockjs-authed:
|
||||||
|
|
||||||
|
octoprint.server.sockjs.authed
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: socket_authed_hook(socket, user, *args, **kwargs):
|
||||||
|
|
||||||
|
Allows plugins to be notified that a user got authenticated or deauthenticated on the socket (e.g. due to logout).
|
||||||
|
|
||||||
|
See the bundled :ref:`Forcelogin Plugin <sec-bundledplugins-forcelogin>` for an example on how to utilize this.
|
||||||
|
|
||||||
|
:param object socket: the socket object which is about to be registered
|
||||||
|
:param object user: the user that got authenticated on the socket, or None if the user got deauthenticated
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-server-sockjs-register:
|
||||||
|
|
||||||
|
octoprint.server.sockjs.register
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: socket_registration_hook(socket, user, *args, **kwargs):
|
||||||
|
|
||||||
|
Allows plugins to prevent a new :ref:`push socket client <sec-api-push>` to be registered to the system.
|
||||||
|
|
||||||
|
Handlers should return either ``True`` or ``False``. ``True`` signals to proceed with normal registration. ``False``
|
||||||
|
signals to not register the client.
|
||||||
|
|
||||||
|
See the bundled :ref:`Forcelogin Plugin <sec-bundledplugins-forcelogin>` for an example on how to utilize this.
|
||||||
|
|
||||||
|
:param object socket: the socket object which is about to be registered
|
||||||
|
:param object user: the user currently authenticated on the socket - might be None
|
||||||
|
:return: whether to proceed with registration (``True``) or not (``False``)
|
||||||
|
:rtype: boolean
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-server-sockjs-emit:
|
||||||
|
|
||||||
|
octoprint.server.sockjs.emit
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: socket_emit_hook(socket, user, message, payload, *args, **kwargs):
|
||||||
|
|
||||||
|
Allows plugins to prevent any messages to be emitted on an existing :ref:`push connection <sec-api-push>`.
|
||||||
|
|
||||||
|
Handlers should return either ``True`` to allow the message to be emitted, or ``False`` to prevent it.
|
||||||
|
|
||||||
|
See the bundled :ref:`Forcelogin Plugin <sec-bundledplugins-forcelogin>` for an example on how to utilize this.
|
||||||
|
|
||||||
|
:param object socket: the socket object on which a message is about to be emitted
|
||||||
|
:param object user: the user currently authenticated on the socket - might be None
|
||||||
|
:param string message: the message type about to be emitted
|
||||||
|
:param dict payload: the payload of the message about to be emitted (may be None)
|
||||||
|
:return: whether to proceed with sending the message (``True``) or not (``False``)
|
||||||
|
:rtype: boolean
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-timelapse-extensions:
|
||||||
|
|
||||||
|
octoprint.timelapse.extensions
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: timelapse_extension_hook(*args, **kwargs)
|
||||||
|
|
||||||
|
Allows extending the set of supported file extensions for timelapse files. Handlers must return a list of
|
||||||
|
additional file extensions.
|
||||||
|
|
||||||
|
**Example**
|
||||||
|
|
||||||
|
Allow the management of timelapse GIFs with extension ``gif``.
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
def get_timelapse_extensions(*args, **kwargs):
|
||||||
|
return ["gif"]
|
||||||
|
|
||||||
|
__plugin_hooks__ = {
|
||||||
|
"octoprint.timelapse.extensions": get_timelapse_extensions
|
||||||
|
}
|
||||||
|
|
||||||
|
:return: a list of additional file extensions
|
||||||
|
:rtype: list
|
||||||
|
|
||||||
.. _sec-plugins-hook-ui-web-templatetypes:
|
.. _sec-plugins-hook-ui-web-templatetypes:
|
||||||
|
|
||||||
octoprint.ui.web.templatetypes
|
octoprint.ui.web.templatetypes
|
||||||
@@ -922,3 +1524,69 @@ octoprint.ui.web.templatetypes
|
|||||||
:param dict template_sorting: read-only dictionary of currently configured template sorting specifications
|
:param dict template_sorting: read-only dictionary of currently configured template sorting specifications
|
||||||
:return: a list of 3-tuples (template type, rule, sorting spec)
|
:return: a list of 3-tuples (template type, rule, sorting spec)
|
||||||
:rtype: list
|
:rtype: list
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-users-factory:
|
||||||
|
|
||||||
|
octoprint.access.users.factory
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: user_manager_factory_hook(components, settings, *args, **kwargs)
|
||||||
|
|
||||||
|
Return a :class:`~octoprint.access.users.UserManager` instance to use as global user manager object. This will
|
||||||
|
be called only once during initial server startup.
|
||||||
|
|
||||||
|
The provided ``components`` is a dictionary containing the already initialized system components:
|
||||||
|
|
||||||
|
* ``plugin_manager``: The :class:`~octoprint.plugin.core.PluginManager`
|
||||||
|
* ``printer_profile_manager``: The :class:`~octoprint.printer.profile.PrinterProfileManager`
|
||||||
|
* ``event_bus``: The :class:`~octoprint.events.EventManager`
|
||||||
|
* ``analysis_queue``: The :class:`~octoprint.filemanager.analysis.AnalysisQueue`
|
||||||
|
* ``slicing_manager``: The :class:`~octoprint.slicing.SlicingManager`
|
||||||
|
* ``file_manager``: The :class:`~octoprint.filemanager.FileManager`
|
||||||
|
* ``plugin_lifecycle_manager``: The :class:`~octoprint.server.LifecycleManager`
|
||||||
|
* ``preemptive_cache``: The :class:`~octoprint.server.util.flask.PreemptiveCache`
|
||||||
|
|
||||||
|
If the factory returns anything but ``None``, it will be assigned to the global ``userManager`` instance.
|
||||||
|
|
||||||
|
If none of the registered factories return a user manager instance, the class referenced by the ``config.yaml``
|
||||||
|
entry ``accessControl.userManager`` will be initialized if possible, otherwise a stock
|
||||||
|
:class:`~octoprint.access.users.FilebasedUserManager` will be instantiated, linked to the default user storage
|
||||||
|
file ``~/.octoprint/users.yaml``.
|
||||||
|
|
||||||
|
:param dict components: System components to use for user manager instance initialization
|
||||||
|
:param SettingsManager settings: The global settings manager instance to fetch configuration values from if necessary
|
||||||
|
:return: The ``userManager`` instance to use globally.
|
||||||
|
:rtype: UserManager subclass or None
|
||||||
|
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-timelapse-capture-pre:
|
||||||
|
|
||||||
|
octoprint.timelapse.capture.pre
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: capture_pre_hook(filename)
|
||||||
|
|
||||||
|
Perform specific actions prior to capturing a timelapse frame.
|
||||||
|
|
||||||
|
``filename`` will be the future path of the frame to be saved.
|
||||||
|
|
||||||
|
:param str filename: The future path of the frame to be saved.
|
||||||
|
:return: None
|
||||||
|
:rtype: None
|
||||||
|
|
||||||
|
.. _sec-plugins-hook-timelapse-capture-post:
|
||||||
|
|
||||||
|
octoprint.timelapse.capture.post
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. py:function:: capture_post_hook(filename, success)
|
||||||
|
|
||||||
|
Perform specific actions after capturing a timelapse frame.
|
||||||
|
|
||||||
|
``filename`` will be the path of the frame that should have been saved.
|
||||||
|
``sucesss`` indicates whether the capture was successful or not.
|
||||||
|
|
||||||
|
:param str filename: The path of the frame that should have been saved.
|
||||||
|
:param boolean success: Indicates whether the capture was successful or not.
|
||||||
|
:return: None
|
||||||
|
:rtype: None
|
||||||
@@ -41,15 +41,15 @@ An overview of these properties follows.
|
|||||||
OctoPrint's file manager, an instance of :class:`octoprint.filemanager.FileManager`.
|
OctoPrint's file manager, an instance of :class:`octoprint.filemanager.FileManager`.
|
||||||
``self._printer``
|
``self._printer``
|
||||||
OctoPrint's printer management object, an instance of :class:`octoprint.printer.PrinterInterface`.
|
OctoPrint's printer management object, an instance of :class:`octoprint.printer.PrinterInterface`.
|
||||||
``self._app_session_manager``
|
|
||||||
OctoPrint's application session manager, an instance of :class:`octoprint.server.util.flask.AppSessionManager`.
|
|
||||||
``self._user_manager``
|
``self._user_manager``
|
||||||
OctoPrint's user manager, an instance of :class:`octoprint.users.UserManager`.
|
OctoPrint's user manager, an instance of :class:`octoprint.access.users.UserManager`.
|
||||||
|
``self._connectivity_checker``
|
||||||
|
OctoPrint's connectivity checker, an instance of :class:`octoprint.util.ConnectivityChecker`.
|
||||||
|
|
||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
:class:`~octoprint.plugin.core.Plugin` and :class:`~octoprint.plugin.types.OctoPrintPlugin`
|
:class:`~octoprint.plugin.core.Plugin` and :class:`~octoprint.plugin.types.OctoPrintPlugin`
|
||||||
Class documentation also containing the properties shared among all mixing implementations.
|
Class documentation also containing the properties shared among all mixin implementations.
|
||||||
|
|
||||||
:ref:`Available Mixins <sec-plugins-mixins-available>`
|
:ref:`Available Mixins <sec-plugins-mixins-available>`
|
||||||
Some mixin types trigger the injection of additional properties.
|
Some mixin types trigger the injection of additional properties.
|
||||||
|
|||||||
@@ -68,11 +68,14 @@ calls are done is as follows:
|
|||||||
|
|
||||||
* Plugins with a return value that is not ``None`` for :meth:`~octoprint.plugin.core.SortablePlugin.get_sorting_key`
|
* Plugins with a return value that is not ``None`` for :meth:`~octoprint.plugin.core.SortablePlugin.get_sorting_key`
|
||||||
for the provided sorting context will be ordered among each other first. If the returned order number is equal for
|
for the provided sorting context will be ordered among each other first. If the returned order number is equal for
|
||||||
two or more implementations, the plugin's identifier will be the next sorting criteria.
|
two or more implementations, they will be sorted first by whether they come bundled with OctoPrint or not, then by
|
||||||
* After that follow plugins which returned ``None`` (the default). They are sorted by their identifier.
|
their identifier.
|
||||||
|
* After that follow plugins which returned ``None`` (the default). They are first sorted by whether they come bundled
|
||||||
|
with OctoPrint or not, then by their identifier.
|
||||||
|
|
||||||
Example: Consider three plugin implementations implementing the :class:`~octoprint.plugin.StartupPlugin` mixin, called
|
Example: Consider four plugin implementations implementing the :class:`~octoprint.plugin.StartupPlugin` mixin, called
|
||||||
``plugin_a``, ``plugin_b`` and ``plugin_c``. ``plugin_a`` doesn't override :meth:`~octoprint.plugin.core.SortablePlugin.get_sorting_key`.
|
``plugin_a``, ``plugin_b``, ``plugin_c`` and ``plugin_d``, the latter coming bundled with OctoPrint. ``plugin_a``
|
||||||
|
and ``plugin_d`` don't override :meth:`~octoprint.plugin.core.SortablePlugin.get_sorting_key`.
|
||||||
``plugin_b`` and ``plugin_c`` both return ``1`` for the sorting context ``StartupPlugin.on_startup``, ``None`` otherwise:
|
``plugin_b`` and ``plugin_c`` both return ``1`` for the sorting context ``StartupPlugin.on_startup``, ``None`` otherwise:
|
||||||
|
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
@@ -99,7 +102,7 @@ Example: Consider three plugin implementations implementing the :class:`~octopri
|
|||||||
|
|
||||||
class PluginB(octoprint.plugin.StartupPlugin):
|
class PluginB(octoprint.plugin.StartupPlugin):
|
||||||
|
|
||||||
def get_sorting_key(context):
|
def get_sorting_key(self, context):
|
||||||
if context == "StartupPlugin.on_startup":
|
if context == "StartupPlugin.on_startup":
|
||||||
return 1
|
return 1
|
||||||
return None
|
return None
|
||||||
@@ -120,7 +123,7 @@ Example: Consider three plugin implementations implementing the :class:`~octopri
|
|||||||
|
|
||||||
class PluginC(octoprint.plugin.StartupPlugin):
|
class PluginC(octoprint.plugin.StartupPlugin):
|
||||||
|
|
||||||
def get_sorting_key(context):
|
def get_sorting_key(self, context):
|
||||||
if context == "StartupPlugin.on_startup":
|
if context == "StartupPlugin.on_startup":
|
||||||
return 1
|
return 1
|
||||||
return None
|
return None
|
||||||
@@ -134,13 +137,45 @@ Example: Consider three plugin implementations implementing the :class:`~octopri
|
|||||||
|
|
||||||
__plugin_implementation__ = PluginC()
|
__plugin_implementation__ = PluginC()
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
:linenos:
|
||||||
|
:caption: plugin_d.py
|
||||||
|
|
||||||
|
# in this example this is bundled with OctoPrint
|
||||||
|
import octoprint.plugin
|
||||||
|
|
||||||
|
class PluginD(octoprint.plugin.StartupPlugin):
|
||||||
|
|
||||||
|
def on_startup(self, *args, **kwargs):
|
||||||
|
self._logger.info("PluginD starting up")
|
||||||
|
|
||||||
|
def on_after_startup(self, *args, **kwargs):
|
||||||
|
self._logger.info("PluginD started up")
|
||||||
|
|
||||||
|
__plugin_implementation__ = PluginD()
|
||||||
|
|
||||||
OctoPrint will detect that ``plugin_b`` and ``plugin_c`` define a order number, and since it's identical for both (``1``)
|
OctoPrint will detect that ``plugin_b`` and ``plugin_c`` define a order number, and since it's identical for both (``1``)
|
||||||
will order both plugins based on their plugin identifier. ``plugin_a`` doesn't define a sort key and hence will be
|
will order both plugins based first on their bundling status and then on their plugin identifier.
|
||||||
put after the other two. The execution order of the ``on_startup`` method will hence be ``plugin_b``, ``plugin_c``, ``plugin_a``.
|
``plugin_a`` and ``plugin_d`` don't define a sort key and hence will be
|
||||||
|
put after the other two, with ``plugin_d`` coming *before* ``plugin_a`` since it comes bundled with OctoPrint.
|
||||||
|
The execution order of the ``on_startup`` method will hence be ``plugin_b``, ``plugin_c``, ``plugin_d``, ``plugin_a``.
|
||||||
|
|
||||||
Now, the execution order of the ``on_after_startup`` method will be determined based on another sorting context,
|
Now, the execution order of the ``on_after_startup`` method will be determined based on another sorting context,
|
||||||
``StartupPlugin.on_after_startup`` for which all of the plugins return ``None``. Hence, the execution order of the
|
``StartupPlugin.on_after_startup`` for which all of the plugins return ``None``. Hence, the execution order of the
|
||||||
``on_after_startup`` method will be purely ordered by plugin identifier, ``plugin_a``, ``plugin_b``, ``plugin_c``.
|
``on_after_startup`` method will be ordered first by bundle status, then by plugin identifier: ``plugin_d``, ``plugin_a``, ``plugin_b``, ``plugin_c``.
|
||||||
|
|
||||||
|
This will result in the following messages to be generated:
|
||||||
|
|
||||||
|
.. code-block:: plain
|
||||||
|
|
||||||
|
Plugin B starting up
|
||||||
|
Plugin C starting up
|
||||||
|
Plugin D starting up
|
||||||
|
Plugin A starting up
|
||||||
|
Plugin D started up
|
||||||
|
Plugin A started up
|
||||||
|
Plugin B started up
|
||||||
|
Plugin C started up
|
||||||
|
|
||||||
.. _sec-plugins-mixins-injectedproperties:
|
.. _sec-plugins-mixins-injectedproperties:
|
||||||
|
|
||||||
@@ -153,7 +188,7 @@ An overview of these properties can be found in the section :ref:`Injected Prope
|
|||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
:class:`~octoprint.plugin.core.Plugin` and :class:`~octoprint.plugin.types.OctoPrintPlugin`
|
:class:`~octoprint.plugin.core.Plugin` and :class:`~octoprint.plugin.types.OctoPrintPlugin`
|
||||||
Class documentation also containing the properties shared among all mixing implementations.
|
Class documentation also containing the properties shared among all mixin implementations.
|
||||||
|
|
||||||
.. _sec-plugins-mixins-available:
|
.. _sec-plugins-mixins-available:
|
||||||
|
|
||||||
|
|||||||
@@ -56,9 +56,9 @@ Example:
|
|||||||
// more of your view model's implementation
|
// more of your view model's implementation
|
||||||
}
|
}
|
||||||
|
|
||||||
// we don't explicitely declare a name property here
|
// we don't explicitly declare a name property here
|
||||||
// our view model will be registered under "myCustomViewModel" (implicit
|
// our view model will be registered under "myCustomViewModel" (implicit
|
||||||
// name derived from contructor name) and "yourCustomViewModel" (explicitely
|
// name derived from constructor name) and "yourCustomViewModel" (explicitly
|
||||||
// provided as additional name)
|
// provided as additional name)
|
||||||
OCTOPRINT_VIEWMODELS.push({
|
OCTOPRINT_VIEWMODELS.push({
|
||||||
construct: MyCustomViewModel,
|
construct: MyCustomViewModel,
|
||||||
@@ -125,7 +125,7 @@ gcodeFilesViewModel
|
|||||||
logViewModel
|
logViewModel
|
||||||
View model for the logfile settings dialog.
|
View model for the logfile settings dialog.
|
||||||
loginStateViewModel
|
loginStateViewModel
|
||||||
View model for the current loginstate of the user, very interesting for plugins that need to
|
View model for the current login state of the user, very interesting for plugins that need to
|
||||||
evaluate the current login state or information about the current user, e.g. associated roles.
|
evaluate the current login state or information about the current user, e.g. associated roles.
|
||||||
navigationViewModel
|
navigationViewModel
|
||||||
View model for the navigation bar.
|
View model for the navigation bar.
|
||||||
@@ -168,7 +168,7 @@ OctoPrint's web application will call several callbacks on all registered view m
|
|||||||
Those are listed below:
|
Those are listed below:
|
||||||
|
|
||||||
onStartup()
|
onStartup()
|
||||||
Called when the first initialization has been done: All view models are constructed and hence their dependencies
|
Called when the first initialization has been done. All view models are constructed and hence their dependencies
|
||||||
resolved, no bindings have been done yet.
|
resolved, no bindings have been done yet.
|
||||||
|
|
||||||
onBeforeBinding()
|
onBeforeBinding()
|
||||||
@@ -210,7 +210,7 @@ onDataUpdaterPluginMessage(plugin, message)
|
|||||||
Called when a plugin message is pushed from the server with the identifier of the calling plugin as first
|
Called when a plugin message is pushed from the server with the identifier of the calling plugin as first
|
||||||
and the actual message as the second parameter. Note that the latter might be a full fledged object, depending
|
and the actual message as the second parameter. Note that the latter might be a full fledged object, depending
|
||||||
on the plugin sending the message. You can use this method to asynchronously push data from your plugin's server
|
on the plugin sending the message. You can use this method to asynchronously push data from your plugin's server
|
||||||
component to it's frontend component.
|
component to its frontend component.
|
||||||
|
|
||||||
onUserLoggedIn(user)
|
onUserLoggedIn(user)
|
||||||
Called when a user gets logged into the web app, either passively (upon initial load of the page due to a valid
|
Called when a user gets logged into the web app, either passively (upon initial load of the page due to a valid
|
||||||
@@ -220,6 +220,11 @@ onUserLoggedIn(user)
|
|||||||
onUserLoggedOut()
|
onUserLoggedOut()
|
||||||
Called when a user gets logged out of the web app.
|
Called when a user gets logged out of the web app.
|
||||||
|
|
||||||
|
onUserPermissionsChanged(user)
|
||||||
|
Called when a change in the permissions of the current user is detected. The user data of the just logged in user
|
||||||
|
will be provided as only parameter. Note that this may also be triggered for not logged in guests if the guest
|
||||||
|
group is modified. In this case ``user`` will be undefined.
|
||||||
|
|
||||||
onTabChange(next, current)
|
onTabChange(next, current)
|
||||||
Called before the main tab view switches to a new tab, so `before` the new tab becomes visible. Called with the
|
Called before the main tab view switches to a new tab, so `before` the new tab becomes visible. Called with the
|
||||||
next (changed to) and current (still visible) tab's hash (e.g. ``#control``). Note that ``current`` might be undefined
|
next (changed to) and current (still visible) tab's hash (e.g. ``#control``). Note that ``current`` might be undefined
|
||||||
@@ -299,6 +304,138 @@ on your view model, taking a list of all bound view models:
|
|||||||
});
|
});
|
||||||
})
|
})
|
||||||
|
|
||||||
|
.. _sec-plugins-viewmodels-livecycle:
|
||||||
|
|
||||||
|
Lifecycle diagrams
|
||||||
|
------------------
|
||||||
|
|
||||||
|
.. _sec-plugins-viewmodels-startup:
|
||||||
|
|
||||||
|
Web interface startup
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. mermaid::
|
||||||
|
|
||||||
|
sequenceDiagram
|
||||||
|
participant Main
|
||||||
|
participant DataUpdater
|
||||||
|
participant LoginStateViewModel
|
||||||
|
participant SettingsViewModel
|
||||||
|
participant UiStateViewModel
|
||||||
|
|
||||||
|
Note over DataUpdater: connectCallback = undefined
|
||||||
|
Note over UiStateViewModel: loaded = false
|
||||||
|
|
||||||
|
activate Main
|
||||||
|
|
||||||
|
Main->>+DataUpdater: connect
|
||||||
|
Note right of DataUpdater: initialized = false
|
||||||
|
DataUpdater-->>Main: ok
|
||||||
|
deactivate Main
|
||||||
|
DataUpdater->>DataUpdater: asynchronous connect to server...
|
||||||
|
activate DataUpdater
|
||||||
|
Note right of DataUpdater: store any callbacks instead of triggering (e.g. onServerConnect, fromHistoryData, fromCurrentData, ...)
|
||||||
|
DataUpdater-X+Main: done
|
||||||
|
deactivate DataUpdater
|
||||||
|
deactivate DataUpdater
|
||||||
|
|
||||||
|
Main->>+DataUpdater: connectCallback = onServerConnect
|
||||||
|
Note right of DataUpdater: connectCallback = onServerConnect
|
||||||
|
DataUpdater-->>-Main: ok
|
||||||
|
Main->>+Main: onServerConnect
|
||||||
|
Main->>+LoginStateViewModel: passiveLogin
|
||||||
|
LoginStateViewModel-->>Main: ok
|
||||||
|
Main-->>Main: ok
|
||||||
|
deactivate Main
|
||||||
|
deactivate Main
|
||||||
|
|
||||||
|
LoginStateViewModel->>+LoginStateViewModel: asynchronous passive login
|
||||||
|
Note over Main,UiStateViewModel: Session available!
|
||||||
|
LoginStateViewModel-X+Main: done
|
||||||
|
deactivate LoginStateViewModel
|
||||||
|
deactivate LoginStateViewModel
|
||||||
|
|
||||||
|
Main->>+DataUpdater: initialized
|
||||||
|
Note right of DataUpdater: initialized = true
|
||||||
|
DataUpdater->DataUpdater: trigger stored callbacks
|
||||||
|
DataUpdater-->>-Main: ok
|
||||||
|
|
||||||
|
Main->>+Main: fetchSettings
|
||||||
|
Note right of Main: trigger onStartup
|
||||||
|
|
||||||
|
Main->>+SettingsViewModel: requestData
|
||||||
|
SettingsViewModel-->>Main: ok
|
||||||
|
deactivate Main
|
||||||
|
deactivate Main
|
||||||
|
|
||||||
|
SettingsViewModel->>+SettingsViewModel: asynchronous settings fetch
|
||||||
|
Note over Main,UiStateViewModel: Settings available!
|
||||||
|
SettingsViewModel-X+Main: done
|
||||||
|
deactivate SettingsViewModel
|
||||||
|
deactivate SettingsViewModel
|
||||||
|
|
||||||
|
Main->>+Main: bindViewModels
|
||||||
|
|
||||||
|
loop for each view model
|
||||||
|
Main->Main: trigger onBeforeBinding
|
||||||
|
Main->Main: trigger onBoundTo
|
||||||
|
Main->Main: trigger onAfterBinding
|
||||||
|
end
|
||||||
|
|
||||||
|
Main->Main: trigger onAllBound
|
||||||
|
opt User is logged in
|
||||||
|
Main->>+LoginStateViewModel: onAllBound
|
||||||
|
LoginStateViewModel->LoginStateViewModel: trigger onUserLoggedIn
|
||||||
|
LoginStateViewModel-->>-Main: ok
|
||||||
|
end
|
||||||
|
|
||||||
|
Main->>+UiStateViewModel: loaded
|
||||||
|
Note right of UiStateViewModel: loaded = true
|
||||||
|
UiStateViewModel-->>-Main: ok
|
||||||
|
|
||||||
|
Main->Main: trigger onStartupComplete
|
||||||
|
deactivate Main
|
||||||
|
deactivate Main
|
||||||
|
|
||||||
|
|
||||||
|
.. _sec-plugins-viewmodels-reconnect:
|
||||||
|
|
||||||
|
Web interface reconnect
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
.. mermaid::
|
||||||
|
|
||||||
|
sequenceDiagram
|
||||||
|
participant onServerConnect
|
||||||
|
participant DataUpdater
|
||||||
|
participant LoginStateViewModel
|
||||||
|
|
||||||
|
activate DataUpdater
|
||||||
|
DataUpdater->>DataUpdater: call connectCallback
|
||||||
|
DataUpdater->>+onServerConnect: call
|
||||||
|
onServerConnect-->>DataUpdater: ok
|
||||||
|
deactivate DataUpdater
|
||||||
|
|
||||||
|
onServerConnect->>+LoginStateViewModel: passiveLogin
|
||||||
|
LoginStateViewModel-->>onServerConnect: ok
|
||||||
|
deactivate onServerConnect
|
||||||
|
LoginStateViewModel->>+LoginStateViewModel: asynchronous passive login
|
||||||
|
Note over onServerConnect,LoginStateViewModel: Session available!
|
||||||
|
opt User is logged in
|
||||||
|
LoginStateViewModel->LoginStateViewModel: trigger onUserLoggedIn
|
||||||
|
end
|
||||||
|
|
||||||
|
activate onServerConnect
|
||||||
|
LoginStateViewModel-XonServerConnect: done
|
||||||
|
deactivate LoginStateViewModel
|
||||||
|
deactivate LoginStateViewModel
|
||||||
|
|
||||||
|
onServerConnect->>+DataUpdater: initialized
|
||||||
|
DataUpdater->DataUpdater: trigger stored callbacks
|
||||||
|
DataUpdater-->>onServerConnect: ok
|
||||||
|
deactivate DataUpdater
|
||||||
|
deactivate onServerConnect
|
||||||
|
|
||||||
.. seealso::
|
.. seealso::
|
||||||
|
|
||||||
`OctoPrint's core viewmodels <https://github.com/foosel/OctoPrint/tree/devel/src/octoprint/static/js/app/viewmodels>`_
|
`OctoPrint's core viewmodels <https://github.com/foosel/OctoPrint/tree/devel/src/octoprint/static/js/app/viewmodels>`_
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
# coding=utf-8
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import, division, print_function, unicode_literals
|
||||||
|
|
||||||
__author__ = "Gina Häußge <osd@foosel.net>"
|
__author__ = "Gina Häußge <osd@foosel.net>"
|
||||||
__license__ = 'The MIT License <http://opensource.org/licenses/MIT>'
|
__license__ = 'The MIT License <http://opensource.org/licenses/MIT>'
|
||||||
@@ -84,7 +84,7 @@ class CodeBlockExt(CodeBlock):
|
|||||||
return node
|
return node
|
||||||
|
|
||||||
# replace all created literal_blocks with literal_block_ext instances
|
# replace all created literal_blocks with literal_block_ext instances
|
||||||
return map(find_and_wrap_literal_block, code_block)
|
return list(map(find_and_wrap_literal_block, code_block))
|
||||||
|
|
||||||
def _wrap_literal_block(self, node):
|
def _wrap_literal_block(self, node):
|
||||||
literal = literal_block_ext.from_literal_block(node)
|
literal = literal_block_ext.from_literal_block(node)
|
||||||
@@ -160,10 +160,10 @@ class PygmentsBridgeExt(object):
|
|||||||
# for py3, recognize interactive sessions, but do not try parsing...
|
# for py3, recognize interactive sessions, but do not try parsing...
|
||||||
lexer = sphinx.highlighting.lexers['pycon3']
|
lexer = sphinx.highlighting.lexers['pycon3']
|
||||||
elif lang == 'guess':
|
elif lang == 'guess':
|
||||||
try:
|
# try:
|
||||||
lexer = sphinx.highlighting.guess_lexer(source)
|
lexer = sphinx.highlighting.guess_lexer(source)
|
||||||
except Exception:
|
# except Exception:
|
||||||
lexer = sphinx.highlighting.lexers['none']
|
# lexer = sphinx.highlighting.lexers['none']
|
||||||
else:
|
else:
|
||||||
if lang in sphinx.highlighting.lexers:
|
if lang in sphinx.highlighting.lexers:
|
||||||
lexer = sphinx.highlighting.lexers[lang]
|
lexer = sphinx.highlighting.lexers[lang]
|
||||||
@@ -255,4 +255,4 @@ def setup(app):
|
|||||||
handler = (visit_literal_block_ext, depart_literal_block_ext)
|
handler = (visit_literal_block_ext, depart_literal_block_ext)
|
||||||
app.add_node(literal_block_ext, html=handler, latex=handler, text=handler)
|
app.add_node(literal_block_ext, html=handler, latex=handler, text=handler)
|
||||||
|
|
||||||
return dict(version="0.1")
|
return dict(version="0.1")
|
||||||