I have been using Thunderbird for many years now and the other day the system upgraded to the latest version since then I am unable to get mail from my Gmail account. All existing mail has gone from my inbox and sent items. However the windows notification tells me that I have mail in my Gmail account
the error that comes up is
The current operation on 'Inbox' did not succeed. The mail server for account firstname.lastname@example.org responded: System Error (Failure).
when clicking on my inbox folder of that account. The same also happens when I click on the "Important" folder of that account or on "All Mail". It does, however, not happen when clicking on "Starred", "Sent Mail", or "Drafts".
I of course googled this problem and read that this happens when IMAP is disabled. However, I didn't touch the settings of my email account before this problem randomly occurred. Disabling and re-enabling IMAP did not help either. Gmail also suggested that I switch on the setting for less secure app which I also tried but no difference
How can this problem be resolved?