Open guythnick opened 1 year ago
Sorry for my English, I'm using google translate here.
I believe this error was caused by changing the check method of the ir_attchment model. Apparently this modification added the following lines:
if not self.env.is_system() and (res_field or (not res_id and create_uid != self.env.uid)):
raise AccessError(_("Sorry, you are not allowed to access this document."))
As far as I understand, if the file is linked to a certain field or not linked to a specific record and the user who uploaded it is different from the current one, the code will display an error.
In my case, access to the file was done by a cron, so to solve the problem I linked the system administration role (base.group_system) to the user linked to cron, so that he could access the file even though he was not the its creator.
In my case, access to the file was done by a cron, so to solve the problem I linked the system administration role (base.group_system) to the user linked to cron, so that he could access the file even though he was not the its creator.
@Moscardi , can you explain where you made this change? Was it in the database or the docker image file system?
Looking at the server logs I was able to identify which cron job was accessing the document. Upon identification, I went to the Odoo interface that manages the cron tasks and looked at the "Scheduler User" field to see which user is being used by cron to perform the accesses.
Knowing who the user is, it is possible to go to Odoo's user management and grant access to "settings" in the "administration" category. This access is what has the "base.group_system" identifier that I mentioned earlier.
Remembering that to make all these modifications you need to have developer access to Odoo.
Ah, I see. I don't think that is the same issue as I am having. In my case, pages do not even display in the browser.
Jeez, it's true, now that I've seen it, the error message is very similar but in my case it was an access error, in yours it's showing as file not found.
Sorry, it was my fault, I should have paid more attention and read the issue more calmly.
@guythnick I just read your issue. So you upgraded ("pulled") a new Odoo:16 image and this happened to you?
Can you share:
Have been running odoo:16 successfully for a while now. Some update in Feb 2023 has caused the page to just be white. No images work, and when clicking on a link from the splash page it will show only a white screen. When trying to navigate to a page, the below error is shown: