I have the same issue. I just updated my Test-Installation of Flarum an ran into the same error with s9e/sweetdom
.
While updating s9e/sweetdom
went from 2.1.2
to 3.2.0
. I am not exactly sure if Flarum itself requires this or if it is an extension. I tried disabling FoF Formatting but this does not fix the issue.
Loading composer repositories with package information
Updating dependencies
Lock file operations: 1 install, 13 updates, 0 removals
- Locking carbonphp/carbon-doctrine-types (1.0.0)
- Upgrading flarum/approval (v1.8.0 => v1.8.1)
- Upgrading guzzlehttp/guzzle (7.8.0 => 7.8.1)
- Upgrading guzzlehttp/promises (2.0.1 => 2.0.2)
- Upgrading guzzlehttp/psr7 (2.6.1 => 2.6.2)
- Upgrading nesbot/carbon (2.71.0 => 2.72.0)
- Upgrading s9e/sweetdom (2.1.2 => 3.2.0)
- Upgrading s9e/text-formatter (2.14.3 => 2.15.0)
- Upgrading symfony/console (v5.4.31 => v5.4.32)
- Upgrading symfony/css-selector (v6.3.2 => v6.4.0)
- Upgrading symfony/filesystem (v6.3.1 => v6.4.0)
- Upgrading symfony/http-foundation (v5.4.31 => v5.4.32)
- Upgrading symfony/string (v6.3.8 => v6.4.0)
- Upgrading tijsverkoyen/css-to-inline-styles (2.2.6 => v2.2.7)
Flarum Error Log:
[2023-12-08 16:17:58] flarum.ERROR: TypeError: s9e\SweetDOM\Document::query(): Return value must be of type DOMNodeList, bool returned in /var/www/example.com/flarum/vendor/s9e/sweetdom/src/Document.php:75
Stack trace:
#0 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Configurator/TemplateNormalizations/AbstractNormalization.php(73): s9e\SweetDOM\Document->query()
#1 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Configurator/TemplateNormalizations/AbstractNormalization.php(43): s9e\TextFormatter\Configurator\TemplateNormalizations\AbstractNormalization->getNodes()
#2 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Configurator/TemplateNormalizer.php(146): s9e\TextFormatter\Configurator\TemplateNormalizations\AbstractNormalization->normalize()
#3 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Configurator/Items/Template.php(165): s9e\TextFormatter\Configurator\TemplateNormalizer->normalizeTemplate()
#4 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Configurator/TemplateNormalizer.php(124): s9e\TextFormatter\Configurator\Items\Template->normalize()
#5 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Plugins/BBCodes/Configurator.php(162): s9e\TextFormatter\Configurator\TemplateNormalizer->normalizeTag()
#6 /var/www/example.com/flarum/vendor/s9e/text-formatter/src/Plugins/BBCodes/Configurator.php(140): s9e\TextFormatter\Plugins\BBCodes\Configurator->addFromConfig()
#7 /var/www/example.com/flarum/vendor/flarum/bbcode/src/Configure.php(31): s9e\TextFormatter\Plugins\BBCodes\Configurator->addFromRepository()
#8 /var/www/example.com/flarum/vendor/flarum/bbcode/src/Configure.php(18): Flarum\BBCode\Configure->addTagsFromRepositories()
#9 /var/www/example.com/flarum/vendor/flarum/core/src/Foundation/ContainerUtil.php(30): Flarum\BBCode\Configure->__invoke()
#10 /var/www/example.com/flarum/vendor/flarum/core/src/Formatter/Formatter.php(177): Flarum\Foundation\ContainerUtil::Flarum\Foundation\{closure}()
#11 /var/www/example.com/flarum/vendor/flarum/core/src/Formatter/Formatter.php(213): Flarum\Formatter\Formatter->getConfigurator()
#12 /var/www/example.com/flarum/vendor/illuminate/cache/Repository.php(426): Flarum\Formatter\Formatter->Flarum\Formatter\{closure}()
#13 /var/www/example.com/flarum/vendor/flarum/core/src/Formatter/Formatter.php(214): Illuminate\Cache\Repository->rememberForever()
#14 /var/www/example.com/flarum/vendor/flarum/core/src/Formatter/Formatter.php(257): Flarum\Formatter\Formatter->getComponent()
#15 /var/www/example.com/flarum/vendor/flarum/core/src/Forum/ForumServiceProvider.php(112): Flarum\Formatter\Formatter->getJs()
#16 [internal function]: Flarum\Forum\ForumServiceProvider->Flarum\Forum\{closure}()
#17 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Compiler/Source/StringSource.php(38): call_user_func()
#18 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Compiler/Source/StringSource.php(49): Flarum\Frontend\Compiler\Source\StringSource->getContent()
#19 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Compiler/RevisionCompiler.php(174): Flarum\Frontend\Compiler\Source\StringSource->getCacheDifferentiator()
#20 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Compiler/RevisionCompiler.php(71): Flarum\Frontend\Compiler\RevisionCompiler->calculateRevision()
#21 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Content/Assets.php(105): Flarum\Frontend\Compiler\RevisionCompiler->commit()
#22 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Content/Assets.php(63): Flarum\Frontend\Content\Assets->forceCommit()
#23 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Frontend.php(62): Flarum\Frontend\Content\Assets->__invoke()
#24 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Frontend.php(54): Flarum\Frontend\Frontend->populate()
#25 /var/www/example.com/flarum/vendor/flarum/core/src/Frontend/Controller.php(32): Flarum\Frontend\Frontend->document()
#26 /var/www/example.com/flarum/vendor/flarum/core/src/Http/RouteHandlerFactory.php(41): Flarum\Frontend\Controller->handle()
#27 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ExecuteRoute.php(27): Flarum\Http\RouteHandlerFactory->Flarum\Http\{closure}()
#28 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ExecuteRoute->process()
#29 /var/www/example.com/flarum/vendor/fof/terms/src/Middlewares/RegisterMiddleware.php(59): Laminas\Stratigility\Next->handle()
#30 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): FoF\Terms\Middlewares\RegisterMiddleware->process()
#31 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ContentTypeOptionsHeader.php(21): Laminas\Stratigility\Next->handle()
#32 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ContentTypeOptionsHeader->process()
#33 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ReferrerPolicyHeader.php(30): Laminas\Stratigility\Next->handle()
#34 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ReferrerPolicyHeader->process()
#35 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/FlarumPromotionHeader.php(30): Laminas\Stratigility\Next->handle()
#36 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\FlarumPromotionHeader->process()
#37 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ShareErrorsFromSession.php(57): Laminas\Stratigility\Next->handle()
#38 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ShareErrorsFromSession->process()
#39 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/CheckCsrfToken.php(36): Laminas\Stratigility\Next->handle()
#40 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\CheckCsrfToken->process()
#41 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ResolveRoute.php(69): Laminas\Stratigility\Next->handle()
#42 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ResolveRoute->process()
#43 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/SetLocale.php(51): Laminas\Stratigility\Next->handle()
#44 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\SetLocale->process()
#45 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/AuthenticateWithSession.php(31): Laminas\Stratigility\Next->handle()
#46 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\AuthenticateWithSession->process()
#47 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/RememberFromCookie.php(52): Laminas\Stratigility\Next->handle()
#48 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\RememberFromCookie->process()
#49 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/StartSession.php(61): Laminas\Stratigility\Next->handle()
#50 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\StartSession->process()
#51 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/CollectGarbage.php(46): Laminas\Stratigility\Next->handle()
#52 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\CollectGarbage->process()
#53 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ParseJsonBody.php(28): Laminas\Stratigility\Next->handle()
#54 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ParseJsonBody->process()
#55 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/HandleErrors.php(57): Laminas\Stratigility\Next->handle()
#56 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\HandleErrors->process()
#57 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/InjectActorReference.php(25): Laminas\Stratigility\Next->handle()
#58 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\InjectActorReference->process()
#59 /var/www/example.com/flarum/vendor/fof/merge-discussions/src/Middleware/Redirection.php(28): Laminas\Stratigility\Next->handle()
#60 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): FoF\MergeDiscussions\Middleware\Redirection->process()
#61 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(75): Laminas\Stratigility\Next->handle()
#62 /var/www/example.com/flarum/vendor/middlewares/request-handler/src/RequestHandler.php(84): Laminas\Stratigility\MiddlewarePipe->process()
#63 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Middlewares\RequestHandler->process()
#64 /var/www/example.com/flarum/vendor/middlewares/base-path-router/src/BasePathRouter.php(101): Laminas\Stratigility\Next->handle()
#65 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Middlewares\BasePathRouter->process()
#66 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Middleware/OriginalMessages.php(36): Laminas\Stratigility\Next->handle()
#67 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Laminas\Stratigility\Middleware\OriginalMessages->process()
#68 /var/www/example.com/flarum/vendor/middlewares/base-path/src/BasePath.php(73): Laminas\Stratigility\Next->handle()
#69 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Middlewares\BasePath->process()
#70 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Middleware/ProcessIp.php(24): Laminas\Stratigility\Next->handle()
#71 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/Next.php(49): Flarum\Http\Middleware\ProcessIp->process()
#72 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(75): Laminas\Stratigility\Next->handle()
#73 /var/www/example.com/flarum/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(64): Laminas\Stratigility\MiddlewarePipe->process()
#74 /var/www/example.com/flarum/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php(73): Laminas\Stratigility\MiddlewarePipe->handle()
#75 /var/www/example.com/flarum/vendor/flarum/core/src/Http/Server.php(45): Laminas\HttpHandlerRunner\RequestHandlerRunner->run()
#76 /var/www/example.com/flarum/public/index.php(26): Flarum\Http\Server->listen()
# php flarum info
Flarum core: 1.8.3
PHP version: 8.1.2-1ubuntu2.14
MySQL version: 8.0.35-0ubuntu0.22.04.1
Loaded extensions: Core, date, libxml, openssl, pcre, zlib, filter, hash, json, pcntl, Reflection, SPL, session, standard, sodium, mysqlnd, PDO, xml, bz2, calendar, ctype, curl, dom, mbstring, FFI, fileinfo, ftp, gd, gettext, iconv, imagick, intl, exif, mysqli, pdo_mysql, Phar, posix, readline, shmop, SimpleXML, sockets, sysvmsg, sysvsem, sysvshm, tokenizer, xmlreader, xmlwriter, xsl, zip, Zend OPcache
+--------------------------------------+------------+------------------------------------------+
| Flarum Extensions | | |
+--------------------------------------+------------+------------------------------------------+
| ID | Version | Commit |
+--------------------------------------+------------+------------------------------------------+
| flarum-flags | v1.8.0 | |
| flarum-bbcode | v1.8.0 | |
| flarum-suspend | v1.8.1 | |
| flarum-approval | v1.8.1 | |
| flarum-tags | v1.8.0 | |
| fof-formatting | 1.0.3 | |
| wolfgang-demeter-bbcode-5star-rating | dev-main | 57722d46957880ba45cce5a1e628ef51bb9237ab |
| wolfgang-demeter-amazon-product-api | dev-main | 103a697272450f99fe2fb223aaec2c668e72730b |
| fof-user-bio | 1.3.1 | |
| fof-upload | 1.4.7 | |
| fof-terms | 1.3.0 | |
| fof-split | 1.1.1 | |
| fof-socialprofile | 1.1.6 | |
| fof-recaptcha | 1.3.1 | |
| fof-pages | 1.0.8 | |
| fof-merge-discussions | 1.4.1 | |
| fof-links | 1.2.1 | |
| fof-byobu | 1.3.4 | |
| fof-amazon-affiliation | 1.1.0 | |
| flarum-subscriptions | v1.8.0 | |
| flarum-sticky | v1.8.0 | |
| flarum-statistics | v1.8.0 | |
| flarum-nicknames | v1.8.0 | |
| flarum-mentions | v1.8.2 | |
| flarum-markdown | v1.8.0 | |
| flarum-lock | v1.8.0 | |
| flarum-likes | v1.8.0 | |
| flarum-lang-german | dev-master | |
| flarum-lang-english | v1.8.0 | |
| datlechin-birthdays | v2.0.1 | |
| askvortsov-auto-moderator | v0.1.3 | |
| antoinefr-bbcode-fa | v1.0.0 | |
+--------------------------------------+------------+------------------------------------------+
Base URL: https://dev.example.com
Installation path: /var/www/example.com/flarum
Queue driver: sync
Session driver: file
Mail driver: smtp
Debug mode: ON