Closed (fixed)
Project:
DraggableViews
Version:
6.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
17 Feb 2009 at 22:16 UTC
Updated:
9 Mar 2009 at 10:50 UTC
Jump to comment: Most recent file
Comments
Comment #1
sevi commentedThis patch should display some (more or less) useful information for debugging.
Comment #2
junro commentedThe patch doesn't work for me, maybe it's normal and you need the draggableviews.inc.rej file.
I'm using Cygwin
patch draggalviews.inc < draggableviews.inc.test.patch
patching file draggableviews.inc
Hunk #1 FAILED at 1.
Hunk # FAILED at 694.
2 out of 2 hunks FAILED -- saving projects to file draggableviews.inc.rej
Here the draggableviews.inc.rej file:
***************
*** 1,5 ****
<?php
- // $Id: draggableviews.inc,v 1.7.2.11 2009/02/16 00:00:05 sevi Exp $
/**
* @file
--- 1,5 ----
<?php
+ // $Id: draggableviews.inc,v 1.7.2.7 2009/01/22 16:05:57 sevi Exp $
/**
* @file
***************
*** 694,699 ****
* the nodes array to number
*/
function _draggableviews_number_serially(&$info) {
// loop through all resulting nodes
$minimum_value = $info['order']['fields'][0]['handler']->get_minimum_value();
for ($i = 0; $i < count($info['view']->result); $i++) {
--- 694,701 ----
* the nodes array to number
*/
function _draggableviews_number_serially(&$info) {
+ drupal_set_message("
");
+ drupal_set_message("
");
// loop through all resulting nodes
$minimum_value = $info['order']['fields'][0]['handler']->get_minimum_value();
for ($i = 0; $i < count($info['view']->result); $i++) {
Comment #3
sevi commentedOk, I don't know why the patch doesn't work.
But I know why this bug occurs: It always occurs when
1) a view is beeing created (not yet saved) and
2) a saved view is beeing changed (adding/deleting fields).
..currently writing patch..
Comment #4
sevi commentedThe attached patch should solve this problem. Draggableviews structure will not be built/saved before the view has been saved. And when editing a view the current settings will be used instead of the saved settings, which also lead to this error.
I hope this patch will help to get rid of these ugly circumstances :)
So far, so good. But in the meanwhile I've to deal with another problem which came with #345647: Conflict between draggable views when using Panels - collision error: The theme registry has to be rebuilt each time a view has been saved because each view uses its own form_id (this makes it possible to differ between many different views on the same page). At the moment I don't know where to place the function
call drupal_rebuild_theme_registry();. For now I call it each time a view is being built (..very ugly :(). If you can't see any nodes you might have to refresh the page once (only within the current circumstance).greetings, sevi
Comment #5
sevi commentedOK, got it now. What I posted above about the theme_registry was a mistake. Views does this. Everything seems to work so far :)
Comment #6
junro commentedHello,
can't find file to patch at input line 88
see screenshot
Comment #7
junro commentedI can't understand why some draggable views work and others don't. It souldn't be the same for all views?
Comment #8
sevi commentedHm, maybe I should split them to separated files.
Anyway, the changes are committed and already for http download available.
Comment #9
sevi commentedDoesn't the new version work? Sure, all views should be bug-free, but maybe items_per_page can cause trouble.
I want to bring out a BETA-release in the next few days. So please provide me with bug-information. Let's say: On Monday it must work :)
greetings,
sevi
Comment #10
junro commentedok
Well, I just updated the last dev. version (the seconde one of today), and I've got this error:
Display "Page": Draggableviews: hierarchy field none could not be found (..afterwards removed from Fields section?). Check your settings
and I can't save the view.
I've got this message for all draggable views when I update the draggable style settings.
Comment #11
sevi commentedOk, what a stupid mistake.
The patch makes it better.
Comment #12
junro commentedok! It works! Thanks!
I put the status to Fixed, and I will open a new issue for the next ^^.
Comment #13
junro commentedHum I've got Fatal error: Maximum execution time of 30 seconds exceeded in ...., when I've got to much items to display I think.
With only 10 items, no problems.
Comment #14
sevi commentedexceeded in... where?
Comment #15
junro commentedin differents modules, each times, the module name change.
I tried again, It works.
I think this message was nothing to do with your module.
Comment #16
junro commentedTest: 10 drags:
1 Fatal error: Maximum execution time of 30 seconds exceeded in /home/pariscin/www/modules/user/user.module on line 21
2 GOOD
3 Fatal error: Maximum execution time of 30 seconds exceeded in /home/pariscin/www/sites/all/modules/pathauto/pathauto.inc on line 481
4 Fatal error: Maximum execution time of 30 seconds exceeded in /home/pariscin/www/sites/all/modules/pathauto/pathauto.inc on line 145
5 GOOD
6 GOOD
7 GOOD
8 GOOD
9 GOOD
10 GOOD
11 GOOD well it seems to work... no fatal error anymore... I don't know what could do that. Maybe my serveur settings or I don't know....
12 Fatal error: Maximum execution time of 30 seconds exceeded in /home/pariscin/www/sites/all/modules/pathauto/pathauto.inc on line 147
13 SURPRISE:
Please contact the server administrator, and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
Apache/2.0.59 (Unix) mod_ssl/2.0.59 OpenSSL/0.9.8g Server Port 80
14 Fatal error: Maximum execution time of 30 seconds exceeded in /home/pariscin/www/sites/all/modules/pathauto/pathauto.inc on line 147
15 Fatal error: Maximum execution time of 30 seconds exceeded in /home/pariscin/www/sites/all/modules/pathauto/pathauto.inc on line 452
Comment #17
junro commentedI recreated from scratch one of my 2 biggest draggable views and they seem to work fine. ^^
Comment #18
sevi commentedHmm,
I think I know why the "Maximum execution time" error occurs. Each time a view is broken all nodes have to be renumbered. So the entire view (all X rows) will be loaded and the save function will be called X times. Especially in case of CCK-fields this needs a lot of performance.
I believe the progress of renumbering can be done with a single SQL statement instead of covering each row separately (with big overhead).
I'll try to make a patch.
You still have these errors, right?
sevi
Comment #19
junro commentedI don't have the m"maximum execution time" errors anymore, I think this is because the draggable views is not broken anymore.
I will check this with the next broken structure.
Comment #20
sevi commented