jellyfin-archive / jellyfin-android-original

Android Client for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
271 stars 65 forks source link

Fix bluetooth music notification #234

Closed Artiume closed 4 years ago

Artiume commented 4 years ago

This was causing artist and album to be swapped while using bluetooth. Not yet verified.

thornbill commented 4 years ago

@Artiume have you been able to verify this? It seems like a logical fix.

Artiume commented 4 years ago

I'm still working on learning how to compile it :)

vitorsemeano commented 4 years ago

If you need any help with the compiling process, i can help you out :)

Artiume commented 4 years ago

So I have Android SDK installed but I got stopped there. I get distracted a lot lol

vitorsemeano commented 4 years ago

Did you follow the instructions to compile in the readme? You need to also install npm to run the commands to compile and deploy to the emulator or your phone

Artiume commented 4 years ago

Let me look at them and see if I have any issues

Artiume commented 4 years ago

Yeah, I can't get it. The readme isn't clear, I cloned via git, installed npm and the build failed.

There's nothing here either https://jellyfin.org/docs/general/administration/building.html

was trying to follow this but how do i differentiate between dev branch and my custom fork? https://www.reddit.com/r/jellyfin/comments/aixsf4/help_needed_how_to_compile_android/eet2n6e

vitorsemeano commented 4 years ago

Can you provide the build error?

dkanada commented 4 years ago

causing artist and album to be swapped

Don't you mean artist was displayed for both values? Do you have a screenshot of this bug in action, I haven't actually seen it anywhere.

Artiume commented 4 years ago

Here's the build logs

Using jellyfin-web from node_modules/jellyfin-web/dist
[12:45:52] Using gulpfile /repo/gulpfile.js
[12:45:52] Starting 'default'...
[12:45:52] Starting 'clean'...
[12:45:52] Finished 'clean' after 43 ms
[12:45:52] Starting 'copy'...
[12:45:52] Starting 'modifyIndex'...
[12:45:52] Starting 'scripts'...
[12:45:52] Finished 'copy' after 24 ms
[12:45:52] 'modifyIndex' errored after 26 ms
[12:45:52] Error: File not found with singular glob: /repo/node_modules/jellyfin-web/dist/index.html (if this was purposeful, use `allowEmpty` option)
    at Glob.<anonymous> (/repo/node_modules/glob-stream/readable.js:84:17)
    at Object.onceWrapper (events.js:315:30)
    at emitOne (events.js:116:13)
    at Glob.emit (events.js:211:7)
    at Glob._finish (/repo/node_modules/glob/glob.js:197:8)
    at done (/repo/node_modules/glob/glob.js:182:14)
    at Glob._processSimple2 (/repo/node_modules/glob/glob.js:688:12)
    at /repo/node_modules/glob/glob.js:676:10
    at Glob._stat2 (/repo/node_modules/glob/glob.js:772:12)
    at lstatcb_ (/repo/node_modules/glob/glob.js:764:12)
[12:45:52] 'default' errored after 72 ms
[12:45:52] The following tasks did not complete: scripts
[12:45:52] Did you forget to signal async completion?
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! jellyfin-android@0.9.0 postinstall: `gulp`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the jellyfin-android@0.9.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-01-06T12_45_52_720Z-debug.log
+ cleanup
+ rm -rf /tmp/tmp.iFtr1LgfXD

@dkanada No, It was the artist and album switched on the stereo in my car. This was the only oddity in the code that would explain the issue so hopefully it fixes the issue.

Stampede10343 commented 4 years ago

Did you run npm install? It sounds like its trying to pull the web code in but its not in the node_modules folder.

dkanada commented 4 years ago

@Artiume this looks fine to me so I'll just merge it and see what happens.

Artiume commented 4 years ago

I still need to figure out how to build for bigger projects :p lol. What's the turn around time for this being merged in the app store?

Artiume commented 4 years ago

So testing the patch was not successful. Testing the bug on chrome mobile verified the same issue. I'll start looking in the backend to see if perhaps it's there.

anthonylavado commented 4 years ago

So to be clear, it’s showing up swapped on your car display, right?

Artiume commented 4 years ago

Yes, this is on two separate vehicle's displays while connected via BT

ferferga commented 4 years ago

Do we know what this piece of code was for? Did it broke something? Because I remember to hear that this wasn't fixed still until jellyfin/jellyfin-web#738 got merged

Artiume commented 4 years ago

I want to say I did see a change in how the artist/album/track were displayed but it fixed a duplication, not the swapping but I can't remember if that's correct or not

dkanada commented 4 years ago

If nothing else I feel like this should be kept regardless, it seems like a logical change.

ferferga commented 4 years ago

Great then! Just for confirming!