From ebfb3ac4924b420f7dec4a8b279f3ddf5c9a322b Mon Sep 17 00:00:00 2001 From: Lilian937342 Date: Thu, 28 Jul 2022 11:07:03 +0200 Subject: [PATCH] websocket --- .../api/api/__pycache__/asgi.cpython-310.pyc | Bin 918 -> 918 bytes .../api/__pycache__/settings.cpython-310.pyc | Bin 4464 -> 4184 bytes backend/api/api/settings.py | 4 ++-- backend/api/db.sqlite3 | Bin 1585152 -> 1585152 bytes .../__pycache__/views.cpython-310.pyc | Bin 18776 -> 18786 bytes backend/api/exercices/views.py | 4 ++-- .../__pycache__/consumers.cpython-310.pyc | Bin 12318 -> 12341 bytes backend/api/room/consumers.py | 3 +-- frontend/.env.production | 6 ------ frontend/context/websocket.context.js | 2 +- 10 files changed, 6 insertions(+), 13 deletions(-) diff --git a/backend/api/api/__pycache__/asgi.cpython-310.pyc b/backend/api/api/__pycache__/asgi.cpython-310.pyc index 3f2c180c69e7e74e77ed62c6578c4fe0fa29235b..236b7a5e74628e29454d426b0b2c8eff675d15b9 100644 GIT binary patch delta 19 ZcmbQnK8>9#pO=@50SML|-pJL%3;-%r1d{*& delta 19 ZcmbQnK8>9#pO=@50SJnYY~<=;1^_7W1Xut7 diff --git a/backend/api/api/__pycache__/settings.cpython-310.pyc b/backend/api/api/__pycache__/settings.cpython-310.pyc index 253607b3c4ae82f589ece68906eb1d58f63001e1..f8d68288acd401d2996d5b2a8a6cdad47d76de7b 100644 GIT binary patch delta 94 zcmeyMbVETqpO=@50SG?&KT29J$-wX!#6bpZK#l_t7YA(A4q#+u3TDtW*}RRBm77UZ he{%uv1t!jw3`JHz1w~eqqXgm@r%m1|FrA5o7XX6s6TJWc delta 375 zcmcbi@IgsCpO=@50SMl3ZcADz$-wX!#6boiSqC64Zri9Gz-X$(YHQ zVv^37VxD3#hbhGp#7<>gpr2xuV!eAG;rRxQk6s0ESdL-th zK~a7|VtQgpswV3#_A;~7qT8Lu eSQwf9GyP{_V`60a$HdCQ$i)a`{bl;k^#uUyw{Y|T diff --git a/backend/api/api/settings.py b/backend/api/api/settings.py index bb89aca0..08fb5431 100644 --- a/backend/api/api/settings.py +++ b/backend/api/api/settings.py @@ -232,7 +232,7 @@ REST_FRAMEWORK = { -LOGGING = { +"""LOGGING = { 'version': 1, 'disable_existing_loggers': False, 'handlers': { @@ -251,7 +251,7 @@ LOGGING = { 'propagate': False, }, }, -} +}""" diff --git a/backend/api/db.sqlite3 b/backend/api/db.sqlite3 index ace2d4eab0dd09a7b35ebe5101bb864ac423946b..620f2ed12c404f63e9bb41e656de8f1069a635bb 100644 GIT binary patch delta 5812 zcmcIoTWllOc_u}QOX|X-t#`A#wGnf*M(V;l)SS5wTO;OW#G7~%MM~5{73WIve!m(H zSBj$`eMnq8FoOm~(4uGxBnY+8-> zQF(hMW)$A}@e1{dbq4&(0Pcfdy|YmJC0Lj>8I2a(xU?SJzIWSbzKwc(VgUaMK6!Ux z<|FW&*<>)<^uju4Fc@aRPYvKx@G=Cv!^8?_xU^W_!lua1dPOEQR zV^;6DzG?9sefs>&!jJ8<;KQ+b@b74f4@XNM>l1uD^DelmgP;Vxbo%rX^XlbI&(Zz= znVDN!Fx$Uv09EiM`#;&g{m#YPuiJ-yi+RUw)JTfrHH}jVh2|JlQ(20oWtFByk|r4u z=V*oCL`5QSg1~SVBRB`nyKvk^uucZYA;H-Ev-(7|A~7_l@;s~YDl5sN$l;0#IgKS) zQPnt!VMUJNxRZ&l;-mxTTsY&xp%c;+!!s7Y8O=0`ub6&wwDG*@&Vm^@3?Kpq;QPRV zKraF8rfKIhL$-_}D<=5jX9YI;lNHnNAd~MKz`ub{z`ug`k;%USU)E`~S@hB}tCuD- z_%Fk(LBBQ6pfxowqGI0UFxY>#cz5BO^Luk1+jAHG-g0O5cg>2)@eX`t#xy)|&(B6) zzvyNQ`8?HE`EmuZTWHc+o2;uc+pqBuLZwSP)ljcghzPM<-<|Mi*lKg&4WrP;sSUiz(vC6F1W&OC zH|Ay|Uro7Hs?x6)`&Fjbt`$4wW~tCAH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X!y4^iDe`2QE5hz&6lN(85#XHv&qJYGJe^dY~;kmcz*IS zlRAzPu^P@4u@t$lg%~xE=SSwf~xIijJX(3~ZayIJ(#-i&$zBHJxBFRuIR3nt4n#}|h zKT#uCE0`w?<}(BN*MRESQj}_hW;4uXN>N+L1e9f|5lm4NXQ&k{ktvZ~AXme`kP#@N zK8LA9K1(4*W3r&VxbWw4Mn(n@j0EBohF}Iw&CPLU;!KkpEut6|C*QHCVd7-m9BSFj z$jCPNrd1Fl$7UVtFrdFTH`^LAYCfzHT_6jzjxj|8=sd9+u@p_P^Dfnh)`|k12jYXA Z_h9mUJ5R>Hn>Fp9F*CAl7H|$?0{}*LX+Qt~ diff --git a/backend/api/exercices/views.py b/backend/api/exercices/views.py index 68083ddf..4edcd0d4 100644 --- a/backend/api/exercices/views.py +++ b/backend/api/exercices/views.py @@ -432,7 +432,7 @@ def pdfGen(request): check=True, cwd=direct) except TexError: - raise TexError(log=log, source=latex, + raise TexError(log="./logs.txt", source=latex, template_name='test.tex') try: subprocess.run(command, shell=True, @@ -441,7 +441,7 @@ def pdfGen(request): check=True, cwd=direct) except TexError: - raise TexError(log=log, source=latex, + raise TexError(log='./logs.txt', source=latex, template_name='test.tex') with open(os.path.join(direct, 'tmp.pdf'), 'rb') as out: diff --git a/backend/api/room/__pycache__/consumers.cpython-310.pyc b/backend/api/room/__pycache__/consumers.cpython-310.pyc index b7c5172d9254cb7582147c9d316cd9da17c4166f..b77f23ac6e3d43a69da82c805107418396d7d233 100644 GIT binary patch delta 3079 zcma)8O;A%;6n-xWkOC3pCxpL{hyoE1v>@`+NSWHAt-oNaV2k19DGx#t?|aBptx9XH zZMC(YjT>7XXF9`l(NU+1cGYFK&ggXJZQ6CmT{|vZ^?v7Rz?e8@ao&07e&0Fgo_p?j z`TpoHM|~-uuUL`4?)l%RXYcq9y40JbxxNTmYvM(psj6~Dxmk8g*{Q^pQAJe_%jcL9 z@m_QHdu@-Un^vTp2Hjd9EsUgP7ifu;sV}Rx$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W{=^O#O_OL8)p5(Y0= z8SM3W_|w+5gLwlpoiR1Oeg&=b%vX;&;q9OmpVqe8K*I~W21;3_c(9iNR&hUXuh~iK zozUeTDG#;pk|+7A?dQV7;1^{bNjV7AQpC@tV)YFHM-hj?|7uSkBfHJkF3AdJQdpX$ zOxKqphMHn@+wcXjCVf8N7}E3i9&{|q)^Hz#b+>>y_MSk|-86xy*j+*qa5DN}P!QK( zJPnu!P!>la%>dj0)KFYo9N$SN{SAsJdQ8o2z4yhumrn67gEL1oFdWm2ocrN}Vk$IZ z%&M4XD0(8HDk*E4YbaG*5HI=o!=RVXbT)^V;M6`%$(ZF-AkhJ8N{tnqlI%mliNjZd z-|ZZdHU3*?qcsG#52#Xn$+F|oDIPxFH8Q@D8%k?6@CT3zgf7~@b zh^tbNWxADf(Rf@>>>>>> 14ab2403983411dea6475cad781ddef9a1c89b7c diff --git a/frontend/context/websocket.context.js b/frontend/context/websocket.context.js index b3c2e64c..021f15ca 100644 --- a/frontend/context/websocket.context.js +++ b/frontend/context/websocket.context.js @@ -18,7 +18,7 @@ export const WebsocketProvider = ({ children }) => { var url = url.startsWith('/')? url: '/' + url ws.current = new ReconnectingWebSocket( - `ws://${process.env.NEXT_PUBLIC_HOST}:${process.env.NEXT_PUBLIC_PORT}${url}` + `ws://${process.env.NEXT_PUBLIC_HOSTNAME}:${process.env.NEXT_PUBLIC_PORT}${url}` ); ws.current.onopen = () => {