欢迎各位兄弟 发布技术文章
这里的技术是共享的
Dec 7 08:34:30 crca drupal: http://www.crca.org.au|1260174870|boost|65.55.207.78|http://www.crca.org.au/Resources/WordOfSalvation/TheSevenTrumpets||0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_handler_filter_many_to_one::init() should be compatible with that of views_handler_filter::init() [file] => /home/crca-website/public_html/sites/all/modules/views/handlers/views_handler_filter_many_to_one.inc [line] => 0 Lookup Error Type Turn Off Error Checking
Regards,
NIgel
Comment | File | Size | Author |
---|---|---|---|
#38 | 6.5 KB | vijaycs85 | |
#18 | 928 bytes | keinstein | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch cck_0.diff. Unable to apply patch. See the log in the details link for more information. View | |||
#18 | 704 bytes | keinstein | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch date_handler_field_multiple.inc_.diff. Unable to apply patch. See the log in the details link for more information. View | |||
#13 | 14.3 KB | keinstein | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_1.diff. Unable to apply patch. See the log in the details link for more information. View | |||
#9 | 13.19 KB | dawehner | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views-653628_0.patch. Unable to apply patch. See the log in the details link for more information. View |
yes there is. But the dev version needs perhaps 6 or 12 hours to be build. Perhaps its not fixed in the latest dev version.
File | Size |
---|---|
3.69 KB | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch 653628-extra-ampersand.patch. Unable to apply patch. See the log in the details link for more information. View |
Ack, I got distracted after the commit and did not post the patch that I used here:
Status: | Fixed | » Active |
It looks to me like there are similar issues with some other code:
After that one is out of the way, i'm now seeing:
http://www.crca.org.au|1260266705|boost|67.195.112.126|http://www.crca.org.au/Resources/WordOfSalvation?page=10||0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_handler_filter_term_node_tid::value_validate() should be compatible with that of views_handler_filter::value_validate() [file] => /home/crca-website/public_html/sites/all/modules/views/modules/taxonomy/views_handler_filter_term_node_tid.inc [line] => 0 Lookup Error Type Turn Off Error Checking
and
http://www.crca.org.au|1260248779|boost|66.249.71.148|http://www.crca.org.au/AboutUs/WhoWeAre/Locations/Blaxland||0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_handler_filter::options_validate() should be compatible with that of views_handler::options_validate() [file] => /home/crca-website/public_html/sites/all/modules/views/handlers/views_handler_filter.inc [line] => 0 Lookup Error Type Turn Off Error Checking
Regards,
Nigel
Status: | Active | » Needs review |
Issue tags: | +alpha-2 blocker |
File | Size |
---|---|
2.46 KB | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views-653628.patch. Unable to apply patch. See the log in the details link for more information. View |
Yes, I found 2 more. Thanks for reporting.
Status: | Needs review | » Reviewed & tested by the community |
Thanks.
That seems to have gotten rid of the errors. Unfortunately I've now discovered another (unrelated) bug - will go see if anyone has reported it already.
Status: | Reviewed & tested by the community | » Active |
Hi again.
Got some more, I'm afraid...
Dec 11 02:19:07 crca drupal: http://www.crca.org.au|1260497947|boost|67.195.112.126|http://www.crca.org.au/category/Tags/resurrectionofChrist||0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_handler_filter::options_submit() should be compatible with that of views_handler::options_submit() [file] => /home/crca-website/public_html/sites/all/modules/views/handlers/views_handler_filter.inc [line] => 0 Lookup Error Type Turn Off Error Checking
Dec 11 02:22:11 crca drupal: http://www.crca.org.au|1260498131|boost|202.148.231.138|http://www.crca.org.au/|http://www.google.com.au/search?hl=en&source=hp&q=CRCA&meta=&aq=f&oq=|0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_plugin_style_default::options() should be compatible with that of views_object::options() [file] => /home/crca-website/public_html/sites/all/modules/views/plugins/views_plugin_style_default.inc [line] => 0 Lookup Error Type Turn Off Error Checking
Dec 11 02:22:11 crca drupal: http://www.crca.org.au|1260498131|boost|202.148.231.138|http://www.crca.org.au/|http://www.google.com.au/search?hl=en&source=hp&q=CRCA&meta=&aq=f&oq=|0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_handler_field_user::init() should be compatible with that of views_handler_field::init() [file] => /home/crca-website/public_html/sites/all/modules/views/modules/user/views_handler_field_user.inc [line] => 0 Lookup Error Type Turn Off Error Checking
Dec 11 02:25:51 crca drupal: http://www.crca.org.au|1260498351|boost|65.55.207.51|http://www.crca.org.au/Resources/WordOfSalvation/ByTitle?page=1||0||There are php errors on this page, preventing boost from caching. ERROR: Array [type] => 2048 [message] => Declaration of views_handler_filter_user_name::value_submit() should be compatible with that of views_handler_filter_in_operator::value_submit() [file] => /home/crca-website/public_html/sites/all/modules/views/modules/user/views_handler_filter_user_name.inc [line] => 0 Lookup Error Type Turn Off Error Checking
Regards,
Nigel
Status: | Active | » Needs review |
File | Size |
---|---|
13.19 KB | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views-653628_0.patch. Unable to apply patch. See the log in the details link for more information. View |
I greped and found some other ones.
all options_submit
all init
all value_submit
based on dagmars patch for views 3.x
Status: | Needs review | » Needs work |
Issue tags: | -alpha-2 blocker |
Committed to 3.x; however, this does not apply to 2.x. It probably should be rerolled for 2.x (and possilby 7.x-3.x?)
File | Size |
---|---|
14.3 KB | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_1.diff. Unable to apply patch. See the log in the details link for more information. View |
adaption of views-653628.patch to 6.x-2.10 I didn't search for additional places.
there is still an error message “Declaration of views_plugin_row::options_validate() should be compatible with that of views_plugin::options_validate() E:\esg\sites\all\modules\views\plugins\views_plugin_row.inc:135”, but I don't know whats wrong there.
I'm not sure, if I interpreted value_validate right. I've decided to use the form
function value_validate($form, &$form_state);
This triggers #774270 Can someone confirm that this interpretation is right?
Still getting some:
views_plugin_access_role::options_submit() should be compatible with that of views_plugin_access::options_submit()
views_handler_filter_user_name::value_submit() should be compatible with that of views_handler_filter_in_operator::value_submit()
(Unrelated, I assume) rules_data_type_string::get_default_input_form() should be compatible with that of rules_data_type::get_default_input_form()
File | Size |
---|---|
704 bytes | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch date_handler_field_multiple.inc_.diff. Unable to apply patch. See the log in the details link for more information. View | |
928 bytes | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch cck_0.diff. Unable to apply patch. See the log in the details link for more information. View | |
14.3 KB | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_2.diff. Unable to apply patch. See the log in the details link for more information. View |
I have another patch. This might be my last one on this issue. So don't rely on me, please.
There was one pre_render(&value) function somewhere in the views code. At a first glance I didn't know, how to avoid that. So I changed all occurrences of pre_render to be called by reference. This affects also the cck and the date module. I attach some prelimnary patches here. If you decide to follow my decition, they must be forwarded to the corresponding projects.
Status: | Needs review | » Needs work |
Please make a patch from the root of views. This is really hard to apply
I'm seeing these errors when using authcache, and I'm not clear on the status of this... Is there a 6.x release that includes the fixes? Or do I need to use dev?
Thanks,
Kristen
I have many similar problems right now, in 6x.3.x-dev
I suppose that options_validate() should not use the & but it was there except in two places so I re-instated it in my version. Works nice now. 8-)
function query($get_count = FALSE);
function options_submit($form, &$form_state);
function options_validate(&$form, &$form_state);
grep 'ion query' views/* views/*/*
views/handlers/views_handler_area.inc: function query($get_count = FALSE) { }
views/handlers/views_handler_area.inc: function query($get_count = FALSE) { /* No query to run */ }
views/handlers/views_handler_argument_formula.inc: function query($get_count = FALSE) {
views/handlers/views_handler_argument_group_by_numeric.inc: function query($group_by = FALSE) {
views/handlers/views_handler_argument.inc: function query($get_count = FALSE) {
views/handlers/views_handler_argument.inc: function query($get_count = FALSE) { /* No query to run */ }
views/handlers/views_handler_argument_many_to_one.inc: function query($get_count = FALSE) {
views/handlers/views_handler_argument_null.inc: function query($get_count = FALSE) {}
views/handlers/views_handler_argument_numeric.inc: function query($get_count = FALSE) {
views/handlers/views_handler_argument_string.inc: function query($get_count = FALSE) {
views/handlers/views_handler_field_counter.inc: function query($get_count = FALSE) {
views/handlers/views_handler_field_custom.inc: function query($get_count = FALSE) {
views/handlers/views_handler_field_group_by_numeric.inc: function query($get_count = FALSE) {
views/handlers/views_handler_field.inc: function query($get_count = FALSE) {
views/handlers/views_handler_field.inc: function query($get_count = FALSE) { /* No query to run */ }
views/handlers/views_handler_field_math.inc: function query($get_count = FALSE) { }
views/handlers/views_handler_filter_boolean_operator.inc: function query($get_count = FALSE) {
views/handlers/views_handler_filter_boolean_operator_string.inc: function query($get_count = FALSE) {
views/handlers/views_handler_filter_group_by_numeric.inc: function query($get_count = FALSE) {
views/handlers/views_handler_filter.inc: function query($get_count = FALSE) {
views/handlers/views_handler_filter.inc: function query($get_count = FALSE) { /* No query to run */ }
views/handlers/views_handler_filter_in_operator.inc: function query($get_count = FALSE) {
views/handlers/views_handler_filter_numeric.inc: function query($get_count = FALSE) {
views/handlers/views_handler_filter_string.inc: function query($get_count = FALSE) {
views/handlers/views_handler_relationship.inc: function query($get_count = FALSE) {
views/handlers/views_handler_relationship.inc: function query($get_count = FALSE) { /* No query to run */ }
views/handlers/views_handler_sort_date.inc: function query($get_count = FALSE) {
views/handlers/views_handler_sort_formula.inc: function query($get_count = FALSE) {
views/handlers/views_handler_sort_group_by_numeric.inc: function query($get_count = FALSE) {
views/handlers/views_handler_sort.inc: function query($get_count = FALSE) {
views/handlers/views_handler_sort.inc: function query($get_count = FALSE) { /* No query to run */ }
views/handlers/views_handler_sort_menu_hierarchy.inc: function query($get_count = FALSE) {
views/handlers/views_handler_sort_random.inc: function query($get_count = FALSE) {
views/includes/handlers.inc: function query($group_by = FALSE) { }
views/includes/plugins.inc: function query($get_count = FALSE) { }
views/plugins/views_plugin_display.inc: function query($get_count = FALSE) { }
views/plugins/views_plugin_exposed_form.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_exposed_form_input_required.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_pager_full.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_pager.inc: function query($get_count = FALSE) { }
views/plugins/views_plugin_pager_none.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_pager_some.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_query_default.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_query.inc: function query($get_count = FALSE) { }
views/plugins/views_plugin_row.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_style.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_style_summary.inc: function query($get_count = FALSE) {
views/plugins/views_plugin_style_summary_jump_menu.inc: function query($get_count = FALSE) {
grep 'ion options_validate' views/* views/*/*
views/handlers/views_handler_argument.inc: function options_validate(&$form, &$form_state) {
views/handlers/views_handler_field_serialized.inc: function options_validate(&$form, &$form_state) {
views/handlers/views_handler_filter_date.inc: function options_validate(&$form, &$form_state) {
views/handlers/views_handler_filter.inc: function options_validate(&$form, &$form_state) {
views/handlers/views_handler_sort.inc: function options_validate(&$form, &$form_state) {
views/includes/handlers.inc: function options_validate(&$form, &$form_state) { }
views/includes/plugins.inc: function options_validate(&$form, &$form_state) { }
views/plugins/views_plugin_access.inc: function options_validate(&$form, &$form_state) { }
views/plugins/views_plugin_access_role.inc: function options_validate(&$form, &$form_state) {
views/plugins/views_plugin_argument_default.inc: function options_validate(&$form, &$form_state) { }
views/plugins/views_plugin_argument_validate.inc: function options_validate(&$form, &$form_state) { }
views/plugins/views_plugin_display.inc: function options_validate(&$form, &$form_state) {
views/plugins/views_plugin_display_page.inc: function options_validate(&$form, &$form_state) {
views/plugins/views_plugin_pager_full.inc: function options_validate(&$form, &$form_state) {
views/plugins/views_plugin_pager.inc: function options_validate(&$form, &$form_state) { }
views/plugins/views_plugin_query.inc: function options_validate(&$form, &$form_state) { }
views/plugins/views_plugin_row.inc: function options_validate(&$form, &$form_state) { }
grep options_submit views/* views/*/*
views/handlers/views_handler_area_text.inc: function options_submit($form, &$form_state) {
views/handlers/views_handler_area_text.inc: parent::options_submit($form, $form_state);
views/handlers/views_handler_argument.inc: function options_submit($form, &$form_state) {
views/handlers/views_handler_argument.inc: $plugin->options_submit($form['argument_default'][$default_id], $form_state, $options);
views/handlers/views_handler_argument.inc: $plugin->options_submit($form['argument_validate'][$validate_id], $form_state, $options);
views/handlers/views_handler_filter.inc: function options_submit($form, &$form_state) {
views/handlers/views_handler_sort.inc: function options_submit($form, &$form_state) {
views/includes/admin.inc: $display->handler->options_submit($form, $form_state);
views/includes/admin.inc: $display->handler->options_submit($form, $form_state);
views/includes/admin.inc: $form_state['handler']->options_submit($form['options'], $form_state);
views/includes/admin.inc: $form_state['handler']->extra_options_submit($form['options'], $form_state);
views/includes/admin.inc: $form_state['handler']->options_submit($form['options'], $form_state);
views/includes/admin.inc: $form_state['handler']->options_submit($form['style_options'], $form_state);
views/includes/handlers.inc: function options_submit($form, &$form_state) { }
views/includes/handlers.inc: function extra_options_submit($form, &$form_state) { }
views/includes/plugins.inc: function options_submit($form, &$form_state) { }
views/plugins/views_plugin_access.inc: function options_submit($form, &$form_state) { }
views/plugins/views_plugin_access_role.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_argument_default.inc: function options_submit($form, &$form_state) { }
views/plugins/views_plugin_argument_validate.inc: function options_submit(&$form, &$form_state) { }
views/plugins/views_plugin_display_attachment.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_display_attachment.inc: parent::options_submit($form, $form_state);
views/plugins/views_plugin_display_block.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_display_block.inc: parent::options_submit($form, $form_state);
views/plugins/views_plugin_display_feed.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_display_feed.inc: parent::options_submit($form, $form_state);
views/plugins/views_plugin_display.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_display.inc: $plugin->options_submit($form['access_options'], $form_state);
views/plugins/views_plugin_display.inc: $plugin->options_submit($form['cache_options'], $form_state);
views/plugins/views_plugin_display.inc: $plugin->options_submit($form['query']['options'], $form_state);
views/plugins/views_plugin_display.inc: $plugin->options_submit($form[$section], $form_state);
views/plugins/views_plugin_display.inc: $plugin->options_submit($form['exposed_form_options'], $form_state);
views/plugins/views_plugin_display.inc: $plugin->options_submit($form['pager_options'], $form_state);
views/plugins/views_plugin_display_page.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_display_page.inc: parent::options_submit($form, $form_state);
views/plugins/views_plugin_exposed_form_input_required.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_exposed_form_input_required.inc: parent::options_submit($form, $form_state);
views/plugins/views_plugin_pager.inc: function options_submit($form, &$form_state) { }
views/plugins/views_plugin_query.inc: function options_submit($form, &$form_state) { }
views/plugins/views_plugin_row_fields.inc: function options_submit($form, &$form_state) {
views/plugins/views_plugin_row.inc: function options_submit($form, &$form_state) { }
File | Size |
---|---|
22.69 KB | |
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views-3.x-incompatible_signature-6.x.patch. Unable to apply patch. See the log in the details link for more information. View |
Just in case, I'm attaching a 3.x-dev patch.
Thank you.
Alexis Wilke
P.S. the patch below is not 100% complete, but that's a quite good start already.
This is still not resolved... and I have not gotten any good answer on whether it should be one way or the other. Maybe no one knows... 8-)
Anyway, there is me looking at the function query($get_count = FALSE) that remains. There are several still! (Most lost their parameters and for the few that did not yet lose their parameter they generally don't need it.)
So... function compile_fields() from views/plugins/views_plugin_query_default.inc around line 920:
function compile_fields($fields_array) {
$fields = $distinct = array();
$non_aggregates = array();
foreach ($fields_array as $field) {
$string = '';
if (!empty($field['table'])) {
$string .= $field['table'] . '.';
}
$string .= $field['field'];
// store for use with non-aggregates below
$fieldname = (!empty($field['alias']) ? $field['alias'] : $string);
if (!empty($field['distinct'])) {
$string = "DISTINCT($string)";
}
if (!empty($field['count'])) {
// Retained for compatibility
$field['function'] = 'count';
}
if (!empty($field['function'])) {
$info = $this->get_aggregation_info();
if (!empty($info[$field['function']]['method']) && function_exists($info[$field['function']]['method'])) {
$string = $info[$field['function']]['method']($field['function'], $string);
}
$this->has_aggregate = TRUE;
}
elseif ($this->distinct && !in_array($fieldname, $this->groupby)) {
$string = $GLOBALS['db_type'] == 'pgsql' ? "FIRST($string)" : $string;
}
elseif (empty($field['aggregate'])) {
$non_aggregates[] = $fieldname;
}
if ($field['alias']) {
$string .= " AS $field[alias]";
}
if (!empty($field['distinct']) && empty($field['function'])) {
$distinct[] = $string;
}
else {
$fields[] = $string;
}
if (!empty($get_count_optimized)) {
// We only want the first field in this case.
break;
}
}
return array(
$distinct,
$fields,
$non_aggregates,
);
}
The if (!empty($get_count_optimized))
(last if() in the function) checks a function that's not defined.
Then the following function is a query($get_count = FALSE) which actually makes use of the $get_count variable which I would imagine will always be false since no other query() function has that parameter (and will break the whole thing since the base class defines query() without parameters.)
Note that the compute_fields() is probably trying to use $this->get_count_optimized and thus the query() function should too, methink.
Shall I continue?
Version: | 6.x-2.8 | » 6.x-2.16 |
Status: | Needs work | » Needs review |
File | Size |
---|---|
6.04 KB | |
PASSED: [[SimpleTest]]: [MySQL] 0 pass(es). View |
A little sad to be patching 2.16, but came across these warnings when doing a PHP 5.4 upgrade on an old site.
I've gone through the patch from #13 and manually applied what is outstanding from the latest release. This should apply cleanly against 2.16, or I can re-roll for dev if needed. Don't know if this is likely to be committed given what has moved on, but the patch file might be useful for someone else...
Issue summary: | View changes | |
Status: | Needs review | » Needs work |
Patch applies fine, but missing two files which require similar changes
views_handler_filter.inc
views_handler_filter_date.inc
Seeing this in 7.26-1 when I activate the Calendar module.
Strict warning: Declaration of views_handler_filter_user_relationships_type::value_submit() should be compatible with views_handler_filter_in_operator::value_submit($form, &$form_state) in _registry_check_code() (line 3161 of /usr/share/drupal7/includes/bootstrap.inc).
Version: | 6.x-2.16 | » 6.x-2.x-dev |
Status: | Needs work | » Needs review |
Issue tags: | +php54 |
File | Size |
---|---|
6.04 KB | |
PASSED: [[SimpleTest]]: [MySQL] 0 pass(es). View |
Re-rolled the patch in #28 to add an ocurrance in views_handler_filter.inc (thanks @ajayg). I can't see any problems with views_handler_filter_date.inc
@-Shaman- - views will run on new versions of PHP, there are just a few patches that need applying. We're successfully running views on PHP 5.5 with this patch and a few others applied in our build process (using drush mask to make adding patches easy)
Status: | Needs review | » Needs work |
strict warning: Declaration of views_plugin_row::options_validate() should be compatible with views_plugin::options_validate($form, &$form_state) in sites/all/modules/views/plugins/views_plugin_row.inc on line 134.
strict warning: Declaration of views_plugin_row::options_submit() should be compatible with views_plugin::options_submit($form, &$form_state) in sites/all/modules/views/plugins/views_plugin_row.inc on line 134.
I applied the patch in #32 to the newest version of views-6.x-2.x-dev; without the patch, the newer version results in no errors on my sites, but with the patch, there's tons of this sort of error. Does #32 actually regress the work done in the most recent dev version of the module?
Just adding a reference to the other issue that may be related, #893128: Fix E_STRICT notices - method declaration compatibility with init(), pre_render(), _validate() and _submit() with PHP 5.4.x
Status: | Needs work | » Closed (duplicate) |
Issue tags: | +PHP 5.4 |
Marking this as duplicate of #2411093: PHP strict warnings: Declaration of ... should be compatible with ..., as this issue initially was abut the init()-functions which seems that it got fixed in views 6.x-2.x. Looking at the patches seems that what is left is the PHP strict warnings problem.