BUG report: env.DB.prepare throws error on first load

For Workes & Pages, what is the name of the domain?

example.com

What is the issue or error you’re encountering

At first run after a while await env.DB.prepare fails with error: at D1Database._sendOrThrow (cloudflare-internal:d1-api:66:19)\n at async D1PreparedStatement.first (cloudflare-internal:d1-api:159:35)\n

Can you please share some of your code?

Just call that method, nothing more!