def diff(): lhs_id = int(request.args.get('lhs', 0)) rhs_id = int(request.args.get('rhs', 0)) lhs = (db.session.query(Report).filter(Report.id == lhs_id).first()) rhs = (db.session.query(Report).filter(Report.id == rhs_id).first()) if lhs is None or rhs is None: abort(404) frames_diff = seq_diff( lhs.backtraces[0].frames, rhs.backtraces[0].frames, lambda lhs, rhs: lhs.symbolsource.symbol == rhs.symbolsource.symbol) return render_template("reports/diff.html", diff=frames_diff, lhs={ 'id': lhs_id, 'type': lhs.type }, rhs={ 'id': rhs_id, 'type': rhs.type })
def diff(): lhs_id = int(request.args.get("lhs", 0)) rhs_id = int(request.args.get("rhs", 0)) lhs = db.session.query(Report).filter(Report.id == lhs_id).first() rhs = db.session.query(Report).filter(Report.id == rhs_id).first() if lhs is None or rhs is None: abort(404) frames_diff = seq_diff( lhs.backtraces[0].frames, rhs.backtraces[0].frames, lambda lhs, rhs: lhs.symbolsource.symbol == rhs.symbolsource.symbol, ) return render_template( "reports/diff.html", diff=frames_diff, lhs={"id": lhs_id, "type": lhs.type}, rhs={"id": rhs_id, "type": rhs.type}, )