Skip to content

Move ext-deepclone version check from Composer conflict to runtime - #172

Merged
HypeMC merged 4 commits into
sofascore:2.xfrom
Brajk19:fix-deepclone-conflict
Sep 29, 2026
Merged

HypeMC merged 4 commits into
sofascore:2.xfrom
Brajk19:fix-deepclone-conflict

Conversation

@Brajk19

@Brajk19 Brajk19 commented Sep 29, 2026 •

Copy link
Copy Markdown
Member

Summary 📝
purgatory-bundle 2.0.0 can't be installed when the native deepclone extension is loaded

v2 added the conflict "ext-deepclone": "<0.7.1".
symfony/polyfill-deepclone declares "provide": {"ext-deepclone": "*"}, and Composer counts that * as matching <0.7.1.

we already have runetime check !\function_exists('deepclone_to_array') but it's not enough because function existed in older version but did not support serializing closures declared in constant expressions (that's what we need for PurgeOn and DynamicValues)

Checklist ✅

  • Tests updated 🐛
  • Docs updated 📚
  • Changelog updated 📋
  • Breaking change ⚠️

@Brajk19
Brajk19 requested a review from HypeMC September 29, 2026 18:18
@Brajk19 Brajk19 self-assigned this Sep 29, 2026
@codecov

codecov Bot commented Sep 29, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 57.14286% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 97.33%. Comparing base (48b36d1) to head (b1018aa).
⚠️ Report is 1 commits behind head on 2.x.

Files with missing lines Patch % Lines
src/Attribute/PurgeOn.php 60.00% 2 Missing ⚠️
src/Attribute/RouteParamValue/DynamicValues.php 50.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##                2.x     #172      +/-   ##
============================================
- Coverage     97.45%   97.33%   -0.12%     
- Complexity      688      692       +4     
============================================
  Files            75       75              
  Lines          1648     1653       +5     
============================================
+ Hits           1606     1609       +3     
- Misses           42       44       +2     
Flag Coverage Δ
8.1 90.86% <57.14%> (-0.10%) ⬇️
8.2 90.91% <57.14%> (-0.10%) ⬇️
8.3 90.73% <57.14%> (-0.10%) ⬇️
8.4 91.82% <57.14%> (-0.10%) ⬇️
8.5 97.21% <57.14%> (-0.12%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Brajk19 Brajk19 changed the title remove composer conflit and add runtime check for deepclone extension Move ext-deepclone version check from Composer conflict to runtime Sep 29, 2026
@Brajk19
Brajk19 marked this pull request as ready for review September 29, 2026 18:27
HypeMC
HypeMC previously approved these changes Sep 29, 2026
@HypeMC
HypeMC merged commit 486ceed into sofascore:2.x Sep 29, 2026
26 of 27 checks passed
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.

2 participants