vedic ahalyA

Source: TW

Even being the lover of a married woman is not problematic because we are talking about literal Gods here, forces of nature. Thus we have Vedic references to Índra giving children to the wife of an impotent man (R̥V 1.116.13, 1.117.24, 10.39.7)—though one could choose to interpret this as literally “giving” (√dā) a son without an implication of being a lover, if one wishes.

Adding to this, remember that the most “sexually puritan” religion in the world, Christianity, has their god imprægnating a married woman. Clearly there is no religion aside from ʾIslām that sees gods’ relationships with women the same as mens'.

In any case the word used with Áhalyā in the Brā́hmaṇa-s is jārá “lover” (not necessarily extramarital by the definition of the word—it could theoretically refer to a husband—but in this case necessarily extramarital since Áhalyā Māítrēyī is a human woman and nowhere mentioned to be His wife).

I don’t see anything problematic about either case; in the first, a God is doing a favor to a family by providing them with offspring, and in the second, a virile God is the lover of a human maiden with no mention of deceit by Índra or adultery by Áhalyā. There is no falsehood or transgression of moral law involved.