timekiller 5 Posted December 23, 2019 Posted December 23, 2019 Hello, I'm somewhat new to Emby, I setup my first server and have been trying to get it configured to my liking. For the media I am serving, I can not use the standard metadata downloaders. Instead, I have a series of json files with the data I need. I configured Emby to save NFO files with the media, the intention being for me to write a script that takes the json data and uses that to write NFO files. I have many videos and after running my script, some of the videos show the new data in the UI, but many do not. I reload the media page and it's still missing the new metadata. I open the video's NFO and confirm the new metadata is there (it is). The script also sets <lockdata> to true to avoid Emby overwriting my changes. Thinking that the video's metadata might be cached I try restarting Emby, The new metadata is still not shown. I try "Scan Library Files" and that's where Emby overwrites the NFO, removing my changes. For one video I even tried manually checking "Lock this item to prevent future changes" in the UI, updating the NFO on disk, then scanning library files - it STILL overwrote my changes, and UNCHECKED the Lock!?!? Please help, I have thousands of videos that I have the metadata for, but I can't get Emby to consistently use my changes. For reference, I am using the latest binhex emby docker image (Emby version 4.3.0.30) on unraid.
Luke 42085 Posted December 23, 2019 Posted December 23, 2019 Hi there, what new metadata is not being shown? The lock will not nfo files from being saved. If you don't want them to be saved, then don't enable that in library options. What the lock will do is prevent data fields from being changed.
timekiller 5 Posted December 23, 2019 Author Posted December 23, 2019 Hi there, what new metadata is not being shown? The lock will not nfo files from being saved. If you don't want them to be saved, then don't enable that in library options. What the lock will do is prevent data fields from being changed. my script is adding `plot`, `title`, `genre`, and `actors`. None of that data is being shown in the UI. Initially I let Emby write the NFO files which generated the generic data like `dateadded`, `runtime`, and `fileinfo`. Then my script scans through the media folder, pull the nfo data from the generated nfo file, then adds title, plot, etc fromt he json file and writes the new nfo file (overwriting the one generated by Emby). Are you saying if I uncheck Nfo under "Metadata savers" that Emby will not write NFO, but will still use existing nfo files for metadata if one exists?
Luke 42085 Posted December 23, 2019 Posted December 23, 2019 Well I don't really know what to say. Half of our community uses nfo files so obviously there isn't a widespread problem. After you update your nfo files, is the date modified timestamp of the file being updated? Make sure it is, then run a regular library scan and that's all you need to do. If you're not seeing that then let's go over a specific example. Thanks.
Solution timekiller 5 Posted December 23, 2019 Author Solution Posted December 23, 2019 I may have figured out why the NFO is not being used! Ok, so this is my bad. My script didn't take into account that you have to translate special characters like '&'. I updated the script and tested it. The file I've been testing with now shows up properly! Running the script on the whole dir now to make sure that was the only issue. I'm wondering if this is also why the NFO was getting overwritten? Will Emby replace a malformatted NFO file? 1
Luke 42085 Posted December 23, 2019 Posted December 23, 2019 Thanks for the feedback, and yes, that could cause an nfo to be overwritten as well.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now