stm32 - i2c communication fail after disconnecting oscilloscope probe
There is too much capacitive coupling between SDA and SCL due to long wiring and bad selection of pinout on the module, where SDA and SCL are next to each other.
The 10k pull-ups are too weak for this level of stray capacitance between the SDA and SCL.
Make the pull-ups stronger, for example 1.2k pull-ups are much stronger but still within specification for a 3.3V I2C bus.