Closed (fixed)
Project:
Drupal core
Version:
7.x-dev
Component:
other
Priority:
Critical
Category:
Plan
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
25 Feb 2018 at 20:44 UTC
Updated:
25 Oct 2018 at 13:36 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
joseph.olstadcombined the two mentioned patches. props to the authors in those two issues. Thanks
afore
Comment #3
joseph.olstadUn assigning myself , maybe someone else can try fixing the one fail. I don't actually have a system with php 7.2 handy right now.
Comment #4
joseph.olstadOh, looks like patch #2 was a gaffe, forgot to combine the second patch.
Here is a new patch, it is a combination of patch #7 here:
#2885610-7: [PHP 7.2] Avoid count() calls on uncountable variables
with
#2925449-74: [PHP 7] Function each() is deprecated since PHP 7.2 [D7]
Comment #5
joseph.olstadOh, looks like patch #4 was a gaffe *again*, off of wrong commit hash.
Here is a new patch, it is a combination of patch #7 here:
#2885610-7: [PHP 7.2] Avoid count() calls on uncountable variables
with
#2925449-74: [PHP 7] Function each() is deprecated since PHP 7.2 [D7]
see interdiff
Comment #6
joseph.olstadhere is a new patch again, with very slight modification to drupal_web_test_case.php
bogus
Comment #7
joseph.olstadno don't do this
Comment #8
joseph.olstadSo far, patch 5 is the best.
Comment #9
solotandem commentedIn lieu of interdiff file, the changes are:
_drupal_shutdown_function()
- reference on $callback was not present before so omit from patch
_form_validate
- $elements['#value'] instanceof Countable is not necessary
- form API does not use Countable object
module_enable and module_disable
- comments are more concise
book_prev and book_next
- changes are more concise
theme_table
- remove change; add to drupal_common_theme
drupal_common_theme
- correct prototype values on 3 theme items
Comment #11
solotandem commentedsame patch with header removed
Comment #13
joseph.olstadComment #14
ayesh commentedComment #15
mikeytown2 commentedSame error I got over here when I tried to suppress the error to get an idea on where we stood.
#2925449-51: [PHP 7] Function each() is deprecated since PHP 7.2 [D7]
https://www.drupal.org/pift-ci-job/924112
I'm gonna guess you'll have to get php 7.2 running locally and manually debug this :/
PHP 5.3 failed with this
Guessing that was just a random failure
Comment #16
joseph.olstadjust FYI, I've queued something over here:
#2885610-11: [PHP 7.2] Avoid count() calls on uncountable variables
Mikeytown2, I've seen your excellent work on Drupal.org, keep it up.
Comment #17
sjerdoManually tested uploading of modules in PHP 7.2. Uploading a tar file will result in a fatal error due to Archive_Tar incompatibility with PHP 7.2 #2946045: Unable to update modules due to Archive_Tar incompatibility with PHP 7.2
Comment #18
sjerdoUpdated status to Needs work
Comment #19
joseph.olstad@sjerdo, I think that if we combine your patch https://www.drupal.org/files/issues/2018-04-15/update-pear-tar-archive-c...
with the patch from Ayesh #14 (above)
combining these three patches (#14 is two patches combined) will likely mean that php 7.2 will pass all tests.
anyone want to try?
Comment #20
joseph.olstadOk, this patch is simply taking patch 14 (above) and combining it with the system.tar.inc patch by @sjerdo
now expecting all tests to pass with php 7.2
(would be nice)
we'll see what the testbot says.
I am not putting an interdiff because no real patch changes here, simply combining patches. So this patch is actually 3 patches combined. I will summarize after if this works.
Comment #21
joseph.olstadnice work @sjerdo
the combined patch passes all tests for php 7.2
WOOT!
Here's the 3 patches we need committed into D7 core:
#2885610: [PHP 7.2] Avoid count() calls on uncountable variables
#2925449: [PHP 7] Function each() is deprecated since PHP 7.2 [D7]
#2946045: Unable to update modules due to Archive_Tar incompatibility with PHP 7.2
Comment #22
joseph.olstadComment #23
joseph.olstadlets crank this up, contrib needs this to be done so that we can start testing
Comment #24
nwom commented#21 applied cleanly and worked for me. Thanks!
Comment #25
cezkid commentedUpgraded today to 7.2 and was getting "The each() function is deprecated" error. Patch #21 no errors.
Comment #26
maximpodorov commentedWhat about #2938567: PHP 7.2: Warning: count(): Parameter must be an array or an object that implements Countable a theme_table()?
Comment #27
ayesh commentedThe patch in #2885610: [PHP 7.2] Avoid count() calls on uncountable variables , which is also included in the combined patch in this issue fixes that. I marked that issue a duplicate of 2885610.
Comment #28
maximpodorov commentedAre $colgroups and other similar variables arrays always?
Comment #29
fabianx commentedThis is the plan issue, but happy for it to be critical.
Comment #30
axle_foley00 commentedThe patch in #20 worked for me also. Hopefully this will be officially added to core soon.
Comment #31
tshorock commentedFound a case locally where @maximpodorov was right... $colgroups was coming in as a bare null to theme_table().
Looks like the other variables are controlled locally here.
Comment #33
tshorock commented(first time patch, apologies for errors)
Comment #36
joseph.olstadtshorock, there's an issue with the runner. it might not be your patch
see:
#2970950: D7 test runner not working since may 4th 2018 'Composer command failed'
Comment #38
joseph.olstad@tshorock, the test runner was fixed, I re-ran the tests on your patches, most of them passing.
as for naming convention, the last number is the number of your comment , so this comment is 38, so if I uploaded a patch it'd be:
d7_description-issuenumber-38.patch
Comment #39
mcdruid commentedUploading exactly the same patch as #31 just to see if we can get a totally green board from the tests; to me at least, the mess left over from a few testbot errors makes it very unclear whether all tests are actually passing or whether there are legit failures.
If all tests pass, will put this back to RTBC.
Comment #40
mcdruid commentedSo we still saw 3 test failures for PHP7.2 however I'm not entirely convinced they were legitimate.
Queued for a retest; if the same 3 failures come back we'll have to dig into them.
Comment #41
mcdruid commentedUnless I'm missing something, that looks like a pass for PHP7.2 on the re-test; I think the first time around was a testbot snafu.
Good news then! Back to RTBC.
Comment #42
fabianx commentedThank you very much for re-testing. That was a very good idea.
Comment #43
joseph.olstadPatch 31 by tshorock covers everything (known) for core PHP 7.2 compatibility IMHO. It is a big patch, push it to dev branch? Then we can start triggering contrib tests.
I would commit it as is and close the other related issues but be sure to credit those from the other patches for their work on this. Will make for a very long commit message.
Alternatively you commit the three smaller patches and include the interdiff in 31 above.
Probably easiest to push in patch 31 as-is.
Thanks.
Comment #44
joseph.olstadComment #45
rob c commentedIs #2885129: [PHP 7.2] create_function() is deprecated part of this? (old update, but still)
Comment #46
joseph.olstad#2885610: [PHP 7.2] Avoid count() calls on uncountable variables
#2925449: [PHP 7] Function each() is deprecated since PHP 7.2 [D7]
#2946045: Unable to update modules due to Archive_Tar incompatibility with PHP 7.2
These above issues are what makes up patch 31.
patch 31 also includes:
https://www.drupal.org/files/issues/2018-05-15/interdiff_20_to_31.txt
to make things simple, if we just commit patch 31 into dev and credit everyone for their work, if there should (god willing) be anything left to do related to php 7.2 support, it'd be easier to deal with once patch 31 is committed.
We've got progress here, take the baby step , commit patch 31, then if there is anything else to do, it'd be a new issue linked to these and much smaller should there be anything. With that said, patch 31 has what we need to get going, passes tests. What more can you ask for? If there was something else critical to add, these very smart developers above would have already added it.
Comment #47
joseph.olstadok so ya, wouldn't hurt to throw in #2885129: [PHP 7.2] create_function() is deprecated too. but seperately from 31, no need for a reroll.
Comment #48
gary_mazz commentedWhat is the current disposition of patch 31 ? Has it been tested, committed, pushed to release or update ?
I'd like to get rid of warning: "The each() function is deprecated. This message will be suppressed on further calls in menu_set_active_trail() (line 2405 of /var/www/html/xxxx/includes/menu.inc)."
I was hoping to see the message suppressed, but that doesn't seem to be working.. I'm stuck because others are pushing WP.
Comment #49
joseph.olstadthe patch is scheduled for commit. Should happen any day now.
Comment #50
Adam Neutrik commented@gary_mazz: Turn off error messaging if you won't see such warnings. As joseph.olstad stated: on the way in.
Comment #51
truls1502@joseph.olsta - any idea when the patches will be committed?
Or in the meanwhile, could someone help us to point which one to patch while we are waiting for a new release? :)
Comment #52
ayesh commentedYou can track individual progress in the linked issues. Some are merged to the 7.x branch, but not released in a proper release. I wouldn't be surprised if a release takes time because 8.x gets more attention nowadays.
I use the patch at #31 for Drupal 7 sites.
Comment #53
joseph.olstadI've already pinged the right person to get this committed, I'll follow up again in a couple weeks.
Comment #54
farnoosh commentedPatch #31 works for me.
php version: 7.2
Drupal core 7.59
Comment #55
fabianx commentedFixed via the sub-issues
Comment #56
rgpublicHooray. It's fixed. Thanks to everyone involved. Sorry for the dumb question, but: Do I understand correctly that the next release 7.60 will then be fully PHP 7.2 compatible?
Comment #57
ayesh commentedUnless a security release races first, 7.60 will contain all these fixes. I wouldn't call it "Fully 7.2 compatible" because there could be bugs unreported here.
Comment #58
oriol_e9gWhen is it expected to release Drupal 7.60? somebody remember release dates?
Comment #59
apotek commentedComment #60
pipicom commented#31 works for me.
Had to also modify:
@ "includes/theme.inc" file.
- $links = $variables['links'];
+ $links = (array) $variables['links'];
Comment #61
raushan commented#31 Works for me.
Thanks
Comment #62
mrgoodfellow commentedI was able to apply this patch successfully and everything appears to be working as intended in my sandbox php 7.2 environment.
Thank you!
Comment #63
mustanggb commented> When is it expected to release Drupal 7.60? somebody remember release dates?
Afaik it has always been the plan(/target) that releases every 6 months would contain new features.
But 7.50 was over 2 years ago, so I guess that idea didn't last very long.
Comment #64
gnurob commented@MustangGB and @oriol_e9g
The following are prior release dates. Any day now, it would seem. (Thank you everyone who contributed to this.)
7.59 - 25 April 2018
7.58 - 28 March 2018
7.57 - 21 February 2018
7.56 - 21 June 2017
7.55 - 7 June 2017
7.54 - 1 February 2017
7.53 - 7 December 2016
7.52 - 16 November 2016
7.51 - 5 October 2016
7.50 - 7 July 2016
7.44 - 15 June 2016
7.43 - 24 February 2016
7.42 - 3 February 2016
7.41 - 21 October 2015
7.40 - 14 October 2015
7.39 - 19 August 2015
7.38 - 17 June 2015
7.37 - 7 May 2015
7.36 - 2 April 2015
7.35 - 18 March 2015
Comment #65
pramodini123 commentedHello,
I applied patch given... but still not working for php 7.2
still getting.
Fatal error: Uncaught Error: Call to undefined function cache_get() in public_html/includes/module.inc:762 Stack trace: #0 public_html/includes/module.inc(962): module_implements('system_theme_in...') #1 public_html/modules/system/system.module(2511): module_invoke_all('system_theme_in...') #2 /public_html/includes/theme.inc(798): _system_rebuild_theme_data() #3 /public_html/includes/theme.maintenance.inc(57): list_themes() #4/public_html/includes/bootstrap.inc(2881): _drupal_maintenance_theme() #5 /public_html/includes/errors.inc(179): drupal_maintenance_theme() #6 /public_html/includes/bootstrap.inc(2609): _drupal_log_error(Array, true) #7 [internal function]: _drupal_exception_handler(Object(Error)) #8 {main} thrown in/public_html/includes/module.inc on line 762
Help me ....
Comment #66
truls1502@pramodini123 - I can't reproduce your issue, do you mind to tell us the step by step how you faced the error? Maybe a screenshot can also help us.
Comment #67
pramodini123 commentedHello,
Server admin has removed.. php7 so automatically 7.2 is now there.... So I applied the patch given... but still these errors are...
Thank you,
Comment #68
joseph.olstadpramodini123
Rather than apply the patch, try upgrading to Drupal 7.x dev release
drush dl drupal --select
choose the dev version
looks like you've incorrectly applied the patch, this might fix it. this patch is included in Drupal 7.x dev
Comment #69
pramodini123 commentedHello,
I used drupal 7.x dev .. .then also getting same error... I tried also by removing one by one modules but no other errors...
Comment #70
pramodini123 commentedHello,
Thanks joseph.olstad I updated drupal dev version ... with your reply... bu was not working .same error . but..
I just updated fresh settings.php and updated there details with database and other details there... and its working...
Thanks a lot for your help joseph.olstad
Thank you
Comment #72
joseph.olstadWe should pack more great stuff like this into 7.60 and then schedule a virtual release party!
Comment #73
polI completely agree :-)
Comment #74
bruhnrp commentedI think the comment by pipicom #60 was missed. I ran into his same issue with theme.inc
Comment #75
joseph.olstadWe'll have to open a new issue for #60, this one is closed.
Please open a new issue and submit a patch for review, we'll try to get this into 7.60 , should be done right away.
Comment #76
joseph.olstadok, I have openned an issue
#2996519: PHP 7.2 compatibility - make sure some variables are arrays in theme_links().
Comment #77
fabianx commentedAs this is a plan, I feel good to re-open this until #2996519: PHP 7.2 compatibility - make sure some variables are arrays in theme_links(). is fixed.
Thanks!
Comment #78
fabianx commentedFull support of PHP 7.2 is fixed again as of our current knowledge:
#2996519: PHP 7.2 compatibility - make sure some variables are arrays in theme_links().
So marking this plan as fixed again.
Comment #79
mustanggb commentedI don't understand what just happened, is Fabianx trying to give himself three times the amount of work?
Comment #80
ydahiThis is long overdue to be released.. any schedule?
Comment #81
Pablo Gosse commentedWe are having to upgrade our web servers to support PHP 7. It would be great to go direclty to 7.2, instead of having to go to 7.1 until Drupal 7.60 is released to support PHP 7.2.
Is there a planned date for the release of Drupal 7.6?
Thanks,
Pablo
Comment #82
pounardI do use Drupal 7 with PHP 7.2 on dev boxes and various VMs, and I experienced no problems, problem will rise with modules, mostly, core is not really problematic.
Comment #83
joseph.olstadFor those wanting to put PHP 7.2.x to test right away, I've released media_dev 7.x-4.0-beta8 which contains the pre-release Drupal core (7.59+25) based on the dev branch as of a few days ago.
I tested php 7.2.x, everything I tried worked great. The distribution has all the latest contrib (ctools, libraries, views, media, file_entity and more) and I did not observe any issues during my tests. Everything I tried worked fine.
If you find any contrib modules causing a problem with php 7.2.x, please create an issue in the media_dev issue queue.
Thanks
Comment #85
rgpublicHm. There was more than half a year between 7.56 and 7.57 according to #64. I hope this isnt any indication. Does anyone know whether the release process has any transparency? When I search for issues tagged "Drupal 7.60" target I find LOTS of issues. Many "reviewed and tested by the community", many also in "Needs review", "Needs work" state. Many abandoned for many months or even years. I wonder: Is there are some kind of credible list of what needs to be solved until 7.60 is released? Right now, everyone on this issue is anxiously waiting I guess. We have mixed D7/D8 servers with lots of websites on them and we cannot upgrade to 7.2 and profit from the performance benefits etc only due to this issue. And it's not really a solution to use any dev branch etc if you have many, many production websites to take care of.
Comment #86
joseph.olstadusually if there's an extended delay for a drupal core release there is a reason for the delay. I'm expecting 7.60 to be released next week during the release window. Pol the new co-maintainer and Fabianx are well aware that we're all expecting a release soon and I'm sure they've been working on it. With that said, php 7.2.x is getting a lot of traction with the release of Ubuntu 18.04 LTS, it is important and we all know it.
Comment #87
ayesh commentedSecurity releases do not contain bug fixes, so none of these PHP 7.2 fixes were included in the 7.60 release. Hopefully maintainers will finally merge and release a 7.61 with these changes.
Comment #88
martijn de wityup... So many people are waiting for the php 7.2 fixes.
Last functional release: Drupal 7.55, 2017-06-07
Comment #89
El Bandito commentedFor those of us with Drupal 7 sites on shared hosting PHP 7.2 compatibility is increasingly important. Many major players like Midphase have already upgraded their servers and do not provide the option of sticking with an earlier PHP version.
++1 for the swiftest possible release of 7.61.
Comment #90
joseph.olstadphp 7.3.x was recently pushed into my server when I ran an update... let's get php 7.2.x compatibility released so that we can focus on php 7.3.x
++++
Comment #91
ayesh commentedI run a few small ok-if-it-breaks-ware sites on PHP 7.3-rc3 with 7.x-dev, and it surprisingly runs well.
There aren't much deprecations in PHP 7.3 (shameless self plug: https://ayesh.me/Upgrade-PHP-7.3) that raises any big problems.
However, 7.3 is just around the corner, and it would be nice if we could have a 7 61 feature release just so we can say Drupal 7 is compatible with latest photo version.
Comment #92
joseph.olstadBumping to 7.61. This didn't make it into 7.60.
although it is already committed into 7.x dev, so hope this makes it into 7.61
Comment #93
travelvc commented+1 from me - please prioritize PHP 7.2 in 7.61
Comment #94
tbadaczewski commentedYes, for the love of jeebus, let's get PHP 7.2 in 7.61!
Comment #95
damienmckennaThe next stable release of Drupal 7 will include the fixes, the question is whether there'll be another security release before that.
Comment #96
ayesh commentedPerhaps we shouldn't delay a 7.61 release for so long that someone finds a vulnerability in 7.60? To be honest it is getting ridiculous how long these PHP 7.2 fixes let alone improvements are dragging. On a serious note, I am available to help out maintainers if they are time-constraint.
Comment #97
brianlp commentedHostEurope disabled PHP 5.6 yesterday for shared hosting and 7.2 is now their default.
Comment #98
joseph.olstadIt'll probably be the next core release window.
https://www.drupal.org/core/release-cycle-overview
I've spoken to some 7.x core contributors and at least one of them is itching to cut a release.
For the benefit of the community it would be nice though if they would confirm publicly the 7.x release roadmap.
Comment #99
rgpublicThanks a lot, Joseph. Good to know. What I find most disconcerting is not that the release takes a bit longer but the huge intransparency of the release process in general that Drupal and associated modules is often enshrouded in. This bug is in status "Closed (fixed)". And then it stays just like that for an indefinite amount of time. And now, if you search for "Drupal 7.61 target" you see lots of different issues. Are they going to be fixed before 7.61 is released? Or some of them? Or what does it all mean?
I guess the Drupal core developers probably have a list of issues they want to have fixed until Drupal 7.61 is released. And, I guess again, it's not too far-fetched to imagine this list is not on paper but exists in electronic form. Then, I wonder: Why aren't they simply making this information available to the public? Imagine you're waiting at the doctor's office and they say you need to wait for 3 hours. It's bad, but after all you can accept it, read a magazine and wait. Now, imagine you're waiting for 3 hours and you simply don't know if you need to wait another 3 hours, 6 hours or 4 weeks sitting in that office. No one talking to you. The simple information on what to expect makes a huge difference here.
I'm well aware the Drupal folks are a bunch of pretty clever guys and many things might have their reasons but sometimes it would really help *a lot* for those of us who have to get the job done everyday to know a bit more about what's actually going on.
The "open" part of the term "Open Source" IMHO shouldnt only mean you can have the source code, but also that the development process in general is more open. Since LibreOffice split off from OpenOffice and, well, liberated the development process it seems the software is progressing at almost 10x the original speed.
I'm still having a huge list of Drupal patches I keep porting from version to version to make the many Drupal websites we take care of work. Which is OK. It's free after all. But some of those patches also sit there for years. It's admittedly not core though. I honestly sometimes wonder: Is the original maintainer still alive? If you ask me, the information process could really be improved upon. It can and should IMHO be way more clear for happens next with issues that have patches available or are even marked as "fixed".
Ok, just my thoughts on this. Hope this didnt come across as too much of a rant. I like Drupal after all :-)
Comment #100
damienmckennaClosing this discussion as it has gone way off topic.
@joseph.oldstad's comment #98 stands as the final word on the subject.