mordoris / phoshare

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

Support of accented characters #57

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Have a library which name includes an accented character, such as 
'Bibliothèque iPhoto'
2. Select it in Phoshare
3. Launch a dry run

What is the expected output? What do you see instead?
- The following error is reported, and stops the process:
Error: 'ascii' codec can't encode character u'\u0300' in position 35: ordinal 
not in range(128)

What version of the product are you using? On what operating system?
- Phoshare 1.5.2
- Mac OS X 10.8.2

Please provide any additional information below.
- This seems to be a newbie issue, but it's not. I tried to rename the library 
without any accented character ('Bibliotheque iPhoto'), and the dry run is 
executed but no image is found at all, as the library tree has been built by 
iPhoto relatively to the original path which name was with the accented 
character.
As this name is the default one in french iPhoto, it is likely that no french 
user (and more international folks with accented characters) will ever be able 
to use the software properly.

Original issue reported on code.google.com by guillaum...@gmail.com on 3 Feb 2013 at 5:28

GoogleCodeExporter commented 8 years ago
Here is the error stack trace:
----------------

Traceback (most recent call last):
  File "/Users/guillaume/Downloads/Phoshare-1.5.2.app/Contents/Resources/lib/python2.7/phoshare/phoshare_ui.py", line 986, in export_thread
  File "/Users/guillaume/Downloads/Phoshare-1.5.2.app/Contents/Resources/lib/python2.7/phoshare/phoshare_ui.py", line 855, in save
  File "ConfigParser.pyc", line 404, in write
UnicodeEncodeError: 'ascii' codec can't encode character u'\u0300' in position 
35: ordinal not in range(128)

Original comment by guillaum...@gmail.com on 3 Feb 2013 at 5:36

GoogleCodeExporter commented 8 years ago
Remove the folder
  Library/Application Support/Google/Phoshare
The previous library name is stored in there, and triggering the error when 
Phoshare tries to read its stored settings.

Original comment by tsporkert on 3 Feb 2013 at 7:53

GoogleCodeExporter commented 8 years ago
tsporkert, that doesn't fix the issue.
The path to open the library is correct (if I replace the 'é' with an 'e'), 
but I think it's the iPhoto library .xml built with the orignal name that 
includes the 'é'. So removing the Phoshare config file has no effect.

Here are some logs:

Version 9.4 library with 410 images
Phoshare.py --export "/Users/guillaume/Pictures/Album" --iphoto 
"/Users/guillaume/Pictures/Bibliotheque iPhoto VM.photolibrary" --albums "." 
--events "." --foldertemplate "{name}" --nametemplate "{title}" 
--captiontemplate "{description}"
Scanning iPhoto data for photos to export...
Scanning existing files in export folder...
Creating folder /Users/guillaume/Pictures/Album/Feb 2013 - Flux de photos
Creating folder /Users/guillaume/Pictures/Album/iPad
Creating folder /Users/guillaume/Pictures/Album/iPhone
Creating folder /Users/guillaume/Pictures/Album/Jan 2013 - Flux de photos
Exporting photos from iPhoto to export folder...
Failed to resolve alias for /Users/guillaume/Pictures/Bibliothèque iPhoto 
VM.photolibrary/Previews/2013/02/02/20130202-213806/hrSNl3PWRlq%5nubL9gCfQ/IMG_2
118.jpg.
New file: /Users/guillaume/Pictures/Album/Feb 2013 - Flux de 
photos/IMG_2118.jpg (copy)
Failed to resolve alias for /Users/guillaume/Pictures/Bibliothèque iPhoto 
VM.photolibrary/Masters/2013/02/02/20130202-213806/IMG_0078.JPG.
New file: /Users/guillaume/Pictures/Album/Jan 2013 - Flux de 
photos/IMG_0078.jpg (copy)
Failed to resolve alias for /Users/guillaume/Pictures/Bibliothèque iPhoto 
VM.photolibrary/Masters/2013/02/02/20130202-213734/IMG_0087.JPG.
[...]

Original comment by guillaum...@gmail.com on 4 Feb 2013 at 12:56

GoogleCodeExporter commented 8 years ago
Me too. The problem ist not only with the iPhoto Library Name, but also with 
the folder names where the original image is stored. I have the letter 'ö' in 
my path:

/Volumes/Fettplatte1000/Fotos_Lara_und_Joerg/2006_12_24_Heiligabend mit 
Weltschönstem Tannenbaum/img_5387.jpg

Running my script:

/Applications/Phoshare-1.5.2.app/Contents/MacOS/Phoshare --delete --events=. 
--export=/Volumes/Fettplatte1000/iPhoto_Downsample_Export/out 
--iphoto=/Volumes/Fettplatte1000/iPhoto\ Library --gps --size=1248 --iptc 
--verbose 

…causes an error on most of my folder names. Example:

New file: 
/Volumes/Fettplatte1000/iPhoto_Downsample_Export/out/2006_12_24_Heiligabend mit 
weltschönstem Tannenbaum/img_5387.jpg (resize)

sips -g pixelWidth -g pixelHeight 
/Volumes/Fettplatte1000/Fotos_Lara_und_Joerg/2006_12_24_Heiligabend mit 
Weltschönstem Tannenbaum/img_5387.jpg

sips -s format jpeg --resampleHeightWidthMax 1248 
/Volumes/Fettplatte1000/Fotos_Lara_und_Joerg/2006_12_24_Heiligabend mit 
Weltschönstem Tannenbaum/img_5387.jpg --out 
/Volumes/Fettplatte1000/iPhoto_Downsample_Export/out/2006_12_24_Heiligabend mit 
weltschönstem Tannenbaum/img_5387.jpg

/Volumes/Fettplatte1000/Fotos_Lara_und_Joerg/2006_12_24_Heiligabend mit 
Weltschönstem Tannenbaum/img_5387.jpg: Error 10: out_dir_not_found 
/Volumes/Fettplatte1000/iPhoto_Downsample_Export/out/2006_12_24_Heiligabend mit 
weltschönstem Tannenbaum/img_5387.jpg

Try 'sips --help' for help using this tool

Original comment by raettc...@gmail.com on 23 Feb 2013 at 5:14

GoogleCodeExporter commented 8 years ago
Sorry for being misleading: My problem was not with the name of the source 
folder, as I believed, but with the category name in iPhoto. When I remove the 
umlauts in the category name, there's no problem with the umlaut in the folder 
name anymore.

So, yes, there's a bug, but at a different place.

Original comment by raettc...@gmail.com on 23 Feb 2013 at 6:27

GoogleCodeExporter commented 8 years ago
Hello,
I experience the same problem as Guillaume : 
Version 9.4 library with 12600 images
Error: 'ascii' codec can't encode character u'\u0300' in position 34: ordinal 
not in range(128)
Any ideas ?

Original comment by jbois...@gmail.com on 19 Mar 2013 at 9:27

GoogleCodeExporter commented 8 years ago
Hello,
Any news about this issue?
Thanks

Original comment by guillaum...@gmail.com on 2 Apr 2013 at 12:49

GoogleCodeExporter commented 8 years ago
Unfortunately, no. Last October, I posed the message below about suspending 
active development of Phoshare. That doesn't mean it can't be fixed - Phoshare 
has always been open source, meaning anybody with some programming skills can 
step forward and contribute a fix.

https://groups.google.com/forum/?fromgroups=#!topic/phoshare-users/moWsMcD5SdQ

Original comment by tsporkert on 2 Apr 2013 at 4:09