Commit graph

75 commits

Author SHA1 Message Date
Luflosi
d4dcc75711
Avoid "DeprecationWarning: invalid escape sequence"
Without this change, many warnings like this will be generated while running pytest:
```
test/test_template.py:3
  /build/source/test/test_template.py:3: DeprecationWarning: invalid escape sequence '\/'
    """!
```
This can also be seen when manually running python with warnings enabled.

This happens because the comment uses a multiline string and Python interprets the backslash in the logo as an escape character and complains that \/ is not a valid escape sequence. To fix this, prepend the string with the letter r to indicate that the backslash should be treated as a literal character, see https://docs.python.org/3/reference/lexical_analysis.html#index-20.
I also applied this change to all the comment strings since that shouldn't break anything and to establish it as a pattern for the future so this problem hopefully never happens again.

This is what I did specifically:
- Change the comment at the top of bw_client.py and bw_server.py to start with `"""!` since that seems to be the pattern here
- Search-and-Replace all occurances of `"""!` with `r"""!`
- Manually change the strings in `logoToLog()` in boswatch/utils/header.py
2023-09-19 17:49:09 +02:00
Bastian Schroll
e8c0446943
edit docs 2019-10-26 16:23:42 +02:00
Bastian Schroll
1776f91c9e
remove unneded properties 2019-10-25 13:44:22 +02:00
Bastian Schroll
bb1a7f21f9
fix server/client encoding 2019-10-24 18:46:22 +02:00
Bastian Schroll
72f4f3c8d8 fix false socket.shutdown call 2019-10-24 10:55:25 +02:00
Bastian Schroll
60d05dc235 fix some log messages 2019-10-24 10:08:07 +02:00
Bastian Schroll
464c0c2298
fix server/client connection 2019-10-23 19:05:09 +02:00
Bastian Schroll
549fbafc29
fix client.isConnected() 2019-10-23 15:26:35 +02:00
Bastian Schroll
504728191d add recv timeout for client 2019-10-23 14:17:12 +02:00
Bastian Schroll
50095bf4a7 fix errors 2019-10-23 09:19:32 +02:00
Bastian Schroll
3cd5a59bb5 improve client isConnected method 2019-10-23 08:59:19 +02:00
Bastian Schroll
f88c3ea03f improve logging 2019-10-23 08:10:50 +02:00
Bastian Schroll
5f30bcb2f3 fix server test 2019-10-21 12:24:25 +02:00
Bastian Schroll
1ae54bee27 fix server test 2019-10-21 11:53:12 +02:00
Bastian Schroll
422109f3fe test changes 2019-10-21 11:22:53 +02:00
Bastian Schroll
0e587e7698 fix server test 2019-10-21 10:11:54 +02:00
Bastian Schroll
06549b8e26 some improvements 2019-10-20 19:07:16 +02:00
Bastian Schroll
056e7857e5 simplify server/client exception handling 2019-10-20 18:55:02 +02:00
Bastian Schroll
ae36cf8045 changes in client 2019-10-20 17:56:40 +02:00
Bastian Schroll
0445dc38cc fix test_serverStopsWhileConnected 2019-10-20 17:37:37 +02:00
Bastian Schroll
6f364b8e6a fix server client issues
- add test for server stops until clients connected
- add header for data packets
- check header on read and read only data size in
- make readings non blocking
2019-10-20 17:21:03 +02:00
Bastian Schroll
d87247783d fix in TCPClient 2019-09-20 18:19:46 +02:00
Bastian Schroll
43674989b9 little change in server test 2019-03-03 20:14:46 +01:00
Bastian Schroll
c76c179225 various pylint fixes 2019-03-03 19:39:53 +01:00
Bastian Schroll
e372fb75b4 fix some classes for testing 2019-03-03 09:56:36 +01:00
Bastian Schroll
39d88f3e3d implement new router system in server 2019-03-02 09:17:20 +01:00
Bastian Schroll
3fa10911c9 remove generall exception handling 2019-03-02 09:15:40 +01:00
Bastian Schroll
f487bfc104 some refactoring 2019-03-01 22:12:29 +01:00
Bastian Schroll
9371b71ee0 add isRunning/isConnected Props to server and client 2019-02-28 08:57:41 +01:00
Bastian Schroll
e2ca436e5d make client ready for broadcast function 2019-02-27 12:08:55 +01:00
Bastian Schroll
e8c43fc124 Merge branch 'fixes' into develop 2018-09-25 19:10:32 +02:00
Bastian Schroll
bbf71a34a7
Merge branch 'develop' into broadcast 2018-09-25 19:06:56 +02:00
Bastian Schroll
ffb8bba460 fix some small pep8 err 2018-09-25 19:00:07 +02:00
Bastian Schroll
22588caac5 add unittest 2018-09-25 18:50:52 +02:00
Bastian Schroll
26af2ef18b fix in runningState management 2018-09-23 21:27:40 +02:00
Bastian Schroll
59f6ec0732 check running state, add prop for running state 2018-09-23 21:22:22 +02:00
Bastian Schroll
71065672a7 some improvements 2018-09-23 18:44:58 +02:00
Bastian Schroll
16c5388d3d some improvements 2018-09-23 18:19:48 +02:00
Bastian Schroll
9c091fb1f7 add more docu 2018-09-22 22:58:19 +02:00
Bastian Schroll
1b7341c07e resolve todo and add some docu 2018-09-22 08:39:41 +02:00
Bastian Schroll
bec034827f some improvements
- run server in thread
- improve some logging msg
2018-09-21 22:36:11 +02:00
Bastian Schroll
1837ba46af
Merge branch 'develop' into ping 2018-09-21 22:09:30 +02:00
Bastian Schroll
deee515b15 broadcasting func - get conn infos from server 2018-09-21 22:02:07 +02:00
Bastian Schroll
9a3c28744b fix a error in server 2018-09-21 16:37:23 +02:00
Bastian Schroll
24083ad6e8 little improvements 2018-09-21 16:05:48 +02:00
Bastian Schroll
cecde86005 insert logging 2018-09-21 15:27:02 +02:00
Bastian Schroll
11eab418ed improve exc handling and tests 2018-09-21 14:21:33 +02:00
Bastian Schroll
c2b3093bb5
Merge branch 'develop' into server_queue 2018-09-21 12:53:06 +02:00
Bastian Schroll
11dab44098
Merge branch 'develop' into ping 2018-09-21 12:50:08 +02:00
Bastian Schroll
b300d0c578 add docu to NetCheck class 2018-09-21 12:39:36 +02:00