Try this line of code here:
df.set_index('key').join(df2.set_index('key'))
You can check the documentation on the 'key' to reference your code properlly.
https://pandas.pydata.org/pandas-docs/stable/generated/pandas.DataFrame.join.html
Set the 'key' equal to the column you wish to merge with the rest!
Hope this helps.