Renaming/seeing issues with numbers apart of their title

Enhancement requests or feature requests for future Mylar releases.
leaderdog
Posts: 377
Joined: Sun Apr 26, 2015 1:52 pm

Renaming/seeing issues with numbers apart of their title

Post by leaderdog »

Hi! First, great program!

Problem I'm running into is a folder filled with files that has a number in it's title never get seen by Mylar.
example:

Folder is:
Comics\Oni Press\Letter 44 (2013)

I have all 15 issues renamed to Letter 44 - 001.cbr but no matter how many times I hit the "Recheck Files" button it will not see the files in the folder. I have to select them all and change them to "archived" just to get them out of the wanted list.

Code: Select all

2015-04-26 09:08:31 	INFO 	[FILE-RESCAN] I have physically found 0 issues, ignored 0 issues, snatched 0 issues, and accounted for 0 in an Archived state [ Total Issue Count: 0 / 15 ]
2015-04-26 09:08:31 	INFO 	[FILE-RESCAN] Total files located: 0
2015-04-26 09:08:31 	INFO 	[FILE-RESCAN] Updated the status of 15 issues for Letter 44 (2013) that were not found.
2015-04-26 09:08:31 	INFO 	[FILE-RESCAN] Now checking files for Letter 44 (2013) in :Letter 44 (2013)
2015-04-26 09:08:27 	INFO 	[FILE-RESCAN] Now checking files for Letter 44 (2013) in G:\Comics\oni press/Letter 44 (2013)
If I download via nzb then it will copy and rename the file then auto mark as archive. (mouse over the archive info circle says None 0 bytes). That's fine I guess since it is out of the wanted list. But not so great when you can't get the files via nzb.


If I try manual post processing, it renames the file but doesn't move it.

Code: Select all

2015-04-26 08:18:25 	INFO 	[POST-PROCESSING] Manual post-processing completed for 1 issues.
2015-04-26 08:18:25 	INFO 	[POST-PROCESSING][DIRECTORY-CHECK] Found comic directory: G:\Comics\Oni Press/Letter 44 (2013)
2015-04-26 08:18:24 	INFO 	[POST-PROCESSING] [1/1] Starting Post-Processing for Letter 44 issue: 15
2015-04-26 08:18:24 	INFO 	[DUPECHECK] Duplication detection returned no hits. This is not a duplicate of anything that I have scanned in as of yet.
2015-04-26 08:18:24 	INFO 	[DUPECHECK] Duplicate check for F:\Sabnzb\test\Letter 44 (2015) - 015.cbr
2015-04-26 08:17:21 	INFO 	Starting postprocessing for : Manual Run
I also put in "Letter 44" in Alternate name search and Alternate File-Naming just in case it would help. But it didn't.

I then tried this:
1) Copied files out
2) Deleted the comic through Mylar
3) Used the Import comics option and selected it to add

It added Letter 44 (2014) Folder and marked all the files as wanted and of course "Recheck Files" didn't find the 15 files in the folder.

I find this happens with some other titles too with "-" in them (All-New X-Men) for example.
It will snatch files and archive them as 0 bytes but (unfortunately i can't remember if I just dumped these files in from a different download) but I have 7 files that need to be renamed but it won't find them.

I tried changing the name, taking the "-" out and reducing it down to just the name and number but it refuses to see it.
2015-04-26 09:18:53 INFO [FILE-RESCAN] Now checking files for All-New X-Men (2013) in G:\Comics\marvel/All-New X-Men (2013)
I'm not sure if Mylar is already set up this way, but could it check the current folder name against the files in there to assist with the renaming/recognizing? I'm not sure if that would help or not, but if it's base look up is to search for the folder's name and "-" (if present) it might help.

I'm no programmer and I had my fair share of issues getting Mylar set up. Perhaps I missed something along the way that will remedy this as is.

Thanks for your time. I hope I wasn't to unclear. :D

oh I guess I should mention this too:

Mylar Version: development
-- git build 2b98184718ff65fbce4a344b6b8174dac82a696b.
Python Version : 2.7.8
User avatar
evilhero
Site Admin
Posts: 2883
Joined: Sat Apr 20, 2013 3:43 pm
Contact:

Re: Renaming/seeing issues with numbers apart of their title

Post by evilhero »

It's actually not the number in the series, but the way you have the filename named (at least in the case of Letter 44). Having a dash as a separator will confuse the file checker that mylar runs through when checking for valid naming. Basically when it sees a dash in a filename it checks three things:
- if it's in the series title, mylar checks to see if its a valid name against the title itself.
If the above comes back as not having a dash in the series title or the dash is outside of the range where it could be located within a series title, then it tries the other two options:
- if the - is followed by a digit, mylar assumes it's a negative issue number and processes it as such.
- it checks the actual title of the issue and compares it against what's past the - it discovered (text wise).

For a name to be valid for mylar to scan in it requires :
- series name
- issue number

Depending on the volume of the series (if there are more than one volumes of the series), it will either require a volume label or not. If it's the only volume with a series of that name, then no volume label is necessary. Otherwise, it requires a volume label of some kind (either a v3,v2013,vol.2,vol.2014,etc),as it needs to know the exact series the issue belongs to.

Adding the issue year is not necessary, but it greater helps mylar when determining things as well as ensuring things are correct.

So if you named your Letter 44 files as: 'Letter 44 1.cbz' or 'Letter 44 1 (2014).cbz' or something similar it should be able to pick it up ok. The importer and the file checking use different techniques to parse the filename, and the importer is a bit more flexible with some naming conventions.

The querying parent folder option of a series is coming.. I tend to do little side projects and use some of the code techniques from them and integrate it back into mylar. So it's coming, just needs some fine tuning (along with being able to scan metadata from files when doing an import as well).

Hope that helps abit, and if you have any other problems or questions feel free to ask!
leaderdog
Posts: 377
Joined: Sun Apr 26, 2015 1:52 pm

Re: Renaming/seeing issues with numbers apart of their title

Post by leaderdog »

Thanks for the quick reply.

And that does put things into perspective. Sadly using dashes is how I've always organized my titles (comics,tv etc). I find it looks much cleaner and more appealing for my eye to pick out everything in the title.

Guess ya can't please every one :D

Thanks again,
leaderdog
Posts: 377
Joined: Sun Apr 26, 2015 1:52 pm

Re: Renaming/seeing issues with numbers apart of their title

Post by leaderdog »

Hi EvilHero,

I decided I could live with the "~" as my separator. So far it seems to be ok. It changes the file to archived as far as the All-New X-men are concerned. Not sure if that's a feature or still a result of the "-" in the comic name.

ok Steps taken:

1) I restarted Mylar
2) removed the - so Letter 44 001.cbr is what the file looks like now
3) "Rechecked Files" and get

Code: Select all

2015-04-26 14:21:36 	INFO 	[FILE-RESCAN] I have physically found 0 issues, ignored 0 issues, snatched 0 issues, and accounted for 0 in an Archived state [ Total Issue Count: 0 / 15 ]
2015-04-26 14:21:36 	INFO 	[FILE-RESCAN] Total files located: 0
2015-04-26 14:21:36 	INFO 	[FILE-RESCAN] Updated the status of 15 issues for Letter 44 (2013) that were not found.
2015-04-26 14:21:36 	INFO 	[FILE-RESCAN] Now checking files for Letter 44 (2013) in :Letter 44 (2013)
2015-04-26 14:21:36 	INFO 	[FILE-RESCAN] Now checking files for Letter 44 (2013) in G:\Comics\oni press/Letter 44 (2013)
4) tried a couple more times same result
5) used flash renamer and added the ~ so title now looks like Letter 44 ~ 001.cbr
6) Recheck Files and get:

Code: Select all

2015-04-26 14:26:16 	INFO 	[FILE-RESCAN] I have physically found 0 issues, ignored 0 issues, snatched 0 issues, and accounted for 0 in an Archived state [ Total Issue Count: 0 / 15 ]
2015-04-26 14:26:16 	INFO 	[FILE-RESCAN] Total files located: 0
2015-04-26 14:26:16 	INFO 	[FILE-RESCAN] Updated the status of 15 issues for Letter 44 (2013) that were not found.
2015-04-26 14:26:16 	INFO 	[FILE-RESCAN] Now checking files for Letter 44 (2013) in :Letter 44 (2013)
2015-04-26 14:26:12 	INFO 	[FILE-RESCAN] Now checking files for Letter 44 (2013) in G:\Comics\oni press/Letter 44 (2013)
Unless I'm doing something more wrong here.

So just to test.

1) I took out the "-" so now title looks like 28 Days Later 001.cbr
2) Marked all as wanted (previously said "Archived")
3) "Recheck Files" yields no results even tho files 1-24 are there (also made sure it was the only ongoing series which it is)
4) Renamed them all with Flash renamer to 28 Days Later ~ 001.cbr
5) "Recheck Files" and get:

Code: Select all

2015-04-26 14:40:52 	INFO 	[FILE-RESCAN] I have physically found 0 issues, ignored 0 issues, snatched 0 issues, and accounted for 0 in an Archived state [ Total Issue Count: 0 / 24 ]
2015-04-26 14:40:52 	INFO 	[FILE-RESCAN] Total files located: 0
2015-04-26 14:40:52 	INFO 	[FILE-RESCAN] Updated the status of 24 issues for 28 Days Later (2009) that were not found.
2015-04-26 14:40:51 	INFO 	[FILE-RESCAN] Now checking files for 28 Days Later (2009) in :28 Days Later (2009)
6) Just for kicks and giggles removed 28 from the start of the title but that didn't work either.
7) Now to compare I went to the Unity Folder titles all 0 - 17 files named as Unity - 001.cbr They are all seen as Downloaded (not archived)
8) Hit rename and it changed them all to Unity 001.cbr (forgot I took the grave out to test... adding it in now)
9) It renamed all the files to Unity ~ 001.cbr but now everything is listed as "archived".

Code: Select all

2015-04-26 14:47:03 	INFO 	[FILE-RESCAN] I have physically found 0 issues, ignored 0 issues, snatched 0 issues, and accounted for 18 in an Archived state [ Total Issue Count: 18 / 18 ]
2015-04-26 14:47:03 	INFO 	Issue Title given as : None
2015-04-26 14:47:03 	INFO 	[FILE-RESCAN] Total files located: 0
2015-04-26 14:47:03 	INFO 	[FILE-RESCAN] Updated the status of 18 issues for Unity (2013) that were not found.
10) Hit "Recheck Files" and get this:

Code: Select all

2015-04-26 14:49:51 	INFO 	[FILE-RESCAN] I have physically found 0 issues, ignored 0 issues, snatched 0 issues, and accounted for 18 in an Archived state [ Total Issue Count: 18 / 18 ]
2015-04-26 14:49:51 	INFO 	[FILE-RESCAN] Total files located: 0
2015-04-26 14:49:51 	INFO 	[FILE-RESCAN] Updated the status of 18 issues for Unity (2013) that were not found.
2015-04-26 14:49:50 	INFO 	[FILE-RESCAN] Now checking files for Unity (2013) in :Unity (2013)
2015-04-26 14:49:41 	INFO 	[FILE-RESCAN] Now checking files for Unity (2013) in G:\Comics\Valiant/Unity (2013)
So 2 questions:
1 - Does the "~" affect anything? Obviously I'd rather use "-" but if that's not an option.
2 - the number in the title is it keeping it from being able to see the files in the folder?

Thanks again!
User avatar
evilhero
Site Admin
Posts: 2883
Joined: Sat Apr 20, 2013 3:43 pm
Contact:

Re: Renaming/seeing issues with numbers apart of their title

Post by evilhero »

Ok, so firstly I have to apologize for a) taking longer than expected to reply and b) providing you with the wrong information.

When I was looking through the code today, it looks like it's incorrectly removing the entire series title from the filename when doing the comparison against your watchlist title. So in essence, 'Letter 44 001' is compared against '001' - now why it's doing this I'm not sure (I know I had did it for a reason, but it was probably ages ago and had since been accomplished another way). If, however, the year was provided for the issue, then it would flip into another segment of the code and would be able to find it just fine.

In looking through all the filechecking code, it's pretty due for an overhaul. It's being used by so many things within Mylar (file-checking, manual post-processing, importing) that it needs to be abit more 'forgiving' about some aspects of it - plus the code is just a mess :(

All I can suggest right now is to include the issue year in your filenames - so that it will get picked up and scanned in.
1 - Does the "~" affect anything? Obviously I'd rather use "-" but if that's not an option.
The '~' isn't one of the characters checked for as an 'extra character', so I would have to add that exception in (not a big deal, but just requires abit of testing after the above gets fixed to ensure it all works). The '-' definitely isn't usable as it is, and even with an upcoming code-change I'm not sure if I'd be able to accomodate the use of the character like that (since it can also signify a negative number), but I'll see what I can do.
2 - the number in the title is it keeping it from being able to see the files in the folder?
It's not so much the number (that gets accounted for), it's not including the issue year. I've run through various combinations of including the volume label even, and without and if the issue year isn't present it's not flipping it. Now this will only happen when a series has a number in it under these conditions. If it's a non-numeric named series, it will work as it is (even with the - seperating the issue number as you had it originally).

The Archived status will only display issues that Mylar cannot scan in - but it knows that it was there previously (it got marked as being in a Downloaded status, and now it can't find it - so it assumes it's been 'archived' off somewhere else). An issue can't be marked as Archived if it exists in the series directory - on a rescan/recheck of files, if said issues exist in the series directory and they are in an Archived status, they will be changed to Downloaded as they are discovered. Note - that alot of functions depend on the status - if an issue is in Downloaded status, then other options become available (manual meta-tagging/renaming / viewing meta-data / etc).

Just keep in mind that 'Downloaded' = 'Completed/Present' (basically).I think I may need to change the actual status' naming as I think it might be a bit outdated...

I'll be working on this over the next little while, so hopefully I can get things sorted out so they work as expected.
leaderdog
Posts: 377
Joined: Sun Apr 26, 2015 1:52 pm

Re: Renaming/seeing issues with numbers apart of their title

Post by leaderdog »

No problem for the delay. I'm sure you have other responsibilities and other people bugging you.

I went back to using the "-" something about old dog and new tricks fit in here. :D It all reacts normally really, they are seen and accounted for in the folder just fine... except for all-new x-men it just seems to choke all over the dashes in that one. I just use it for organizing not worried about tagging and what not.

I tried adding the date to the title for Letter 44 and it indeed did work. Renamed it fine too to Letter 44 - 001.cbr but it changed status to snatched since it started the download before I could finish testing. Then it couldn't find it in the folder again. No big deal tho for that er well for my needs anyways.

I'd imagine if/when you implement the folder name check then it could look for the actual title name minus the date so for Letter 44 (2013) being the folder name if it looked for "Letter 44" in the file it would reduce the load/logic required to determine the title name.

Thanks for your hard work and patience. :)

Raymond
User avatar
evilhero
Site Admin
Posts: 2883
Joined: Sat Apr 20, 2013 3:43 pm
Contact:

Re: Renaming/seeing issues with numbers apart of their title

Post by evilhero »

So here's what I have so far in the quick bit of time I had to work on this:

Image

You can see that using the '-' as a separator works for series that have numbers in the series title (issues formatted as 'Letter 44 - 1.cbr' or 'Letter 44 1.cbr' should now both be working based on some quick tests).

I also got it working for the All-New X-Men series as well, so now they can be named in the format of 'All-New X-Men - 1.cbr' (previously it was assuming it was a negative number).

(This was without the 'check parent folder' option that was being discussed above).

Expect this fix out shortly to the development branch...
leaderdog
Posts: 377
Joined: Sun Apr 26, 2015 1:52 pm

Re: Renaming/seeing issues with numbers apart of their title

Post by leaderdog »

That's some fine work there good sir! I look forward to the next release. :)

Thanks for taking care of this so quickly.

Once I get the update if I have problems I'll let you know.
User avatar
evilhero
Site Admin
Posts: 2883
Joined: Sat Apr 20, 2013 3:43 pm
Contact:

Re: Renaming/seeing issues with numbers apart of their title

Post by evilhero »

It's up now (another commit when up just a few moments ago), but it's in there ;)

Let me know how it works, and if there's any other problems that might arise from this - hopefully it's addressed some of the problems you were having!
leaderdog
Posts: 377
Joined: Sun Apr 26, 2015 1:52 pm

Re: Renaming/seeing issues with numbers apart of their title

Post by leaderdog »

That was fast.

Letter 44 had no trouble finding the files. But I changed them to "wanted" then did "Recheck Files" They found them! I was quite pleased but then sab started populating Letter 44 for download. I kept having to delete them. So for some reason it didn't remove them from the "wanted" list (I didn't look to see tho), or they all got que'd up really fast. It did seem like it took some time for each comic to get added to sab.

28 Days Later. I left them all as archived and hit "Recheck Files" and it found all but 2 oddly enough.

Code: Select all

2015-04-27 22:06:33 	INFO 	[FILE-RESCAN] I have physically found 22 issues, ignored 0 issues, snatched 0 issues, and accounted for 2 in an Archived state [ Total Issue Count: 24 / 24 ]
2015-04-27 22:06:33 	INFO 	[FILE-RESCAN] Total files located: 22
2015-04-27 22:06:33 	INFO 	[FILE-RESCAN] Updated the status of 2 issues for 28 Days Later (2009) that were not found.
2015-04-27 22:06:32 	INFO 	[FILE-RESCAN] Now checking files for 28 Days Later (2009) in :28 Days Later (2009)
2015-04-27 22:06:26 	INFO 	[FILE-RESCAN] Now checking files for 28 Days Later (2009) in G:\Comics\Boom Studios/28 Days Later (2009)
I ran the "Recheck File" a second time but it read exactly the same way.

All-New X-men. This one is still a bit finicky when renaming is concerned. This is what the files look like (how they were downloaded):

All New X-Men 009 (2013) (Digital) (Zone-Empire).cbr
All_New_X-Men_011_(2013)_(Digital)_(Zone-Empire).cbr

When I hit Recheck Files with these file names I get (There are 36 files in the folder. I'm missing a few yet).

Code: Select all

2015-04-27 22:26:18 	INFO 	[FILE-RESCAN] I have physically found 32 issues, ignored 0 issues, snatched 0 issues, and accounted for 0 in an Archived state [ Total Issue Count: 32 / 41 ]
2015-04-27 22:26:18 	INFO 	[FILE-RESCAN] Total files located: 32
2015-04-27 22:26:18 	INFO 	[FILE-RESCAN] Updated the status of 8 issues for All-New X-Men (2013) that were not found.
2015-04-27 22:26:14 	INFO 	[FILE-RESCAN] Now checking files for All-New X-Men (2013) in :All-New X-Men (2013)
2015-04-27 22:25:47 	INFO 	[FILE-RESCAN] Now checking files for All-New X-Men (2013) in G:\Comics\marvel/All-New X-Men (2013)
If I rename the file to the way I want it to be All-New X-men - 009.cbr it is now found with "recheck files".

All in all, that's pretty darn good :)
Post Reply