You can also make it a bit prettier by adding spaces:
>>> print(f"{d['key'][1] = }")
d['key'][1] = 'one'
It works with any expression you like, not just variables: >>> print(f'{np.sin(np.pi/4.) = }')
np.sin(np.pi/4.) = 0.7071067811865475