update python warning syntax