Page MenuHomePhabricator

Fatal error on meta when entering unmatched translation tags
Closed, ResolvedPublic


I made crash with the following fatal error.

PHP fatal error in /usr/local/apache/common-local/php-1.21wmf3/extensions/Translate/tag/PageTranslationHooks.php line 367:
Call to undefined method TPException::getWikiText()

I used the following text. I am aware that the tags do not match, but the failure should not be fatal I'd say.

Wikidata will provide a knowledge base that everyone can edit. In this article we want to improve discussion and communication about the project by defining important terminology. There are significant advantages if we use the terminology consistently in the project.</translate>

  • {{anchor|Wikidata}}<translate><!--T:3-->

'''Wikidata''' is a new website that is being developed during the initial Wikidata development. A first part of it was launched at [].It runs an instance of MediaWiki with the Wikibase extensions that allows Wikidata editors to enter and browse the pages in Wikidata.</translate>

  • {{anchor|Wikibase extensions}}<translate><!--T:4-->

'''Wikibase''' is the software behind Wikidata. It consists of three MediaWiki extensions: Wikibase, Wikibase client, and WikibaseLib. The '''Wikibase extension''' (for the Wikidata server, often called just ''repo'') allows a MediaWiki installation to collect and maintain structured data and will be used on the Wikidata website. The '''Wikibase client extension''' (often called just ''client'') enables MediaWiki installations to query and display data from a Wikidata server on its own pages, and will be deployed on Wikipedias in different languages, and probably on other sites. The '''WikibaseLib extension''' has common libraries for both of the major extensions.</translate>

  • {{anchor|Wikidata editors}}<translate><!--T:5-->

'''Wikidata editors''' are users of Wikidata who create and collaboratively maintain its content. Together, they are part of the Wikidata community.</translate>

  • {{anchor|Initial Wikidata development}}<translate><!--T:6-->

'''Initial Wikidata development''' refers to the work that will be done by the initial Wikidata development team—described in the [[meta:Wikidata/Technical proposal|technical proposal]]—in the April 2012 to March 2013 timeframe.</translate>
<translate>[[File:Wikidata statement.png|thumbnail|right|Wikidata terminology]]</translate>

  • {{anchor|Page}}<translate><!--T:7-->

'''Page''' means a page or {{anchor|article}}'''article''' in the main space of a wiki. In Wikidata there will be pages in different namespaces (just as in the Wikipedias). Pages in the main namespace of Wikidata will be about items.</translate>

  • {{anchor|Entity}}<translate>

'''Entity''' (also called ''topic'', ''thing'', or ''subject'') is the real-life subject (or abstract concept) a page in Wikipedia is about. This thing is not the description itself, or the page—it is the concept the article describes. For now there are three different types of entities: items, properties, and queries.</translate>

  • {{anchor|Item}}<translate><!--T:8-->

'''Item''' (also called ''topic'', ''thing'', ''entity'', or ''lemma'') is what a page in Wikidata is about. An item is identified by its label and description (see [[meta:Wikidata/Notes/Data model|Data model]]) and by the Wikipedia articles linked to the page.</translate>
'''Statement''' (also called ''fact'', ''claim'', or ''triple'', even though these are not completely correct) is one piece of data about an item, recorded on one page. In the simplest case, a statement is just a "property: value" pair (for example, "Location: Germany"), but often statements can have further qualifiers (such as temporal qualifiers). See [[meta:Wikidata/Notes/Data model|Data model]]. Wikidata makes no assumptions about the correctness of statements, but merely collects and reports them with a reference to a source.</translate>

  • {{anchor|Reference}}<translate><!--T:10-->

'''Reference''' (or ''source'') describes the origin of a statement in Wikidata. A source is often an item in its own right; for example, a book. Wikidata does not aim to answer the question of whether a statement is correct, but merely whether the statement appears in a reference. What constitutes valid references is expected to be a question of debate among the ''Wikidata editors''.</translate>

  • {{anchor|Data}}{{anchor|Metadata}}<translate><!--T:11-->

'''Data''' and '''Metadata''': In Wikidata, '''data''' is the collection of all statements and their references—in general, everything entered by the Wikidata editors into Wikidata. In contrast, '''metadata''' is all of the data that Wikidata either records about this, or that is embedded in the software and cannot be changed by the editors, e.g. the edit history of a page, the Wikidata editor who has entered a statement or given a reference.</translate>

  • {{anchor|Export}}<translate><!--T:12-->

'''Export''' refers to the way data and metadata from Wikidata are made available for further consumption. The intention is to make machine-readable exports of the data available in widely used formats such as JSON or RDF/XML.</translate>

  • {{anchor|languageattribute}}<translate>

'''Language attributes''' are the language-specific {{anchor|languageattribute-label}}'''labels''' and {{anchor|languageattribute-description}}'''descriptions''' that are attached to items. These are human-readable text to improve understanding of the scope of the item; i.e. the specific type of entity.</translate>

  • {{anchor|aliases}}<translate>

'''Aliases''' are alternate names for the entities that can be used for lookup the same way as labels. Similar to the the labels they are language specific, but unlike the labels there can be as many aliases as necessary.

  • {{anchor|sitelinks}}<translate>

'''Site links''' are special links that contain a {{anchor|sitelinks-site}}'''site''' and a {{anchor|sitelinks-title}}'''title''', and go from individual items in Wikidata to pages on other sites such as Wikipedia. They are used both for identifying an item from an external site, and as a replacement for interlanguage links. Site links can have attached {{anchor|sitelinks-badge}}'''badges''' and will usually show that a page has been a ''featured article'', or of similar status.</translate>

Terms in the data model

The following terms are relevant for the [[meta:Wikidata/Notes/Data model|data model]] and thus are also helpful for using the Web and internal API.

  • {{anchor|Value}}<translate>

'''Values''' (or ''datavalues'') are the fillers for the properties of a claim.</translate>

  • {{anchor|Type}}<translate>

'''Types''' (or ''datatypes'') describe the kind a value can have. They are defined by the property that is used.</translate>

  • {{anchor|Snak}}<translate>

'''Snaks''' are internal parts of the data model. Qualifiers are represented as snaks as well as the main property and value of a claim. These elements should not be visible in the user interface, but they will in the Web API.</translate>

  • {{anchor|Qualifier}}<translate>

'''Qualifier''' is a part of the claim that says something about the specific claim, often in a descriptive way. A qualifier can specify certain context about the claim, e.g. for which year it holds or other further information.</translate>

  • {{anchor|Claim}}<translate><!--T:21-->

'''Claim''' (also called ''fact'' or ''statement'', although this is not entirely correct) is the part of a statement without the references.</translate>

  • {{anchor|Property}}<translate>

'''Property''' (also called ''member'', or ''field'') is a smaller part of an item, and are themselves entities. A property is the identificator for a value or set of values inside an item, but not the value or values themself, and each property is described and defined on a special property page.</translate>

  • {{anchor|Query}}<translate>

'''Query''' is predefined search across items, and are themselves entities. A query is the predefined search, and each search is described and defined on a special property page.</translate>

  • {{anchor|Statement}}<translate><!--T:9-->


Related terms</translate> ==

  • {{anchor|MediaWiki}}<translate><!--T:13-->

'''MediaWiki''' is the software that runs projects like Wikipedia and Wikimedia Commons; see [[:en:MediaWiki|MediaWiki]].</translate>

  • {{anchor|RDF}}<translate><!--T:14-->

'''RDF''' is a W3C standard for the data model of the semantic web; see [[:en:Resource Description Framework|Resource Description Framework]].</translate>

  • {{anchor|JSON}}<translate><!--T:15-->

'''JSON''' is a JavaScript-based notation for exchanging data; see [[:en:JSON|JSON]].</translate>

  • {{anchor|XML}}<translate><!--T:16-->

'''XML''' is a W3C standard for an extensible markup language; see [[:en:XML|XML]].</translate>

  • {{anchor|RDF/XML}}<translate><!--T:17-->

'''RDF/XML''' is a serialization format of RDF in XML; see [[:en:RDF/XML|RDF/XML]].</translate>


Version: unspecified
Severity: normal
See Also:



Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:46 AM
bzimport set Reference to bz41844.

Simpler scenario to trigger the exception:

Replace contents of [1] with "<translate>" and hit save.

Giving [2] the same contents (page doesn't exist yet), gives expected behaviour on save: "Unbalanced label <translate>."


Merged. Will be picked up by 1.21wmf4 branch unless someone asks me to backport it to 1.21wmf3.