| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
I can definitely see benefits here, but I'm also curious if the multiple log files will make it more challenging to grab data from users when they need support. The functionality itself looks good, but will wait for @Core447 to chime in |
Sorry, something went wrong.
|
Nevermind, I see my confusion. This doesn't replace the base plugin logger, this creates a new logger specifically for troubleshooting. I think this is a good start, but I think this could be expanded upon a little more to make it more user friendly. Something like the following:
I think the only thing missing from your implementation is the ability to call the troubleshoot function from StreamController somewhere. I think this would be better than putting inside a specific action as we may want to troubleshoot some part of the plugin that is preventing actions from loading. |
Sorry, something went wrong.
|
I want to replace the Plugin Logger with this, its in my opinion a better way and it provides a dedicated "space" for every Plugin to use. Adding the button to the settings that starts a troubleshoot/diagnostic sounds like a good idea! Under Settings -> Plugins -> Your Plugin -> About -> Troubleshooting -> Debugging Info we already have the section to show the log, just like StreamController does it and I would just use that. I would create 2 methods: |
Sorry, something went wrong.
…d always showing a troubleshooting section
|
@ImDevinC could you take a look again? Added everything you wanted/needed |
Sorry, something went wrong.
|
This change now results in the following (Its a long line): 2025-06-20 15:19:52.578 | com_gapls_AudioControl | actions.AudioCore:troubleshoot:190 - Troubleshooting for action: Mute on : {'selected_device': <Device pulse_name=Browser pulse_index=34 device_name=Browser>, 'device_filter': <SimpleComboRowItem display=Sink value=sink filter=Sink>, 'info_content': <SimpleComboRowItem display=Volume value=volume filter=Volume>, 'show_info_content': True, 'device_name': '', 'show_device_name': True, 'use_standard': False, 'loaded_devices': [<Device pulse_name=System pulse_index=31 device_name=System>, <Device pulse_name=Game pulse_index=32 device_name=Game>, <Device pulse_name=Voice Chat pulse_index=33 device_name=Voice Chat>, <Device pulse_name=Browser pulse_index=34 device_name=Browser>, <Device pulse_name=alsa_output.pci-0000_18_00.6.analog-stereo pulse_index=75 device_name=ALC897 Analog>, <Device pulse_name=alsa_output.usb-Focusrite_Scarlett_Solo_USB_Y756R404B041C6-00.HiFi__Line1__sink pulse_index=79 device_name=Scarlett Solo USB>], 'icon_keys': [<Icons.MUTED: 'mute'>, <Icons.UNMUTED: 'audio'>], 'current_icon_name': <Icons.UNMUTED: 'audio'>}
The code for this is very simple: async def troubleshoot(self, *args, **kwargs):
self.log(f"Troubleshooting for action: {self.__class__.__name__} on ",
selected_device=self.selected_device,
device_filter=self.device_filter,
info_content=self.info_content,
show_info_content=self.show_info_content,
device_name=self.device_nick,
show_device_name=self.show_device_name,
use_standard=self.use_standard_device,
loaded_devices=self.loaded_devices,
icon_keys=self.icon_keys,
current_icon_name=self._icon_name) |
Sorry, something went wrong.
|
This looks great, thanks for putting it together so quickly! |
Sorry, something went wrong.
|
Alright opened it for merge! Now we just have to wait and see what @Core447 thinks |
Sorry, something went wrong.
|
@Core447 bumping this aswell. what do you think? |
Sorry, something went wrong.
|
I like it. Only reason I'm not merging yet is a very selfish one: I don't have very much experience with all things logging, and I want to try a bit around with it, so that I understand it better and can work with this myself. Hope I can merge soon |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
This adds Plugin Based logging to StreamController.
It adds a log file for every plugin using loguru.
I added custom file retention as Im using date/time based log names that are different on every start. I did this because that makes it easy to only display the latest informations in the about window of the plugin