5

I was given a database backup (with filestore), the filestore folder and another folder with the installed modules on that database.

I am expected to restore that backup in Odoo 8 with no more data. So what I did is create the PostgreSQL role who owns the database tables and give it enough permissions (login, createdb, replication). Then I created an Odoo config file. Inside this, I set this new PostgreSQL role in db_user and its password in db_password. I added the path where I stored the filestore in data_dir, and the path of the folder with all the modules in addons_path.

As I was given no launcher file, I copied the OCB folder of other Odoo instance I have and used its odoo.py file to start Odoo.

The new instance seems to run well, but now I have just restored the database, and I get this error:

QWebException: "'HttpRequest' object has no attribute 'endpoint_arguments'" while evaluating
'website.get_alternate_languages(request.httprequest)'

I was googling a lot but I was not able to find anything about it, except for a non-answered question in other forum.

Does anyone know what is this about?

forvas
  • 9,801
  • 7
  • 62
  • 158
  • Can you please tell me your actual aim ? What you want to do with that ? – Emipro Technologies Pvt. Ltd. Aug 23 '16 at 05:54
  • It seems you are not using official Odoo (as you mention OCB folder, it should be one from the OCA?) Either switch to the latest official Odoo 8.0 as I suggested or if for any reason you cannot switch to the official version, than you can manually pick up the two changes that I referenced in my answer and apply them to your Odoo instance. Anyway an update of your instance still may be a solution for your OCA version as well, if OCA have the same fix applied to their version, if not than the manual change will be necessary. – T.V. Aug 23 '16 at 19:22
  • [sometimes OCA version is updated with a delay](https://www.odoo.com/fr_FR/forum/aide-1/question/why-is-the-ocb-v8-github-repository-less-recent-then-the-official-odoo-v8-60949) + the time since you last updated your server. So... – T.V. Aug 23 '16 at 19:27

2 Answers2

1

Changes related to this issue were introduced in Odoo on 29 February, 2016 (I mean the following changes: [FIX] website: alternate languages translated URL and [FIX] website: backport of as you can check for now these changes are available in the official Odoo 8.0 code base as well).
So most probably you have used outdated Odoo 8.0 server that do not contain above mentioned fixes. Please update to the latest official Odoo 8.0 and check if the issue still persists. Normally your issue should disappear after the update.

T.V.
  • 467
  • 5
  • 8
0

When you move backup databases and you want to restore them later on, make sure you mark the branch and commit point of the server files that you took the backup from. I have taken a look at my local v8 odoo and I can see that the endpoint_arguments variable is initialised upon the creation of a web request (openerp/http.py class WebRequest around line 192.)

You mention though that you are restoring the database on the v8 OCB Odoo. If you navigate their distribution and on commit:

https://github.com/OCA/OCB/commit/3913667396e17075528108ac1031939e6f479ced#diff-5e2f434047c379642786a87195c806f9

you will see that this variable was missing and they have added it. So make sure that you git pull the server file to get that commit.

The root of the issue is that you took a backup from a server that had different codebase than the one you are trying to restore the database to. (The qweb file was searching for a variable that is not there)

George Daramouskas
  • 3,720
  • 3
  • 22
  • 51