The main issue I see here with this code, is that the worker code is embedded inside the run-tests.php code, so they're all convoluted together, and are stepping on each other's toes. run_all_tests() code is expected to work either as the main php process or as one of the worker processes.
We've added a class inline, inside run-tests.php, "RuntestsValgrind", and I'm looking to make an additional class, but have it as a separate file, instead of inside. What's the deal here? AFAIK the next master target is for PHP8, and we don't have overhead issues anymore, like we used to.
Morning, I got the following failing test output - there's no explanations at this summary part. Is there a way I can uncover more thorough details as to what specifically failed? (assertions that didn't match: expected vs actual) ? Thanks - gist.github.com/dragoonis/f21dce17748b71d45102e42cf331c31a
@PaulDragoonis see qa.php.net/write-test.php#analyzing-failing-tests. You can also pass --show-diff to run-tests.php, to show the diffs in the output. Or set TEST_PHP_JUNIT=report.xml to generate a JUNIT report (also includes diffs for fails).
@NikiC While reading nikic.github.io/2020/05/10/Make-LLVM-fast-again.html a while ago I thought: Should we not have compile-time performance benchmarks (how long does it take to compile a piece of PHP code) and runtime benchmarks (how long does it take to execute a piece of PHP code) as part of CI? Probably not for each push, but maybe nightly? weekly? for tags?
Having official benchmarks to link to would be nice to show improvements (and of course for detecting regressions).
In the olden times it was a Win specific alternative to OPcache; now it offers some additional caching capabilities (e.g. file caching), but I think it mostly abandoned.
@NikiC also a good question, I'm still strugling with some exclusions because the docs are not that clear, but I can ignore warning codes so the report should be more useful, and I also think that due to WSL1 I'm getting some bogus warnings
For the record, I have a strong belief that getting better at having distributed systems, that can be plugged together in interesting ways is a really useful thing to have.
Which reminds me... @PeeHaa @PeeHaa @PeeHaa how is it going?
@cmb Regarding you comment "What about dropping f and q altogether?". Do you mean to only drop these variables or to drop the parameters themselves? I've already managed to drop the f variable.
thanks, I will use show-diff to get a better idea of why tests are failing.
A question to everyone is: for the list of failing tests I linked to, maybe I don't have system libs or exts installed? Is --show-diff be the best way to track this down, or is there a more specific way? Thanks.
@PaulDragoonis if a required ext is missing, the test should be skipped (respective check in SKIPIF section). So yes, I suggest you have a look at the diffs; might be just some system settings (on Windows I get several failures due to German locale and missing priviledges, for instance).
why? I'm not seeing a technical justification for it so far. It's 2020 now, and with PHP8 we don't have the perf issues we had with PHP4. Explain to me what I'm missing. Thank you
@PaulDragoonis Because it is used for pecl extensions, and you suddenly have to think about paths, and autoloading. You change it from a self contained people can just run, to something more complicated.
However one thing I'd love for run-tests to do for PECL extensions is to not ask you to send your report to qa.php.net cause I'm just testing local changes aaaaaaaaaaaaaaaaaaaaaaaaaaa
@PaulDragoonis Sadly I don't even know where the phpize repo is :/
I'm here to re-evaluate the developer experience of our test suite. that's core dev, ext dev and standard users who wish to help in the running of the tests.
If you have a suggestion on how to better manage this situations, do reach out so I can think about it further.
Every time a member of the php community compiles an extension for their project, they run "phpize" in a extension's src dir. Is this the same script? That's what I'm asking.
As per this link - https://github.com/php/php-src/blob/master/scripts/phpize.in#L14
it's already doing run-tests*.php, which tells me there is an opportunity here. Does anyone know of any examples where we have more than run-tests.php, such as run-tests-somtehing.php?
In any case, please do feel free to refactor run-tests.php to reduce global state, but keep the class declarations in the same file. It's really not that hard.
@NikiC The primary factor is the autoloader I think. If you have a good idea how we can autoload arbitrarily named classes from differently named files you're welcome :x
I'm not opposed to putting the utility classes inside run-tests.php itself. If we need to do that, we will.
There's clearly two separate use cases here. a) the creation and maintenance of our test suite: clean separated maintainable code. b) the usage of our test suite for extension developers: a simple process to copy over the test suite files and execute this. phpize already does this for us with its "cp php-tests*.php".
I don't think B needs to compromise on the abilities of A. Nobody is forcing this upon us.
Can someone point me to the script which generates our releases / release candidates? I'dl ike to see the process it goes through when putting everything together. Thanks
@brzuchal no. I have the id already. I just want doctrine to insert the id value that I have generated. The data is actually going to be reused elsewhere in other storage systems, so I don't want to tie it to doctrine directly.
yeah, that's what I want also. it just isn't using my id property.
Okay, I have this xpat to find a element that contains a Text : //span[text()[contains(., 'MyText')]] But if my Text on the website is case sensitive - i.g. mytex - this cannot be found with my approach. How to ignore case sensitivity? I tried "match" but this does not work in browser console for a tes
@Danack Ok, I get it, I though it's similar to my case, but I've never delt with strings instead of Uuid objects, I suppose you've already tried without the @GeneratedValue
Personally I don't think using strings instead of Uuid objects has something to do with infrastruture independent storage mechanisms, I prefer to deal with objects
I cannot remember if this was in the original version of The Pragmatic Programmer or not, (I don't think it was) but good section of the revised version of the book nonetheless. media.pragprog.com/titles/tpp20/inheritance-tax.pdf
guys i am having a brain fart, how do you call code paths that get executed a lot compared to the rest of the program? there's a common way to say it afaik
As per my message here - https://chat.stackoverflow.com/transcript/message/49481148#49481148
I've identified some areas that could allow us to combine our test utility classes into a single file, for including and for easy usage by extensions.
One is in "phpize" when It copies files across to the /ext/ local DIR, so we can do the combining first, then copy over a single file into the /ext/ dir. Another is in our "make" file when it's installing phpize-type programs. Lastly there's a "scripts/dev/genfile" which we use in making our distributions (releases) and that could do a c…
What visualization/tools are we using to consume our JUNIT output right now, for local developers, extension developers, ci systems, members of the community?
@Derick - in your script you are glob()ing over junit files, did you get them pre-created from somewhere? or are you executing run-tests yourself on xdebug code
Anyone ever worked with MultiDimensional eXpressions (MDX)? I don't have a question about them... just curious how often this query language is used among those in our Room 11 group.
@Tiffany depends what you're trying to demonstrate? that particular example is the same as declaring both properties as type A, which in turn is the same as not re-declaring on class B at all: 3v4l.org/tjmRG
@IMSoP I don't plan to use it as an example, but I need to add a description for self and parent, and I realized I had no idea how they worked in the context of typed properties
I was going to combine them on the same table row, but then decided to separate them, though your example makes me think I could probably combine them into the same row again... but probably better to keep them in separate rows so that I can be clear in the descriptions for either.
+--------+-------------------------------------------------------------------------------+
| self | The property must be an instance of the same class in which it's defined.|
+--------+-------------------------------------------------------------------------------+
| parent | The property must be a parent of the class in which it's defined. |
@StatikStasis tried building an example of the two rows with the descriptions, but couldn't get the table formatting correct within SO chat... and I didn't want to edit the message a million times
but optionally could be misconstrued as "inclusion of parent and sub-class" which is... not right
@StatikStasis I prefer concise and clarity. Remove any extraneous words that don't offer anything to explain the situation, while also being as clear as possible.
my current workflow is writing stuff out on paper, scratching out words I don't like, rewriting them on paper, until I find something I like... but I'm beginning to run out of scratch paper
LOL! I do the same thing. I like using the large Ledger paper when I am in a meeting because it gives me plenty of room to write for a long time while they're talking during meetings.
I do the same thing for coding. Always on paper first.
if you don;t have it then a request for /foo/bar/baz/quz.html will generate stat("/foo/bar/baz/.htaccess"); stat("/foo/bar/.htaccess"); stat("/foo/.htaccess"); stat("/.htaccess"); for every request (maybe others)
gmfdi I want to go to a nightclub and dance around like a prick less than 2m away from other ppl
at least the pub in the village has starting selling pints again, albeit in plastic glasses and you have to go sit on the field over the road but it's better than nowt
@DaveRandom do you want someone to run a hose over the field for a few hours, so you can recreate that classic glastonbury "what even is a solid surface anyway" vibe?
@brzuchal it turns out I had a left over @generatedValue annotation on another property that was not needed, and generatedvalue annotations affect the class id, regardless of what property they are on. Deleting the bogus one has fixed the problem.
@cmb thanks for this. I do prefer to squash my commits on this particular PR, since they're just duplicates :) If I was making commits across a few different contexts then perhaps multi-commits would be valuable :-)
Cool. I'll say more about the general idea another time....but as I said before, I think one of the things the PHP project has done wrong is just making it difficult to share information. Even just having things like "which votes are going to be opened soon" would be a useful thing to have as a datasource, and then have that info piped to other places (like this room), rather than having the info hidden away.
@cmb I may need your help to setup a GitLab CI pipeline for a Windows build to run PVS-Studio on it, as it looks like on the Linux build no issues are found (or you could run a build localy first before I try to go throught the hassle...)