Commit graph

24 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 3feda678e2 some little fixes 2019-03-03 19:14:00 +01:00
Bastian Schroll 4b69b08028 fix test config file location and paths 2019-03-03 13:58:37 +01:00
Bastian Schroll 3fa10911c9 remove generall exception handling 2019-03-02 09:15:40 +01:00
Bastian Schroll a42676010e some reworks
- rework configYaml
- rework router mechanism test
- move plugin and module files
2019-03-01 12:09:12 +01:00
Bastian Schroll ff8e1347bd add fixme warning 2018-09-21 12:43:43 +02:00
Bastian Schroll f0081d6e6d fix path 2018-09-20 10:53:09 +02:00
Bastian Schroll 449c8f9726 add system adaption for config path 2018-09-20 09:51:47 +02:00
Bastian Schroll 478868c225 change comment 2018-09-20 08:10:40 +02:00
Bastian Schroll aca20faf18 add comment 2018-09-20 08:02:42 +02:00
Bastian Schroll 2037921ee6 change a todo to note 2018-09-19 15:09:30 +02:00
Bastian Schroll a6e10dd6f5 fix error 2018-09-18 05:48:18 +02:00
Bastian Schroll 16a8424b80 logs on linux in /var/log/boswatch/
on windows in log/ folder
2018-09-17 20:15:30 +02:00
Bastian Schroll a1e8393627 little changes + tests 2018-02-22 07:34:42 +01:00
Bastian Schroll b23cc40e4a little changes (comment/todo) 2018-02-02 23:42:34 +01:00
Bastian Schroll d80db0d6cc add template plugin 2018-01-14 16:28:11 +01:00
Bastian Schroll f0d19eaba0 some little changes 2018-01-13 09:56:46 +01:00
Bastian Schroll 6e011301d4 fix some typos and other 2018-01-11 13:01:27 +01:00
Bastian Schroll 1ba76cc66b edit some files 2018-01-08 23:42:26 +01:00
Bastian Schroll 2b49059594 new tests for config class 2018-01-08 14:35:54 +01:00
Bastian Schroll 9a7dbaeade little edits 2018-01-08 07:47:32 +01:00
Bastian Schroll f64a521bd9 little adds and changes 2018-01-07 23:41:52 +01:00
Bastian Schroll bf6777d095 edit paths and descriptor tests 2018-01-07 23:02:04 +01:00
Bastian Schroll 73c0541629 add server/client class 2018-01-07 21:50:41 +01:00