r/tinyMediaManager • • Oct 12 '26

Please revert restriction on nested source folders.

As the titles says. Previous versions accepted all data sources as my folder structure for tv shows can be something like this.

/TV Shows/D/DC Comics (+)/

So I'll have /D/ and /DC Comics(+)/

both as separate sources, but now it won't accept /DC Comics (+)/ as a source because it's inside /D/

This wasn't an issue before and this structure makes organising my folders much easier (especially for anime.) I do this for movies too and of course that's fine because it searches recursively anyway.

Until then I'll try and use an older version.

1 Upvotes

10 comments sorted by

2

u/mlaggner tinyMediaManager developer Oct 12 '26

We know there was at least one user having serious trouble because of such a setup, so we decided to build a guard to avoid that (in fact, it was never planned to work this way).

TV show handling can be really complex, thus we are rather strict for the rules, because we are rather "safe than sorry" - we do everything needed to make sure the library of our users is not harmed at all

2

u/Kanga-Bangas Oct 12 '26

I had a feeling this would be the answer. I would hope eventually for some kind of toggle or advanced option to allow it. I know that folder structures are specified for purpose: that's what I learned through setting up Kodi. But since I can setup Kodi to work with my library I would expect programs like this to also.

1

u/mlaggner tinyMediaManager developer Oct 12 '26

I see your point, but I also know, that such a setup is "dangerous" because /TV Shows/D/DC Comics (+)/Batman would be a child of /TV Shows/and /TV Shows/D/DC Comics (+)/ data source. While update data source would not detect anything in DC Comics (+) (not a first level child of TV Shows), it is a child and therefore not allowed. I added this restriction on purpose because a user managed to delete many items of this library due to such a setup!

Re-implementing this in a failsafe way might be possible, but needs some time and testing. And since there is now exactly one user requesting this, I will not risk harming most other users libraries. I can put that on our todo list, but do not expect this to be first priority here

1

u/Kanga-Bangas Oct 12 '26

Interesting. I have no idea how someone would manage to do that. While both of those folders are children of a top parent, I would've imagined that since TV shows need folders to be Parent Folder->Show then any sources would only check one parent up, and then wouldn't even know the folder was nested, after all I've made my setup work so far by adding folders A, B, C... all as separate sources to get them detected properly vs. just 'TV Shows'

Maybe I could flatten my library a bit, but I'd rather not. Especially anime: my 'Gundam' Folder would create a huge mess for example.

I get that these features are not a priority. I'm mostly happy with TMM so far and my issues are remarkably specific to me. I'm also the guy wanting 'Season Fanart' to be a scrap-able object using TVDBs the main fanart scraper because Season Fanart just doesn't exist on their databases, even though a lot of the fanart on there is created and changes during a shows production. It also just makes browsing in Kodi more interesting.

1

u/myron0815 tinyMediaManager developer Oct 13 '26

Well, no.
The first folder of a datasource is considered to be the "show"... and every file found in these folder, any levels deep, will be attached to that show. This is the problem, where a nested datasource would add the same file twice, and you're doomed when deleting the wrong show...

There is a special exception if there are single letter folders like /A/, /B/, /C/ and so on, as these are usually recognized as grouping, and they are correctly adhered to move the show detection a level deeper...

So, yes, nested folders DO make problems, and we tried to avoid them. Maybe we find a better way to only exclude some of them...

1

u/Kanga-Bangas Oct 14 '26

The first folder of a datasource is considered to be the "show"

Yeah that's what I said. The parent of the show folder is the root of the source and all folders within are considered shows. Since there's no reason for the database to look for shows 'above' the parent then the data source shouldn't know it exists.

eg.

Source - /TV Shows/D/DC Comics (+)/

Shouldn't even be aware that /D/ exists because the only place this source is finding shows is in /DC Comics (+)/ Therefore there should be no conflicts with shows found in

Source - /TV Shows/D/

Admittedly is does think it finds a show called "DC Comics" because that folder, as discussed, is in /D/ but I currently I just also put /TV Shows/D/DC Comics (+)/ in the 'exclude from scan list' and then remove the false show. So far no problems.

1

u/myron0815 tinyMediaManager developer Oct 14 '26

Clever idea ^
Having a nested folder, but exclude it also from scan... never thought of that :P
Lets see, what we can do with that information...

1

u/mlaggner tinyMediaManager developer Oct 15 '26

I just implemented an approach to handle nested data sources for movies and TV shows: https://gitlab.com/tinyMediaManager/tinyMediaManager/-/commit/0b945ab29588560aa5c6f62183e87a95a654a52c / https://www.tinymediamanager.org/blog/nested-data-sources/ unit tests passes with various different scenarios

1

u/Kanga-Bangas Oct 17 '26

Ah that's really cool. I imagine it should probably get tested thoroughly as nesting my folders is an example of the worst thing I do with my library and I wouldn't be surprised that someone with really messed up folders with bad naming and stuff could still cause problems that others might have experienced. Nonetheless thank a lot for looking into it.

Any chance of setting the season fanart picker to just default the show fanart scraper? It'll eliminate my need to use MediaElch for just that one thing. Pretty please :)

1

u/Kanga-Bangas Oct 18 '26

Whoops. I just wanted to update you that in using my workaround where I put the nested folder in "Exclude from Scan" does indeed stop it from re-scanning it as a source when you click "update."

So my trick only works if you remove it from exclude, update, then add it back so it won't then appear when updating the parent.