gursi26 commited on
Commit
1eb1bd0
1 Parent(s): 4be4378

trying something

Browse files
Files changed (1) hide show
  1. app.py +10 -3
app.py CHANGED
@@ -3,10 +3,17 @@ import io, sys, time
3
  from utils import *
4
  from client import CobotController
5
 
6
- render_log_window()
 
 
 
 
 
 
 
 
7
 
8
 
9
  user_id = get_user_id()
10
  user, passwd, host, endpoint, port = get_credentials(False)
11
- client = CobotController(user, passwd, host, port, endpoint, user_id)
12
-
 
3
  from utils import *
4
  from client import CobotController
5
 
6
+ # render_log_window()
7
+
8
+ class StreamlitRedirector:
9
+ def write(self, message):
10
+ if message.strip(): # Avoids writing empty lines
11
+ st.write(message)
12
+
13
+ # Set up the redirection
14
+ sys.stdout = StreamlitRedirector()
15
 
16
 
17
  user_id = get_user_id()
18
  user, passwd, host, endpoint, port = get_credentials(False)
19
+ client = CobotController(user, passwd, host, port, endpoint, user_id)