Fix schema_assets_filter configuration docs#731
Conversation
The callable set as schemaAssetsFilter should return false for tables that you want filtered out See e.g. https://github.com/doctrine/dbal/blob/3.6.x/src/Configuration.php#L167
|
A description about what to expect on true and false would be insightful. Something like "If the function returns true, then..." |
driehle
left a comment
There was a problem hiding this comment.
Yes, please add something in the writting text as well on how this filter works!
|
My intent with this PR was to fix the documentation error. With the latest package versions (dbal 3.5.3 and migrations 3.5.5) adding the 'migrations' table to the asset filter breaks doctrine migrations (and not adding it makes the schema-tool when run with the the "--complete" option drop the table) |
|
Adding a table to the schema_asset_filter will not prevent an entity table from being created, only tables not owned by the DBAL from being dropped, I changed this in the first line. Also I added some explanation on how the schema_assets_filter works and removed the 'migrations' table from the example as adding it to the asset filter currently breaks doctrine migrations. |
Opened issue doctrine/migrations#1317 |
Fix Ignored error pattern #Parameter \doctrine#1 .* of method Doctrine\\Common\\DataFixtures\\Executor\\ORMExecutor::execute\(\)# in path tests/Paginator/AdapterTest.php was not matched in reported errors.
| - | ||
| message: '#Parameter \#1 .* of method DoctrineORMModule\\Options\\Configuration.* stdClass given#' | ||
| path: tests/Options/ConfigurationOptionsTest.php | ||
| - |
The callable set as schemaAssetsFilter should return false for tables that you want filtered out
See for example https://github.com/doctrine/dbal/blob/3.6.x/src/Configuration.php#L168 and https://github.com/doctrine/dbal/blob/4.0.x/src/Schema/AbstractSchemaManager.php#L204