Need help in logic condition - python script?

Hi ,
Need help in logic :
if([j, ‘Key’] ==[i, ‘Key’]) then the below case will happen. (note df2,df1 key contains multiple rows)

Qualified =

CASE WHEN Timesheet Date >=Date Start && Timesheet Date <= Date End Comments contains “L” then “Learner”

     WHEN Timesheet Date >= Date Start && Timesheet Date <= Date Expiry then "Qualified"

     WHEN Timesheet Date >=Date End && Date Expiry = null then "Not Qualified"

     WHEN Timesheet Date < Date Start then "Learner"
import pandas as pd
import numpy as np
import os

import datetime 

df1 = pd.read_excel(r'C:\Users\sbhadra\AppData\Local\Programs\Python Scripts\Excel\data.xlsx')
df2 = pd.read_excel(r'C:\Users\sbhadra\AppData\Local\Programs\Python Scripts\Excel\Q.xlsx')

df1 = df1[['Key','Employee Code','Skill Code','Timesheet Date','Qualified']]
df1['Timesheet Date']=df1['Timesheet Date'].astype('datetime64[ns]')

df2 = df2[['Key','Employee Code','Qualification ID','Date Start','Date End','Date Expiry','Comments','Skill Level','Skill Qualified']]
df2['Qualification ID']=df2['Qualification ID'].fillna(-1)
df2['Qualification ID']=df2['Qualification ID'].astype(int)
df2['Date Start']=df2['Date Start'].astype('datetime64[ns]')
df2['Date End']=df2['Date End'].astype('datetime64[ns]') 
df2['Date Expiry']=df2['Date Expiry'].astype('datetime64[ns]')     

for i in df2.index:
    if(pd.isnull([i, 'Date End'])):[i, 'Date End'] =[i, 'Date Start']

for i in df1.index:
    for j in df2.index:
        if([j, 'Key'] ==[i, 'Key']):
            if([i, 'Timesheet Date'] >=[i, 'Date Start'] and[i, 'Timesheet Date'] <=[i, 'Date Start']):
      [i, 'Qualified'] = 'Learner'
        print(i,[i, 'Employee Code'],[i, 'Skill Code'],[i, 'Timesheet Date'],[i, 'Date Start'],[i, 'Date End'],[i, 'Date Expiry'])

Please find the path for the code;

Any help is appreciated.