Kodi Community Forum

Full Version: TMDB Scraper do not work with mixed Chinese and English filename?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
For example:

Neither the following 2 line can be Scraped.

水果传.Legend.of.Fruit.S02.2019.1080p.WEB-DL.x264.AAC-HQC
水果传.Legend.of.Fruit

Both of the follwing 2 line work
水果传
Legend.of.Fruit


And after manual scrape, the directory name keeps RAW instead of TV title, I donot know how to make it display as Its Season-01.

Image
Moved to metadata scrapers
Anyone knows how to fix it?
(2020-01-05, 07:19)kirbyzhou Wrote: [ -> ]Neither the following 2 line can be Scraped.

水果传.Legend.of.Fruit.S02.2019.1080p.WEB-DL.x264.AAC-HQC
水果传.Legend.of.Fruit
I would not expect that to scrape. You cannot mix languages in the title. The language you use to name your folders and files should be the same as the language you selected in the scraper settings.

(2020-01-05, 07:19)kirbyzhou Wrote: [ -> ]And after manual scrape, the directory name keeps RAW instead of TV title, I donot know how to make it display as Its Season-01.
You have provided a tiny snippet of a screen, so I don't know what screen you are looking at. But, to me that looks like Videos>Files and shows the show is unscraped.

If you want more help then provide a full screenshot, and a Debug Log that captures you trying to scrape the problem show after you have fixed your mixed languages.
(2020-01-28, 09:17)Karellen Wrote: [ -> ]
(2020-01-05, 07:19)kirbyzhou Wrote: [ -> ]Neither the following 2 line can be Scraped.

水果传.Legend.of.Fruit.S02.2019.1080p.WEB-DL.x264.AAC-HQC
水果传.Legend.of.Fruit
I would not expect that to scrape. You cannot mix languages in the title. The language you use to name your folders and files should be the same as the language you selected in the scraper settings. 
Thanks for your comments, but mixed language folder name is really a big requirements in Asian countries.
At least, please at least try to take the first part of folder name before dot/space to scrape.
(2020-01-28, 09:17)Karellen Wrote: [ -> ]
(2020-01-05, 07:19)kirbyzhou Wrote: [ -> ]And after manual scrape, the directory name keeps RAW instead of TV title, I donot know how to make it display as Its Season-01.
You have provided a tiny snippet of a screen, so I don't know what screen you are looking at. But, to me that looks like Videos>Files and shows the show is unscraped.

If you want more help then provide a full screenshot, and a Debug Log that captures you trying to scrape the problem show after you have fixed your mixed languages.  
Yes, the screen is "Videos>Files", I have tried something to reproduce the problem.
It seems that, if you have one season of TV series in KODI database, then the rest seasons must be put into the same folder.
Otherwise "Videos>Files" will display the folder of rest seasons with RAW name instead of TV title.
(2020-01-28, 11:14)kirbyzhou Wrote: [ -> ]It seems that, if you have one season of TV series in KODI database, then the rest seasons must be put into the same folder.
Of course. You must use a TV Show folder. You cannot have episodes and seasons added separately.
See here... https://kodi.wiki/view/Naming_video_files/TV_shows

(2020-01-28, 11:14)kirbyzhou Wrote: [ -> ]but mixed language folder name is really a big requirements in Asian countries.
It would help if you explain why, especially as you are the only person I have seen ask for it. Why do you need two languages? I don't type my shows in part Italian and part English, so why would you need Mandarin(?) and English?

But for your request, there are currently no new features being added nor any major changes.
(2020-01-28, 11:31)Karellen Wrote: [ -> ]
(2020-01-28, 11:14)kirbyzhou Wrote: [ -> ] 
It would help if you explain why, especially as you are the only person I have seen ask for it. Why do you need two languages? I don't type my shows in part Italian and part English, so why would you need Mandarin(?) and English?

But for your request, there are currently no new features being added nor any major changes. 

English titles are used to uniquely identify videos.
Chinese title is used to read quickly.

In China, English title of movie is not well known, and a lot of Movies do not have a official Chinese title, because they are not officially released in China.
So in our country, Resource naming is usually a mixture of Chinese and English.
Ok, that makes sense.

Looking into it a bit more, it is not the scraper that cleans the folder and file name strings, but Kodi core so this affects all scrapers and any adjustments will need to be made at the core level.

I was looking for solutions and with help from @olympia came up with the following three...

1. IMDB ID
This works for movies, but I have never tested on TV Shows and don't think it will work for tv shows
Use the IMDB ID in the folder name. It will require you adding an extra folder level as shown...
-MyMovies
---小丑回魂 2 It Chapter 2
-----tt7349950
-------小丑回魂 2 It Chapter 2.mkv
Kodi will read the tt... number in the folder name and use it for the search criteria.
But this only works if the tt.... number is available at TheMovieDB entry, and for your movie Legend Of Fruit there is no tt.... number and there is no entry at IMDB, so this method will not always work

2. advancedsettings.xml
https://kodi.wiki/view/Advancedsettings....eanstrings
You can create a Regex and add it to advancedsettings.xml to clean the filename and foldernames.
The following works, but it may cause more problems than it fixes because it strips all English words from all folders and filenames.

<video>
<cleanstrings action="prepend">
<regexp>\.[a-zA-Z]</regexp>
</cleanstrings>
</video>

3. Information
The third alternative is a manual lookup and is the easiest and most reliable but needs to be done show by show.
Go to Videos>Files>Your Source and locate your movie or tv show.
Call up the Information page by pressing i on your keyboard
When the onscreen keyboard pops up, adjust the displayed search string.
Oh, and let's not forget the obvious fourth method...

4. Parsing NFO
Use a Parsing NFO file... https://kodi.wiki/view/NFO_files#Parsing_nfo
(2020-01-28, 23:53)Karellen Wrote: [ -> ] 
Thanks for your suggestion, I think maybe cleanstrings or NFO is the best way for me.

How to set cleanstrings to obtain a string contains only chars before the first dot/space?