I have an app with two different databases for the development and the production branches. Some tables are shared across the two databases and some are not.
I just deleted one table that was unique to the development database and shared the corresponding table from the production database. No code change was required, because the newly shared table replaced the deleted one with the same name.
After this the app stopped working and the log was littered with anvil.server.PermissionDenied: Cannot read from this table from server code.
Only after I changed one line of code on a server module the app finally restarted working.
I think that the problem was caused by having the persistent server option enabled.