code: def upgrade():
      bind = op.get_bind()
      session = db.Session(bind=bind)
  
      for schedule in (
          session.query(ReportSchedule)
          .filter(ReportSchedule.last_state == ReportState.WORKING)
          .all()
      ):
          schedule.last_value = None
          schedule.last_value_row_json = None
  
      session.commit()
  
      for execution_log in (
          session.query(ReportExecutionLog)
          .filter(ReportExecutionLog.state == ReportState.WORKING)
          .all()
      ):
          execution_log.value = None
          execution_log.value_row_json = None
  
      session.commit()
      session.close()
  
file_path: superset/superset/migrations/versions/2022-05-03_19-39_cbe71abde154_fix_report_schedule_and_log.py
imports: from alembic import op
  from sqlalchemy import Column, Float, Integer, String, Text
  from sqlalchemy.ext.declarative import declarative_base
  from superset import db
  from superset.reports.models import ReportState
label_desc: Use image node_id 1 for calling a global function with example usage: upgrade() without return types