Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I've just moved the code back from the sandbox, and when running the D8 tests on the d.o test bot for the first time I got a lot of errors. Running locally, everything is fine, and the last Travis builds also didn't show these errors (they only had an issue with the very long-running processor integration test).
So, I guess we should soon investigate what could be behind this, what differences there are in d.o's testbot environment, etc., and fix those incompatibilities so we can have proper testing integration in the D8 issue queue as well.
Comment | File | Size | Author |
---|---|---|---|
#30 | 2386357-30-interdiff.txt | 446 bytes | Berdir |
#30 | 2386357-30.patch | 26.36 KB | Berdir |
#29 | 2386357-29-interdiff.txt | 3.43 KB | Berdir |
#29 | 2386357-29.patch | 25.93 KB | Berdir |
#27 | 2386357-25-interdiff.txt | 1009 bytes | Berdir |
Comments
Comment #2
drunken monkeyTried the solution Berdir mentions in #2386309-1: Views query plugin does not check for aborted in build() method. Cross your fingers …
Comment #3
BerdirWe found the reason for this, see #2372745: KernelTestBase ignores extensions in site-specific directories
Comment #4
drunken monkeyHm, no, it seems that didn't help at all … :-/
Comment #5
drunken monkeyAh, OK, great! So that causes all our test failures? (OK, all except the new
ProcessorIntegrationTest
failures I just saw locally …)However, I don't really understand the issue. Is the fix of moving the test modules to the root directory of the module still necessary, or can I revert that?
Comment #6
BerdirNot sure, moving it worked for us, if it doesn't for you then you can probably move it back. Hard to test.
Comment #7
BerdirThe mentioned core issue was committed today.
I think there are valid test fails now as well, e.g. related to config schema validation. That is now strict by default.
Comment #8
BerdirYep, looking at https://qa.drupal.org/pifr/test/577238, all I can see there right now are schema validation failures.
Comment #9
Nick_vhStarted fixing the schema errors and some other annoying errors that I came across when trying to fix the tests.
Comment #10
BerdirComment #12
Nick_vhReversed patch...
Comment #13
Nick_vhno needs review needed yet. Tests won't pass yet.
Comment #14
drunken monkeyAre you currently working on this, or is there a newer version? Otherwise I'd now have the time to work on this myself. (It's probably a good idea to first fix all of this before tackling other issues.)
Comment #15
Nick_vhIf you want to work on this, please take the patch and improve and post back. That way we can iteratively fix the test failures. Mostly they are schema inconsistencies.
Comment #16
Nick_vhComment #17
drunken monkeySorry, won't have the time after all, just got a pretty time-intensive project for the next weeks.
I'll see what I can do, but probably I won't have time to work on D8 again until March. :-/ (I'll try to commit any patches you come up with, though – otherwise please ping me via mail!)
Comment #18
BerdirWorked a bit on this.
Comment #20
BerdirThis should be close. Can't reproduce the local task test fails locally, but I've seen them elsewhere too.
The test failures in IntegrationTest were annoying. It was all the bundles schema. It was integer, but that was wishful thinking, what we actually store are strings, because checkboxes. Casting that to integer resulted in them being stored as 0. I also tried boolean, which I think we would be correct, but *that* broke change tracking in the setConfiguration() method, maybe we could fix that too, but I gave up and just went with string for now.
Will comment a bit on my changes in a self-review.
Comment #21
BerdirThis works now :)
Did not even notice that it was in fact string before, should probably revert the label too?
I think those @todo additions and removals were added by Nick, didn't track them down, not sure why we remove some and add others.
Unneeded changes.
The fact that we have to add the key inside is a bit annoying, also the fact that this behavior is currently only in the form (and now here).
What the todo says, I followed the lead of submitForm() here, but I don't think it is correct.
This was one of the many wrong leads that I followed with IntegrationTest. The weird part about the index edit form is that we call the submit methods on the plugins, let them update their configuration, but then don't core about that. The reason it worked is because we got the values mapped into datasource_configs directly from the form values. So if a plugin wants to convert something (e.g., checkbox values to bool), we would never see that.
This means that we set it twice now. Core has similar weird behavior with block settings, they are also set through the default entity form behavior and through the plugins. There it works automatically through plugin collections, maybe we should use that in search api too, but those changes are not trivial and it wouldn't really change something.
I changed this because it eat the config schema exceptions. I'm not sure why exactly we are catching all exceptions here and are displaying only a generic error message, and what exception we should catch, but I left it for now.
No idea why this is removed?
More unneeded changes.
I only fixed the condition here, was if (!array($stopwords), no idea what that was supposed to do :)
Also not sure why this is even necessary, when is it not an array?
Comment #23
BerdirUff, that was real scary. Something super weird happend when serializing and unseralizing the $processors array in $form_state. So I refactored it to only keep it that between validate and submit, and also some more changes there to avoid saving settings for disabled sensors, because they have not been validate/processed.
Still no idea about LocalTasksTest, I've seen that fail before, but it is working fine for me now, in UI, run-test.sh, phpunit, locally and on the server that is running http://d8ms.worldempire.ch/, as visible there, and I saw it failing there as well some days ago. So wth?
Comment #24
BerdirWrong patches.
Comment #26
BerdirThe new test fail is easy to fix. But I'm officially giving up on LocalTasksTest. I suggest to disable/drop that and open an issue to figure out what is going on and enable it again.
Comment #27
Berdirinterdiff was wrong.
Comment #29
BerdirMore core changes...
Comment #30
BerdirAnd here is a patch that disables that test. not sure if that will actually work with testbot. Otherwise we have to drop the class.
Comment #33
drunken monkeySee #2383093-8: Fix saving of "Fields" settings on processors: I already discovered and fixed that.
And with #2349435-27: Seperate filters/processors by stage still awaiting reviews, we now have two monster patches, partially fixing the same things and, pretty surely, often touching the same code. Also really scary.
But since this fixes all the tests and makes the test bot happy again, I guess comitting this right away makes the most sense. I'll just have to find the time to do a merge with the other branch again – probably not before the week after next, though. (If someone else feels strong enough, that would of course be a great help! But, in any case, better not work on something large other than that merge for now – don't want to create another big patch needing to be merged.) At that point I'll also review this patch properly – I sadly don't have the time right now.
Anyways, thanks a lot for your help, must have been quite some work!
Committed.
Thanks again!
Also thanks to Nick for providing the initial patches!
Comment #36
BerdirYay! :)
Seeing all those old issues being re-opened by the testbot, looks like we have a green search_api 8.x-1.x branch in the main project for the first time :)