One of the interpretations in the ancient Church tradition that He wrote each of the presenter's sins is theologically speaking correct, for He showed His divine feature of knowing hearts - καρδιογνώστης /Acts 1:24/ - (which feature belongs properly only to the Father, the Son (Jesus), who knows Father just as Father knows Him (Matt 11:27), and Holy Spirit who "knows the depth of God" (1 Cor. 2:10) - the epistemological equality of the three, in fact, indicating their ontological equality also), and this is matching with other such occurrences in the Gospels when Jesus shows the same divine feature, like in Luke 5:22, or Mark 2:8, or in the instance with the Samaritan woman whom He astonished by telling her about all her previous husbands and that her present partner was not her lawful husband in John's ch. 4.
Moreover, He also forgives her, for by saying that "neither I condemn you, go and sin no more", he implies that from that instance onwards the previous sin is not accounted to her, thus showing his another divine feature (again, properly belonging only to the Father, the Son and the Holy Spirit) - the sovereign authority of forgiving sins, which ontologically speaking is nothing else but making a healing touch into one's soul's/heart's depth, for sin is nothing but a scar and infirmity of soul. This authority He shewed in other instances as well, for which He was considered to be a blasphemer as making Himself an usurper and appropriator of something belonging properly only to God (cf. Mark 2:7 or Matthew 9:3).
To sum it up, Jesus makes manifest his double divine feature: 1) knowing the depth of human hearts and 2) and His sovereign authority of forgiving sins, that is to say, of penetrating this human depth with a healing touch of His Grace.
With all that it can be said that the tradition of Jesus' writing each of the presenter's sins (probably it is implied the similar sins of adultery for which they were poised to kill the woman) matches well the Gospels' teaching about the divine dignity of Jesus. Thus the tradition is theologically truthful and in accord with other testimonies of the Gospels. However, whether this tradition is objectively true or not, that is to say, whether they really took a look on Jesus' words written on ground and their consciences were pricked already by them before Jesus said also loudly those famous words, is unclear, and John purposefully leaves a riddle for us that we may be free to venture our interpretations and read the text more attentively and creatively, thus, with a greater spiritual benefit to ourselves.
A possible solution
But is it at all possible that Jesus wrote sins of a l l present there with those threatening stones? Hardly! For had He written sins of all of them, it would have taken too much time both for the Writer and the readers. But it is quite possible and plausible that He wrote sins of few most ardent and zealous among them, the very instigators and leaders of the crowd, and as they read their sins, they dropped the stones, the rest following their lead. It is quite logical also from the textual point of view, as a matter of fact, because we read immediately (John 8:9) that first the eldest left the place the rest following after them; thus, it is quite possible that Jesus wrote sins of those few eldest who were also the leaders and instigators, the driving force of the entire affair, and when those few got pricked in their consciences after seeing their sins written down, then they dropped stones and departed, providing thus an example to the rest, without Jesus having any need to write sins also of the latter.
But again, John leaves us riddles to be solved or speculated about, and admirably so, for our own benefit.