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.

Comments

TapocoL’s picture

Version: » 6.x-1.0-alpha1
Status: Active » Postponed (maintainer 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.

Renee S’s picture

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

TapocoL’s picture

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

webchick’s picture

Status: Postponed (maintainer 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. :)

deekayen’s picture

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.

deekayen’s picture

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.

TapocoL’s picture

Status: Active » Fixed

Fixed on latest revision.

Anonymous’s picture

Status: Fixed » Closed (fixed)

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