Skip to content

Fix PHP 8.5 curl_close()/curl_multi_close() deprecation#119

Merged
lohanidamodar merged 1 commit intomainfrom
fix/clo-4292-curl-close-php85
May 4, 2026
Merged

Fix PHP 8.5 curl_close()/curl_multi_close() deprecation#119
lohanidamodar merged 1 commit intomainfrom
fix/clo-4292-curl-close-php85

Conversation

@lohanidamodar
Copy link
Copy Markdown
Contributor

@lohanidamodar lohanidamodar commented May 3, 2026

Summary

  • Remove no-op \curl_close($ch) and \curl_multi_close($mh) calls in Messaging\Adapter that trigger Deprecated notices on PHP 8.5.

Why

Both functions have been no-ops since PHP 8.0 and are now formally deprecated in 8.5. Handles are freed when their variables go out of scope.

Test plan

  • composer lint (Pint) — pass
  • composer analyse (PHPStan L6) — pass

@greptile-apps
Copy link
Copy Markdown

greptile-apps Bot commented May 3, 2026

Greptile Summary

Removes three deprecated no-op calls — curl_close() (×2) and curl_multi_close() — from Adapter.php to eliminate Deprecated notices on PHP 8.5. The change is correct: both functions have been no-ops since PHP 8.0, handles are freed automatically when their variables leave scope, and the remaining curl_share_close($sh) call is unaffected.

Confidence Score: 5/5

Safe to merge — straightforward removal of formally deprecated no-op calls with no behavioral change.

Single-file change that removes calls which have been no-ops since PHP 8.0. No logic is altered, no resource management is affected (GC handles cleanup on scope exit), and curl_share_close is correctly retained.

No files require special attention.

Important Files Changed

Filename Overview
src/Utopia/Messaging/Adapter.php Removes deprecated curl_close() and curl_multi_close() no-op calls to fix PHP 8.5 deprecation notices; handles are freed on scope exit as expected.

Reviews (1): Last reviewed commit: "Remove deprecated curl_close() and curl_..." | Re-trigger Greptile

@lohanidamodar lohanidamodar merged commit 85e5d22 into main May 4, 2026
3 of 4 checks passed
@lohanidamodar lohanidamodar deleted the fix/clo-4292-curl-close-php85 branch May 4, 2026 08:53
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