Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema validation errors #311

Open
bizmate opened this issue Feb 7, 2020 · 0 comments
Open

Schema validation errors #311

bizmate opened this issue Feb 7, 2020 · 0 comments
Assignees
Labels

Comments

@bizmate
Copy link
Contributor

bizmate commented Feb 7, 2020

Short problem description

Entities define a schema that is invalid according to doctrine schema validation tool. As a result the schema cannot be created

Steps to reproduce

  1. bin/console doctrine:schema:validate
  2. shows validation errors
[Mapping]  FAIL - The entity-class 'PhpList\Core\Domain\Model\Messaging\SubscriberList' mapping is invalid:
* The field PhpList\Core\Domain\Model\Messaging\SubscriberList#subscribers is on the owning side of a bi-directional relationship, but the specified mappedBy association on the target-entity PhpList\Core\Domain\Model\Subscription\Subscriber# does not contain the required 'inversedBy' attribute.

[Mapping]  FAIL - The entity-class 'PhpList\Core\Domain\Model\Subscription\Subscriber' mapping is invalid:
* The field PhpList\Core\Domain\Model\Subscription\Subscriber#subscribedLists is on the owning side of a bi-directional relationship, but the specified mappedBy association on the target-entity PhpList\Core\Domain\Model\Messaging\SubscriberList# does not contain the required 'inversedBy' attribute.


In SchemaException.php line 109:
                                                                  
  The table with name 'phplist.phplist_listuser' already exists.  

  1. As a result also the schema cannot be generated

Expected behaviour

no errors when running bin/console doctrine:schema:create and a consistent db structure as a result

Actual behaviour

As per description in steps

System configuration

docker, php7.2, mysql 5.7
Extra info at https://github.com/bizmate/phplist-benchmark

Package version

dev-master tried both hashes 9f890f2 and d4dc77b

PHP and Composer version

php - php7.2 ( https://github.com/bizmate/phplist-benchmark/blob/master/docker/php/Dockerfile#L1 )
Composer version 1.9.3 2020-02-04 12:58:49

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants