No Code Attached Yet Information Required bug
avatar crystalenka
crystalenka
26 Jan 2023

Steps to reproduce the issue

  1. Set up a blank Joomla installation and install an additional language of your choice.
  2. Install multilingual sample data.
  3. Go to Smart Search > Index > and then click the "Index" button.
  4. If it works as expected, go to options, change something in the index settings, and then try again.

Expected result

Site is indexed.

Actual result

Frozen index modal which never errors out or succeeds. (I've left it for something like 15-20 minutes just in case.)

Screenshot 2023-01-26 at 11 59 50

Not sure if the background indexing is okay and the modal just gets stuck.

Possibly related console error:

[Error] SyntaxError: JSON Parse error: Unrecognized token '<'
	parse (indexer.min.js:1:2366)
	onSuccess (indexer.min.js:1:2366)
	(anonymous function) (core.min.js:1:6230)

Possibly related PHP notice:

PHP Deprecated:  Locale::getPrimaryLanguage(): Passing null to parameter #1 ($locale) of type string is deprecated in /administrator/components/com_finder/src/Indexer/Helper.php on line 357

System information (as much as possible)

PHP 8.1
Joomla 4.2.6 and 4.2.7-RC2

Additional comments

Doesn't always happen, I haven't been able to pin down the conditions in which it happens vs it doesn't.

avatar crystalenka crystalenka - open - 26 Jan 2023
avatar joomla-cms-bot joomla-cms-bot - change - 26 Jan 2023
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 26 Jan 2023
avatar brianteeman
brianteeman - comment - 26 Jan 2023

have you tried "enable logging" in the finder component options. Might give some clues.

avatar crystalenka
crystalenka - comment - 26 Jan 2023

I've done that now and tried again, but not sure where to find the log.

avatar brianteeman
brianteeman - comment - 26 Jan 2023

No idea either - I would assume administrator/logs

You also get some more detailed info if you have debug on when running the index iirc

avatar crystalenka
crystalenka - comment - 26 Jan 2023

Found it.

This is what's logged within a few seconds after I clear the index and start from scratch:

2023-01-26T10:19:20+00:00	INFO ::1	-	Starting the indexer
2023-01-26T10:19:20+00:00	INFO ::1	-	Starting the indexer batch process
2023-01-26T10:19:20+00:00	INFO ::1	-	Batch completed, peak memory usage: 6,291,456 bytes

So it appears that the index works fine, but something funky is happening with the modal as it's still frozen like in my screenshot above.

You also get some more detailed info if you have debug on when running the index iirc

Interesting! Will try that next.

avatar crystalenka
crystalenka - comment - 26 Jan 2023

Modal is still frozen with debug on, with additional frozen debug info haha:

Screenshot 2023-01-26 at 12 22 23

I'm going to guess this is some kind of javascript error based on the error in the console.

avatar wilsonge
wilsonge - comment - 29 Jan 2023

From your error it's more likely the php warning to be honest. If you look in the network tab of dev tools

image

Filter by XHR requests to make life easier you should be able to see the raw response coming back from the server and which one isn't valid JSON. Sorry I've tried reproducing on my PHP 8.1 setup and can't seem to reproduce with error reporting on maximum :( otherwise would do it myself!

avatar Hackwar Hackwar - change - 22 Feb 2023
Labels Added: bug
avatar Hackwar Hackwar - labeled - 22 Feb 2023
avatar Hackwar
Hackwar - comment - 28 Feb 2023

@crystalenka Did you check this again?

avatar Hackwar Hackwar - change - 28 Feb 2023
Labels Added: Information Required
avatar Hackwar Hackwar - labeled - 28 Feb 2023
avatar crystalenka
crystalenka - comment - 28 Feb 2023

@Hackwar it's on my list for today :)

avatar Hackwar
Hackwar - comment - 28 Feb 2023

We have a fix in #39965. Closing this one. :-)

avatar Hackwar Hackwar - close - 28 Feb 2023
avatar Hackwar Hackwar - change - 28 Feb 2023
Status New Closed
Closed_Date 0000-00-00 00:00:00 2023-02-28 11:45:21
Closed_By Hackwar
avatar wilsonge
wilsonge - comment - 1 Mar 2023

This stops the output from hard crashing but doesn't solve @crystalenka 's underlying root cause of some sort of php error so would still be good to get that info please Crystal!

Add a Comment

Login with GitHub to post a comment