Ticket #1570 (closed defect: fixed)

Opened 9 months ago

Last modified 8 months ago

Entities without columns cause php warnings when running Doctrine tasks

Reported by: Chekote Owned by: jwage
Priority: minor Milestone: 1.0.4
Component: Schema Files Version: 1.0.3
Severity: Keywords:
Cc: Has Test: no
Status: Pending Core Response Has Patch: no

Description

Having an entity without columns in your schema, such as:

schema.yml

MyEntity:

results in the following error during doctrine tasks execution:

Warning: array_keys(): The first argument should be an array in /Users/dtyler/Sites/quartz/plugins/sfDoctrinePlugin/lib/doctrine/Doctrine/Import/Schema.php on line 333

Obviously this is a *very* rare edge case, and is more of an annoyance than anything. But it could certainly cause a newcomer confusion and cause them to spend a lot of time trying to fix a problem in their schema that doesn't exist.

Anyone who is running into this problem and want's a workaround, can simply add an empty "columns:" definition the the entity as follows:

schema.yml

MyEntity:
  columns:

Change History

Changed 9 months ago by jwage

  • milestone changed from Unknown to 1.0.4

Changed 8 months ago by jwage

  • status changed from new to closed
  • resolution set to fixed

(In [5130]) [1.0, 1.1] fixes #1570

Note: See TracTickets for help on using tickets.