Closed (fixed)
Project:
Drupal core
Version:
7.x-dev
Component:
system.module
Priority:
Critical
Category:
Bug report
Assigned:
Reporter:
Created:
5 Nov 2008 at 22:00 UTC
Updated:
18 Jan 2009 at 12:10 UTC
Jump to comment: Most recent file
Comments
Comment #1
drewish commentedGot the tests working and was able to get the status matching working correctly.
Comment #2
drewish commentedmaybe that'll lure in some reviews ;)
Comment #3
grendzy commentedThis looks pretty solid. All the relevant tests pass. I did remove this line:
+file_put_contents('/Users/amorton/Sites/dh/sites/default/files/drupal.log', print_r($row,1), FILE_APPEND);Comment #4
drewish commentedgood catch on that... also noticed that i'd accidentally rolled #329226: Store file_test.module's values in variables rather than globals in with it. so here's your patch minus #329226.
Comment #5
grendzy commentedAh, much clearer now. The unit tests still look good.
Comment #6
Anonymous (not verified) commentedThe last submitted patch failed testing.
Comment #7
grendzy commentedWeird, the bot tested the wrong patch. #4 is the latest.
Comment #8
Anonymous (not verified) commentedThe last submitted patch failed testing.
Comment #9
drewish commentedhere's a re-roll.
Comment #10
dries commentedIn the code comments,
that'sshould bethat is, not?Do these binary operations work on PostgreSQL and SQLite?
Comment #11
drewish commentedIt's a standard ANSI SQL operator so it should work. installed sqlite and started to run all the system test but sweet jesus is it slow so just ran the cron tests and everything looked good.
I thought "that's" was a valid contraction of "that is" but i'm not looking to hold the patch up over an English quiz ;)
Comment #13
drewish commentedPatch is failing because it was accidentally applied as part of #314870: UNSTABLE-4 blocker: Add api.php for every core module.
Comment #14
damien tournoud commentedBreaks badly on PostgreSQL, with message:
Back to the drawing board :)
Comment #15
jhedstromThis PDOException is breaking the postgresql installer. After commenting out the query in system_cron, the install works fine.
I found a similar issue, that was resolved with some PDO config magic:
http://bugs.php.net/bug.php?id=36652
Comment #16
jhedstromI traced this down to the fact that the timestamp column is of type int_unsigned, and along the way filed this issue: #339588: Column type of int_unsigned causing pdoexception.
Comment #17
dave reidShould the bitwise operator be removed? I didn't think that was standard, acceptable thing to do. Plus the following just look weird...
WHERE status & :permanent != :permanent AND timestamp < :timestamp', array(':permanent' => FILE_STATUS_PERMANENT, ...Comment #18
drewish commentedDave Reid, i think the problem was the way we did data types on pgsql. as far as i can tell pgsql supports them when you've got the right data types: http://www.postgresql.org/docs/7.4/static/functions-math.html
Comment #19
drewish commented#341910: file_space_used() not checking properly checking bitmapped status value (adds unit tests) was running into the same situation. the patch on #339588: Column type of int_unsigned causing pdoexception gets this passing and i'd guess addresses #341910 as well.
Comment #20
drewish commentedpostponing until #339588: Column type of int_unsigned causing pdoexception get committed.
Comment #21
drewish commentedComment #23
drewish commentedokay that's freaking annoying... at least re-test it before slamming the status back...
Comment #24
dries commentedCommitted to CVS HEAD. Thanks, drewish.
Comment #25
damien tournoud commentedThe issue was that it is invalid to use both times the same placeholder:
Here you are trying to use ":permanent" two times. This will fail when using the C prepare statement on PostgreSQL, and even of some PHP/MySQL configurations as reported in #352956: PDOException on install.
Please review the fix there.