andypp opened a new issue #10502:
URL: https://github.com/apache/airflow/issues/10502


   **Apache Airflow version**: 2.0.0-dev (master)     
                                                                                
                                                                 
   **What happened**:                                  
                                                                                
                                                                
   retry logs for attempts (try number) > 1 are appended to log for attempt 
1.Logs for attempts > 1 only show `Log file does not exist`                     
                                        
   
   **What you expected to happen**:            
                                                                                
                                                                        
   each retry should output logs to their own files    
                                                                                
                                                                
   **How to reproduce it**:           
                                                                                
                                                                                
 
   run DAG with a task that fail with retry, once the task fail, view the log
   
   **Anything else we need to know**:      
                                                                                
                                                                            
   this seems to happen after apache/airflow#7370 that deletes 
`ti.refresh_from_db()` from task_instance                                       
                                                     
   ```diff
   index 8ce74a246..d5ae41a3d 100644                                            
                                                                                
                                    --- a/airflow/cli/commands/task_command.py  
                                                                                
                                                                     +++ 
b/airflow/cli/commands/task_command.py                                          
                                                                                
                             @@ -169,8 +169,6 @@ def task_run(args, dag=None):  
                                                                                
                                                                   task = 
dag.get_task(task_id=args.task_id)
        ti = TaskInstance(task, args.execution_date)
   -    ti.refresh_from_db()
   -
        ti.init_run_context(raw=args.raw)
   ```
   


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

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


Reply via email to