Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2306)

Unified Diff: appengine/findit/model/crash/cracas_crash_analysis.py

Issue 2322133002: [Findit] Add cracas_crash_analysis (Closed)
Patch Set: Use ChromeCrashAnalysis as base model shared by FracasCrashAnalysis and CracasCrashAnalysis Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: appengine/findit/model/crash/cracas_crash_analysis.py
diff --git a/appengine/findit/model/crash/cracas_crash_analysis.py b/appengine/findit/model/crash/cracas_crash_analysis.py
new file mode 100644
index 0000000000000000000000000000000000000000..397061669f51567a20780c88abeb408bc02120c0
--- /dev/null
+++ b/appengine/findit/model/crash/cracas_crash_analysis.py
@@ -0,0 +1,20 @@
+# Copyright 2016 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import hashlib
+import json
+
+from google.appengine.ext import ndb
+
+from model.crash.chrome_crash_analysis import ChromeCrashAnalysis
+
+# TODO(katesonia): Deprecate FracasCrashAnalysis after switching from Fracas
wrengr (wrong one) 2016/09/10 00:22:06 This todo is no longer relevant (for this file)
Sharu Jiang 2016/09/14 20:46:36 Done.
+# to Cracas.
+class CracasCrashAnalysis(ChromeCrashAnalysis):
+ """Represents an analysis of a Chrome crash."""
+
+ @staticmethod
+ def _CreateKey(crash_identifiers):
+ return ndb.Key('CracasCrashAnalysis', hashlib.sha1(
+ json.dumps(crash_identifiers, sort_keys=True)).hexdigest())

Powered by Google App Engine
This is Rietveld 408576698