I find duplicate strings where there is null. I get labels by comparing the main data frame([False False True False False True False False True]). Apply masking using ~, that is, I show rows with opposite indexes.
import pandas as pd
df = pd.DataFrame({'patientld': [89, 84, 84, 9, 9, 84, 5, 3, 84],
'pathology': ['null', 'null', 'null', 'yes', 'null', 'null', 'yes', 'yes', 'null']})
a = df[(df.duplicated()) & (df['pathology'].isin(['null']))]
index = df.index.isin(a.index)
print(df[~index])
Output
patientld pathology
0 89 null
1 84 null
3 9 yes
4 9 null
6 5 yes
7 3 yes