Path of Exile 2 Wiki:Troubleshooting known issues: Difference between revisions
>Illviljan No edit summary |
m (46 revisions imported) |
||
(19 intermediate revisions by 8 users not shown) | |||
Line 4: | Line 4: | ||
===Item=== | ===Item=== | ||
The {{tlx|Item}} template uses the | The {{tlx|Item}} template uses the Cargo database to store data so it can be queried and displayed in tables automatically. See {{section link||Cargo}}. | ||
====Items not showing up or is out of sync in lists, item tables and other places==== | ====Items not showing up or is out of sync in lists, item tables and other places==== | ||
Line 13: | Line 13: | ||
=====Fixing item caching issues===== | =====Fixing item caching issues===== | ||
Changes (if needed) should be applied to the item's main page and the page(s) not showing the items. See {{section link||Fixing caching issues}}. | |||
=====Fixing invalid queries===== | =====Fixing invalid queries===== | ||
Line 24: | Line 24: | ||
* Adjust the query terms to be more broader or more precise | * Adjust the query terms to be more broader or more precise | ||
* If hitting query limits, consider creating a concept or simplifying the query | * If hitting query limits, consider creating a concept or simplifying the query | ||
=====Fixing template errors===== | =====Fixing template errors===== | ||
Line 49: | Line 48: | ||
Client-side cache issues should require no action on the wiki. Consider clearing your browser's cache or using a different browser to verify it's not client-side. | Client-side cache issues should require no action on the wiki. Consider clearing your browser's cache or using a different browser to verify it's not client-side. | ||
Issues with the Cloudflare will fix themselves eventually; if you preview a page you will get the current version. If you perform a [[wikipedia | Issues with the Cloudflare will fix themselves eventually; if you preview a page you will get the current version. If you perform a [[wikipedia:Wikipedia:Purge#Null_edit|null edit]] and you still see a version different from the version you just saved, don't worry about it - you're seeing a cached version which will be eventually updated to the saved version. | ||
Please note that if you have a gamepedia PRO subscription you'll see the live version of pages instead, bypassing the cloud flare cache. | Please note that if you have a gamepedia PRO subscription you'll see the live version of pages instead, bypassing the cloud flare cache. | ||
Mediawiki and addon related caching issues can be generally resolved by [[wikipedia | Mediawiki and addon related caching issues can be generally resolved by [[wikipedia:Wikipedia:Purge#Null_edit|null edit]] the affected pages. Please note you may need to null edit other pages if you're transcluding content from other pages or are fetching semantic values (from Semantic MediaWiki). | ||
If the edits are still not being applied, consider doing a [[wikipedia:Help:Dummy_edit|dummy edit]]. | If the edits are still not being applied, consider doing a [[wikipedia:Help:Dummy_edit|dummy edit]]. | ||
Line 67: | Line 66: | ||
===Cargo=== | ===Cargo=== | ||
<section begin=cargo/> | <section begin=cargo/> | ||
[[mw:extension | [[mw:extension:Cargo|Cargo]] is a type of database used to store interesting values in various items, mods, versions etc. as rows in [[Special:CargoTables|cargo tables]]. The syntax is very similar to MySQL or SQL because it uses MySQL at its core. | ||
The [[Path_of_Exile_Wiki:PyPoE|PyPoE]] page has more information on how information is stored in Cargo. | |||
====Missing rows==== | ====Missing rows==== | ||
Cargo sometimes misses pages when it repopulates the tables. [[Null edit]]ing each page works most of the time. | Cargo sometimes misses pages when it repopulates the tables. [[Null edit]]ing each page works most of the time. Check "Page values" on the page, if "_pageData" holds no data, the page hasn't been populated entirely and needs to be repopulated by null-editing. | ||
Pages affected by this can be found using queries: | |||
For regular items: | |||
<pre>{{#cargo_query: | |||
|tables=items, _pageData | |||
|join on=items._pageID=_pageData._pageID | |||
|fields=items._pageName | |||
|where=_pageData._pageID IS NULL | |||
}}</pre> | |||
For skills and skill items: | |||
<pre>{{#cargo_query: | |||
|tables=skill, _pageData | |||
|join on=skill._pageID=_pageData._pageID | |||
|fields=skill._pageName | |||
|where=_pageData._pageID IS NULL | |||
}}</pre> | |||
====Duplicate rows==== | ====Duplicate rows==== | ||
When updating pages cargo sometimes does not remove the old rows. So the old row values would still be there and show up in queries. | When updating pages cargo sometimes does not remove the old rows. So the old row values would still be there and show up in queries. | ||
Solutions: | |||
* Having data in template that changes every time needs to be removed; for example <nowiki>{{CURRENTTIME}}</nowiki> or <code><nowiki><ref></nowiki></code> tags | |||
* Null-editing the page or purging the cache until no more duplicates show under the data | |||
* <code>group by</code> helps clean up duplicates but there is no guarantee that you will get latest version. | |||
====One template declares/attaches to multiple cargo tables==== | ====One template declares/attaches to multiple cargo tables==== | ||
Cargo tables can become quite large with a lot fields. Since multiple tables can be joined together and queried for it is more elegant to move the fields to other tables instead. The caveat is that the templates need to be split as well otherwise cargo bugs out. 1 template per cargo table. | Cargo tables can become quite large with a lot fields. Since multiple tables can be joined together and queried for it is more elegant to move the fields to other tables instead. The caveat is that the templates need to be split as well otherwise cargo bugs out and cannot populate the tables automatically. 1 template per cargo table works best. There is a workaround for this, let's say you have the following template: | ||
'''Template:Cargo_store''' | |||
<pre> | |||
<includeonly> | |||
{{#cargo_store: | |||
_table = table_1 | |||
|field_1 = value 1 | |||
}} | |||
{{#cargo_store: | |||
_table = table_2 | |||
|field_1 = value 1 | |||
}} | |||
</includeonly> | |||
<noinclude> | |||
{{#cargo_attach: | |||
_table = table_1 | |||
}} | |||
</noinclude> | |||
</pre> | |||
This template now #cargo_stores to two tables. But attaching is only allowed once per template. The workaround is to create a new template with the other #cargo_attach in the noinclude and '''nothing''' in the includeonly: | |||
'''Template:Cargo_store/Attach_2''' | |||
<pre> | |||
<includeonly></includeonly><noinclude> | |||
{{#cargo_attach: | |||
_table = table_2 | |||
}} | |||
</noinclude> | |||
</pre> | |||
Now transclude this template in the storing template: | |||
'''Template:Cargo_store''' | |||
<pre> | |||
<includeonly> | |||
{{#cargo_store: | |||
_table = table_1 | |||
|field_1 = value 1 | |||
}} | |||
{{#cargo_store: | |||
_table = table_2 | |||
|field_1 = value 1 | |||
}} | |||
{{Template:Cargo_store/Attach_2}} | |||
</includeonly> | |||
<noinclude> | |||
{{#cargo_attach: | |||
_table = table_1 | |||
}} | |||
</noinclude> | |||
</pre> | |||
====Errors during previews==== | ====Errors during previews==== | ||
Line 98: | Line 178: | ||
====Number can't be used in #expr==== | ====Number can't be used in #expr==== | ||
* #cargo_query returns integers/floats with thousand separator. Not surprisingly this will break most calculators. Wrap <code>CONCAT()</code> around the number field to remove thousand separators. | * #cargo_query returns integers/floats with thousand separator. Not surprisingly this will break most calculators. Wrap <code>TRIM()</code> or <code>CONCAT()</code> around the number field to remove thousand separators. | ||
* #cargo_query sometimes returns the numbers with hidden characters as well. Use <code>no html</code> to remove those.<section end=cargo /> | * #cargo_query sometimes returns the numbers with hidden characters as well. Use <code>no html</code> to remove those.<section end=cargo /> | ||
=== | ====Cannot execute query from Wikimedia\Rdbms\DatabaseMysqlBase::tableExists while transaction status is ERROR==== | ||
This error can appear if a template that '''queries''' a cargo table is on the same page as a template that stores to an '''uncreated''' cargo table. Make sure all tables are declared and created before storing. | |||
{{cot|Example error}} | |||
[e2e6cbe98a6849d175cbc70f] /News Wikimedia\Rdbms\DBTransactionStateError from line 1313 of includes/libs/rdbms/database/Database.php: Cannot execute query from Wikimedia\Rdbms\DatabaseMysqlBase::tableExists while transaction status is ERROR. | |||
Backtrace: | |||
#0 includes/libs/rdbms/database/Database.php(1096): Wikimedia\Rdbms\Database->assertTransactionStatus(string, string) | |||
#1 includes/libs/rdbms/database/DatabaseMysqlBase.php(622): Wikimedia\Rdbms\Database->query(string, string) | |||
#2 extensions/Cargo/includes/parserfunctions/CargoStore.php(77): Wikimedia\Rdbms\DatabaseMysqlBase->tableExists(string) | |||
#3 includes/parser/Parser.php(3426): CargoStore::run(Parser, string, string, string, string, string, string, string, string, string, string, string, string, string) | |||
#4 includes/parser/Parser.php(3127): Parser->callParserFunction(PPTemplateFrame_DOM, string, array) | |||
#5 includes/parser/Preprocessor_DOM.php(1277): Parser->braceSubstitution(array, PPTemplateFrame_DOM) | |||
#6 extensions/ParserFunctions/includes/ExtParserFunctions.php(123): PPFrame_DOM->expand(DOMElement) | |||
#7 includes/parser/Parser.php(3426): ExtParserFunctions::ifeqObj(Parser, PPTemplateFrame_DOM, array) | |||
#8 includes/parser/Parser.php(3127): Parser->callParserFunction(PPTemplateFrame_DOM, string, array) | |||
#9 includes/parser/Preprocessor_DOM.php(1277): Parser->braceSubstitution(array, PPTemplateFrame_DOM) | |||
#10 includes/parser/Parser.php(3305): PPFrame_DOM->expand(DOMElement) | |||
#11 includes/parser/Preprocessor_DOM.php(1277): Parser->braceSubstitution(array, PPFrame_DOM) | |||
#12 includes/parser/Parser.php(2942): PPFrame_DOM->expand(DOMElement, integer) | |||
#13 includes/parser/Parser.php(1293): Parser->replaceVariables(string) | |||
#14 includes/parser/Parser.php(443): Parser->internalParse(string) | |||
#15 includes/content/WikitextContent.php(323): Parser->parse(string, Title, ParserOptions, boolean, boolean, integer) | |||
#16 includes/content/AbstractContent.php(516): WikitextContent->fillParserOutput(Title, integer, ParserOptions, boolean, ParserOutput) | |||
#17 includes/poolcounter/PoolWorkArticleView.php(144): AbstractContent->getParserOutput(Title, integer, ParserOptions) | |||
#18 includes/poolcounter/PoolCounterWork.php(123): PoolWorkArticleView->doWork() | |||
#19 includes/page/Article.php(604): PoolCounterWork->execute() | |||
#20 includes/actions/ViewAction.php(68): Article->view() | |||
#21 includes/MediaWiki.php(500): ViewAction->show() | |||
#22 includes/MediaWiki.php(294): MediaWiki->performAction(Article, Title) | |||
#23 includes/MediaWiki.php(861): MediaWiki->performRequest() | |||
#24 includes/MediaWiki.php(524): MediaWiki->main() | |||
#25 index.php(42): MediaWiki->run() | |||
#26 | |||
{main} | |||
{{cob}} | |||
===Querying list fields from different tables with the same name=== | |||
Cargo will drop the table specific portion when querying list fields that share the same name even if the full table name is specified in the query. To avoid this problem, <code>__full</code> must be appended individually to the all the list fields that share the same name. | |||
Error: | |||
<pre>{{#cargo_query: | |||
|tables=monsters, monster_types | |||
|fields=monsters.tags=monsters.tags, monster_types.tags=monster_type.tags | |||
|join on=monsters.monster_type_id=monster_types.id | |||
|limit=1 | |||
}}</pre> | |||
Fixed: | |||
<pre>{{#cargo_query: | |||
|tables=monsters, monster_types | |||
|fields=monsters.tags__full=monsters.tags, monster_types.tags__full=monster_type.tags | |||
|join on=monsters.monster_type_id=monster_types.id | |||
|limit=1 | |||
}}</pre> | |||
==== | ==API== | ||
===cargoquery=== | |||
{{main|Path of Exile Wiki:Data query API}} | |||
When selecting one or more fields that begin with an underscore, the request may return an error. To get around this issue, specify an alias for each field that begins with an underscore. | |||
==== | https://www.poewiki.net/w/api.php?action=cargoquery&tables=items&fields=items.name,items._ID=ID&where=items.rarity=%22Unique%22 | ||
[[Category:Path of Exile Wiki]] | |||
Latest revision as of 04:52, 28 November 2024
Issues on this wiki that are known to the admins/sysops and possible solutions on how to fix it. Consider the talk page if you want something added.
Templates/module issues specific to this wiki
Item
The {{Item}}
template uses the Cargo database to store data so it can be queried and displayed in tables automatically. See § Cargo.
Items not showing up or is out of sync in lists, item tables and other places
Can occur due to:
- caching issues
- invalid queries
- template errors
Fixing item caching issues
Changes (if needed) should be applied to the item's main page and the page(s) not showing the items. See § Fixing caching issues.
Fixing invalid queries
The general process here is to check whether your query uses the correct conditions.
Some tips:
- Start by null editing the source page and the list page.
- If the query is performed by the template you're using and not by yourself, make sure to check the template's documentation first
- If an item isn't included in the query, but you think it should be check the item's page values. Adjust your query if needed or check for caching issues
- Adjust the query terms to be more broader or more precise
- If hitting query limits, consider creating a concept or simplifying the query
Fixing template errors
Template errors will prevent the templates from performing correctly. In some cases there are shown on purpose to avoid people using invalid data, but may also be caused by errors in the template itself.
If you can't fix the error right away, check the documentation of the template.
If the error appears in the code of the template itself and if you're unable to fix it , please create a new section on the template talk page and/or notify the template authors/wiki admins on their user pages.
Mediawiki
Page is not added to transcluded categories from pages with <includeonly>
The symptom is generally that the page shows the category correctly at the bottom, but is not actually added to it.
Solution:
- Null edit the page the category is transcluded to.
Fixing caching issues
Prior to attempt to fix caching issues, please note there are multiple caches deployed:
- Cache of your browser (i.e. client-side)
- Intermediate cache from Cloudflare
- Cache used by the Mediawiki software and addons
Client-side cache issues should require no action on the wiki. Consider clearing your browser's cache or using a different browser to verify it's not client-side.
Issues with the Cloudflare will fix themselves eventually; if you preview a page you will get the current version. If you perform a null edit and you still see a version different from the version you just saved, don't worry about it - you're seeing a cached version which will be eventually updated to the saved version. Please note that if you have a gamepedia PRO subscription you'll see the live version of pages instead, bypassing the cloud flare cache.
Mediawiki and addon related caching issues can be generally resolved by null edit the affected pages. Please note you may need to null edit other pages if you're transcluding content from other pages or are fetching semantic values (from Semantic MediaWiki). If the edits are still not being applied, consider doing a dummy edit.
Extensions
Scribunto (Modules/Lua)
The Scribunto extension allows for embedding scripting languages in MediaWiki. Currently the only supported scripting language is Lua. For a reference manual see the Lua reference manual.
mw.text.split is very slow
Solution:
- If possible use
string.split
instead
Cargo
Cargo is a type of database used to store interesting values in various items, mods, versions etc. as rows in cargo tables. The syntax is very similar to MySQL or SQL because it uses MySQL at its core.
The PyPoE page has more information on how information is stored in Cargo.
Missing rows
Cargo sometimes misses pages when it repopulates the tables. Null editing each page works most of the time. Check "Page values" on the page, if "_pageData" holds no data, the page hasn't been populated entirely and needs to be repopulated by null-editing.
Pages affected by this can be found using queries:
For regular items:
{{#cargo_query: |tables=items, _pageData |join on=items._pageID=_pageData._pageID |fields=items._pageName |where=_pageData._pageID IS NULL }}
For skills and skill items:
{{#cargo_query: |tables=skill, _pageData |join on=skill._pageID=_pageData._pageID |fields=skill._pageName |where=_pageData._pageID IS NULL }}
Duplicate rows
When updating pages cargo sometimes does not remove the old rows. So the old row values would still be there and show up in queries.
Solutions:
- Having data in template that changes every time needs to be removed; for example {{CURRENTTIME}} or
<ref>
tags - Null-editing the page or purging the cache until no more duplicates show under the data
group by
helps clean up duplicates but there is no guarantee that you will get latest version.
One template declares/attaches to multiple cargo tables
Cargo tables can become quite large with a lot fields. Since multiple tables can be joined together and queried for it is more elegant to move the fields to other tables instead. The caveat is that the templates need to be split as well otherwise cargo bugs out and cannot populate the tables automatically. 1 template per cargo table works best. There is a workaround for this, let's say you have the following template:
Template:Cargo_store
<includeonly> {{#cargo_store: _table = table_1 |field_1 = value 1 }} {{#cargo_store: _table = table_2 |field_1 = value 1 }} </includeonly> <noinclude> {{#cargo_attach: _table = table_1 }} </noinclude>
This template now #cargo_stores to two tables. But attaching is only allowed once per template. The workaround is to create a new template with the other #cargo_attach in the noinclude and nothing in the includeonly:
Template:Cargo_store/Attach_2
<includeonly></includeonly><noinclude> {{#cargo_attach: _table = table_2 }} </noinclude>
Now transclude this template in the storing template:
Template:Cargo_store
<includeonly> {{#cargo_store: _table = table_1 |field_1 = value 1 }} {{#cargo_store: _table = table_2 |field_1 = value 1 }} {{Template:Cargo_store/Attach_2}} </includeonly> <noinclude> {{#cargo_attach: _table = table_1 }} </noinclude>
Errors during previews
Cargo doesn't handle incorrect cargo queries gracefully and sometimes throws major errors that forces you to go back a page. Copy the source before submitting/previewing so your work doesn't get lost.
HOLDS doesn't work as expected
Cargo bug. Instead of using HOLDS try, *__full instead. The lists then becomes a ordinary string and can be queried as such.
Example:
- Replace
skill_gems.gem_tags HOLDS "Aura"
withskill_gems.gem_tags__full LIKE "%Aura%"
- Use regexp for more advanced queries:
events.id__FULL REGEXP "(, |^)SSF Abyss(, |$)"
.- The delimiter in this case is
,
- Replace
|
with{{!}}
in normal wikitext.
- The delimiter in this case is
Case sensitivity
Cargo is case insensitive. Use BINARY instead. Read more here.
Recreation jobs are queued?
It's possible to see if a cargo data recreation job is active. See this page
Number can't be used in #expr
- #cargo_query returns integers/floats with thousand separator. Not surprisingly this will break most calculators. Wrap
TRIM()
orCONCAT()
around the number field to remove thousand separators. - #cargo_query sometimes returns the numbers with hidden characters as well. Use
no html
to remove those.
Cannot execute query from Wikimedia\Rdbms\DatabaseMysqlBase::tableExists while transaction status is ERROR
This error can appear if a template that queries a cargo table is on the same page as a template that stores to an uncreated cargo table. Make sure all tables are declared and created before storing. Template:Cot [e2e6cbe98a6849d175cbc70f] /News Wikimedia\Rdbms\DBTransactionStateError from line 1313 of includes/libs/rdbms/database/Database.php: Cannot execute query from Wikimedia\Rdbms\DatabaseMysqlBase::tableExists while transaction status is ERROR.
Backtrace:
- 0 includes/libs/rdbms/database/Database.php(1096): Wikimedia\Rdbms\Database->assertTransactionStatus(string, string)
- 1 includes/libs/rdbms/database/DatabaseMysqlBase.php(622): Wikimedia\Rdbms\Database->query(string, string)
- 2 extensions/Cargo/includes/parserfunctions/CargoStore.php(77): Wikimedia\Rdbms\DatabaseMysqlBase->tableExists(string)
- 3 includes/parser/Parser.php(3426): CargoStore::run(Parser, string, string, string, string, string, string, string, string, string, string, string, string, string)
- 4 includes/parser/Parser.php(3127): Parser->callParserFunction(PPTemplateFrame_DOM, string, array)
- 5 includes/parser/Preprocessor_DOM.php(1277): Parser->braceSubstitution(array, PPTemplateFrame_DOM)
- 6 extensions/ParserFunctions/includes/ExtParserFunctions.php(123): PPFrame_DOM->expand(DOMElement)
- 7 includes/parser/Parser.php(3426): ExtParserFunctions::ifeqObj(Parser, PPTemplateFrame_DOM, array)
- 8 includes/parser/Parser.php(3127): Parser->callParserFunction(PPTemplateFrame_DOM, string, array)
- 9 includes/parser/Preprocessor_DOM.php(1277): Parser->braceSubstitution(array, PPTemplateFrame_DOM)
- 10 includes/parser/Parser.php(3305): PPFrame_DOM->expand(DOMElement)
- 11 includes/parser/Preprocessor_DOM.php(1277): Parser->braceSubstitution(array, PPFrame_DOM)
- 12 includes/parser/Parser.php(2942): PPFrame_DOM->expand(DOMElement, integer)
- 13 includes/parser/Parser.php(1293): Parser->replaceVariables(string)
- 14 includes/parser/Parser.php(443): Parser->internalParse(string)
- 15 includes/content/WikitextContent.php(323): Parser->parse(string, Title, ParserOptions, boolean, boolean, integer)
- 16 includes/content/AbstractContent.php(516): WikitextContent->fillParserOutput(Title, integer, ParserOptions, boolean, ParserOutput)
- 17 includes/poolcounter/PoolWorkArticleView.php(144): AbstractContent->getParserOutput(Title, integer, ParserOptions)
- 18 includes/poolcounter/PoolCounterWork.php(123): PoolWorkArticleView->doWork()
- 19 includes/page/Article.php(604): PoolCounterWork->execute()
- 20 includes/actions/ViewAction.php(68): Article->view()
- 21 includes/MediaWiki.php(500): ViewAction->show()
- 22 includes/MediaWiki.php(294): MediaWiki->performAction(Article, Title)
- 23 includes/MediaWiki.php(861): MediaWiki->performRequest()
- 24 includes/MediaWiki.php(524): MediaWiki->main()
- 25 index.php(42): MediaWiki->run()
- 26
{main} Template:Cob
Querying list fields from different tables with the same name
Cargo will drop the table specific portion when querying list fields that share the same name even if the full table name is specified in the query. To avoid this problem, __full
must be appended individually to the all the list fields that share the same name.
Error:
{{#cargo_query: |tables=monsters, monster_types |fields=monsters.tags=monsters.tags, monster_types.tags=monster_type.tags |join on=monsters.monster_type_id=monster_types.id |limit=1 }}
Fixed:
{{#cargo_query: |tables=monsters, monster_types |fields=monsters.tags__full=monsters.tags, monster_types.tags__full=monster_type.tags |join on=monsters.monster_type_id=monster_types.id |limit=1 }}
API
cargoquery
When selecting one or more fields that begin with an underscore, the request may return an error. To get around this issue, specify an alias for each field that begins with an underscore.