Square Thumbnails | No worky anymore [SOLVED]

ClimbingMonkey

Joined: 2005-03-18
Posts: 62
Posted: Tue, 2005-06-14 03:57

<TYPE YOUR MESSAGE HERE, ENTER SYSTEM DETAILS BELOW>
<Please check the G2 FAQ (sticky topic in this forum) before posting!>
----

Gallery URL (optional): In my user info
Gallery version: Latest CVS (Core = 0.9.24)
Webserver (with version): IIS 6
Datatabase (with version): MySQL 4.1.10
PHP version (eg 4.2.1): 4.3.10
phpinfo URL (optional):
Graphics Toolkit(s): GD, ffmpeg
Operating system: 2003 Server
Web browser/version: FF /IE
G1 version (for migration bugs):

Been running nightly for 6 months now with now issues at all. I update on a weekly basis or so and just updated both my G2 installs. I found that with this latest release square thumbnail support wont work with my php bundled GD.

When I try to activate the module is says "This module requires you to have at least one graphics toolkit active in order for it to operate properly. Please return to the Modules page and activate a graphics toolkit."

Since it has worked without a hitch for like forever, and I have never touched GD I'm just curious if there is an issue with the latest codebase or you can no longer use gd for square thumbs (which would be a huge bummer...) Oh and yes GD is installed and activated! :)

-Marc

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Tue, 2005-06-14 05:22

could you deactive AND uninstall the GD module, then install and ativate it again? and also click the test button there.
then try to reactivate the square thumbs module.

 
ClimbingMonkey

Joined: 2005-03-18
Posts: 62
Posted: Wed, 2005-06-15 01:14

Nope same result. I uninstalled everything except core and rearrange, cleaned up all cache dirs, optimized the DB, then installed gd. It activated with no problems and passes the tests.

GD version Required Pass/fail
2.0.28 (bundled) 2.0 Passed

When I try to activate square thumbs, it give me the same result. Anything else it could be?

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Wed, 2005-06-15 09:48

did you also try it with GD disabled? maybe another toolkit, e.g. netpbm or imagemagick.
you can get netpbm from http://sourceforge.net/project/showfiles.php?group_id=7130&package_id=14464

get the right netpbm binaries for the operating system of the server. see http://codex.gallery2.org for more instructions (Gallery 1) on how to install netpbm.

 
ClimbingMonkey

Joined: 2005-03-18
Posts: 62
Posted: Sun, 2005-06-19 09:52

Yep, and I updated G2, I've been through every combo that is possible. Is there debug info I can use to troubleshoot? It has been great for months and months and all the sudden (with NO system changes other than an updated G2) poof... DENIED... :)

 
ClimbingMonkey

Joined: 2005-03-18
Posts: 62
Posted: Sun, 2005-06-19 10:08

So after a little digging in CVS I diffed a few files that were changed on the 12th. Here's my guess. the module.inc file is the only one with changes.. Here's a quick code snippet from line 118

list ($ret, $toolkit) = GalleryCoreApi::getToolkitByOperation('image/x-portable-pixmap',
'convert-to-image/jpeg');
if ($ret->isError()) {
return array($ret->wrap(__FILE__, __LINE__), null);
}

As far as I know (and what gallery tells me) GD can't process x-portable-pixmap's.

So with this change you essentially make square thumbs dependant on a toolkit that can process x-portable-pixmap's which means GD is screwed.

How did I do? Thoughts?

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sun, 2005-06-19 12:25

some of the square thumb tests don't even run on my unit tests run.
see:
http://gallery.pastebin.com/301762

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sun, 2005-06-19 16:34

ClimbingMonkey, if you try to activate the squarethumb module in site admin -> modules, it should say you that it can't because there's no image toolkit supporting it. (see modules/squarethumb/module.inc::activate())

but i too don't know why this operation is required for the squarethumb module. mindless will know more.

 
ClimbingMonkey

Joined: 2005-03-18
Posts: 62
Posted: Mon, 2005-06-20 06:24

Yep that is EXACTALLY what is says.

Cool, at least I know I'm not drunk or something. lol... I'll wait till mindless chimes in and in the meantime, I'll revert that module back to to the previous revision. :)

Thanks for all your help valiant, it is much appreciated. BTW we are making great progress on our Worpress/G2 integration and I believe ozgreg beat me to the punch on our thoughts about the direction of the G2 template/themes. I have another question for you as well, but I'll PM sometime later this week on that. :)

-Marc

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Mon, 2005-06-20 07:06

yes, squarethumbs now supports fit-into-square mode in addition to the original crop-to-square. it is this new mode that requires the ability to convert ppm to jpeg. i suppose we could allow the module to activate and use only crop mode if this operation isn't supported. surprising that gd doesn't support a simple format like ppm.

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Mon, 2005-06-20 15:33

I filed this bug.

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Mon, 2005-06-20 16:04

..and fixed it. Update from cvs later today or get tomorrow's nightly snapshot and squarethumb should activate with only Gd toolkit.. it will not offer fit-to-square mode in this case.

 
ClimbingMonkey

Joined: 2005-03-18
Posts: 62
Posted: Sun, 2005-06-26 17:33

Pulled it down and it works like a charm... :) Thanks mindless!