ephraimbuddy commented on PR #38743:
URL: https://github.com/apache/airflow/pull/38743#issuecomment-2037779329

   > > It's necessary because we execute the method each time we run the 
downgrade command, so later when we want to downgrade 2.9.1+ to 2.9.0, we 
should skip the decryption
   > 
   > Yeah. condition to run decrypt is is right - but as @ephraimbuddy it's not 
the condition to run the method that is wrong, it's the `if not 
inspect(session.bind).has_table(Trigger.__tablename__): ` that caused the query 
to be skipped which is really the cause it has not been found before _I think_
   
   I think the code is right. If the table has been dropped, the decrypt is not 
run. Because in 2.8.4, we still have the trigger table, the decryption ran and 
failed. The code path is only evaluated at the end of migrations so if user is 
going from 2.9.0 to 2.0.0, it will only be run when the migration completes and 
DB in 2.0.0 state


-- 
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