Axes.twinx, twiny use figure.add_axes, so they return a plain Axes, not a SubplotBase. Therefore tight_layout doesn't recognize them.