At least in Finland there is nowadays a practice where household solar power producers don’t sell and buy from the grid during same hour. So even if the grid usage or solar production fluctuates within an hour so that eg first 15 min I produce more than I use but then rest of the hour I consume more than I produce the consumption is based on the full hour. This means that in the energy graph in Home Asistant there should never be both Energy Sold and Energy Consumed in the hourly graph. Instead eg the current Energy Sold would be subtracted from the Energy Consumed.
Not sure how typical this is in other countries. Could this be incorporated as an option in the energy configuration options for HA?