Closed tobi-wan-kenobi closed 2 years ago
So, i have pactl
. Should i turn it on somehow? Bc this is stilll present:
Can it be caused bc something in my i3-configs?
How can i debug this?
Can you try enabling logging and calling bumblebee-status from the commandli e?
This looks liks some broken output.
Just past the logfile and the output here and I will take a look.
Thanks!
R u talking about that?
> ./bumblebee-status -c ../config
{"version":1}
[
[{"full_text": " File contains no section headers.\nfile: '../config', line: 2\n'set $mod Mod4\\n' ", "background": "#ff0000", "color": "#ffffff", "name": "error", "instance": "the-only-one"}],
[{"full_text": " File contains no section headers.\nfile: '../config', line: 2\n'set $mod Mod4\\n' ", "background": "#ff0000", "color": "#ffffff", "name": "error", "instance": "the-only-one"}],
[{"full_text": " File contains no section headers.\nfile: '../config', line: 2\n'set $mod Mod4\\n' ", "background": "#ff0000", "color": "#ffffff", "name": "error", "instance": "the-only-one"}],
[{"full_text": " File contains no section headers.\nfile: '../config', line: 2\n'set $mod Mod4\\n' ", "background": "#ff0000", "color": "#ffffff", "name": "error", "instance": "the-only-one"}],
My i3 config: https://github.com/HappyCthulhu/.config/blob/master/i3/config
Ah, that does not have anything to do with my changes. Seems your config file has syntax errors.
I cannot open the link, is it possible that the repo is private?
I think, your changes caused this problem. Bc when i remove pasink
module, problem disappears. And when i switching from local branch to main)
Yeah, sorry, repo was private. Change visibility to public.
Haha, this is going to be an interesting one...
Ah, wait - please call bumblebeee-status like it is on your config (ie just copy the whole command), passing the i3 config to bumblebee-status does not work.
e.g.
bumblebee-status -m pasink -d
and paste what you get, olease.
Thank you!
Yeah, i thought about it, but before your changes it worked well...
strange, that looks good, actually :(
ahaha u r facing with paramiko errors to))) Yeah, i thought im the only one
It could be the paramiko warning, which would be weird, though.
Does it work better if you only use the pasink module in your i3 config for testing?
Weirdly, bumblebee is not using paramiko at all, something must pull it in...
Fucking hell, mate) Im facing really weird behaviour. Is it appropriate to make something like chat in telegram, discord, skype, zoom, etc? I just wanna to show u)
I can give u my contacts
If it is not appropriate, i can try to explain it in this tread. It just spent more time
In principle, I am OK with that, but if it is not too much hassle, I'd be grateful if you could write a summary (between my day job and 2 small kids, I mostly work on bumblebee at night and don't want to wake anybody)
Ok, So, tell me, if u will be able to rearch out 2 me somehow.
Summary:
status_command ~/.config/i3/bumblebee-status/bumblebee-status -m layout-xkb pasink battery time date nic
This works fine. And now we r entering interesting part. When im trying to add something more in this string, im facing error, that was described previously. And im not talking only about modules. If im adding space or backslash, this error appears too.
Ofc, this error disappear if i remove pasink
module from status_command
YAY, i can reproduce! this is weird
@HappyCthulhu Please try again, i am 80% sure your issue should be gone & you should have a nice and working and responsive pulseaudio module.
Thank you very much for your patience!
(If you are interested: Turns out I drew the status line too early - bumblebee-status uses an event-based mechanism for loose coupling internally, and somehow, when too many modules were initialized, the thread would draw before all modules were available, causing a massive mess-up in the status data)
btw @HappyCthulhu thank you for an excellent piece of debugging, your error descriptions were really useful, spot on and precise!
Yeah, i thought, that this issue is related to length of status-bar. It working cool rn, just facing weird behaviour of color scheme. But that might be my local problem, idk: https://user-images.githubusercontent.com/23531195/187940131-22e75e5e-c528-4106-be00-668957a89765.MOV
No problem, i like bumblestatus very much and thats cool, that i can help u somehow)
Btw, i can help u with some coding part, im a little bit of python dev too.
Ah, that probably is a drawing issue, I hope I can fix that easily.
PRs and new code are always appreciated, thanks!
Hm, this is very strange again. I cannot reproduce the issue. Are you using different settings than in your .config that you linked?
Hm, this is very strange again. I cannot reproduce the issue. Are you using different settings than in your .config that you linked?
Yeah. It can be related to my weak cpu...
ah, good hint. will try to implement some subtle rate limiting.
stay tuned :)
Sooooo, I have just committed a "rate limiting" to the output that only produces output every 300ms max. That can occasionally cause delays, but normally, should be fine, I think.
Please let me know if it improves your situation or not. If not, you can try playing around with the value in bumblebee_status/core/output.py (method "draw()") - increasing should reduce flickering, but make the bar less responsive.
This colour bug happens only on 917 branch. It doesnt appears on main. And no, your bug fix is not working for now
Sorry to hear that :-(
Yeah, only the dev branch being affected makes sense, becausechanging the volume causes the event monitor to trigger as well :thinking:
Will try to come up wih an idea to fix that
Another idea: I am now rate-limiting the pulseaudio events, but at the same time ensuring the module gets updated regularly.
I hope that this improves the situation a bit (I capped my CPUs to the minimum frequency and scrolled like crazy, and cannot reproduce the flickering anymore - I was able to, before). It lags a lot with events, if you scroll a lot up and down, but that's OK, IMHO.
Hope it works for you as well, @HappyCthulhu
i think, that really helped... Looks cool!
bruh, wtf((( still happens sometimes after reloading i3
yeah, and colorscheme gleaching without any actions with i3 status...
damn, so the race condition isn't solved yet....
I will find a way to fix that, for sure :)
one q: the coloracheme glitches don't happen on main, right?
one q: the coloracheme glitches don't happen on main, right?
yeah
@HappyCthulhu Can I ask you for another round of tests, please?
This time, I feel pretty good about having found a real issue - there was a multithreading concurrency issue between update and draw, if invoked from a separate thread.
Now its working fine. Dont close this issue for a day, ok? Just to be sure, that everything is fine.
Btw, could u reproduce this bug on your pc?
I was able to partially reproduce it, by clamping down the CPU speed of my machine to the minimum.
Once I realized it was a threading issue, judiciously adding sleeps helped a lot to reproc reliably :)
Plus: I am really glad it looks promising for you, now!
@HappyCthulhu Is it OK if I close the issue now? :fingerscrossed:
Yeah, all right. I think, u can close issue)
@HappyCthulhu Sorry, but this needs work before merging to main - using the module multiple times causes really high cpu load.
I need to find a reliable way to detect volume/state changes for a given device, that is ... surprisingly difficult
@HappyCthulhu Sorry to be a bother!
I just pushed a new version - this time something cool :)
I added 2 new modules pulsein
(for microphone) and pulseout
(for speakers). Those are 100% event-based (using the python module pulsectl
, which needs to be installed), and for me, this works like a charm.
Right now, those modules don't have any parameters, but if you report back promising findings, I want to eventually make those "drop-in" replacements for the existing modules.
Actually, @HappyCthulhu I will merge this to main right away, as the module is now a real drop-in replacement (all parameters work exactly the same), and there is no impact on other parts of bumblebee-status, hopefully.
I would still highly appreciate your input on whether the module works for you & improves your experience (it doesn't use executables anymore & only has half the lines of code, so it should be much nicer)
Didnt have enought time to test your features. I will do it rn. I have some troubles with pulseaudio, so, mb, i will not be able to install your latest modules.
Anyway, this is my telegram, so u can text me even if all issues are closed: https://privnote.com/hsOTFZiG#CBWZdRHxy. Make sure, that u copy telegram in first time, because, when u will open it in second time this note will be destroyed.
A follow-up on #913
For the pulseaudio module, it would be nice to support some kind of P.A. event monitoring to adjust the module not periodically, but only when actual changes to pulseaudio happen.