Lots o' notices

webchick - July 1, 2008 - 15:02
Project:Validation API
Version:6.x-1.0-alpha1
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

If you're developing on a DRUPAL-6 CVS checkout or a 6.x-1.x-dev tarball that has E_ALL reporting on (and you totally should! :)), there are lots of notices as you click around and use the site. For example:

admin/build/validation_api/fields/add?form_id=blog_node_form&form_field=title:
notice: Undefined index: message in /Applications/MAMP/htdocs/6x/sites/all/modules/validation_api/validation_api.admin.inc on line 279.

admin/build/validation_api/validators/import:
notice: Undefined variable: defaults in /Applications/MAMP/htdocs/6x/sites/all/modules/validation_api/validation_api.admin.inc on line 429.

admin/build/validation_api/fields/add?form_id=validation_api_admin_import_form&form_field=code:
* notice: Undefined variable: options in /Applications/MAMP/htdocs/6x/sites/all/modules/validation_api/validation_api.admin.inc on line 278.
* notice: Undefined index: message in /Applications/MAMP/htdocs/6x/sites/all/modules/validation_api/validation_api.admin.inc on line 279.
* warning: Invalid argument supplied for foreach() in /Applications/MAMP/htdocs/6x/includes/form.inc on line 1405.

This makes it a bit distracting to review because regular error messages get mixed in with notices.

#1

TapocoL - July 12, 2008 - 17:24
Version:» 6.x-1.0-alpha1
Status:active» active (needs more info)

Is this only on the development snapshots? I set error_reporting to E_ALL in php.ini, restarted apache, and was not able to recreate your notices. I have also made a couple commits since then. So, there could have been fixes in there. Let me know if you continue you have these notices.

#2

z allen - July 15, 2008 - 18:50

I'm getting this too, brand new install. It just happened the first time I entered the module admin. area.

#3

TapocoL - July 15, 2008 - 19:03

Can you give me the specs on what you used? (Validation API version, Drupal version, PHP version, Database, Server)

#4

webchick - July 17, 2008 - 16:12
Status:active (needs more info)» active

Any stable release of Drupal (6.2, 6.3, etc.) forces E_ALL ^ E_NOTICE. You need to use a development snapshot of Drupal (6.x-dev) and/or a CVS checkout of DRUPAL-6 to see them. It's generally best practice for developers to run CVS checkouts of Drupal so that they can more easily do core patches if required. :)

#5

deekayen - July 17, 2008 - 16:41

On the latest CVS checkout of DRUPAL-6, I'm not even able to go to the main Validation API landing page, but I can in 6.3 release:

Fatal error: Unsupported operand types in /Users/davidnorman/Sites/drupal6/includes/common.inc on line 1435

I haven't been able to consistently reproduce it, though.

#6

deekayen - July 17, 2008 - 16:47

Just to keep this updated, notices are still there. They all seem like things that could be cleared up with empty and isset.

validation import screen:

notice: Undefined variable: defaults in /Users/davidnorman/Sites/drupal6/sites/all/modules/validation_api/validation_api.admin.inc on line 469.

validation export screen:

notice: Undefined variable: options in /Users/davidnorman/Sites/drupal6/sites/all/modules/validation_api/validation_api.admin.inc on line 417.

clone:

notice: Undefined variable: options in /Users/davidnorman/Sites/drupal6/sites/all/modules/validation_api/validation_api.admin.inc on line 528.

add field:

notice: Undefined variable: options in /Users/davidnorman/Sites/drupal6/sites/all/modules/validation_api/validation_api.admin.inc on line 301.
warning: Invalid argument supplied for foreach() in /Users/davidnorman/Sites/drupal6/includes/form.inc on line 1405.

#7

TapocoL - July 18, 2008 - 19:18
Status:active» fixed

Fixed on latest revision.

#8

Anonymous (not verified) - August 1, 2008 - 19:24
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.