Skip to content
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

[jqplotchart] Internal error: Class "ResourceLoader" not found #852

Closed
jongfeli opened this issue Oct 15, 2024 · 4 comments · Fixed by #855
Closed

[jqplotchart] Internal error: Class "ResourceLoader" not found #852

jongfeli opened this issue Oct 15, 2024 · 4 comments · Fixed by #855
Labels
bug MW 1.43 MediaWiki 1.43 (LTS)

Comments

@jongfeli
Copy link

jongfeli commented Oct 15, 2024

Setup

MediaWiki : 1.43.0-alpha (d521558)
PHP : 8.3.12 (apache2handler)
ICU : 72.1
MariaDB : 11.4.0-MariaDB
Pygments : 2.15.1
Elasticsearch : 7.10.2
Semantic MediaWiki : 5.0.0-alpha (dev-master)
Semantic Result Formats 4.2.1 (dev-master)

Issue

I am aware that SRF & SMW are not compatible with MW-1.43 yet but when using jqplotchart or any other chart type or datatables then "Internal error: Class "ResourceLoader" not found" pops up and the page is not saved. We are testing on MW-1.43 (future LTS) on PHP 8.1 and PHP 8.3 I can not get PHP 8.2 to work under windows.

Steps to reproduce

{{#ask:[[Category:SomeCategory]][[SomeProperty::true]]
| ?SomeValue
| format             = jqplotchart
| link               = all
| headers            = show
| searchlabel        = … further results
| distributionsort   = none
| direction          = vertical
| numbersaxislabel   = Some Label
| height             = 300
| width              = 100%
| valueformat        =
| ticklabels         = 1
| theme              = vector
| filling            = 1
| chartlegend        = none
| datalabels         = value
| charttype          = bar
| sort               = SomeValue
| order              = desc
| limit              = 100
| min                = 0
| charttitle         = Some Title
}}

Expected result: ...

Observed result:
See below.

Stacktrace

[f92d7fa3c91d4944e6d3199c] /testwiki/index.php?title=Sandbox&action=submit Error: Class "ResourceLoader" not found
Backtrace:

from C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticResultFormats\SemanticResultFormats.utils.php(79)
#0 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticResultFormats\formats\jqplot\SRF_jqPlotChart.php(61): SRFUtils::makeVariablesScript()
#1 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\Query\ResultPrinters\AggregatablePrinter.php(109): SRFjqPlotChart->getFormatOutput()
#2 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\Query\ResultPrinters\ResultPrinter.php(337): SMW\Query\ResultPrinters\AggregatablePrinter->getResultText()
#3 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\Query\ResultPrinters\ResultPrinter.php(302): SMW\Query\ResultPrinters\ResultPrinter->buildResult()
#4 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\includes\query\SMW_QueryProcessor.php(344): SMW\Query\ResultPrinters\ResultPrinter->getResult()
#5 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\ParserFunctions\AskParserFunction.php(363): SMWQueryProcessor::getResultFromQuery()
#6 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\ParserFunctions\AskParserFunction.php(200): SMW\ParserFunctions\AskParserFunction->doFetchResultsFromFunctionParameters()
#7 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\ParserFunctionFactory.php(392): SMW\ParserFunctions\AskParserFunction->parse()
#8 C:\Program Files\Apache\htdocs\testwiki\includes\parser\Parser.php(3446): SMW\ParserFunctionFactory->SMW\{closure}()
#9 C:\Program Files\Apache\htdocs\testwiki\includes\parser\Parser.php(3129): MediaWiki\Parser\Parser->callParserFunction()
#10 C:\Program Files\Apache\htdocs\testwiki\includes\parser\PPFrame_Hash.php(276): MediaWiki\Parser\Parser->braceSubstitution()
#11 C:\Program Files\Apache\htdocs\testwiki\includes\parser\Parser.php(2963): PPFrame_Hash->expand()
#12 C:\Program Files\Apache\htdocs\testwiki\includes\parser\Parser.php(1611): MediaWiki\Parser\Parser->replaceVariables()
#13 C:\Program Files\Apache\htdocs\testwiki\includes\parser\Parser.php(713): MediaWiki\Parser\Parser->internalParse()
#14 C:\Program Files\Apache\htdocs\testwiki\includes\content\WikitextContentHandler.php(384): MediaWiki\Parser\Parser->parse()
#15 C:\Program Files\Apache\htdocs\testwiki\includes\content\ContentHandler.php(1692): MediaWiki\Content\WikitextContentHandler->fillParserOutput()
#16 C:\Program Files\Apache\htdocs\testwiki\includes\content\Renderer\ContentRenderer.php(79): MediaWiki\Content\ContentHandler->getParserOutput()
#17 C:\Program Files\Apache\htdocs\testwiki\includes\Revision\RenderedRevision.php(263): MediaWiki\Content\Renderer\ContentRenderer->getParserOutput()
#18 C:\Program Files\Apache\htdocs\testwiki\includes\Revision\RenderedRevision.php(236): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached()
#19 C:\Program Files\Apache\htdocs\testwiki\includes\Revision\RevisionRenderer.php(239): MediaWiki\Revision\RenderedRevision->getSlotParserOutput()
#20 C:\Program Files\Apache\htdocs\testwiki\includes\Revision\RevisionRenderer.php(172): MediaWiki\Revision\RevisionRenderer->combineSlotOutput()
#21 [internal function]: MediaWiki\Revision\RevisionRenderer->MediaWiki\Revision\{closure}()
#22 C:\Program Files\Apache\htdocs\testwiki\includes\Revision\RenderedRevision.php(199): call_user_func()
#23 C:\Program Files\Apache\htdocs\testwiki\includes\Storage\DerivedPageDataUpdater.php(1451): MediaWiki\Revision\RenderedRevision->getRevisionParserOutput()
#24 [internal function]: MediaWiki\Storage\DerivedPageDataUpdater->getCanonicalParserOutput()
#25 C:\Program Files\Apache\htdocs\testwiki\includes\edit\PreparedEdit.php(97): call_user_func()
#26 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\MediaWiki\EditInfo.php(100): MediaWiki\Edit\PreparedEdit->getOutput()
#27 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\MediaWiki\Hooks\RevisionFromEditComplete.php(83): SMW\MediaWiki\EditInfo->fetchEditInfo()
#28 C:\Program Files\Apache\htdocs\testwiki\extensions\SemanticMediaWiki\src\MediaWiki\Hooks.php(600): SMW\MediaWiki\Hooks\RevisionFromEditComplete->process()
#29 C:\Program Files\Apache\htdocs\testwiki\includes\HookContainer\HookContainer.php(159): SMW\MediaWiki\Hooks->onRevisionFromEditComplete()
#30 C:\Program Files\Apache\htdocs\testwiki\includes\HookContainer\HookRunner.php(3332): MediaWiki\HookContainer\HookContainer->run()
#31 C:\Program Files\Apache\htdocs\testwiki\includes\Storage\PageUpdater.php(1394): MediaWiki\HookContainer\HookRunner->onRevisionFromEditComplete()
#32 C:\Program Files\Apache\htdocs\testwiki\includes\Storage\PageUpdater.php(932): MediaWiki\Storage\PageUpdater->doModify()
#33 C:\Program Files\Apache\htdocs\testwiki\includes\editpage\EditPage.php(2524): MediaWiki\Storage\PageUpdater->saveRevision()
#34 C:\Program Files\Apache\htdocs\testwiki\includes\editpage\EditPage.php(1798): MediaWiki\EditPage\EditPage->internalAttemptSavePrivate()
#35 C:\Program Files\Apache\htdocs\testwiki\includes\editpage\EditPage.php(729): MediaWiki\EditPage\EditPage->attemptSave()
#36 C:\Program Files\Apache\htdocs\testwiki\includes\actions\EditAction.php(66): MediaWiki\EditPage\EditPage->edit()
#37 C:\Program Files\Apache\htdocs\testwiki\includes\actions\SubmitAction.php(38): EditAction->show()
#38 C:\Program Files\Apache\htdocs\testwiki\includes\actions\ActionEntryPoint.php(733): SubmitAction->show()
#39 C:\Program Files\Apache\htdocs\testwiki\includes\actions\ActionEntryPoint.php(510): MediaWiki\Actions\ActionEntryPoint->performAction()
#40 C:\Program Files\Apache\htdocs\testwiki\includes\actions\ActionEntryPoint.php(146): MediaWiki\Actions\ActionEntryPoint->performRequest()
#41 C:\Program Files\Apache\htdocs\testwiki\includes\MediaWikiEntryPoint.php(200): MediaWiki\Actions\ActionEntryPoint->execute()
#42 C:\Program Files\Apache\htdocs\testwiki\index.php(58): MediaWiki\MediaWikiEntryPoint->run()
#43 {main}
@jaideraf jaideraf added MW 1.43 MediaWiki 1.43 (LTS) bug labels Oct 15, 2024
@jaideraf jaideraf changed the title Internal error: Class "ResourceLoader" not found [jqplotchart] Internal error: Class "ResourceLoader" not found Oct 20, 2024
JLTRY pushed a commit to JLTRY/SemanticResultFormats that referenced this issue Oct 29, 2024
JLTRY pushed a commit to JLTRY/SemanticResultFormats that referenced this issue Oct 29, 2024
…urceLoader" not found

sort the use statements
@jongfeli
Copy link
Author

I just tested SemanticResultFormats master and the datatables format is fixed, it works but the jqplot format still gives Error: Class "ResourceLoader" not found. I also mentioned this in #855 some time ago. I am happy to do some tests or send info if needed, so please let me know.

@jongfeli
Copy link
Author

jongfeli commented Dec 9, 2024

Ping @jaideraf should I create a new issue?

@jaideraf
Copy link
Member

jaideraf commented Dec 9, 2024

No need. I am just reopening this one.

@jaideraf jaideraf reopened this Dec 9, 2024
@jongfeli
Copy link
Author

jongfeli commented Jan 6, 2025

This is no longer a problem anymore, all is working fine now. This seems to be solved in #896

@jaideraf jaideraf closed this as completed Jan 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug MW 1.43 MediaWiki 1.43 (LTS)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants