> I am waiting for ENOSPC to be 100% solved and understood
It's understood, there's no black magic. When there's not enough contiguous space to perform a metadata copy (it's a copy on write filesystem, no in-place overwrites!) then it returns an error, even if there's still some free but fragmented space or some free space in the data block groups. A rebalance when metadata blockgroup total size diverges significantly from actual use should solve this.
For small filesystems there also is the option to choose mixed block groups, then there won't be the situation where there's still free space in the data groups while the metadata groups are full.
It's understood, there's no black magic. When there's not enough contiguous space to perform a metadata copy (it's a copy on write filesystem, no in-place overwrites!) then it returns an error, even if there's still some free but fragmented space or some free space in the data block groups. A rebalance when metadata blockgroup total size diverges significantly from actual use should solve this.
For small filesystems there also is the option to choose mixed block groups, then there won't be the situation where there's still free space in the data groups while the metadata groups are full.