ManikandanUV opened a new issue, #26497:
URL: https://github.com/apache/airflow/issues/26497

   ### Apache Airflow version
   
   2.4.0
   
   ### What happened
   
   Stopped existing processes, upgraded from airflow 2.3.4 to 2.4.0, and ran 
airflow db upgrade successfully. Upon restarting the services, I'm not seeing 
any dag runs from the past 10 days. I kick off a new job, and I don't see it 
show up in the grid view. Upon checking the systemd logs, I see that there are 
a lot of postgress errors with webserver. Below is a sample of such errors.
   
   `
   [SQL: INSERT INTO ab_view_menu (name) VALUES (%(name)s) RETURNING 
ab_view_menu.id]
   [parameters: {'name': 'Datasets'}]
   (Background on this error at: https://sqlalche.me/e/14/gkpj)
   [2022-09-19 14:03:16,183] {manager.py:511} ERROR - Creation of Permission 
View Error: (psycopg2.errors.NotNullViolation) null value in column "id" 
violates not-null constraint
   DETAIL:  Failing row contains (null, 13, null).
   
   [SQL: INSERT INTO ab_permission_view (permission_id, view_menu_id) VALUES 
(%(permission_id)s, %(view_menu_id)s) RETURNING ab_permission_view.id]
   [parameters: {'permission_id': 13, 'view_menu_id': None}]
   (Background on this error at: https://sqlalche.me/e/14/gkpj)
   [2022-09-19 14:03:16,209] {manager.py:420} ERROR - Add View Menu Error: 
(psycopg2.errors.NotNullViolation) null value in column "id" violates not-null 
constraint
   DETAIL:  Failing row contains (null, Datasets).
   
   [SQL: INSERT INTO ab_view_menu (name) VALUES (%(name)s) RETURNING 
ab_view_menu.id]
   [parameters: {'name': 'Datasets'}]
   (Background on this error at: https://sqlalche.me/e/14/gkpj)
   [2022-09-19 14:03:16,212] {manager.py:511} ERROR - Creation of Permission 
View Error: (psycopg2.errors.NotNullViolation) null value in column "id" 
violates not-null constraint
   DETAIL:  Failing row contains (null, 17, null).
   
   [SQL: INSERT INTO ab_permission_view (permission_id, view_menu_id) VALUES 
(%(permission_id)s, %(view_menu_id)s) RETURNING ab_permission_view.id]
   [parameters: {'permission_id': 17, 'view_menu_id': None}]
   (Background on this error at: https://sqlalche.me/e/14/gkpj)
   [2022-09-19 14:03:16,229] {manager.py:420} ERROR - Add View Menu Error: 
(psycopg2.errors.NotNullViolation) null value in column "id" violates not-null 
constraint
   DETAIL:  Failing row contains (null, DAG Warnings).
   
   [SQL: INSERT INTO ab_view_menu (name) VALUES (%(name)s) RETURNING 
ab_view_menu.id]
   [parameters: {'name': 'DAG Warnings'}]
   (Background on this error at: https://sqlalche.me/e/14/gkpj)
   [2022-09-19 14:03:16,232] {manager.py:511} ERROR - Creation of Permission 
View Error: (psycopg2.errors.NotNullViolation) null value in column "id" 
violates not-null constraint
   DETAIL:  Failing row contains (null, 17, null).
   
   [SQL: INSERT INTO ab_permission_view (permission_id, view_menu_id) VALUES 
(%(permission_id)s, %(view_menu_id)s) RETURNING ab_permission_view.id]
   [parameters: {'permission_id': 17, 'view_menu_id': None}]
   (Background on this error at: https://sqlalche.me/e/14/gkpj)
   [2022-09-19 14:03:16,250] {manager.py:511} ERROR - Creation of Permission 
View Error: (psycopg2.errors.NotNullViolation) null value in column "id" 
violates not-null constraint
   DETAIL:  Failing row contains (null, 13, 23).
   `
   
   I tried running airflow db check, init, check-migration, upgrade without any 
errors, but the errors still remain. 
   
   Please let me know if I missed any steps during the upgrade, or if this is a 
known issue with a workaround.
   
   ### What you think should happen instead
   
   All dag runs should be visible 
   
   ### How to reproduce
   
   upgrade airflow, upgrade db, restart the services
   
   ### Operating System
   
   Ubuntu 18.04.6 LTS
   
   ### Versions of Apache Airflow Providers
   
   _No response_
   
   ### Deployment
   
   Official Apache Airflow Helm Chart
   
   ### Deployment details
   
   _No response_
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to