Extension talk:Page Schemas
Archives
|
---|
|
Error when trying to create schema
editHi!
I installed the extension, and it shows up on Special Pages, but as soon as I try to create a schema, I encounter this error:
Fatal error: OOUI\Exception: OOUI\Theme::singleton was called with no singleton theme set. in /volume1/web_packages/mediawiki/vendor/oojs/oojs-ui/php/Theme.php:31 Stack trace: #0 /volume1/web_packages/mediawiki/vendor/oojs/oojs-ui/php/Element.php(260): OOUI\Theme::singleton() #1 /volume1/web_packages/mediawiki/vendor/oojs/oojs-ui/php/Tag.php(494): OOUI\Element->toString() #2 /volume1/web_packages/mediawiki/extensions/PageForms/specials/PF_CreateTemplate.php(275): OOUI\Tag->__toString() #3 /volume1/web_packages/mediawiki/extensions/PageForms/specials/PF_CreateTemplate.php(283): PFCreateTemplate::printTemplateStyleButton('standard', 'pf_createtempla...', 'template_format...', 'standard') #4 /volume1/web_packages/mediawiki/extensions/PageSchemas/includes/specials/PSEditSchema.php(404): PFCreateTemplate::printTemplateStyleInput('template_format...', 'standard') #5 /volume1/web_packages/mediawiki/extensions/PageSchemas/includes/specials/PSEditSchema.php(604): PSEditSchema->printTemplateSection() #6 /volume1/web_packages/mediaw in /volume1/web_packages/mediawiki/vendor/oojs/oojs-ui/php/Tag.php on line 496
Any help would be greatly appreciated!
Thank you in advance!
Attila Attila.horvath (talk) 12:10, 13 February 2023 (UTC)
- What versions of MediaWiki and Page Schemas are you running? Yaron Koren (talk) 18:40, 13 February 2023 (UTC)
- Hi!
- I am using:
- MediaWiki 1.35.6
- PHP 7.4.30 (fpm-fcgi)
- MariaDB 10.3.32-MariaDB
- Page Schemas 0.5 (bd5178d)07:24, 2023 February 13 Attila.horvath (talk) 19:56, 13 February 2023 (UTC)
- I assume you're using the REL1_35 branch of Page Schemas. You should instead the latest code, from master - I'm guessing that that will make this problem go away. Yaron Koren (talk) 20:20, 13 February 2023 (UTC)
- Thank you very much! It works now! Attila.horvath (talk) 21:06, 13 February 2023 (UTC)
- I assume you're using the REL1_35 branch of Page Schemas. You should instead the latest code, from master - I'm guessing that that will make this problem go away. Yaron Koren (talk) 20:20, 13 February 2023 (UTC)
How to show the Edit Schema and Generate Pages in Citizen Skins
editWhen I switch the Skins from Vector to Citizen, in the category page, we lost the link for the Edit Schema and Generate Pages.
Any idea how to customise and add these links into Citizen Skins ?
TypeError: Illegal offset type in isset or empty with PHP 8.0.28
editIt seems that after I upgraded the PHP 7.4.X to PHP 8.0.24.
I hit the following error when want to create the page schema.
[bb1b3266302c2d98304dd7ff] /index.php?title=Category:Demo_Page&action=editschema TypeError: Illegal offset type in isset or empty
Any one have issues used with PHP 8.0.24 ? Else I need to downgrade to use PHP 7.4.X .
Lotusccong (talk) 14:50, 19 April 2023 (UTC)
- What is the file name and line number for the error? And what version of Page Schemas are you using? Yaron Koren (talk) 15:27, 19 April 2023 (UTC)
- I am using 0.7 (9cfec4c) 15:26, 25 November 2022
- Below are the detail error message
- [cdae79292448f1c121954098] /index.php?title=Category:%E6%95%91%E5%BA%A6%E7%9C%BE%E7%94%9F&action=editschema TypeError: Illegal offset type in isset or empty
- Backtrace:
- from /XXX/public_html/includes/Html.php(699)
- 0 /XXX/public_html/extensions/SemanticMediaWiki/includes/SMW_PageSchemas.php(194): Html::input()
- 1 /XXX/public_html/extensions/PageSchemas/includes/specials/PSEditSchema.php(455): SMWPageSchemas::getTemplateEditingHTML()
- 2 /XXX/public_html/extensions/PageSchemas/includes/specials/PSEditSchema.php(644): PSEditSchema->printTemplateSection()
- 3 /XXX/public_html/extensions/PageSchemas/includes/specials/PSEditSchema.php(819): PSEditSchema->printForm()
- 4 /XXX/public_html/extensions/PageSchemas/includes/PSEditSchemaAction.php(40): PSEditSchema->execute()
- 5 /XXX/public_html/includes/MediaWiki.php(542): PSEditSchemaAction->show()
- 6 /XXX/public_html/includes/MediaWiki.php(322): MediaWiki->performAction()
- 7 /XXX/public_html/includes/MediaWiki.php(904): MediaWiki->performRequest()
- 8 /XXX/public_html/includes/MediaWiki.php(562): MediaWiki->main()
- 9 /XXX/public_html/index.php(50): MediaWiki->run()
- 10 /XXX/public_html/index.php(46): wfIndexMain()
- 11 {main} Lotusccong (talk) 04:47, 20 April 2023 (UTC)
- Okay, I thought that error message looked familiar - I believe this is a bug in the Semantic MediaWiki code that was fixed a few months ago; you can see the fix here. Upgrading to the latest SMW code should fix the problem. Yaron Koren (talk) 13:43, 21 April 2023 (UTC)
- I am running with SMW 4.1.1 , After I swicth back to PHP 7.4.X. The error message gone. However I screwed up my PHP 8.0 version of MW and SMW. I decided to use PHP 7.4.X and installeld with SMW 4.1.1. Will keep it posted if I encounter this error again. Lotusccong (talk) 15:40, 23 April 2023 (UTC)
Why the Semantic property always generated even you deselect it ?
editI am running with MW 1.39.0 , PHP 7.4.33, Semantic Bundle 6.0.1, SMW 4.0.2 , Page Schemas 0.7 (9cfec4c) 15:26, 25 November 2022 and Page Forms 5.5.1.
It seems that any Fields that I create with Form input and deselect the Semantic Property. The Semantic Property with Page datatype is auto selected, therefore when I generate pages, it will included the Semantic Property where I don't need for some of the fields.
Any mistake that I make that cause this issues or have anyone facing this issue before?
Bug Blank Field is added when created Schemas
editHello
When I create a category with Special:CreateCategory and Proceed with the creation of the Schemas.
As soon as I save, a Mysterious Blank field appear.
The blank field is either the first one or the last one.
I can remove it easly by editing the schemas but for user not aware of the bug when they try to create the Cargo Table they have a error message.
I don't know why I have this weird bug on all of my Wiki
Even on a new wiki from scratch.
Product | Version |
---|---|
MediaWiki | 1.39.6 |
PHP | 8.2.12 (apache2handler) |
MariaDB | 10.4.32-MariaDB |
ICU | 71.1 |
Lua | 5.1.5 |
Pygments | 2.11.2 |
Page Schemas | 0.8 | GPL-2.0-or-later | Defines the data structure for all pages in a category using XML | Yaron Koren, Ankit Garg and others |
Page Forms | 5.6.3 | GPL-2.0-or-later | Forms for creating and editing wiki pages | Yaron Koren, Stephan Gambke and others |
Cargo | 3.4.4 | GPL-2.0-or-later | Storage and querying of template data | Yaron Koren |
AjaxDeshayes (talk) 12:29, 8 February 2024 (UTC)
On another note, is the only way to do add a Hierarchy with Page Schemas is to edit the source of my template page and add it manually every time the template is being generated ? The Pages Schemas do not support the hierarchy structure natively like pages Form with Cargo do ? I doesn't have the button add hierarchy like Pages Form do and because of that when the hierarchy is place in the Cargo allowed value field in the schemas the the hierarchy is going to be generated like this in the template and don't work.
(allowed values=(hierarchy;allowed values=* Entrer ** les valeurs *** de la hiérarchie *** dans ** un *** format * comme ** celui-ci)).
12/02/2024
If you put a @ in Text that will be printed before the field: and save, now you can't edit the schemas and save you need to edit sources and remove the <pageforms_FormInput> for the field
<pageforms_FormInput> <TextBeforeField>@</TextBeforeField> </pageforms_FormInput>
to
</pageforms_FormInput>
and voila you can now edit and save with edit schemas if you put an @ again you need to do it again Tested on PageSchemas 0.9
- This seems like three different issues in one - it's better to have a different section for each separate problem. With that said, these are all legitimate issues. I just checked in what I think are fixes for the first and third. That first one is really a major bug! It's hard to believe that it was in place for as long as it was (maybe years). The second one, with hierarchy values, is also a problem, but harder to fix. But hopefully the code is in a better state now. Yaron Koren (talk) 17:26, 13 February 2024 (UTC)
Error when trying to Edit schema after updating to MW 1.41.0
editHello Yaron,
I've just updated my wiki from 1.38 to 1.41. I've also updated Cargo, Page Schemas, Page Forms.
The wiki works just fine but the Page Schemas category editing feature. When I click on "Edit schema" I get the following:
[26319d06c00d39ad8f626e7b] /innovation/index.php?title=Category:Activity&action=editschema Error: Call to a member function getTitle() on null
Backtrace:
from /var/www/changanwikis.com/innovation/extensions/PageSchemas/includes/PSEditSchemaAction.php(31)
#0 /var/www/changanwikis.com/innovation/includes/MediaWiki.php(583): PSEditSchemaAction->show()
#1 /var/www/changanwikis.com/innovation/includes/MediaWiki.php(363): MediaWiki->performAction()
#2 /var/www/changanwikis.com/innovation/includes/MediaWiki.php(960): MediaWiki->performRequest()
#3 /var/www/changanwikis.com/innovation/includes/MediaWiki.php(613): MediaWiki->main()
#4 /var/www/changanwikis.com/innovation/index.php(50): MediaWiki->run()
#5 /var/www/changanwikis.com/innovation/index.php(46): wfIndexMain()
#6 {main}
The "Edit source" works just fine.
Can you help?
Thanks! Carloposo (talk) 13:22, 21 March 2024 (UTC)
- Thanks for pointing that out, and sorry about the problem - indeed, Page Schemas did not work with MediaWiki 1.40+. I just checked in a fix for this problem, here. Yaron Koren (talk) 14:33, 21 March 2024 (UTC)
- Thank you @Yaron Koren
- What is the best way to get the fix? Should I download the two changed files from Phabricator? Carloposo (talk) 08:36, 22 March 2024 (UTC)
- How did you update Page Schemas before? If you do the exact same thing now, that might be enough. Yaron Koren (talk) 12:06, 22 March 2024 (UTC)
- Before I downloaded Page Schemas for MW 1.41 from here
- Should I download the Master version this time? Carloposo (talk) 12:52, 22 March 2024 (UTC)
- Oh, okay. Yes. Yaron Koren (talk) 20:58, 22 March 2024 (UTC)
- How did you update Page Schemas before? If you do the exact same thing now, that might be enough. Yaron Koren (talk) 12:06, 22 March 2024 (UTC)