Might be because flatpak doesn't have access to the directory with the libraries.
Allowing read only permissions for these dri directories might resolve the issue: https://askubuntu.com/questions/1086529/how-to-give-a-flatpak-app-access-to-a-directory