I am working on an airflow version 1.9.0 (Python 2.7) while starting the airflow I am getting the below exception, everything in the SQL/SQLite db looks good, can someone help me debug this
below is an exception I get on dag view, i am getting a similar error on dag runs (backfill, runs)
____/ ( ( ) ) ___
/( ( ( ) _ )) ) )
(( ( )( ) ) ( ) )
((/ ( _( ) ( _) ) ( () ) )
( ( ( (_) (( ( ) .((_ ) . )_
( ( ) ( ( ) ) ) . ) ( )
( ( ( ( ) ( _ ( _) ). ) . ) ) ( )
( ( ( ) ( ) ( )) ) _)( ) ) )
( ( ( ) ( (_ ( ) ( ) ) ) ) )) ( )
( ( ( ( (_ ( ) ( _ ) ) ( ) ) )
( ( ( ( ( ) (_ ) ) ) _) ) _( ( )
(( ( )( ( _ ) _) _(_ ( (_ )
(_((__(_(__(( ( ( | ) ) ) )_))__))_)___)
((__) \||lll|l||/// _))
( /(/ ( ) ) ) )
( ( ( ( | | ) ) ) )
( /(| / ( )) ) ) )) )
( ( ((((_(|)_))))) )
( ||(|(|)|/|| )
( |(||(||)|||| )
( //|/l|||)|\ )
(/ / // /|//||||\ _)
-------------------------------------------------------------------------------
Node: <>
-------------------------------------------------------------------------------
Traceback (most recent call last):
File "/mnt/airflow/venv/local/lib/python2.7/site-packages/flask/app.py", line 1988, in wsgi_app
response = self.full_dispatch_request()
File "/mnt/airflow/venv/local/lib/python2.7/site-packages/flask/app.py", line 1641, in full_dispatch_request
rv = self.handle_user_exception(e)
[...rest of traceback see edit history...]
first_packet = self.connection._read_packet()
File "/mnt/airflow/venv/local/lib/python2.7/site-packages/pymysql/connections.py", line 676, in _read_packet
packet.raise_for_error()
File "/mnt/airflow/venv/local/lib/python2.7/site-packages/pymysql/protocol.py", line 223, in raise_for_error
err.raise_mysql_exception(self._data)
File "/mnt/airflow/venv/local/lib/python2.7/site-packages/pymysql/err.py", line 107, in raise_mysql_exception
raise errorclass(errno, errval)
ProgrammingError: (pymysql.err.ProgrammingError) (1064, u"You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '[(\'dag_id\', u\'test-dag\')]'')' at line 1") [SQL: u'INSERT INTO log (dttm, dag_id, task_id, event, execution_date, owner, extra) VALUES (%(dttm)s, %(dag_id)s, %(task_id)s, %(event)s, %(execution_date)s, %(owner)s, %(extra)s)'] [parameters: {'task_id': None, 'extra': "[('dag_id', u'test-dag')]", 'execution_date': None, 'event': 'graph', 'owner': None, 'dttm': datetime.datetime(2024, 4, 23, 2, 15, 13, 141266), 'dag_id': u'test-dag'}]
sql table ddl (it is created by airflow itself using airflow.cfg path, if i am not wrong).
CREATE TABLE `log` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`dttm` datetime(6) DEFAULT NULL,
`dag_id` varchar(250) DEFAULT NULL,
`task_id` varchar(250) DEFAULT NULL,
`event` varchar(30) DEFAULT NULL,
`execution_date` datetime(6) DEFAULT NULL,
`owner` varchar(500) DEFAULT NULL,
`extra` text DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=32179 DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci;
I am new to this older version, I gave it a try to check all possibilities, i have restarted airflow as well, but no help