When trading with villagers, or not even trading with them at all, a very small amount of them will just have their GUI's flash on my screen then they disappear almost instantly. I reloaded the game a few times and it still wouldn't work. Even a villager I got to the master level all of a sudden wouldn't trade with me because of this bug. I thought it was my resource pack too, but i turned on the default one and it still was occurring. I don't know whats causing it, but all I know this happens to some villagers and then it may occur randomly to another,
Thank you for your report!
We're actually already tracking this issue in MC-154201, so I resolved and linked this ticket as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.