Zenphoto 1.1 Bug Hunt

Hello ZenPhoto fans!

We have been working hard to bring you the first update to ZenPhoto in half a year! What this means is that version 1.1 will contain a TON of new features that have the potential for bugs. Anyone willing to find any bugs or just try out the new version you can do so by downloading the nightly build here: http://www.zenphoto.org/files/nightly (you must run upgrade.php as there have been many database changes)

We hope to release this new version before the end of the month. Please submit any and all bugs you find to the trac site: http://www.zenphoto.org/trac/newticket

Or view the running issue list here:
http://www.zenphoto.org/trac/report/3

Thank you for your help!
«134

Comments

  • there was a change lost in revision 507 that made ticket 116 broken. If the albums foldername was changed, it was not possible to browse inside the albums.

    I have added a patch to roll it back (116).
  • Thanks jordi-kun, its been implemented again into SVN 541
  • jordi-kun:

    In the future, please also reopen the ticket so that we will notice that it needs attention.

    I may figure it out, but in case I don't, what file does this patch?

    Got it: class-album.php

    Did you ever get zenPhoto to access an album outside of the zenPhoto folders?
  • @sbillard: yes, tweaking the getAlbumFolder function. I haven't published it because it is not generic, either outside or inside, haven't figured out how to mix the 2 situations.

    ` //return $root . zp_conf('album_folder');

    //albums outside htdocs

    if ($root=SERVERPATH) {

    return zp_conf('album_folder');

    }

    else {

    return $root . zp_conf('album_folder');

    }`

    apache has to be configured with an alias if it is outside htdocs
  • Keep us posted. I presume you put the fully qualified path in the $_zp_conf_vars array? Probably could test that to see if it is == to the ALBUMFOLDER define to see if it is inside the zp folders. Or test it to see if there is a path present. `count(explode('/', zp_conf('album_folder')) > 1` should do it.
  • I don't quite get you, sorry. OK, here is my whole scenario.

    `localhost/zenphoto/` (which is inside the apache's "htdocs" folder)
    `localhost/fotos/` (it is located in another hard drive. i had to set an alias in the apache's configuration to be accessible, `Alias /Fotos "D:/fotos"`)

    therefore, in zp-config i have the ALBUMFOLDER overriden to `/fotos/`. with the current SVN, the getAlbumFolder is appending the album folder to the zenphoto's root. with the patch y did, it gets the correct path (regardless of where zenphoto is located).

    So, how to know if ALBUMFOLDER (set as `/fotos/`), the user means inside zenphoto or outside htdocs? Here is where i'm stuck. Of course another parameter would do though.
  • What I was thinking is that $_zp_conf_vars['album_folder'] would have:

    `/fotos/` for when the folder is within the zen folders,
    `/localhost/fotos/` for when the folder is outside the zen folders.

    Then we check to see if there is a folder path in front of the folder name.
    `if ($root=SERVERPATH) {

    if (count(explode('/', zp_conf('album_folder'))> 2) { // there is a full path, must be outside of zen folders

    return zp_conf('album_folder');

    } else {

    return $root . zp_conf('album_folder');

    }

    } else {

    return $root . zp_conf('album_folder');

    }`

    So, if the name has any directory names we treat it as outside of zen, if not it is inside of zen.

    You'll have to check the count, not sure if the explode will create an empty item for the trailing slash.
  • just starting off. From plane ol'e 1.0.8 to this community build, after running upgrade.php then clicking on view gallery I get a MYSQL error

    Zenphoto Error

    MySQL Query ( INSERT INTO `204svnzp_options` (`name`, `value`, `description`, `bool`) VALUES ('spam_filter', 'none', '', ''); ) Failed. Error: Out of range value adjusted for column 'bool' at row 1

    Then if I fix this using phpmyadmin, the next error I get is

    Zenphoto Error

    MySQL Query ( INSERT INTO `204svnzp_options` (`name`, `value`, `description`, `bool`) VALUES ('Theme_colors', 'light', 'Set the colors of the theme (green, blue, earth)', ''); ) Failed. Error: Out of range value adjusted for column 'bool' at row 1

    Either way.. I can still get past both of those..

    I can get to the options page and I chose spam filter: akismet. I was click happy and hit save without entering in my API key. Now my options page stops at Spam Filter and I cant even enter it and the admin page says

    Zenphoto Error

    MySQL Query ( INSERT INTO `204svnzp_options` (`name`, `value`, `description`, `bool`) VALUES ('Akismet_key', '', 'Proper operation requires an Akismet key obtained by signing up for a Wordpress.com account.', ''); ) Failed. Error: Out of range value adjusted for column 'bool' at row 1

    Ill keep playin with it and see if I can find any more.
  • as well. I actually dont see a spot to add my askimet API key anywhere. So I set spam filtering to none and unchecked moderate and I now receive this when I comment

    Zenphoto Error

    MySQL Query ( INSERT INTO `204svnzp_comments` (imageid, name, email, website, comment, inmoderation, date) VALUES ('285', 'danfrei', 'na@na.com', 'http://www.chilifrei.net', 'Love the velvet', '', NOW()) ) Failed. Error: Out of range value adjusted for column 'inmoderation' at row 1
  • Found the problem with the options.

    Craig has been working on a plugin in for Aksimet, which should be up on the SVN as soon as Mark sees the e-mail. Once it is up, we would appreciate your testing!

    When the options work, there is an option for the key. I suggest you delete the rows from your options table when you get the new release with the fix.
  • I hate to be this person....

    I thought there may have been some stuff with upgrades.. so I did a full download and fresh install. I caught something.. during the install it says
    zenphoto setup
    database connected

    We're all set to create the database tables: `zpc_albums`, `zpc_images`, and `zpc_comments`.

    Go!

    I press go and it says complete. I click view gallery and it gives me

    Zenphoto Error

    MySQL Query ( INSERT INTO `zpc_options` (`name`, `value`, `description`, `bool`) VALUES ('spam_filter', 'none', '', ''); ) Failed. Error: Out of range value adjusted for column 'bool' at row 1

    Now according to the setup page, it never created zpc_options. Now.. it really did create the options table.. so the text just has to be updated.. but I still do get the error on the very first page after the install.

    Since I am having a ton of SQL errors.. this info might be helpful.
    MySQL 5.0.20-nt
    IIS 6.0
    PHP 5.1.2
  • And another one... After above didnt work.. I went to zen/admin.php and set spam filter to none and hit save up at the admin login information since the rest of the options page didnt show up. That got rid of my spam filter error but then brought up

    Zenphoto Error

    MySQL Query ( INSERT INTO `zpc_options` (`name`, `value`, `description`, `bool`) VALUES ('current_theme', 'default', 'Holds the current theme', ''); ) Failed. Error: Out of range value adjusted for column 'bool' at row 1

    Since this was a theme problem, i clicked on the theme tab to choose my theme.. but i receive the same error and the themes dont show up.
  • You are too quick at reading the posts. I have edited my post. Your mySql is complaining about "true" and "false" not being in range. Mine didn't so that's why I never noticed this.
  • By the way, when I run upgrade, it lists all four tables. This is from line 112 of options.php. So maybe there is still a problem with the files you uploaded.
  • Finally, it has been ages since the comment for effervescence_simpleviewer had that description. There is definately something wrong with what you have got for the SVN.
  • What version Mysql are you running?

    upgrade.php does say all 4.. setup.php does not

    and I am not following where effervesence_simpleviewer comes into play.
  • MySql 5.0.45.

    Effervescence_simpleviewer is where the setOptionsDefault comes from. That is the code that eventually gets the DB error setting "Theme_colors".
  • OK, fount that one, too. Someone copied the Effervescence_simpleviewer code into the default theme without changing it.
  • ok.. you had me through a loop there.

    Also. .. i just realized I was still pulling from the community branch and I was supposed to pull from Nightly Builds..

    Unfortunately all still a no go.. I am getting the same errors. If I go down to the testing theme I can post comments.. but heres a kicker.. the Image Info link.. it works on firefox and not on IE.. Damn IE
  • The steril theme does the same thing the default theme was doing too

    MySQL Query ( INSERT INTO `zpc_options` (`name`, `value`, `description`, `bool`) VALUES ('Theme_colors', 'light', 'Set the colors of the theme', ''); ) Failed. Error: Out of range value adjusted for column 'bool' at row 1
  • They are all going to do it until the fix is up.
  • @sbillard: i tried another approach. look for the zen-logo.jpg that has to be in the album folder. If it is found outside htdocs, it behaves as an ousider folder. if not, normal behaviour. I haven't tried thoroughly yet.

    `function getAlbumFolder($root=SERVERPATH) {

    global $_zp_conf_vars;

    if (!array_key_exists('album_folder', $_zp_conf_vars)) {

    $_zp_conf_vars['album_folder'] = ALBUMFOLDER;

    }

    if (file_exists(zp_conf('album_folder')."/zen-logo.jpg")) {

    //outside htdocs

    return zp_conf('album_folder');

    }

    else {

    return $root . zp_conf('album_folder');

    }

    }`
  • That is dangerous, because that file is put into the album folder as part of the zp initialization. So, if you change the album folder, presumably it will be put wherever you put the album folder.

    Do you see a problem with looking at the number of folder names in the path?
  • indeed, i didn't realize that, it would be impossible to change the albums folder.
    the thing is that ALBUMSFOLDER is defined as `/fotos/` which represents at the root of the server (http://localhost/fotos/), not as `/localhost/fotos/`.

    i went for the easy way, define a parameter for absolute or relative path:
    `define('ABSOLUTE_ALBUMFOLDER', false);`
    (of course, overridden in zp-config.php to true)

    `function getAlbumFolder($root=SERVERPATH) {

    global $_zp_conf_vars;

    if (!array_key_exists('album_folder', $_zp_conf_vars)) {

    $_zp_conf_vars['album_folder'] = ALBUMFOLDER;

    }

    if (ABSOLUTE_ALBUMFOLDER) {

    return zp_conf('album_folder');

    }

    else {

    return $root . zp_conf('album_folder');

    }

    }`
  • on the new nightly build.. it is lookin much better. upgrades went fine and playin around was going fine.. Only 1 thing to report now

    Comments set to allow
    Moderate is NOT checked
    Spam filter set to none

    I get this error

    Zenphoto Error

    MySQL Query ( INSERT INTO `zpc_comments` (imageid, name, email, website, comment, inmoderation, date) VALUES ('20', 'danfrei', 'editedout@editedout.com', 'http://www.chilifrei.net', 'DROPPED!!!', '', NOW()) ) Failed. Error: Out of range value adjusted for column 'inmoderation' at row 1

    This is after a clean upgrade from 1.0.8.2 so looks like maybe a default option not getting put in the DB problem like some of the other things.

    Otherwise lookin great.. Ill keep pluggin away at it.
  • Also with comments.. If I choose akismet and put in my key. No comments get posted. No matter how hard I try to not type something spam like it always flags me.
    Once I go back in and choose the forgiving option. my comments go into moderation.
    And unless I am missing something when I uncheck them, I would assume they would no longer be flagged as in moderation. But all I can do after I uncheck them is press the Delete selected comments button. And if i press it (with the moderation checkbox unchecked)... they go right back to being checked. I cannot save it unchecked. Am I missing something there?
  • The uncheck on moderation is not implemented yet.

    The sql error is another case of your mySql complaining about a value of false. I'll get that fixed in the next update. Keep trying things since I don't see those errors.

    Craig (thinkdreams) did the Akismet plugin. Hope he is monitoring this thread and will look into the detection.
  • Jordi-kun:

    Sounds reasonable. If you are comfortable that it all works, go ahead and release it to the SVN.
  • dwn Member
    hello,
    i have right now upgraded to comunity build and a can say that it is great :) Until now i have found one error... it is in probably in sorting of images.

    Take a look here:
    http://gallery.harcek.info/akcie/pohoda2007/
    Sorting of this album is to "filename" but it looks like it is reversed some way. Image which should be first is first on second page. Another one is that two images are shown two times in this album...

    I know that i'm not using themes which is modified for this new build but i have tested it with default theme (dark) and it was the same.

    Otherwise good work, and i hope 1.1 will be here soon:)

    Best regards

    p.s.: i was thinking about creating an issue in trac, but i'm not 100% sure if it isn't just error in theme which i am using. so take a look at it please and let me know if i have to put it in trac.
  • @sbillard
    all attempts to change album foldername and path went ok. I have added the patch in ticket 101
Sign In or Register to comment.