Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 12:13
    jakubmisek commented #565
  • 12:11

    jakubmisek on master

    (binary) cast operator to cast… (compare)

  • 11:22
    jan-ai commented #565
  • 11:05
    jakubmisek commented #565
  • 10:57
    jan-ai opened #565
  • 09:09

    jakubmisek on master

    test case for https://github.co… (compare)

  • 09:05
    jakubmisek commented #555
  • 09:04

    jakubmisek on master

    comment (compare)

  • 09:03
    jakubmisek closed #564
  • 09:03

    jakubmisek on master

    workaround for Laravel making a… (compare)

  • 09:02
    jakubmisek commented #564
  • 09:02
    jakubmisek commented #564
  • 09:02
    menturion commented #555
  • 09:00
    jakubmisek commented #564
  • 08:56
    jakubmisek commented #564
  • 08:55
    jakubmisek edited #252
  • 08:55
    jakubmisek edited #252
  • 08:54
    jakubmisek edited #252
  • 08:49
    jakubmisek edited #564
  • 08:48
    jakubmisek commented #564
Calvin Baart
@calvinbaart
getLastErrors in peachpie has the [return: CastToFalse] attribute, but according to the documentation getLastErrors should always return an array. Maybe thats the problem
Jakub Míšek
@jakubmisek
just found it! you're right. I'll double check but I think even PHP returns FALSE if none of date functions were called yet
Calvin Baart
@calvinbaart
With #535 closed can we now require non-compiled .php files?
Jakub Míšek
@jakubmisek

@calvinbaart we've changed the getLastError() implementation so it never returns FALSE. Note in PHP it does return FALSE sometimes but it is not documented and I think developers (and frameworks) do not expect it anyway.

The only scenario where it can be used would be if someone would like to check if any of date-parsing function were used already by checking getLastError() is FALSE.

Calvin Baart
@calvinbaart
Great! Just triggered a new build to see if this resolves the issue: https://travis-ci.com/calvinbaart/laravel-peachpie-sample/builds/127997383
Jakub Míšek
@jakubmisek
thanks!
@calvinbaart the #535 only adds necessary API so w can get it implemented in future, but the whole eval() think is not ready for it yet. Note compiler needs the whole context, all the classes and dependencies. It cannot just compile a piece of it, or at least not efficiently.
We will use it for implementing FIleProviders in ASP.NET Core, so we can pack all the content files (.js, .css,...) into a .NET resource and serve it from there, and PHP's file functions will treat it like it is saved physically on disk.
Calvin Baart
@calvinbaart
That sounds interesting, Would be pretty useful for Laravel :)
Jakub Míšek
@jakubmisek
yes, basically the entire PHP component/web (like the entire wordpress) can be distributed and published as a single DLL file (approx 20MB large)
@calvinbaart we have changed the project's version from 0.9.9 to 1.0.0 (-dev)!
preparing for -alpha, -beta and -rc
Calvin Baart
@calvinbaart
Ic, I won't be able to change the versions now so I guess that will have to wait till tonight
Jakub Míšek
@jakubmisek
sure, thank you :)
smx
@smx-smx
thanks for replies @jakubmisek :)
thanks for the awesome work btw
Musti132
@Musti132
Any news on pthreads?
Calvin Baart
@calvinbaart
@jakubmisek After the latest fixes I started getting the compile crash again (perhaps I'm doing something wrong with the version?) so I tried building PeachPie in Debug for extra information but this gives the following assertion when compiling Laravel: https://travis-ci.com/calvinbaart/laravel-peachpie-sample/builds/128080202
Jakub Míšek
@jakubmisek
@calvinbaart let me add some more debug information
@smx-smx thanks!
@Musti132 no news
Calvin Baart
@calvinbaart
@jakubmisek Retriggered the build, this is the assertion message: Argument for params is expected to be of type PhpValue[], at Headers::__construct(). It looks like a PHP error so I'll look into it when I'm home
Jakub Míšek
@jakubmisek
thanks, seems a __construct() vararg argument might be type-hinted?
Calvin Baart
@calvinbaart
Yea, I'll need to find that class to see whats going wrong. Thanks for adding the debug messages, that atleast gives me some clue :)
Jakub Míšek
@jakubmisek
looking for the class as well :)
Contains a type-hinted vararg constructor aswell
Jakub Míšek
@jakubmisek
yes (HeaderInterface ...$headers) thanks!
test case, pretty simple:
class X {
    function __construct(int ...$args) {
        //print_r( $args );
    }
}
Jakub Míšek
@jakubmisek
fixed, thanks @calvinbaart :)
Calvin Baart
@calvinbaart
Great thanks, I'll trigger the build again
Jakub Míšek
@jakubmisek
I guess you have enabled debug build :)
Calvin Baart
@calvinbaart
Yea....I should probably have enabled it sooner (because of all the assertions I should have hit)
Daniel Llewellyn
@diddledan
only one override in WordPress now! iolevel/wpdotnet-sdk#45
Jakub Míšek
@jakubmisek
@calvinbaart should be fixed in latest commit
This message was deleted
@diddledan thanks! what is the last override? that PEAR_Error ?
Calvin Baart
@calvinbaart
Ah debug build....: https://travis-ci.com/calvinbaart/laravel-peachpie-sample
I'll try building in Release...
Jakub Míšek
@jakubmisek
well the debug build should pass as well :) so feel free to keep it, we have to fix all the assertions anyway
seems this is not an assertion btw
Jakub Míšek
@jakubmisek
looks like eval() created the same class twice
Daniel Llewellyn
@diddledan
@jakubmisek yeah, the last one is an
if (class_exists('PEAR_Error')) {
    class foo extends PEAR_Error {}
}
Calvin Baart
@calvinbaart
@jakubmisek I linked the wrong one, this was the build with the failing assertion: https://travis-ci.com/calvinbaart/laravel-peachpie-sample/builds/128209553
Jakub Míšek
@jakubmisek
@calvinbaart thanks! working on it
Jakub Míšek
@jakubmisek
@calvinbaart as I see the most recent issue is the __destruct() being called (in .NET by the Garbage Collection) and crashes
Calvin Baart
@calvinbaart
@jakubmisek Yea, I think its happening because the __destruct is not called deterministically. I think the destruct is called after laravel resets itself for the next test and then fails because its not in the state the original test expected, I'll keep looking into this to see if this is actually the case though (I can't really reproduce this easily, I'll probably disable the __destruct for now)
Calvin Baart
@calvinbaart
New assertion! https://travis-ci.com/calvinbaart/laravel-peachpie-sample/builds/128627715 Debug mode is a goldmine I guess.... :)
I'm not really sure how to report these since I can't get any of them to reproduce reliably outside of the unit test
Christopher Pereira
@kripper
Hi, how can I set global PHP variables for my web app from .cs ?
Christopher Pereira
@kripper
I found something about 'BeforeRequest'...will try