@klaasvaak wrote:
Hello, I've been using an altered version of the jonybat config https://github.com/zilexa/flexget_config
this config uses the kodi plugin to update it's library after moving files.
After I've moved files, I'd like to update the kodi library, but this seems broken in kodi 18. I'm receiving an error in the flexget.log
JSONRPC failed. Error -32099: Bad client permission
which seems to point to https://forum.kodi.tv/showthread.php?tid=324598 wich tells me some new of way of doing this which is safer?
I'm also using a sh script that runs after a torrent has finished in transmission/usr/bin/wget --header='Content-Type:application/json' --post-data='{"jsonrpc": "2.0", "method": "VideoLibrary.Scan", "id": "osmc", "params": {"directory":"'"$TR_TORRENT_DIR"'/"}}' "http://localhost:80/jsonrpc"
This does work.The part of the config that is trying to update the kodi library
########## LIBRARY ##########
move-series:
priority: 31
template:
- disable-seen-retry
- series-metainfo
- series-guessit
filesystem:
path: "/{? folder.root ?}{? folder.downseries ?}"
recursive: yes
retrieve: files
regexp: '.*\.(avi|mkv|mp4)$'
accept_all: yes
move:
to: "/{? folder.root ?}{? folder.series ?}{{tvdb_series_name|escape|replace(''', '')|pathscrub}}/S{{series_season|pad(2)}}/"
rename: "{{tvdb_series_name|escape|replace(''', '')|pathscrub}} - {{series_id}}{% if tvdb_ep_name|default(False) %} - {{tvdb_ep_name|pathscrub}}{% endif %}{% if quality|default(False) %} - [{{quality}}]{% endif %}"
along:
extensions:
- srt
- sub
subdirs:
- Subs
clean_source: 50
kodi_library:
action: scan
category: video
url: http://192.168.1.214
port: 80
list_add:
- subtitle_list:
list: subtitles
path: "{{location}}"
remove_after: 7 days
exec:
on_exit:
phase: find "/{? folder.root ?}{? folder.downseries ?}"* -type d -empty -delete
Posts: 1
Participants: 1