Page MenuHomePhabricator

Elastica 5.3 uses the each keyword which is deprecated in PHP 7.2
Closed, ResolvedPublic

Description

It may cause a lot of deprecation warnings for users switching to PHP 7.2 as it is used in the Transport/Http class.
Should we try to upstream a patch to remove 7.2 deprecation warnings?
We could also try to see if we can use the Elastica extension itself to backport a fix there, Transport class can be extended IIRC.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

I'm certain upstream has already fixed this, just not in the versions we support. Elastica 6 supports php 7, but also requires elasticsearch 6. We could do some custom hacks locally until we are ready for 6?

EBjune triaged this task as Medium priority.Jun 7 2018, 5:17 PM
EBjune moved this task from needs triage to watching / waiting on the Discovery-Search board.

Change 467079 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[mediawiki/vendor@master] ruflin/elastica: Backport patch to stop using each()

https://gerrit.wikimedia.org/r/467079

Change 467079 merged by jenkins-bot:
[mediawiki/vendor@master] ruflin/elastica: Backport patch to stop using each()

https://gerrit.wikimedia.org/r/467079

Legoktm claimed this task.
Legoktm subscribed.

No backport to 1.31 needed because elastica isn't bundled.