Jump to content

Plugin: EmbyCredits, detect end credits and add auto skip.


Go to solution Solved by yocker,

Recommended Posts

rechigo
Posted

I’m running into an issue on the latest version where I’m no longer able to save the tesseract api endpoint when using a docker container name (for example, http://tesseract-ocr:8100). I now get an error message saying that only localhost and local network addresses are allowed.

spk2010
Posted
On 3/13/2026 at 1:22 PM, yocker said:

@spk2010@DarWunI finished and added the "fix" to Emby deleting the time stamps. Hopefully this will fix all the problems with Emby doing that until the devs look into the problem.

I've been testing the new version since the day you posted it and I still have the same problem, the CreditsStart mark disappears when I click the "Next Episode" button. It's not a problem for me because I restore backups with Cron, but if you need any proof or logs just ask me.

  • Like 1
yocker
Posted
5 hours ago, spk2010 said:

I've been testing the new version since the day you posted it and I still have the same problem, the CreditsStart mark disappears when I click the "Next Episode" button. It's not a problem for me because I restore backups with Cron, but if you need any proof or logs just ask me.

New version in the test phase right now.

Btw. mind sharing the cron job?

yocker
Posted (edited)

Also just noticed that a metadata refresh makes it so Emby's own intro detection wont run on the series that had the metadata refreshed.

The devs might need to look at that one.

Edited by yocker
spk2010
Posted
28 minutes ago, yocker said:

Btw. mind sharing the cron job?

credits_detector_backup+scan.sh:

#!/bin/bash

API_KEY="XXXXXXXXXXXXXXXXXX"
EMBY_URL="http://localhost:8096"
BACKUP_FILE="/home/pi/emby_backup/credits_detector_backup.json"
LIBRARY_ID="242"

echo "=== RESTAURANT BACKUP ==="

if [ ! -f "$BACKUP_FILE" ]; then
    echo "No hi ha backup, en creo un inicial..."
    curl -s -X POST "$EMBY_URL/emby/CreditsDetector/ExportCreditsBackup?api_key=$API_KEY" \
        -o "$BACKUP_FILE"
    echo "Backup inicial creat"
else
    jq -Rs '{JsonData: ., OverwriteExisting: false}' "$BACKUP_FILE" > "${BACKUP_FILE}.ready"

    curl -s -X POST "$EMBY_URL/emby/CreditsDetector/ImportCreditsBackup?api_key=$API_KEY" \
        -H "Content-Type: application/json" \
        --data @"${BACKUP_FILE}.ready"

    rm -f "${BACKUP_FILE}.ready"
    echo "Restauració feta"
fi

echo
echo "=== INICIANT ESCANEIG ==="

curl -s -X POST "$EMBY_URL/emby/CreditsDetector/StartDetection?api_key=$API_KEY" \
    -H "Content-Type: application/json" \
    -d "{\"LibraryId\":\"$LIBRARY_ID\",\"SkipExistingMarkers\":true}"

echo

URL="$EMBY_URL/emby/CreditsDetector/GetProgress?api_key=$API_KEY"

while true; do
    STATUS=$(curl -s "$URL")

    RUNNING=$(echo "$STATUS" | jq -r '.IsRunning')
    DONE=$(echo "$STATUS" | jq '.ProcessedItems')
    SKIPPED=$(echo "$STATUS" | jq '.SkippedItems')
    TOTAL=$(echo "$STATUS" | jq '.TotalItems')
    CURRENT=$(echo "$STATUS" | jq -r '.CurrentItem')

    echo "Processats: $DONE | Saltats: $SKIPPED | Total: $TOTAL"
    echo "Actual: $CURRENT"

    [ "$RUNNING" = "false" ] && break

    sleep 10
done

echo
echo "=== ESCANEIG ACABAT ==="
echo

echo "=== CREANT BACKUP FINAL ==="

curl -s -X POST "$EMBY_URL/emby/CreditsDetector/ExportCreditsBackup?api_key=$API_KEY" \
    -o "$BACKUP_FILE"

echo "Backup guardat a: $BACKUP_FILE"

 

  • Thanks 1
Posted

Beta if people want to help test.

I've been testing and re-testing this for a while now and i seem to have gotten the auto-restore fixed so that time stamps gets restores after Emby removes them.
image.thumb.png.190c376ee4f7e5eff2a29cad8d433679.png

Would love more to test it so it's sure to be bug free.

WARNING!!! This is a beta and there might be bugs, as always use at your own risk.

EmbyCredits.dll

  • Like 2
  • Thanks 2
Posted

@Neminemhas been so kind as to help replicate the problem @spk2010has.
If no misunderstanding has happened, it look like Embys skip system might have problems sometimes when fast forwarding to many times to fast or resuming a video mid video.
It's unrelated to this plugin and does not change the metadata/time stamps of the video and going back and restarting the video usually fixes it.

Refreshing metadata, doing rescans and other things can and will in most cases remove the time stamps though, the auto-restore function is made to fix that and is in beta atm.

  • Like 2
rechigo
Posted

Is mark failed episodes for future skipping known to not work? I just ran the scheduled task once to detect and fail everything, and when I went to run it again it tries detecting all failed credits again :(

yocker
Posted
1 hour ago, rechigo said:

Is mark failed episodes for future skipping known to not work? I just ran the scheduled task once to detect and fail everything, and when I went to run it again it tries detecting all failed credits again :(

With the beta?

yocker
Posted (edited)

New version up (v2.4.0) on yocksers/EmbyCredits Github.

Added:

  1. Audo-Restore Markers.
    This will try and detect when Emby have changed the time markers in videos and run a backup restore if the credit markers have been removed.
  2. Tracer, this will show videos that have been added and not have detection run on them yet.

Changed:

  1. Small cosmetic changed.

Please note:
The Auto-Restore Markers requires automating backup running for up to date backups to use.
Also it's not a be all end all solution to Emby removing time markers, it might still fail to notice when it happens sometimes. A real solution would require a fix to Emby it self.
It does limit it happening most of the time!
 

Thank you to all who helped!! You know who you are! :) 
Special thanks to @Neminemfor being ready to help testing as always!!

@GrimReaperI added the functionality you suggested to the editor, thanks for the suggestions!

Edited by yocker
  • Like 2
rechigo
Posted
9 hours ago, yocker said:

With the beta?

The stable version right before the one you released today

yocker
Posted
19 minutes ago, rechigo said:

The stable version right before the one you released today

The new version should have it fixed.

  • Agree 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...