-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes regression added while fixing Bug #72740 #16
Conversation
Hi @glensc, TIA, |
@scara LGTM; altho as expressed elsewhere, it would be cleaner if |
TNX @glensc I agree w/ you:
Will do the planned squashing late my evening. HTH, |
Fixed regression added in b1b44e0 while working on #72740
254c224
to
320fb73
Compare
Hi @glensc, I've added a ref to this PR even in the original bug, https://bugs.php.net/bug.php?id=72740#1562881713. HTH, |
Hi @glensc, TIA, |
@scara I'm nobody in pecl/php/pecl-solr scope, sorry ;) you need to reach maintainers somehow. I can only encourage maintainers (with this comment) that this PR looks ok for me and should be merged into 2.5.1 patch release |
Still wondering why after 7 months the PR is still at this stage, without a peer review from the maintainers. BTW TNX to @glensc for the time spent on helping me, really appreciated! Matteo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks
Hi, is there any scheduled planned for this, say 2.6.0 or 2.5.1 or anything? Having to build solr everywhere with the patch applied, because the upstream version simply doesn't work ok, or having to force boost values as a workaround aren't really the best options. That said by an ignorant that knows nothing about the internals, just the experience is suboptimal, I'm afraid. Many thanks for all the work with this awesome extension, much appreciated! Ciao :-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment on behalf of omars at php.net: merged |
With the release of php-solr 2.5.1 (20200909) we can be back to the upstream extension. The problems in previous version (see php/pecl-search_engine-solr#16) have been fixed and it should work as is. This comes with php71, 72, 73, 74 and 80 support.
With the release of php-solr 2.5.1 (20200909) we can be back to the upstream extension. The problems in previous version (see php/pecl-search_engine-solr#16) have been fixed and it should work as is. This comes with php71, 72, 73, 74 and 80 support.
With the release of php-solr 2.5.1 (20200909) we can be back to the upstream extension. The problems in previous version (see php/pecl-search_engine-solr#16) have been fixed and it should work as is. This comes with php71, 72, 73, 74 and 80 support.
With the release of php-solr 2.5.1 (20200909) we can be back to the upstream extension. The problems in previous version (see php/pecl-search_engine-solr#16) have been fixed and it should work as is. This comes with php71, 72, 73, 74 and 80 support.
With the release of php-solr 2.5.1 (20200909) we can be back to the upstream extension. The problems in previous version (see php/pecl-search_engine-solr#16) have been fixed and it should work as is. This comes with php71, 72, 73, 74 and 80 support.
With the release of php-solr 2.5.1 (20200909) we can be back to the upstream extension. The problems in previous version (see php/pecl-search_engine-solr#16) have been fixed and it should work as is. This comes with php71, 72, 73, 74 and 80 support.
HI @0mars,
b1b44e0#diff-ab0834017b5c60ae382501bce9a32bbc added a breaking regression when using Query Fields qith no boost value due to a "NUL byte issue".
It has been there since 2.5 years ago: most of - i.e. not all - the package maintainers in several distro were still using 2.4.0 with just few patches for 7.2 compat.
Test coverage was unfortunately incomplete to highlight the
#0;
issue in theqf
parameter.2.5.0 is finally out and using it under the condition above breaks any expected response; the improved test now shows the issue:
# make test TESTS="--show-all tests/bug_72740.phpt" [cut] ========DIFF======== 016+ [qf] => score#0; manufacturedate_dt#0; 016- [qf] => score^ manufacturedate_dt^ ========DONE========
Long story short, I discovered this issue since months in a project called Moodle within the context of its CI Docker Toolbox: you can read more in moodlehq/moodle-php-apache#16 and moodlehq/moodle-php-apache#19 but limited spare time and the availability of workarounds kept me far from proposing kind of fix, waiting for the release of 2.5.0.
On 7/7 I found some spare time to explore the code and to propose a quick fix to highlight where the problem was (scara@c2c94b4) and posted it into https://bugs.php.net/bug.php?id=75631: @glensc was kind enough to do a quick peer review (really appreciated!).
I've decided to keep the initial quick fix in this PR since it looks like the way the code is actually managing the NULL byte check, even if @glensc is super right in suggesting a better refactoring which IMHO should be done at any level in the code to remove the pattern of checking for the value to be
NULL
and then viastrlen() > 0
since it has been initialized with an empty string i.e.\0
.For the record, https://bugs.php.net/bug.php?id=72740 is still open even if it has been already "addressed".
HTH,
Matteo