runkit
runkit copied to clipboard
PHP7 support
Hello, is there a plan for php 7 support? I use your module and recently I installed php 7 so I can start testing my apps and I would really appreciate if you make a php 7 version :)
Show me the money ;)
Okay, I will donate you, if you make the php 7 version :)
I forked the project to support a subset of runkit's functions for PHP7: https://github.com/runkit7/runkit7
EDIT: Current status can be seen at https://github.com/runkit7/runkit7#compatability-php70-to-php-72
- This has been compiled in 64-bit builds of PHP on Linux EDIT: and 32-bit builds work equally well, as well as on windows.
- ... and will run (downhill, downwind, in a hurricane). There are bugs related to segmentation faults and memory management. There are also bugs related to language features that have changed in PHP7. EDIT: Any segfaults were fixed, memory management is still not freed (to avoid crashes), but should be suitable for unit testing
- 59/177 of runkit's tests are passing in the PHP7 fork
- 32-bit builds haven't been tested, and probably aren't working yet.
- The enabled runkit functions are
-
runkit_method_add
-
runkit_method_copy
-
runkit_method_redefine
-
runkit_method_remove
-
runkit_function_add
-
runkit_function_copy
-
runkit_function_remove
, and -
runkit_function_redefine
. - EDIT:
runkit_object_id
was added - EDIT:
runkit_import
is in progress for a subset of flags, doesn't allow importing properties yet
Help is welcome from people with experience creating/maintaining/upgrading PHP extensions, or who are familiar with Zend internals.
:+1: on PHP7 support. I use runkit for unit testing, and want to test out a PHP5 project on PHP7.
EDIT: More tests are working, including some(but not all) of the tests of constants (Zend VM aggressively inlines constants within the same scope/file). I still don't have class manipulation, properties or import working, sadly. EDIT: tests are passing, except for some expected failures for constant manipulation (some inlined by Zend VM optimizations). property manipulation was disabled. EDIT: runkit_import has partial support, but doesn't support all of the flags EDIT: This now supports php 7.2 and 7.3alpha2 as well
I don't like the idea of castrating Runkit for PHP7.
Why castrating? PHP 5 will be a thing of past in few years, why do you think it's best idea to port it for PHP7?
Now people use PHP 5 and there are no reasons to discard it. Anyway now I already have "Tests passed: 90" and I will not participate in @TysonAndre 's branch. Sorry.
I'm okay with that, it's your choice, I just do not understand your point of view, that's all. Anyway, thanks for your work on this module, I use it in my project :)
That's fine.
To clarify: you're developing a branch of runkit that works with the latest release candidate of PHP 7, and 90/177 tests are passing?
Also, which way do you plan to port runkit to PHP7?
- A single branch that should compile with both PHP 7 and PHP <= 5.6?
- A separate branch for PHP7?
Yes, actually 97/175 with php7rc2, a single branch for all PHP versions.
I do agree with @zenovich, it's better to keep every change to this repository in order to have a single runkit version compatible with both PHP 5 and PHP 7 because PHP 5 will be used for another decade.
@tristanleboss I would agree with zenovich too, but he stated that he does not "like the idea of castrating Runkit for PHP7".
@tristanleboss @RikudouSage To be fair, I think @TysonAndre 's intention was to simply get it working with PHP7 as a proof of concept, not to drop the support for good. If I were to try to do it myself, I'd probably figure it out how to make it work for PHP7 first and then bother with the older PHP versions. The intent would not be to "castrate" it.
Sorry, guys, but Runkit that works only with PHP 7 x64 without importing, without constants and properties manipulations, and without classes adoption or emancipation was definitely castrated.
@zenovich It wasn't the plan to leave it out, I think that was just testing around. At least that's how I would have approached it and that's how it looks to me.
EDiT: So, to clarify, I totally agree that it would be "castrating" it to remove older PHP and I am not disagreeing with you. I'm just pointing out that this was not actually intended as something that would be ever released.
Again, I already know how to achieve the full support of PHP 7 compatibly with PHP 5, but it is big work and I'm sure this work should be paid for. Sponsors are welcomed to discuss this via email [email protected]
@zenovich Well you are the guy to do it :) We've spoken over email already and what we've discussed still stands.
Some news about support runkit on Php 7 ^^
How much money? :smile:
We can talk about this in person if you want to. My email is [email protected].
@zenovich didn't you think about https://www.kickstarter.com/discover/categories/technology/software ? set some reasonable price and it will be faster I guess
@digitalist I thought of different things, but I have no time to do them.
Are there any news regarding php7 support? Runkit would fit perfectly for our use case but we use PHP 7 in development and also in production in a short time.
Can we start investing in runkit or should we find an alternative?
I mentioned my unaffiliated runkit7 fork earlier.
See https://github.com/runkit7/runkit7#compatability-php70-partial-buggy and https://github.com/runkit7/runkit7#reasons-for-disabling-property-manipulation to see if that fits your use case.
@TysonAndre I've seen your repo, but that is an incomplete implementation "Runkit that (mostly) works in PHP7" and as I said, we need to run this in production.
I managed to get the fork installed but am struggling with "unknown type" on a string argument (in debug the variable looks like a string).
Any suggestions?
@pfalsoncup File a bug in https://github.com/runkit7/runkit7 instead of this thread for issues with the fork.
If you can create a self-contained test case (E.g. a repo with instructions to reproduce the bug, or preferably a self-contained php file, php-config
output, and optionally ini settings), that would help with fixing that.
nvm...I ended up using json/decode+encode.
FWIW I'm just trying to trace when laravel urldecodes (as I have an app that works on one box but not another).
Please support PHP7. I would consider donating as well. Several users have offered.
The current source won't even compile! I wanna use a spoon, not a fork!
@zenovich How about name your price on kickstarter? $50k? $100k? I wouldn't be surprised if business users would put in real money. As it stands php5 is now officially deprecated (support ended in Jan 17) so my company is moving to php7, which that means we will lose runkit for our tests.
@dricket A year and a half ago I had a lot of free time and started working on support for PHP7 in Runkit. I thought there had to be some people and companies interested in and willing to pay for that. There were some, actually, but $1,000 were the most generous offer from them. For that reason, I postponed the PHP7 support although I had implemented some part of this task.
Now I have a regular job and don't have much time for doing something else. But, of course, if it's possible to fundraise $100,000 for that, I will spend all my free time working on the project.
I haven't tried Kickstarter yet. Do you think it can help indeed?
Is there a runkit project to suport PHP7?
@zenovich I was just exploring upgrading to PHP 7 and found this sad thread. We use Runkit Sandbox extensively. I'm certain that if you setup a kickstarter/gofundme/... project that you would get some, perhaps a lot, of support.
Especially if you added bonus spiff levels such as "Runkit for PHP7 with small feature addition." or "Runkit for PHP7 with large feature edition."
@cpriest what do you mean by "some" and "a lot" of support? just write an order of magnitude
You'd have a better idea of that, I've no idea how many companies / people use runkit.
So, just to recap, instead of actually having partial, kinda buggy, PHP7 support a year ago we though it'd be better to have none?
Folks (sorry Dima) -- you can always try https://github.com/runkit7/runkit7
A colleague developed it and thanks to it we were able to move to PHP 7 and beyond. If there are issues you have, you can always file an issue on the issue tracker on GitHub. Contributions of code are welcome, too!
Just to be clear, I am aware of this, I was just commenting on how it's funny how we needed two repos/projects for this because reasons. Thanks for it!
What happened?
Zenovich is not dead. https://github.com/France-ioi/AlgoreaBackend/commit/029788bcc245ff70ae43ef9529974d1dedd7c81b
Commit's even GPG signed...
Hello, is there a plan for php 7 support? I use your module and recently I installed php 7 so I can start testing my apps and I would really appreciate if you make a php 7 version :)
I can change your product and it will works on both versions like PHP 5+ and PHP 7 as well.