Open kajarit opened 9 months ago
Thanks for reporting and for good info about the issue. @hacketiwack do you think you can look into this? Maybe PR #1446 is of relevance here.
Thanks for looking into this, what about Postman not receiving any notifications, but still connected during playback?
@hacketiwack any chance you can look at this?
Yes, sure. Let me check that.
@kajarit do you have any particular reason to build on an unsupported version of macOS (Big Sur is unsupported since September 2023) and use macports instead of homebrew? No judgment here, I just don't want to waste my time building a virtual machine in a specific version when there is no particular reason.
I have a 2014 Mac Mini, and I use homebrew. I don't plan to change this machine in the near future.
@kajarit, I built OwnTone on a macOS Big Sur virtual machine (following the instructions I gave earlier last year). I could reproduce the errors and the behaviour.
However, I don't know what they really mean. I guess error codes are related to these reasons.
@ejurgensen, do you have any idea what these codes mean?
In the logs there are plenty of notify callback reasons, like: 11, 71, 49, 20, 53, 0, 6, 38, 78.
The only other suspicious error is: mdns: Error registering record owntone.local, error -65540
but it probably has nothing to do with our problem here.
I also tested with macOS Monterey with the same results. I suspect that even with the latest version of macOS, you'll have the same problems.
In your specific situation @kajarit macOS Big Sur is not supported and Homebrew is also not supported on this version of macOS. Therefore, my recommendations would be to make use of the containerisation to avoid having to built OwnTone by yourself.
And if you can't install Docker properly. I would suggest to upgrade your Mac Mini to a newer version of macOS with the help of Dortania
Thanks for the tips, I'll have a look on those. Before building natively, I also tried with Docker but I couldn't make it work for several reasons.
I don't know those error codes. I think if this issue isn't present with current versions of MacOS/libwebsockets then it's fine to close the issue.
I also tested with macOS Monterey with the same results. I suspect that even with the latest version of macOS, you'll have the same problems.
Does this mean that even with the latest macOS the websocket doesn't work?
Does this mean that even with the latest macOS the websocket doesn't work?
I need to test it with Sonoma to be sure.
OK. No good news is coming with this comment. Actually, I get the error on all versions of macOS: from Big Sur to Sonoma.
Now the question is where to start searching within the integration of libwebsocket. @ejurgensen any idea where I could start my investigation? What I could try is to compile libwebsockets myself and not take the one coming from Homebrew.
Actually, I get the error on all versions of macOS: from Big Sur to Sonoma.
So you get an error message - what is that? From the thread above I couldn't see an error message (the notify reasons aren't errors, and the mdns error is unrelated).
If you have some error message I suppose you could search for it in the lws source code. But yes, compiling lws yourself with debug symbols could also be useful for debugging. Have you found a basic way to reproduce? Just browsing the web UI might be a difficult way, since there is a bunch of communication going on, so if you can isolate the error it would be useful.
You're right these are not error messages, but "reasons" for whatever it means. I don't have receive any errors or whatever.
I will try to compile with debug symbols and try to find a scenario that could provoke these messages in a reliable way.
Do we know what was the last known working websocket version of OwnTone/macOS ever?
Do we know what was the last known working websocket version of OwnTone/macOS ever?
Excellent question. No idea.
What I could try is to compile libwebsockets myself and not take the one coming from Homebrew.
Hi @hacketiwack, have you been able to try this?
@kajarit i did compile my own version of libwebsocket but it gives the same results. I’m quite puzzled about the reason of this not working properly.
@hacketiwack should we raise an issue at libwebsockets?
Actually, yes, that would be great. I was wondering if there was some kind of HTML test with libwebsockers server application that could be used to test on macOS.
I am not sure how to create an issue that would help explain the problem.
I am planning to write a test program to help debug this. So basically copy websocket.c into a standalone server. I hope that will also help me understand the current implementation. It's a bit of a black box to me now, even after trying to read the code.
@ejurgensen That would be great to have such test program to debug. Thanks.
I've built OwnTone server on macOS 11.7.10 Big Sur with the help of these sources:
OwnTone Server Version 28.8
Almost everything works fine, except things I noticed:
I also noticed, that the browser page also updates itself when I move to other tab and back.
Postman test
Postman header (defaults hidden)
And here's the owntone.log fitered for web debug messages: