Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Cog 2848] Cog interface locks up when network media is unavailable (for each item in playlist) #392

Open
timmb opened this issue Jan 31, 2024 · 4 comments
Assignees

Comments

@timmb
Copy link

timmb commented Jan 31, 2024

Describe
I'm playing music on an SMB share. The files linger on the Cog playlist after the share has disconnected (I may have restarted Cog in between). If I try to play one of these tracks, the UI of Cog locks up while it tries to access the file.

It's a bigger problem because Cog will cycle through the whole playlist trying, and I can't stop it because the UI is locked up. I have to Force Quit, reopen, and immediately clear the playlist.

To Reproduce
Steps to reproduce the behavior:

  1. Mount a network share over SMB with music on it
  2. Add some of the network music into Cog
  3. Play to test it works.
  4. Close Cog
  5. Disconnect the network or turn off the SMB server (so any reconnection attempt fails)
  6. Reopen Cog
  7. Double click the first entry in the playlist
  8. Observe the UI is locked up for a few seconds while it tries to connect
  9. When "There is a problem connecting" message appears, click OK
  10. Repeat steps 8 and 9 until Cog makes it through the entire playlist

Expected behavior
The UI should remain responsive while Cog is trying to connect. If this is not possible, Cog should not try to play the next track after showing the error message.

Screenshots
cog bug screenshot

Version information:*

  • macOS version: 13.6.3
  • Cog version: 2848 (2848-g42ea8249)
@kode54
Copy link
Collaborator

kode54 commented Feb 1, 2024

That is a system dialog. I can’t even check if files still exist without incurring a delay and popup per file.

@timmb
Copy link
Author

timmb commented Feb 1, 2024

Ideal would be to do it on a different thread than the UI, but I guess that might be a grand change to make.

A workaround could be to stop playback on MacOS if a network file fails to play. It sounds annoying if you have a big playlist with just a file missing, but given the UI popup blocks Cog anyway then playback is already stopped until the user interacts.

@kode54
Copy link
Collaborator

kode54 commented Feb 1, 2024

The thing is, I can't tell from the path string that it's a network path, unless it's http or https via manually added stream paths. Network shares look just like local file mounts, and I have to ask for a bookmark to the file to access them after a restart. It is asking for this bookmark that triggers macOS trying to reconnect to the network share. Similarly, folder bookmarks work the same way, it tries to reconnect to the network share that the bookmark is located on.

I'm open to suggestions of how to better handle this, since bookmarks are fully opaque, and the file path is only something like file:///Volumes/SomeShareFolderMountPoint/path/to/file

I suppose I could halt all playback the instant any path that starts with /Volumes/ fails.

And I can't really update the app right now anyway, no adequate Apple Silicon Mac in my possession. No Mac that runs anything newer than Big Sur, either, so I definitely can't run the latest Xcode.

@fulldecent
Copy link

I am also experiencing lockup when adding some files that are on a local attached drive.

It is a Samsung T9 drive, super fast. Attached direct on Thunderbolt 4.

As a separate test, I tried dropping a media folder of 200GB on Cog. One folder, lots of MP3s. Fast drive. And this causes the UI to lockup. Maybe there is a way to do these updates on a background thread with progress published to the UI, and then inside that thread maybe the loading operation can happen incrementally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants