Home of the Squeezebox™ & Transporter® network music players.
Page 3 of 9 FirstFirst 12345 ... LastLast
Results 21 to 30 of 88
  1. #21
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    5,015
    Quote Originally Posted by slartibartfast View Post
    I get the same error after turning this off.

    Sent from my Pixel 3a using Tapatalk
    It still appears to be converting FLAC to MP3 with the conversion turned off.

    Sent from my Pixel 3a using Tapatalk

  2. #22
    Senior Member
    Join Date
    Mar 2017
    Posts
    2,122
    Quote Originally Posted by slartibartfast View Post
    It still appears to be converting FLAC to MP3 with the conversion turned off.
    Yup, the reading of this flag is broken. Will release an update in a bit. For now you could edit Plugin.pm and change (from line 344) from:

    Code:
    sub _convertToMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $convertExt = shift;
        my $fixed = $path;
    
        if ($convertExt) {
            my @parts = split(/#/, $path);
            if (2==scalar(@parts)) {
                $fixed = $parts[0] . ".CUE_TRACK." . $parts[1] . ".mp3";
            }
            if (!main::ISWINDOWS && !main::ISMAC) {
                if (! ('.mp3' eq substr $fixed, -length('.mp3'))) {
                    $fixed = $fixed . ".mp3";
                }
            }
        }
        if ($mipPath) {
            $fixed =~ s/$lmsPath/$mipPath/g;
        }
    
        if ($convertExt || $mipPath) {
            main::DEBUGLOG && $log->debug("TO MIP: " . $path . " -> " . $fixed);
        }
        return $fixed;
    }
    
    sub _convertFromMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $fixed = $path;
        my $convertExt = shift;
    
        if ($convertExt) {
            my @parts = split(/\.CUE_TRACK\./, $path);
            if (2==scalar(@parts)) {
                my $end = substr $parts[1], 0, -4; # Remove .mp3 ext
                $fixed = $parts[0] . "#" . $end;
            }
            if (!main::ISWINDOWS && !main::ISMAC) {
                if ('.m4a.mp3' eq substr $fixed, -length('.m4a.mp3')) {
                    $fixed = substr $fixed, 0, -4;
                } elsif ('.ogg.mp3' eq substr $fixed, -length('.ogg.mp3')) {
                    $fixed = substr $fixed, 0, -4;
                } elsif ('.flac.mp3' eq substr $fixed, -length('.flac.mp3')) {
                    $fixed = substr $fixed, 0, -4;
                }
            }
        }
        if ($mipPath) {
            $fixed =~ s/$mipPath/$lmsPath/g;
        }
    
        if ($convertExt || $mipPath) {
            main::DEBUGLOG && $log->debug("FROM MIP: " . $path . " -> " . $fixed);
        }
        return $fixed;
    }
    to

    Code:
    sub _convertToMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $convertExt = shift;
        my $fixed = $path;
    
        return $fixed;
    }
    
    sub _convertFromMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $fixed = $path;
        my $convertExt = shift;
    
        return $fixed;
    }
    This will disable all path conversions.
    Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

  3. #23
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    5,015
    Quote Originally Posted by cpd73 View Post
    Yup, the reading of this flag is broken. Will release an update in a bit. For now you could edit Plugin.pm and change (from line 344) from:

    Code:
    sub _convertToMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $convertExt = shift;
        my $fixed = $path;
    
        if ($convertExt) {
            my @parts = split(/#/, $path);
            if (2==scalar(@parts)) {
                $fixed = $parts[0] . ".CUE_TRACK." . $parts[1] . ".mp3";
            }
            if (!main::ISWINDOWS && !main::ISMAC) {
                if (! ('.mp3' eq substr $fixed, -length('.mp3'))) {
                    $fixed = $fixed . ".mp3";
                }
            }
        }
        if ($mipPath) {
            $fixed =~ s/$lmsPath/$mipPath/g;
        }
    
        if ($convertExt || $mipPath) {
            main::DEBUGLOG && $log->debug("TO MIP: " . $path . " -> " . $fixed);
        }
        return $fixed;
    }
    
    sub _convertFromMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $fixed = $path;
        my $convertExt = shift;
    
        if ($convertExt) {
            my @parts = split(/\.CUE_TRACK\./, $path);
            if (2==scalar(@parts)) {
                my $end = substr $parts[1], 0, -4; # Remove .mp3 ext
                $fixed = $parts[0] . "#" . $end;
            }
            if (!main::ISWINDOWS && !main::ISMAC) {
                if ('.m4a.mp3' eq substr $fixed, -length('.m4a.mp3')) {
                    $fixed = substr $fixed, 0, -4;
                } elsif ('.ogg.mp3' eq substr $fixed, -length('.ogg.mp3')) {
                    $fixed = substr $fixed, 0, -4;
                } elsif ('.flac.mp3' eq substr $fixed, -length('.flac.mp3')) {
                    $fixed = substr $fixed, 0, -4;
                }
            }
        }
        if ($mipPath) {
            $fixed =~ s/$mipPath/$lmsPath/g;
        }
    
        if ($convertExt || $mipPath) {
            main::DEBUGLOG && $log->debug("FROM MIP: " . $path . " -> " . $fixed);
        }
        return $fixed;
    }
    to

    Code:
    sub _convertToMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $convertExt = shift;
        my $fixed = $path;
    
        return $fixed;
    }
    
    sub _convertFromMip {
        my $path = shift;
        my $mipPath = shift;
        my $lmsPath = shift;
        my $fixed = $path;
        my $convertExt = shift;
    
        return $fixed;
    }
    This will disable all path conversions.
    Getting somewhere now but it can't find any genres it likes. Server log attached.
    Attached Files Attached Files

  4. #24
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    5,015
    Even when I select do not exclude genres every track it finds fails to match genre.

    Sent from my Pixel 3a using Tapatalk

  5. #25
    Senior Member
    Join Date
    Mar 2017
    Posts
    2,122

    0.0.2 Release

    First bug fix release...

    1. Disable extension conversion by default.
    2. Correctly read extension conversion config item.
    3. Fix not filtering by genre.
    Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

  6. #26
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    5,015
    Quote Originally Posted by cpd73 View Post
    First bug fix release...

    1. Disable extension conversion by default.
    2. Correctly read extension conversion config item.
    3. Fix not filtering by genre.
    I think it is working now. It gives me 5 tracks. Does that sound right?

    Sent from my Pixel 3a using Tapatalk

  7. #27
    Senior Member
    Join Date
    Mar 2017
    Posts
    2,122
    Quote Originally Posted by slartibartfast View Post
    I think it is working now.
    Yipee!!!!

    Quote Originally Posted by slartibartfast View Post
    It gives me 5 tracks. Does that sound right?
    Yes, as stated in the first post. When playing the 2nd to last track more tracks will be added - that how DSTM works. This plugin jsut provides some tracks to use.
    Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

  8. #28
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    5,015
    Quote Originally Posted by cpd73 View Post
    Yipee!!!!



    Yes, as stated in the first post. When playing the 2nd to last track more tracks will be added - that how DSTM works. This plugin jsut provides some tracks to use.
    Why did every single track get excluded with genre exclusion turned on? Was there an issue with that part of the code?

    Sent from my Pixel 3a using Tapatalk

  9. #29
    Senior Member
    Join Date
    Mar 2017
    Posts
    2,122
    Quote Originally Posted by slartibartfast View Post
    Why did every single track get excluded with genre exclusion turned on? Was there an issue with that part of the code?
    I thought it was turned off? You stated "when I select do not exclude genres every track it finds fails to match genre." The issue there was it was filtering on genre, when there was no genre => genre did not match, filtered out. Genre filtering itself should work, as that is what I use all the time - and its why I have groups of genres in the JSON file. I found MIP would sometimes mix in a pop track whilst I was listening to Rock, and I did not want that.

    Plugin is still in development, so there will be issues - it works for my use case, but will probably have issues for other use cases.
    Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

  10. #30
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    5,015
    Quote Originally Posted by cpd73 View Post
    I thought it was turned off? You stated "when I select do not exclude genres every track it finds fails to match genre." The issue there was it was filtering on genre, when there was no genre => genre did not match, filtered out. Genre filtering itself should work, as that is what I use all the time - and its why I have groups of genres in the JSON file. I found MIP would sometimes mix in a pop track whilst I was listening to Rock, and I did not want that.

    Plugin is still in development, so there will be issues - it works for my use case, but will probably have issues for other use cases.
    When I first tried it I left all the defaults so genre filtering was turned on but I assume with no JSON file to specify genres. That was the server log I posted. I was surprised that every single track was excluded. I tried another seed track with genre Rock and again all of the tracks were excluded. Is the JSON file required for genre filtering to work?

    After this I tried turning off genre filtering and found the same results but now that works perfectly.

    Sent from my Pixel 3a using Tapatalk

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •