diff --git a/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp b/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp index 6ef468779a..10d9e2eb20 100644 --- a/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp +++ b/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp @@ -534,7 +534,7 @@ bool WriteDRCReport( BOARD* aBoard, const wxString& aFileName, EDA_UNITS aUnits, for( const std::shared_ptr& item : violations ) { SEVERITY severity = item->GetParent() ? item->GetParent()->GetSeverity() - : RPT_SEVERITY_UNDEFINED; + : bds.GetSeverity( item->GetErrorCode() ); fprintf( fp, "%s", TO_UTF8( item->ShowReport( &unitsProvider, severity, itemMap ) ) ); }