Welcome, Guest
Python Scripts for ComicRack

TOPIC: Duplicates Manager (v Alpha - 0.6)

Re: Duplicates Manager (v Alpha - 0.1) 6 years 9 months ago #12226

  • 600WPMPO
  • 600WPMPO's Avatar
  • Offline
  • Moderator
  • Posts: 3788
  • Thank you received: 557
  • Karma: 233
perezmu wrote:
filename keep word1-word2 word3 word4 would make the script search for the string: "word1-word2 word3 word4", so both of your examples would be completely differentiated. Again, this feature, still needs further test!

I tried, but I don't think it worked as intended..

Here, take a look at this portion of the logfile (also attached below):
_________________REMOVE_WITH_WORD______Minutemen-TwiztidSith________
keeping...Justice League - Generation Lost 15 (2011) (two covers) (Minutemen-TwiztidTew).cbz
keeping...Justice League - Generation Lost 015 (2011) (2 covers) (Minutemen-TwiztidSith).cbz
keeping...Justice League - Generation Lost 015 (2011) (2 covers) (fixed) (Minutemen-TwiztidSith).cbz

It keeps all the 3 files, while it should have removed the 2 files with the 'Minutemen-TwiztidSith' suffix.

File Attachment:

File Name: logfile_20...15-2.txt
File Size:5 KB


Anyhow, I am really enjoying the script! This is a really cool script that should've been there a long time ago..

==========================================

Would it be possible for the script to read page types (front cover, advertisement, editorial etc)?

Basically, sometimes I add extra review pages and label them as page type 'Other'. So, an option like this could be helpful:
pagetype	keep	other
Now Playing: The ComicRack Manual (Online)

See my new comics & gadgets on: Tumblr!
Last Edit: 6 years 9 months ago by 600WPMPO.
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.1) 6 years 9 months ago #12228

  • perezmu
  • perezmu's Avatar
  • Offline
  • Platinum Boarder
  • Posts: 1114
  • Thank you received: 64
  • Karma: 51
600WPMPO wrote:
It keeps all the 3 files, while it should have removed the 2 files with the 'Minutemen-TwiztidSith' suffix.

Yep, you are right. Ricardo has provided me with the means to solve this, I will try to have a new version tomorrow.
Anyhow, I am really enjoying the script! This is a really cool script that should've been there a long time ago..

I am glad you feel like that. I just could not keep up with it! 8000+ comics to sort with 3000+ dupes... I really needed this! It will slowly but steadily keep improving.
Would it be possible for the script to read page types (front cover, advertisement, editorial etc)?

Basically, sometimes I add extra review pages and label them as page type 'Other'. So, an option like this could be helpful:
pagetype	keep	other

Uuuum, the way it is working now this would take some time (since I do not really tag pagetypes -though in a perfect world all comics would be c2c with pagetypes set-, I had not thought of it). I'll keep it in mind, but there are quite a few things I feel more urgent... like adding profiles.

Chhers :woohoo:
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12290

  • perezmu
  • perezmu's Avatar
  • Offline
  • Platinum Boarder
  • Posts: 1114
  • Thank you received: 64
  • Karma: 51
NEW VERSION OUT! v0.6, completely coded by PESCUMA who was daring enough to peek into my code... Thanks!
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12344

  • pescuma
  • pescuma's Avatar
  • Offline
  • Expert Boarder
  • Posts: 115
  • Thank you received: 16
  • Karma: 21
New version: 0.7

Added: - New rules:
- pagecount remove largest
- pagecount remove smallest
- filesize remove largest
- filesize remove smallest
- Now it copies some comic information from deleted comics. It is disabled per default.
Enable in constants.py : UPDATEINFO
- Fix for series with multiple volumes


The main feature is the copy of comic info from deleted files. Some fields (like alternate series number) are not handled in cvdb. So, if you added this info to a dup comic that gets deleted, now it is copied to the remaining files. (It only copies the info if the remaining file does not have it). The copied fields are: AlternateCount, AlternateNumber, AlternateSeries, Count, Title


One more side note: since last version the keep pagecount and keep filesize commands accept a percentage as last argument (optional). It can be used in a this case: if you have the same comic compacted as rar and as zip they will have slightly different file sizes. Suppose you prefer to keep the zip files (I do), so you can write in the rules:

filesize keep largest 10%
filesize keep zip
filesize keep largest

What that will do is:
1. Keep the largest file and all files that have a size greater than 90% of that size. Since the zip and rar will have more or less the same size, both will be keep. Smaller files will be removed.
2. From the result, keep only zip files (if there is any zip file - else this rule is ignored)
3. From the result, keep only the largest file. If you had more than one zip with almost the same size both would remain until now
The administrator has disabled public write access.
The following user(s) said Thank You: doolittle

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12383

  • doolittle
  • doolittle's Avatar
  • Offline
  • Fresh Boarder
  • Posts: 16
  • Karma: 0
I love it when you two get together on scripts! :woohoo:
"i aim to misbehave."
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12390

  • perezmu
  • perezmu's Avatar
  • Offline
  • Platinum Boarder
  • Posts: 1114
  • Thank you received: 64
  • Karma: 51
doolittle wrote:
I love it when you two get together on scripts! :woohoo:

Yep, it is great to have pescuma aboard! He was daring enough to peek into my mesh, and make some sense out of it!
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12394

  • doolittle
  • doolittle's Avatar
  • Offline
  • Fresh Boarder
  • Posts: 16
  • Karma: 0
I'm running the 0.7 version and getting the following error.




Not sure what I managed to screw up. :(
"i aim to misbehave."
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12395

  • perezmu
  • perezmu's Avatar
  • Offline
  • Platinum Boarder
  • Posts: 1114
  • Thank you received: 64
  • Karma: 51
Uuuum, that happens to me from time to time when I get another error first... Have you tried restarting comicrack? or reinstalling the script?
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12396

  • doolittle
  • doolittle's Avatar
  • Offline
  • Fresh Boarder
  • Posts: 16
  • Karma: 0
After I restart, the first time I ran DupeMan I got this error:



Followed on the second run by the ScopeStorage error from above. Gonna reinstall, see if it works then.
"i aim to misbehave."
Last Edit: 6 years 9 months ago by doolittle.
The administrator has disabled public write access.

Re: Duplicates Manager (v Alpha - 0.6) 6 years 9 months ago #12397

  • perezmu
  • perezmu's Avatar
  • Offline
  • Platinum Boarder
  • Posts: 1114
  • Thank you received: 64
  • Karma: 51
Well, you must really have broken something ;)

You can try copying the attached file to the script dir (rename .txt to .py)
Attachments:
Last Edit: 6 years 9 months ago by perezmu.
The administrator has disabled public write access.
Time to create page: 0.224 seconds

Who's Online

We have 243 guests and 3 members online