Tests and issues found - wb8tyw/D-Rats GitHub Wiki

Setting up just a page on testing D-Rats

Setup of two d-rats clients and a ratflector on a single node.

Had to modify pluginsrv.py setup of SimpleXMLRPCServer to use port 0 (pick a free port) instead of 9100. Have not been able to find any reason for the use of port 9100. Just seems to need a unique port to work and the API can safely pick one.

Plan to address the pylint issues in a separate Wiki page later.

In the mean time, debugging is made harder by using what pylint calls bare-except and broad-except. In the professional projects that I work on, I am not allowed to use "except:" or "except Exception:". The coding standard is that you must specify the exception(s) that you are catching. If anything else shows up, that is a bug.

For this pass, I am just trying to silence the pylint warnings, either with quick fixes, or supressions.

Bugs being chased down

bytearray issues.

Chat

Submitted fix upstream for chat status issues.

Files

Testing files transfer for bytearray issues. Submitted bytearray fix to upstream.

Generic Exceptions

03/14/2021 15:20:50 Sessionmgr : Received block 0:2 for sessionchat' 03/14/2021 15:20:50 x CommGeneric Exception <class 'socket.error'> [Errno 11] Resource temporarily unavailable 03/14/2021 15:20:50 Transport : Got a block: DDT2+: 0:1:5 WB8TYW-1->CQCQCQ (1On `

popup method now takes an additional parameter.

Locally fixed in main_station. Need to fix in other places.

Outgoing request for position timed out - stack trace on D-rats - another bytearray issue as below

Incoming request for position got a stack trace

So does Get Version

rpc.py needs to handle bytearray. Fix submited to upstream.

Remote file connected to self allowed, does not work

If you connect to your self as a remote file it appears to freeze until you disconnect.

Existing bug/feature to be dealt with later.

03/21/2021 14:56:26 RPC : Sending jobFile list request' to WB8TYW-1 03/21/2021 14:56:26 RPC : Job sent 03/21/2021 14:56:26 Transport : Waiting 1.1 sec before transmitting 03/21/2021 14:56:27 Transport : Sending block: DDT2+: 1:2:0 WB8TYW-1->WB8TYW-1 (RPCFileListJob...[15]) 03/21/2021 14:56:27 Transport : Got a block: DDT2+: 1:2:0 WB8TYW-1->WB8TYW-1 (RPCFileListJob...[15]) 03/21/2021 14:56:27 Sessionmgr : Received looped frame 03/21/2021 14:56:57 RPC : Cancelling job 1 due to timeout 03/21/2021 14:56:57 Mainfiles : Incomplete job `

Shutdown traceback bug

This may be timing related. Have not been able to make much sense of the dump. Not sure how repeatable it is.

The value being complained about is a class constant from ddt2.py, so do not know why it has become a nonetype.

The get_boolean was from a private instance of the config module being passed two strings. The bottom of the traceback is in an exception handler for when the config.py get_boolean() call failed.

` 03/13/2021 20:07:13 Transport : Sending block: DDT2+: 0:1:5 WB8TYW-2->CQCQCQ (9Going offline (D-RATS)...[23]) Exception in thread Thread-3 (most likely raised during interpreter shutdown):Exception in thread Thread-1 (most likely raised during interpreter shutdown): Traceback (most recent call last): File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner Traceback (most recent call last):

File "/usr/lib/python2.7/threading.py", line 754, in run File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner

File "/mnt/aviary/home/malmberg/work/d-rats/D-Rats/d_rats/transport.py", line 376, in worker File "/usr/lib/python2.7/threading.py", line 754, in run

File "/mnt/aviary/home/malmberg/work/d-rats/D-Rats/d_rats/transport.py", line 209, in parse_blocks File "/mnt/aviary/home/malmberg/work/d-rats/D-Rats/d_rats/msgrouting.py", line 620, in _run

<type 'exceptions.AttributeError'>: 'NoneType' object has no attribute 'ENCODED_HEADER' File "/mnt/aviary/home/malmberg/work/d-rats/D-Rats/d_rats/config.py", line 2138, in getboolean

<type 'exceptions.TypeError'>: 'NoneType' object is not callable

`

Apparently existing bugs

Raise exceptions on data validation from remote systems

This allows remote systems or program bugs to be a DDOS attack. These items should be logged or flagged, but not cause D-Rats to pop-up an exception.

Empty message in inbox or outbox

This triggers the issue.

Some problems with message locks

Tried to resend a message that failed to be received by a buggy client, and got the existing client in apparently an endless loop reporting the message is locked instead of reporting a failure and giving up.

Can not send files/messages to itself.

It seems to give up on files right away.

For messages, on receive it rejects them, but the sender keeps retrying apparently until restarted. It keeps the message locked during this.

Not shutting down cleanly.

Getting various errors when d-rats exits. The problem seems to be that threads are throwing exceptions on exit. It looks like on exit, we need something to signal all the threads to exit cleanly, and wait for them to all to end before actually exiting.

The problem apparently

General look and feel

Toolbars missing icons and text

Extra log messages that should be looked at

Msgrouting : Running routing loop

This just generates log noise and should be removed.

Qst: QSTWeatherWU class retired in log

Probably needs to just be removed from the code.

Mainapp: Unable to load translation for en:

([Errno 2] No translation file found for domain: 'D-RATS')

Adding local file

These may be part of my debugging

Right click on station fails

TypeError: popup() takes exactly 7 arguments (6 given)

Locally Fixed. popup on GTK-3 takes one more argument.