Hainzy262 / comictagger

Automatically exported from code.google.com/p/comictagger
0 stars 0 forks source link

File can not be renamed when tag Month == 3 #7

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Change the month-tag of any existing comic to 3
2. rightclick -> rename OR ctrl/n
3.

What is the expected output? What do you see instead?

Usually a new window pops up asking me to confirm the renaming. But when Month 
== 3 literally nothing happens.

What version of the product are you using? On what operating system?

v1.1.2-beta
Ubuntu 12.10 32bit
GUI

Please provide any additional information below.

-Installed via pip.
-renaming template:%series% V%volume% #%issue% (of %issuecount%) (%year%)
--info: changing the template didnt help
-read- and modify style: ComicRack

to be sure the problem was not a corrupt file I even made my own "comic" with 
some pictures i downloaded from google. Still it only was renamed in 11 out of 
12 months.

Original issue reported on code.google.com by Eric.Jan...@gmail.com on 22 Feb 2013 at 6:50

GoogleCodeExporter commented 8 years ago
Interesting problem.  I can't test this now, but I have a theory:

Is the system language on your Ubuntu system set to German?  Even though your 
template doesn't use "%month_name%", the internal processing still creates a 
string for replacement. There might be a problem with "März", since it's the 
only month in German that contains a non-ASCII character.  I probably just need 
to properly handle Unicode in the relevant functions.

Original comment by bevi...@gmail.com on 22 Feb 2013 at 5:25

GoogleCodeExporter commented 8 years ago
Indeed, that seems to be the problem.
Language was set to German, after changing it to English everything worked.
Now I also start to remember that some time ago, when i first used ComicTagger, 
there was a similar problem caused by the German translation for desktop: 
Arbeitsfläche... I just cant remember under what circumstances that happened.

Original comment by Eric.Jan...@gmail.com on 22 Feb 2013 at 10:56

GoogleCodeExporter commented 8 years ago
I've been trying to fix all of the stupid bugs related to character encoding.  
I am sure in earlier versions "Arbeitsfläche" would have caused a problem, but 
sounds like it's not now.  

This particular issue should be fixed in the next release, in the next week or 
so.  If you want to tweak things on your end in the meantime, delete lines 91 
to 97 in /usr/local/lib/python2.7/dist-packages/comictaggerlib/filerenamer.py.  
You should be able to go back to the German settings then.

Thanks for reporting this!

Original comment by bevi...@gmail.com on 23 Feb 2013 at 12:37

GoogleCodeExporter commented 8 years ago
So i commented out these lines and renaming worked, thanks for that.

But i guess i figured out what the problem was with "Arbeitsfläche":
When i open a comic file that has "Arbeitsfläche" in its URL, the next time i 
open ComicTagger it has been reset and is showing the welcome-window. When i 
move the file to another (higher) location, for example to my NAS under 
/mnt/NAS before opening it, this does not happen. I checked if it has to do 
with me changing filerenamer.py, but this happens also when using the original 
script.
Another problem also occurred when a file under "Arbeitsfläche" (or a 
subdirectory) was opened: The OK button in the settings does save changes, but 
doesn't close the settings-window, to close it I had to press "Cancel".
Even when i remove the comic before closing ComicTagger, it is reset.

Let me know if if you want me to test something.

Original comment by Eric.Jan...@gmail.com on 23 Feb 2013 at 3:47

GoogleCodeExporter commented 8 years ago
Ha!  I guess that's why I'm calling this "beta"!

OK, it's the same problem again:  I didn't test everything fully with 
multi-byte characters.  In this case I was assuming the stock ConfigParser 
class was handling this for me.  I was wrong.

Fortunately there is a newer module called "configparser" that will do the job 
with not much more effort.

If you want to to test:

1. pip install configparser
2. Replace /usr/local/lib/python2.7/dist-packages/comictaggerlib/settings.py 
with this file:  
http://comictagger.googlecode.com/svn/trunk/comictaggerlib/settings.py

The should allow non-ASCII characters to be written to the settings file 
without a problem.

Original comment by bevi...@gmail.com on 24 Feb 2013 at 7:18

GoogleCodeExporter commented 8 years ago

Original comment by bevi...@gmail.com on 28 Mar 2013 at 12:09