Add --rx-bytes flag to enable logging of received bytes in hexadecimal#81
Add --rx-bytes flag to enable logging of received bytes in hexadecimal#81jpdillingham wants to merge 3 commits intosoulfind-dev:masterfrom
Conversation
|
I'm wondering if it would be better to do something like |
|
Better to imply the required flag rather than the error if it's missing. It is desirable to have fine-grained control of the output, otherwise sifting through all of the data to find the bit you're looking for will become too overwhelming when in reality you are only going to be testing one part of the protocol at a time (perhaps only one specific message code or set/range of codes) during any given session. Simpler separate flags for each that may category desired...
Suggest dropping the "debug" terminology altogether because its ambiguous if that's for debugging Soulfind itself, or if it's really intended for the purpose of debugging the developer's client that they're working on? |
|
Some more control would be good, but I have some concerns about adding generic separate flags like this. E.g. -d and --db would clash with the existing --database flag for specifying the db path. Maybe a |
|
Yes that would be much more sensible. I'm not saying all these have to be implemented, just exploring what kind of permutations this syntax could potentially allow...
For most of these it wouldn't matter if For the purposes of this PR would be accepting either |
|
Better to start with some basic categories first. I could take a look at implementing that and see what's needed in our arg parser. |
|
Initial implementation of --log argument in #82. |
I wanted to definitively prove that slskd/Soulseek.NET is sending the expected bytes for a message and this was the best way I can think of to do it. To avoid opting everyone wanting
--debugin to the logging of raw message bytes, I added the--rx-bytesthat works in conjunction with--debug(and does nothing but log a warning unless both are supplied).Example output:
I used AI to help with the
writelnsyntax in messages.d.