https://dagster.io/ logo
#ask-community
Title
# ask-community
l

ljx

08/08/2022, 3:16 AM
Hey folks, I've been through this error message for quite a while. I've just set up a repository and include my sensor in the list that it returns. The sensor could run smoothly as I could see in dagster-daemon. But when I click on the sensor tab on the instance status page, an error shows like this.
Copy code
Operation name: InstanceSensorsQuery

Message: (mysql.connector.errors.ProgrammingError) 1054 (42S22): Unknown column 'job_ticks.selector_id' in 'field list'
[SQL: SELECT subquery.id, subquery.selector_id, subquery.tick_body 
FROM (SELECT job_ticks.id AS id, job_ticks.selector_id AS selector_id, job_ticks.tick_body AS tick_body, rank() OVER (PARTITION BY job_ticks.selector_id ORDER BY job_ticks.timestamp DESC) AS `rank` 
FROM job_ticks 
WHERE job_ticks.selector_id IN (%(selector_id_1_1)s)) AS subquery 
WHERE subquery.`rank` <= %(rank_1)s ORDER BY subquery.`rank` ASC]
[parameters: {'rank_1': 1, 'selector_id_1_1': '8a00ac238c48f7ecb32b9e789fc63f58e8aec04e'}]
(Background on this error at: <https://sqlalche.me/e/14/f405>)

Path: ["repositoriesOrError","nodes",0,"sensors",0,"sensorState","ticks"]

Locations: [{"line":150,"column":3}]
I have searched through the slack channel and find out someone has asked a similar question a long time ago. https://dagster.slack.com/archives/C01U954MEER/p1650481399208629 I've tried to check the mysql-connector-python package, it has already been the latest (8.0.29) version. My sqlalchemy version is 1.4.39, dagster version is 0.15.7, and the dagster-mysql version is 0.15.7. Thanks in advance!
c

claire

08/08/2022, 8:16 PM
Hi @ljx. Can you try running
dagster instance migrate
?
l

ljx

08/09/2022, 6:09 AM
it works! Thank u
🌈 1
3 Views