ImageMetadataGramplet and Windows

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

ImageMetadataGramplet and Windows

Helge@Gramps
Here are my results running ImageMetadataGramplet on Windows (64 Bit) using various Gramps versions:
Gramps 3.2.x from svn
        Win7, 64 Bit
        Python    2.6.6, 32 Bit
        GTK+      2.16.6
        pyGTK     2.16.0
        gobject   2.20.0
        cairo     1.4.12
        enchant   1.5.3
        graphviz  2.26.3 (20100126.1600)
        pyexiv2-0.2.2
        exiv2-0.21 for Windows

        using ImageMetadataGramplet
                patched as issue 4522
                inside Splitviews
        ==> running well

Gramps 3.2.x from trunk
        Win7, 64 Bit
        Python    2.6.6, 32 Bit
        GTK+      2.16.6
        pyGTK     2.16.0
        gobject   2.20.0
        cairo     1.4.12
        enchant   1.5.3
        graphviz  2.26.3 (20100126.1600)
        pyexiv2-0.2.2
        exiv2-0.21 for Windows

        ImagMetadataGramplet:
        runs with error only
        D:\GRAMPS\Batches\10 TEST_Trunk>"C:\Program Files (x86)\Python26\python.exe" "C:\ProgrammeNeutral\GrampsTrunk\src\gramps.py"
        Traceback (most recent call last):
  File "C:\ProgrammeNeutral\GrampsTrunk\src\gen\plug\_manager.py", line 219, in load_plugin _module = self.import_plugin(pdata)
  File "C:\ProgrammeNeutral\GrampsTrunk\src\gen\plug\_manager.py", line 251, in import_plugin _module = __import__(pdata.mod_name)
  File "D:\GRAMPS\ZZ_Trunc\gramps\gramps33\plugins\ImageMetadataGramplet\ImageMetadataGramplet.py", line 302
      self.mime_type ) )
                         ^
  SyntaxError: invalid syntax
        None
        Error loading gramplet 'Image Metadata Gramplet': skipping content

GrampsAOI (32Bit: GrampsAIO-3.2.5-4.exe)
        Win7, 64 Bit
        Python    2.7.1, 32 Bit
        GTK+      2.22.1
        pyGTK     2.22.0
        gobject   2.26.0
        cairo     1.8.10
        enchant   1.6.3
        pyexiv2-0.2.2
                ==> so far I understood http://tilloy.net/dev/pyexiv2/download.html 
                    there should be 0.3.0 for Python 2.7, 32 Bit!!
        exiv2-0.21 for Windows

        ImagMetadataGramplet
        Start is OK
        for any selected .jpg I get an error
        Warning: History: Exception occurred in callback function.
        Traceback (most recent call last):
  File "C:\Program Files (x86)\GrampsAIO\share\gramps\gen\utils\callback.py", line 414, in emit fn(*args)
        File "D:\GRAMPS\GrampsAOI_32\gramps\gramps32\plugins\ImageMetadataGramplet\ImageMetadataGramplet.py", line 222, in media_changed if self.plugin_image:
  File "C:\Program Files (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 338, in __len__ return len( [ x for x in self ] )
  File "C:\Program Files (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 335, in __iter__ return chain(self.exif_keys, self.iptc_keys,

self.xmp_keys)
        File "C:\Program Files (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 146, in exif_keys self._keys['exif'] = self._image._exifKeys()
  File "C:\Program Files (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 96, in _image raise IOError('Image metadata has not been read yet')
        IOError: Image metadata has not been read yet

GrampsAOI (32Bit: GrampsAIO-3.2.5-4.exe, PATCH for pyexiv2)
        Win7, 64 Bit
        Python    2.7.1, 32 Bit
        GTK+      2.22.1
        pyGTK     2.22.0
        gobject   2.26.0
        cairo     1.8.10
        enchant   1.6.3
        pyexiv2-0.3.0   (patched)
        exiv2-0.21 for Windows

        ==> all results the same as for pyexiv2-0.2.2 (see above)
        ==> But pyexiv2-0.3.0 should be the right one for my opinion.  
          Is there the need for a Python 2.7 adoption?

GrampsAOI64 (GrampsAIO64-3.2.5-3.exe)
        No pyexiv included. I couldn't found exiv2 for Windows 64 Bit to try any patch
        ==> Do we need for addons a special 64-Bit-Marker?

I hope this will help to improve the very helpfull Gramplet.
-Helge
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Josip
On 08.01.2011 18:25, Helge@Gramps wrote:
>
>
> GrampsAOI64 (GrampsAIO64-3.2.5-3.exe)
> No pyexiv included. I couldn't found exiv2 for Windows 64 Bit to try any
> patch
> ==>  Do we need for addons a special 64-Bit-Marker?
>

If "special 64-Bit-Marker" means: do we need x64 version of libs, then
yes we need x64 version of intl, iconv, zlib and expat to build exiv2
and then boost-python for pyexiv2 which should be linked against x64
python version.

btw there are no enchant 1.6.3 last released is 1.6.0

--
Josip

------------------------------------------------------------------------------
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to
best implement a security strategy that keeps consumers' information secure
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
_______________________________________________
Gramps-windows mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-windows
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Helge@Gramps
No, "special 64-Bit-Marker" means a signal to the user that an addon is or is not available to run as 64 bit version.

-Helge
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Helge@Gramps
In reply to this post by Josip
Josip-3 wrote
...
btw there are no enchant 1.6.3 last released is 1.6.0
...
Well I run all AOI versions using a .cmd file to set GRAMPSHOME and to have the possibility to switch to the native English language for test reports. Inside this script I ask some modules for there version. My report tells just what comes out from enchant.__version__ (enchant package from GrampsAIO-3.2.5-4.exe).

So I do not understand this comment above.
-Helge
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Josip
In reply to this post by Helge@Gramps
On 09.01.2011 16:07, Helge@Gramps wrote:
>
> No, "special 64-Bit-Marker" means a signal to the user that an addon is or is
> not available to run as 64 bit version.
>

Oh i see,
but all plugins should run in 32 or 64 bit version.
That only depends do you have their dependencies installed or not.

Now plugins can't declare their requirements to gramps but on their load
they usually check for himself for that.


--
Josip

------------------------------------------------------------------------------
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to
best implement a security strategy that keeps consumers' information secure
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
_______________________________________________
Gramps-windows mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-windows
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Josip
In reply to this post by Helge@Gramps
On 09.01.2011 16:18, Helge@Gramps wrote:

>
>
> Josip-3 wrote:
>>
>> ...
>> btw there are no enchant 1.6.3 last released is 1.6.0
>> ...
>>
> Well I run all AOI versions using a .cmd file to set GRAMPSHOME and to have
> the possibility to switch to the native English language for test reports.
> Inside this script I ask some modules for there version. My report tells
> just what comes out from enchant.__version__ (enchant package from
> GrampsAIO-3.2.5-4.exe).
>
> So I do not understand this comment above.
> -Helge

Well i thought that you use some new unrelaesed version of enchant (some
new experimental development version) but that is not the case ;-)

Let me explain:
by good custom python extending modules should ship their version in
__version__ string and preferably also provide function to access that.
If their underlying libraries also have their version included then they
will also have function to access that information.

shortly:
   enchant.__version__ #version of PyEnchant module
   enchant.get_enchant_version() #version of underlying Enchant library

--
Josip

------------------------------------------------------------------------------
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to
best implement a security strategy that keeps consumers' information secure
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
_______________________________________________
Gramps-windows mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-windows
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Josip
In reply to this post by Helge@Gramps
On 08.01.2011 18:25, Helge@Gramps wrote:

>
> Here are my results running ImageMetadataGramplet on Windows (64 Bit) using
> various Gramps versions:
> Gramps 3.2.x from svn
> Win7, 64 Bit
> Python    2.6.6, 32 Bit
> GTK+      2.16.6
> pyGTK     2.16.0
> gobject   2.20.0
> cairo     1.4.12
> enchant   1.5.3
> graphviz  2.26.3 (20100126.1600)
> pyexiv2-0.2.2
> exiv2-0.21 for Windows
>
> using ImageMetadataGramplet
> patched as  http://www.gramps-project.org/bugs/view.php?id=4522 issue 4522
> inside Splitviews
> ==>  running well
>
> Gramps 3.2.x from trunk
> Win7, 64 Bit
> Python    2.6.6, 32 Bit
> GTK+      2.16.6
> pyGTK     2.16.0
> gobject   2.20.0
> cairo     1.4.12
> enchant   1.5.3
> graphviz  2.26.3 (20100126.1600)
> pyexiv2-0.2.2
> exiv2-0.21 for Windows
>
> ImagMetadataGramplet:
> runs with error only
> D:\GRAMPS\Batches\10 TEST_Trunk>"C:\Program Files
> (x86)\Python26\python.exe" "C:\ProgrammeNeutral\GrampsTrunk\src\gramps.py"
> Traceback (most recent call last):
>     File "C:\ProgrammeNeutral\GrampsTrunk\src\gen\plug\_manager.py", line
> 219, in load_plugin _module = self.import_plugin(pdata)
>     File "C:\ProgrammeNeutral\GrampsTrunk\src\gen\plug\_manager.py", line
> 251, in import_plugin _module = __import__(pdata.mod_name)
>     File
> "D:\GRAMPS\ZZ_Trunc\gramps\gramps33\plugins\ImageMetadataGramplet\ImageMetadataGramplet.py",
> line 302
>       self.mime_type ) )
>                 ^
>   SyntaxError: invalid syntax
> None
> Error loading gramplet 'Image Metadata Gramplet': skipping content
>
> GrampsAOI (32Bit: GrampsAIO-3.2.5-4.exe)
> Win7, 64 Bit
> Python    2.7.1, 32 Bit
> GTK+      2.22.1
> pyGTK     2.22.0
> gobject   2.26.0
> cairo     1.8.10
> enchant   1.6.3
> pyexiv2-0.2.2
> ==>  so far I understood http://tilloy.net/dev/pyexiv2/download.html
>    there should be 0.3.0 for Python 2.7, 32 Bit!!
> exiv2-0.21 for Windows
>
> ImagMetadataGramplet
> Start is OK
> for any selected .jpg I get an error
> Warning: History: Exception occurred in callback function.
> Traceback (most recent call last):
>     File "C:\Program Files
> (x86)\GrampsAIO\share\gramps\gen\utils\callback.py", line 414, in emit
> fn(*args)
> File
> "D:\GRAMPS\GrampsAOI_32\gramps\gramps32\plugins\ImageMetadataGramplet\ImageMetadataGramplet.py",
> line 222, in media_changed if self.plugin_image:
>     File "C:\Program Files
> (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 338, in __len__
> return len( [ x for x in self ] )
>     File "C:\Program Files
> (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 335, in
> __iter__ return chain(self.exif_keys, self.iptc_keys,
>
> self.xmp_keys)
> File "C:\Program Files
> (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 146, in
> exif_keys self._keys['exif'] = self._image._exifKeys()
>     File "C:\Program Files
> (x86)\GrampsAIO\lib\site-packages\pyexiv2\metadata.py", line 96, in _image
> raise IOError('Image metadata has not been read yet')
> IOError: Image metadata has not been read yet
>
> GrampsAOI (32Bit: GrampsAIO-3.2.5-4.exe, PATCH for pyexiv2)
> Win7, 64 Bit
> Python    2.7.1, 32 Bit
> GTK+      2.22.1
> pyGTK     2.22.0
> gobject   2.26.0
> cairo     1.8.10
> enchant   1.6.3
> pyexiv2-0.3.0   (patched)
> exiv2-0.21 for Windows
>
> ==>  all results the same as for pyexiv2-0.2.2 (see above)
> ==>  But pyexiv2-0.3.0 should be the right one for my opinion.
> Is there the need for a Python 2.7 adoption?
>
> GrampsAOI64 (GrampsAIO64-3.2.5-3.exe)
> No pyexiv included. I couldn't found exiv2 for Windows 64 Bit to try any
> patch
> ==>  Do we need for addons a special 64-Bit-Marker?
>
> I hope this will help to improve the very helpfull Gramplet.
> -Helge

OK i build x64 version and try it, gramplet failed to load due before
mentioned typo.
When that typo fixed gramlet do load but but there are again:

Warning: History: Exception occurred in callback function.
Traceback (most recent call last):
   File "C:\Program
Files\GrampsAIO64\share\gramps\gen\utils\callback.py", line 414, in emit
     fn(*args)
   File "C:\Documents and Settings\Administrator\Application
Data\gramps\gramps32\plugins\ImageMetada
taGramplet\ImageMetadataGramplet.py", line 222, in media_changed
     if self.plugin_image:
   File "C:\Program
Files\GrampsAIO64\lib\site-packages\pyexiv2\metadata.py", line 338, in
__len__
     return len( [ x for x in self ] )
   File "C:\Program
Files\GrampsAIO64\lib\site-packages\pyexiv2\metadata.py", line 335, in
__iter__
     return chain(self.exif_keys, self.iptc_keys, self.xmp_keys)
   File "C:\Program
Files\GrampsAIO64\lib\site-packages\pyexiv2\metadata.py", line 146, in
exif_keys
     self._keys['exif'] = self._image._exifKeys()
   File "C:\Program
Files\GrampsAIO64\lib\site-packages\pyexiv2\metadata.py", line 96, in _image
     raise IOError('Image metadata has not been read yet')
IOError: Image metadata has not been read yet

on configuration:

C:\Program Files\GrampsAIO64\bin>python
Python 2.7.1 (r271:86832, Nov 27 2010, 17:19:03) [MSC v.1500 64 bit
(AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
 >>> import pyexiv2
 >>> pyexiv2.version_info
(0, 3, 0)
 >>> pyexiv2.exiv2_version_info
(0, 21, 0)

--
Josip

------------------------------------------------------------------------------
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to
best implement a security strategy that keeps consumers' information secure
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
_______________________________________________
Gramps-windows mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-windows
Reply | Threaded
Open this post in threaded view
|

Re: ImageMetadataGramplet and Windows

Helge@Gramps
I just got svn 691 from trunk for addons:
ImagemetaDate Gramplet seems to be running without trouble now using trunk and I also see some very nice improvements:
+ No message box if a wrong file type was selected
+ No default text for the description field
Great!!