Aude has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/65968


Change subject: catch RuntimeException for unknown data type id
......................................................................

catch RuntimeException for unknown data type id

- this will occur, for example, in clients trying to access a claim with 
unknown data type
(e.g. one moved from experimental to non-experimental in repo, while client is 
on different/older
version of the extensions).

Change-Id: I7fd58123114916cd9d14145c3087c28af12b403e
---
M lib/includes/SnakFormatter.php
1 file changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase 
refs/changes/68/65968/1

diff --git a/lib/includes/SnakFormatter.php b/lib/includes/SnakFormatter.php
index 1c29ab6..b64a1f7 100644
--- a/lib/includes/SnakFormatter.php
+++ b/lib/includes/SnakFormatter.php
@@ -99,7 +99,9 @@
                        // @todo nicer error handling!
                        wfDebugLog( __CLASS__, __METHOD__ . ': Property '
                                . $snak->getPropertyId()->getPrefixedId() . ' 
not found.' );
-               }
+        } catch ( RuntimeException $e ) {
+            wfDebugLog( __CLASS__, __METHOD__ . ': unknown DataType id for 
$dataTypeId' );
+        }
 
                return '';
        }

-- 
To view, visit https://gerrit.wikimedia.org/r/65968
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7fd58123114916cd9d14145c3087c28af12b403e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Aude <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to