Skip to content

IBX-12046: Removed Symfony and template deprecations triggered by admin-ui - #2112

Merged
ViniTou merged 6 commits into
6.0from
IBX-12046-symfony-deprecations-v2
Sep 24, 2026
Merged

ViniTou merged 6 commits into
6.0from
IBX-12046-symfony-deprecations-v2

Conversation

@ViniTou

@ViniTou ViniTou commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor
🎫 Issue IBX-12046

Related PRs:

Description:

A Symfony 7.x deprecation that admin-ui causes in every kernel loading it, and which therefore sits in the integration baselines of 10–11 consumer repositories:

  • Ibexa\AdminUi\Form\Type\Search\DateIntervalType: ~ defines a service for a class that does not exist (the real type is Date\DateIntervalType, which is what SearchType/TrashSearchType use), triggering "Service id … looks like a FQCN but no corresponding class or interface exists". The definition is dead and was removed.

admin-ui's own phpunit.integration.baseline.xml (the integration gate added in #2100) loses exactly the Search\DateIntervalType entry; nothing added (PHP 8.3 + 8.4, SQLite/MySQL/PostgreSQL give identical baselines). The unit phpunit.baseline.xml is unchanged (no kernel boots there). Cross-checked in scheduler with this branch installed: its regenerated integration baseline loses the DateIntervalType entry, nothing added.

The twig_component defaults (anonymous_template_directory, defaults) come from the symfony/ux-twig-component Flex recipe in projects; test kernels get them from ibexa/test-core#58 instead, so their two baseline entries stay here until that merges.

Also fixed the three template deprecations the integration gate (#2100) reports from TranslationTest — their messages carry the absolute template path, so #2100 baselines them with the CI checkout path; this PR removes those 3 entries again:

  • Moved the Twig use and macro tags to the template root (Twig 3.28). form_fields.html.twig: the use inside content_type_meta_field_definition_enabled_row duplicated the root-level use of the same template and was dropped. modal_add_custom_url.html.twig: the info_text macro moved to a new content/tab/url/macros.html.twig (same pattern as dashboard/macros.html.twig, content_type/macros.html.twig), imported inside the embed — neither import _self inside an embed (refers to the embedded template) nor a root-level import (not visible in the embed's scope) works.
  • Rendered the edit header info bar extras with ibexa_twig_component_group instead of the deprecated ibexa_render_component_group. The two read different registries: fieldtype-richtext-rte registers its presence list in content-form-edit-header-info-bar-extras with the ibexa.twig.component tag, which the old function never read, so it was not rendered.

For QA:

No functional change. Verified locally with a fresh composer update on PHP 8.3 and 8.4: test-unit and the gated test-integration exit 0 (8.4 also against PostgreSQL 10), PHPStan, deptrac and php-cs-fixer clean.

Documentation:

N/A

@ViniTou
ViniTou force-pushed the phpunit-11-deprecation-gate branch from a2aa667 to 6d7e515 Compare September 23, 2026 08:15
@ViniTou
ViniTou force-pushed the IBX-12046-symfony-deprecations-v2 branch from 7f2b6a6 to 5fb9e5e Compare September 23, 2026 08:15
@ViniTou
ViniTou force-pushed the phpunit-11-deprecation-gate branch from 6d7e515 to 8250487 Compare September 23, 2026 08:22
@ViniTou
ViniTou force-pushed the IBX-12046-symfony-deprecations-v2 branch 2 times, most recently from 9a13b36 to a188335 Compare September 23, 2026 08:38
@ViniTou ViniTou changed the title IBX-12046: Prepended twig_component defaults and removed a dead form type definition IBX-12046: Removed Symfony and template deprecations triggered by admin-ui Sep 23, 2026
Base automatically changed from phpunit-11-deprecation-gate to 6.0 September 23, 2026 09:28
@ViniTou
ViniTou force-pushed the IBX-12046-symfony-deprecations-v2 branch from 93c33f2 to a5fc602 Compare September 23, 2026 09:53
@ViniTou
ViniTou changed the base branch from 6.0 to IBX-12606-regenerated-deprecation-baseline September 23, 2026 09:53
Base automatically changed from IBX-12606-regenerated-deprecation-baseline to 6.0 September 23, 2026 10:40
Comment on lines +178 to +183
if ($container->hasExtension('twig_component')) {
$container->prependExtensionConfig('twig_component', [
'anonymous_template_directory' => 'components/',
'defaults' => [],
]);
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this set up by Symfony recipe? If so, then we should just add it onto the test setup instead of prepending it.

@ViniTou ViniTou Sep 23, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, I wanted to move it to our twig compoments, but i guess we can override it at recipe level as well, will check.

but it will prolly pop up on integration tests, so its needs to be added somewhere there as well.

@ViniTou ViniTou Sep 23, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this is just to clean up our baseline from integration tests deprecations I had moved it into ibexa/test-core@d8e42da
on project level lets leave it to customers or original recipes. (I even think it is already there)

@sonarqubecloud

Copy link
Copy Markdown

@ViniTou
ViniTou requested a review from Steveb-p September 23, 2026 13:22
@ViniTou
ViniTou merged commit 38a1ec3 into 6.0 Sep 24, 2026
59 of 67 checks passed
@ViniTou
ViniTou deleted the IBX-12046-symfony-deprecations-v2 branch September 24, 2026 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants