From 0528e56f4c604c2861b7935c8b3492ba9a3d5931 Mon Sep 17 00:00:00 2001 From: "sergio.teruel" Date: Mon, 29 May 2017 17:25:12 +0200 Subject: [PATCH 01/99] [MIG] connector_prestashop: Begin of migration to v10 --- connector_prestashop/README.rst | 171 + connector_prestashop/__init__.py | 7 + connector_prestashop/__manifest__.py | 62 + connector_prestashop/backend.py | 15 + connector_prestashop/connector.py | 12 + connector_prestashop/consumer.py | 69 + connector_prestashop/data/cron.xml | 95 + connector_prestashop/data/ecommerce_data.xml | 43 + .../data/product_decimal_precision.xml | 6 + connector_prestashop/demo/backend.xml | 13 + connector_prestashop/models/__init__.py | 28 + .../models/account_invoice/__init__.py | 4 + .../models/account_invoice/common.py | 93 + .../models/account_invoice/importer.py | 269 + .../models/account_payment_mode/__init__.py | 4 + .../models/account_payment_mode/common.py | 45 + .../models/account_payment_mode/importer.py | 49 + .../models/account_tax/__init__.py | 4 + .../models/account_tax/common.py | 40 + .../models/account_tax/importer.py | 25 + .../models/account_tax_group/__init__.py | 4 + .../models/account_tax_group/common.py | 53 + .../models/account_tax_group/importer.py | 46 + .../models/binding/__init__.py | 4 + connector_prestashop/models/binding/common.py | 51 + .../models/delivery_carrier/__init__.py | 5 + .../models/delivery_carrier/common.py | 69 + .../models/delivery_carrier/exporter.py | 2 + .../models/delivery_carrier/importer.py | 76 + .../models/mail_message/__init__.py | 4 + .../models/mail_message/common.py | 40 + .../models/mail_message/importer.py | 67 + .../models/prestashop_backend/__init__.py | 4 + .../models/prestashop_backend/common.py | 323 + .../models/prestashop_backend/importer.py | 35 + .../models/product_category/__init__.py | 4 + .../models/product_category/common.py | 63 + .../models/product_category/importer.py | 116 + .../models/product_image/__init__.py | 5 + .../models/product_image/common.py | 93 + .../models/product_image/deleter.py | 15 + .../models/product_image/importer.py | 119 + .../models/product_pricelist/__init__.py | 4 + .../models/product_pricelist/common.py | 41 + .../models/product_pricelist/importer.py | 52 + .../models/product_product/__init__.py | 6 + .../models/product_product/common.py | 256 + .../models/product_product/deleter.py | 15 + .../models/product_product/exporter.py | 16 + .../models/product_product/importer.py | 396 + .../models/product_supplierinfo/__init__.py | 4 + .../models/product_supplierinfo/common.py | 92 + .../models/product_supplierinfo/importer.py | 186 + .../models/product_template/__init__.py | 5 + .../models/product_template/common.py | 213 + .../models/product_template/exporter.py | 50 + .../models/product_template/importer.py | 678 + .../models/res_country/__init__.py | 4 + .../models/res_country/common.py | 42 + .../models/res_country/importer.py | 24 + .../models/res_currency/__init__.py | 4 + .../models/res_currency/common.py | 43 + .../models/res_currency/importer.py | 19 + .../models/res_lang/__init__.py | 4 + .../models/res_lang/common.py | 47 + .../models/res_lang/importer.py | 22 + .../models/res_partner/__init__.py | 4 + .../models/res_partner/common.py | 172 + .../models/res_partner/importer.py | 241 + .../models/res_partner_category/__init__.py | 4 + .../models/res_partner_category/common.py | 53 + .../models/res_partner_category/importer.py | 57 + .../models/sale_order/__init__.py | 4 + .../models/sale_order/common.py | 169 + .../models/sale_order/importer.py | 504 + .../models/sale_order_state/__init__.py | 5 + .../models/sale_order_state/common.py | 77 + .../models/sale_order_state/exporter.py | 46 + .../models/sale_order_state/importer.py | 42 + .../models/stock_move/__init__.py | 3 + .../models/stock_move/common.py | 53 + .../models/stock_tracking/__init__.py | 4 + .../models/stock_tracking/common.py | 12 + .../models/stock_tracking/exporter.py | 61 + .../models/stock_warehouse/__init__.py | 4 + .../models/stock_warehouse/common.py | 61 + .../models/stock_warehouse/importer.py | 43 + .../security/ir.model.access.csv | 43 + .../security/prestashop_security.xml | 60 + .../static/description/icon.png | Bin 0 -> 7665 bytes .../static/description/icon.svg | 230 + connector_prestashop/tests/.gitignore | 1 + connector_prestashop/tests/__init__.py | 12 + connector_prestashop/tests/common.py | 355 + .../fixtures/cassettes/sync_metadata.yaml | 144 + .../fixtures/cassettes/test_auth_failure.yaml | 28 + .../fixtures/cassettes/test_auth_success.yaml | 25 + .../cassettes/test_export_stock_quantity.yaml | 109 + .../test_export_tracking_number.yaml | 112 + .../cassettes/test_import_basedata.yaml | 10909 ++++++++++++++++ .../cassettes/test_import_carrier_batch.yaml | 43 + .../test_import_carrier_record_2.yaml | 43 + .../test_import_inventory_batch.yaml | 185 + ...st_import_inventory_record_template_1.yaml | 32 + ...est_import_inventory_record_variant_1.yaml | 32 + .../cassettes/test_import_metadata.yaml | 144 + .../test_import_partner_address_batch.yaml | 43 + .../test_import_partner_address_record_1.yaml | 42 + .../cassettes/test_import_partner_batch.yaml | 86 + ...test_import_partner_category_record_1.yaml | 67 + .../test_import_partner_record_1.yaml | 49 + .../cassettes/test_import_product_batch.yaml | 112 + ...test_import_product_category_record_1.yaml | 262 + ...test_import_product_template_record_1.yaml | 3886 ++++++ .../cassettes/test_import_sale_batch.yaml | 86 + .../cassettes/test_import_sale_record_5.yaml | 320 + connector_prestashop/tests/test_auth.py | 24 + .../tests/test_export_stock_qty.py | 61 + .../tests/test_export_stock_qty_job.py | 74 + .../tests/test_export_tracking.py | 157 + .../tests/test_import_backend_data.py | 78 + .../tests/test_import_carrier.py | 95 + .../tests/test_import_inventory.py | 113 + .../tests/test_import_partner.py | 228 + .../tests/test_import_products.py | 236 + .../tests/test_import_sale.py | 230 + connector_prestashop/unit/__init__.py | 13 + .../unit/auto_matching_importer.py | 118 + connector_prestashop/unit/backend_adapter.py | 222 + connector_prestashop/unit/binder.py | 43 + connector_prestashop/unit/deleter.py | 29 + connector_prestashop/unit/exception.py | 8 + .../unit/export_synchronizer.py | 198 + connector_prestashop/unit/exporter.py | 350 + connector_prestashop/unit/importer.py | 504 + connector_prestashop/unit/mapper.py | 128 + connector_prestashop/unit/version_key.py | 59 + connector_prestashop/views/account_view.xml | 52 + .../views/connector_prestashop_menu.xml | 40 + connector_prestashop/views/delivery_view.xml | 50 + connector_prestashop/views/image_view.xml | 20 + connector_prestashop/views/partner_view.xml | 136 + .../views/prestashop_model_view.xml | 277 + .../views/product_category_view.xml | 56 + connector_prestashop/views/product_view.xml | 173 + connector_prestashop/views/sale_view.xml | 155 + connector_prestashop/views/stock_view.xml | 18 + 147 files changed, 27499 insertions(+) create mode 100644 connector_prestashop/README.rst create mode 100644 connector_prestashop/__init__.py create mode 100644 connector_prestashop/__manifest__.py create mode 100644 connector_prestashop/backend.py create mode 100644 connector_prestashop/connector.py create mode 100644 connector_prestashop/consumer.py create mode 100644 connector_prestashop/data/cron.xml create mode 100644 connector_prestashop/data/ecommerce_data.xml create mode 100644 connector_prestashop/data/product_decimal_precision.xml create mode 100644 connector_prestashop/demo/backend.xml create mode 100644 connector_prestashop/models/__init__.py create mode 100644 connector_prestashop/models/account_invoice/__init__.py create mode 100644 connector_prestashop/models/account_invoice/common.py create mode 100644 connector_prestashop/models/account_invoice/importer.py create mode 100644 connector_prestashop/models/account_payment_mode/__init__.py create mode 100644 connector_prestashop/models/account_payment_mode/common.py create mode 100644 connector_prestashop/models/account_payment_mode/importer.py create mode 100644 connector_prestashop/models/account_tax/__init__.py create mode 100644 connector_prestashop/models/account_tax/common.py create mode 100644 connector_prestashop/models/account_tax/importer.py create mode 100644 connector_prestashop/models/account_tax_group/__init__.py create mode 100644 connector_prestashop/models/account_tax_group/common.py create mode 100644 connector_prestashop/models/account_tax_group/importer.py create mode 100644 connector_prestashop/models/binding/__init__.py create mode 100644 connector_prestashop/models/binding/common.py create mode 100644 connector_prestashop/models/delivery_carrier/__init__.py create mode 100644 connector_prestashop/models/delivery_carrier/common.py create mode 100644 connector_prestashop/models/delivery_carrier/exporter.py create mode 100644 connector_prestashop/models/delivery_carrier/importer.py create mode 100644 connector_prestashop/models/mail_message/__init__.py create mode 100644 connector_prestashop/models/mail_message/common.py create mode 100644 connector_prestashop/models/mail_message/importer.py create mode 100644 connector_prestashop/models/prestashop_backend/__init__.py create mode 100644 connector_prestashop/models/prestashop_backend/common.py create mode 100644 connector_prestashop/models/prestashop_backend/importer.py create mode 100644 connector_prestashop/models/product_category/__init__.py create mode 100644 connector_prestashop/models/product_category/common.py create mode 100644 connector_prestashop/models/product_category/importer.py create mode 100644 connector_prestashop/models/product_image/__init__.py create mode 100644 connector_prestashop/models/product_image/common.py create mode 100644 connector_prestashop/models/product_image/deleter.py create mode 100644 connector_prestashop/models/product_image/importer.py create mode 100644 connector_prestashop/models/product_pricelist/__init__.py create mode 100644 connector_prestashop/models/product_pricelist/common.py create mode 100644 connector_prestashop/models/product_pricelist/importer.py create mode 100644 connector_prestashop/models/product_product/__init__.py create mode 100644 connector_prestashop/models/product_product/common.py create mode 100644 connector_prestashop/models/product_product/deleter.py create mode 100644 connector_prestashop/models/product_product/exporter.py create mode 100644 connector_prestashop/models/product_product/importer.py create mode 100644 connector_prestashop/models/product_supplierinfo/__init__.py create mode 100644 connector_prestashop/models/product_supplierinfo/common.py create mode 100644 connector_prestashop/models/product_supplierinfo/importer.py create mode 100644 connector_prestashop/models/product_template/__init__.py create mode 100644 connector_prestashop/models/product_template/common.py create mode 100644 connector_prestashop/models/product_template/exporter.py create mode 100644 connector_prestashop/models/product_template/importer.py create mode 100644 connector_prestashop/models/res_country/__init__.py create mode 100644 connector_prestashop/models/res_country/common.py create mode 100644 connector_prestashop/models/res_country/importer.py create mode 100644 connector_prestashop/models/res_currency/__init__.py create mode 100644 connector_prestashop/models/res_currency/common.py create mode 100644 connector_prestashop/models/res_currency/importer.py create mode 100644 connector_prestashop/models/res_lang/__init__.py create mode 100644 connector_prestashop/models/res_lang/common.py create mode 100644 connector_prestashop/models/res_lang/importer.py create mode 100644 connector_prestashop/models/res_partner/__init__.py create mode 100644 connector_prestashop/models/res_partner/common.py create mode 100644 connector_prestashop/models/res_partner/importer.py create mode 100644 connector_prestashop/models/res_partner_category/__init__.py create mode 100644 connector_prestashop/models/res_partner_category/common.py create mode 100644 connector_prestashop/models/res_partner_category/importer.py create mode 100644 connector_prestashop/models/sale_order/__init__.py create mode 100644 connector_prestashop/models/sale_order/common.py create mode 100644 connector_prestashop/models/sale_order/importer.py create mode 100644 connector_prestashop/models/sale_order_state/__init__.py create mode 100644 connector_prestashop/models/sale_order_state/common.py create mode 100644 connector_prestashop/models/sale_order_state/exporter.py create mode 100644 connector_prestashop/models/sale_order_state/importer.py create mode 100644 connector_prestashop/models/stock_move/__init__.py create mode 100644 connector_prestashop/models/stock_move/common.py create mode 100644 connector_prestashop/models/stock_tracking/__init__.py create mode 100644 connector_prestashop/models/stock_tracking/common.py create mode 100644 connector_prestashop/models/stock_tracking/exporter.py create mode 100644 connector_prestashop/models/stock_warehouse/__init__.py create mode 100644 connector_prestashop/models/stock_warehouse/common.py create mode 100644 connector_prestashop/models/stock_warehouse/importer.py create mode 100644 connector_prestashop/security/ir.model.access.csv create mode 100644 connector_prestashop/security/prestashop_security.xml create mode 100644 connector_prestashop/static/description/icon.png create mode 100644 connector_prestashop/static/description/icon.svg create mode 100644 connector_prestashop/tests/.gitignore create mode 100644 connector_prestashop/tests/__init__.py create mode 100644 connector_prestashop/tests/common.py create mode 100644 connector_prestashop/tests/fixtures/cassettes/sync_metadata.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_auth_failure.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_auth_success.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_export_stock_quantity.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_export_tracking_number.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_basedata.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_carrier_batch.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_carrier_record_2.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_inventory_batch.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_template_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_variant_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_metadata.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_batch.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_record_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_partner_batch.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_partner_category_record_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_partner_record_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_product_batch.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_product_category_record_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_product_template_record_1.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_sale_batch.yaml create mode 100644 connector_prestashop/tests/fixtures/cassettes/test_import_sale_record_5.yaml create mode 100644 connector_prestashop/tests/test_auth.py create mode 100644 connector_prestashop/tests/test_export_stock_qty.py create mode 100644 connector_prestashop/tests/test_export_stock_qty_job.py create mode 100644 connector_prestashop/tests/test_export_tracking.py create mode 100644 connector_prestashop/tests/test_import_backend_data.py create mode 100644 connector_prestashop/tests/test_import_carrier.py create mode 100644 connector_prestashop/tests/test_import_inventory.py create mode 100644 connector_prestashop/tests/test_import_partner.py create mode 100644 connector_prestashop/tests/test_import_products.py create mode 100644 connector_prestashop/tests/test_import_sale.py create mode 100644 connector_prestashop/unit/__init__.py create mode 100644 connector_prestashop/unit/auto_matching_importer.py create mode 100644 connector_prestashop/unit/backend_adapter.py create mode 100644 connector_prestashop/unit/binder.py create mode 100644 connector_prestashop/unit/deleter.py create mode 100644 connector_prestashop/unit/exception.py create mode 100644 connector_prestashop/unit/export_synchronizer.py create mode 100644 connector_prestashop/unit/exporter.py create mode 100644 connector_prestashop/unit/importer.py create mode 100644 connector_prestashop/unit/mapper.py create mode 100644 connector_prestashop/unit/version_key.py create mode 100644 connector_prestashop/views/account_view.xml create mode 100644 connector_prestashop/views/connector_prestashop_menu.xml create mode 100644 connector_prestashop/views/delivery_view.xml create mode 100644 connector_prestashop/views/image_view.xml create mode 100644 connector_prestashop/views/partner_view.xml create mode 100644 connector_prestashop/views/prestashop_model_view.xml create mode 100644 connector_prestashop/views/product_category_view.xml create mode 100644 connector_prestashop/views/product_view.xml create mode 100644 connector_prestashop/views/sale_view.xml create mode 100644 connector_prestashop/views/stock_view.xml diff --git a/connector_prestashop/README.rst b/connector_prestashop/README.rst new file mode 100644 index 000000000..e53c35ec7 --- /dev/null +++ b/connector_prestashop/README.rst @@ -0,0 +1,171 @@ +.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +========================= +Odoo PrestaShop Connector +========================= + +This module connects Odoo and PrestaShop. + +PrestaShop (http://www.prestashop.com/) is a popular e-commerce platform +written in PHP/MySQL and published under the Open Software licence v3.0. + +This module allows the synchronization of the following objects from PrestaShop +to Odoo: + +* Websites +* Stores and languages +* Carriers +* Product categories +* Products +* Combinations of products +* Partner categories +* Customers + +Once these objects are synchronised, it will allow the import of sales orders, +together with the related customers. + +As an extra feature, you can also export the stock quantities back to +PrestaShop. + +If you want to export from Odoo to PrestaShop changes made on the products, +product categories or product images, you need to install +*connector_prestashop_catalog_manager* module in this same repository. + +This connector supports PrestaShop version up to 1.6.11. Maybe later versions +are also supported, but they haven't been tested. It uses the webservices of +PrestaShop. + +Installation +============ + +It doesn't require any plug-in in PrestaShop, but requires an extra Python +library in Odoo server side, called prestapyt: + +https://github.com/prestapyt/prestapyt/ + +You can use pip install system to install it + +`sudo pip install prestapyt` + +Configuration +============= + +To configure this module, you need to set several things in both PrestaShop +and Odoo: + +Steps in PrestaShop +------------------- + +#. Go to the control panel (usually at /adminps). +#. Login into the system. +#. Go to *Advanced Parameters > Web service* +#. Add a new entry. +#. Generate a new API key that will be needed later. +#. Grant all the needed access according your security policy. + +Steps in Odoo +------------- + +#. Go to *Connectors > PrestaShop > Backends*. +#. Create a new record for registering a PrestaShop backend. You will bind + this backend to an specific company and warehouse. +#. Define the main URL of the PrestaShop web, and the webservice key you + got in PrestaShop. +#. Define other parameters like the discount and shipping products, or if the + taxes are included in the price. +#. Click on "Synchronize Metadata" button. This will bring the basic shop + information that you can find on *Websites* and *Stores* menus. +#. Click on "Synchronize Base Data" button. This will import carriers, + languages, tax groups and the rest of base data that are needed for the + proper work. +#. Go to *Accounting > Configuration > Taxes > Tax Groups*, and include + for each of the tax definition imported from PrestaShop, the corresponding + taxes in Odoo. +#. Activate the job runner, checking the connector documentation for setting + the server correctly for using it in + http://odoo-connector.com/guides/jobrunner.html +#. Alternatively, if you are not able to activate it, you can enable the + scheduled job called "Enqueue Jobs". +#. Activate the scheduled jobs for importing the records you want: + + * PrestaShop - Export Stock Quantities + * PrestaShop - Import Carriers + * PrestaShop - Import Customers and Groups + * PrestaShop - Import Products and Categories + * PrestaShop - Import Sales Orders + * PrestaShop - Import suppliers + * PrestaShop - Payment methods + +Usage +===== + +To use this module, you need to: + +#. Go to *Connectors > Queue > Jobs*, and check the correct enqueuing of + the tasks. +#. Check on each menu the resulting imported records (Customers, Sales + Orders...) + +.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas + :alt: Try me on Runbot + :target: https://runbot.odoo-community.org/runbot/108/9.0 + +Test dependencies +================= + +Extra libs are required to run the tests: +* ``vcrpy`` +* ``freezegun`` + +Known issues / Roadmap +====================== + +* Work with multiple warehouses. +* Tests. + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues +`_. In case of trouble, please +check there if your issue has already been reported. If you spotted it first, +help us smashing it by providing a detailed and welcomed feedback. + +Credits +======= + +Images +------ + +* `PrestaShop logo `_. +* `Odoo logo `_. +* `Cable `_. + +Contributors +------------ + +* Sébastien Beau +* Benoît Guillot +* Alexis de Lattre +* Guewen Baconnier +* Sergio Teruel +* Mikel Arregi +* Pedro M. Baeza +* Simone Orsi + +Maintainer +---------- + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +This module is maintained by the OCA. + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +To contribute to this module, please visit https://odoo-community.org. diff --git a/connector_prestashop/__init__.py b/connector_prestashop/__init__.py new file mode 100644 index 000000000..881f759b5 --- /dev/null +++ b/connector_prestashop/__init__.py @@ -0,0 +1,7 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from . import backend +from . import connector +from . import consumer +from . import models diff --git a/connector_prestashop/__manifest__.py b/connector_prestashop/__manifest__.py new file mode 100644 index 000000000..eb727dad4 --- /dev/null +++ b/connector_prestashop/__manifest__.py @@ -0,0 +1,62 @@ +# -*- coding: utf-8 -*- +# Copyright 2011-2013 Camptocamp +# Copyright 2011-2013 Akretion +# Copyright 2015 AvanzOSC +# Copyright 2015-2016 Tecnativa +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +{ + "name": "PrestaShop-Odoo connector", + "version": "10.0.1.0.0", + "license": "AGPL-3", + "depends": [ + "account", + "product", + "product_multi_category", # oca/product-attribute + "connector_ecommerce", # oca/connector-ecommerce + "product_multi_image", # oca/product-attribute + "purchase", + "product_variant_supplierinfo", # oca/product-variant + # TODO: perhaps not needed: + # "product_variant_cost_price", # oca/product-variant + ], + "external_dependencies": { + 'python': [ + "html2text", + "prestapyt", + # tests dependencies + "freezegun", + "vcr", + "bs4", + ], + }, + "author": "Akretion," + "Camptocamp," + "AvanzOSC," + "Tecnativa," + "Odoo Community Association (OCA)", + "website": "https://github.com/OCA/connector-prestashop", + "category": "Connector", + 'demo': [ + 'demo/backend.xml', + ], + 'data': [ + 'data/cron.xml', + 'data/product_decimal_precision.xml', + 'views/prestashop_model_view.xml', + 'views/product_view.xml', + 'views/product_category_view.xml', + 'views/image_view.xml', + 'views/delivery_view.xml', + 'views/connector_prestashop_menu.xml', + 'views/partner_view.xml', + 'views/sale_view.xml', + 'views/account_view.xml', + 'views/stock_view.xml', + 'security/ir.model.access.csv', + 'security/prestashop_security.xml', + 'data/ecommerce_data.xml', + ], + 'installable': True, + "application": True, +} diff --git a/connector_prestashop/backend.py b/connector_prestashop/backend.py new file mode 100644 index 000000000..714a088cd --- /dev/null +++ b/connector_prestashop/backend.py @@ -0,0 +1,15 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import openerp.addons.connector.backend as backend + + +prestashop = backend.Backend('prestashop') +# version < 1.6.0.9 +prestashop_1_5_0_0 = backend.Backend(parent=prestashop, version='1.5') +# version 1.6.0.9 - 1.6.0.10 +prestashop_1_6_0_9 = backend.Backend(parent=prestashop, version='1.6.0.9') +# version >= 1.6.0.11 +prestashop_1_6_0_11 = backend.Backend(parent=prestashop, version='1.6.0.11') +# version >= 1.6.1.2 +prestashop_1_6_1_2 = backend.Backend(parent=prestashop, version='1.6.1.2') diff --git a/connector_prestashop/connector.py b/connector_prestashop/connector.py new file mode 100644 index 000000000..0c65664a1 --- /dev/null +++ b/connector_prestashop/connector.py @@ -0,0 +1,12 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging + +_logger = logging.getLogger(__name__) + + +def get_environment(session, model_name, backend_id): + _logger.warn('deprecated: please use PrestashopBackend.get_environment') + backend = session.env['prestashop.backend'].browse(backend_id) + return backend.get_environment(model_name, session=session) diff --git a/connector_prestashop/consumer.py b/connector_prestashop/consumer.py new file mode 100644 index 000000000..6e43a5b1d --- /dev/null +++ b/connector_prestashop/consumer.py @@ -0,0 +1,69 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo.addons.connector.event import on_record_write +from odoo.addons.connector_ecommerce.models.event import ( + on_tracking_number_added, +) +from .models.sale_order_state.exporter import export_sale_state +from .models.stock_tracking.exporter import export_tracking_number + +def delay_export(session, model_name, record_id, fields=None, priority=20): + """ Delay a job which export a binding record. + + (A binding record being a ``external.res.partner``, + ``external.product.product``, ...) + """ + if session.context.get('connector_no_export'): + return + export_record.delay( + session, model_name, record_id, fields=fields, priority=priority) + + +def delay_export_all_bindings( + session, model_name, record_id, fields=None, priority=20): + """ Delay a job which export all the bindings of a record. + +@on_record_write(model_names=[ + 'prestashop.product.template', + 'prestashop.product.combination' +]) +def prestashop_product_stock_updated( + env, model_name, record_id, fields=None): + if env.context.get('connector_no_export'): + return + inventory_fields = list(set(fields).intersection(INVENTORY_FIELDS)) + if inventory_fields: + env[model_name].browse(record_id).with_delay( + priority=20).export_inventory(fields=inventory_fields) + + +@on_record_write(model_names='sale.order') +def prestashop_sale_state_modified(env, model_name, record_id, + fields=None): + if 'state' in fields: + sale = env[model_name].browse(record_id) + if not sale.prestashop_bind_ids: + return + # a quick test to see if it is worth trying to export sale state + states = env['sale.order.state.list'].search( + [('name', '=', sale.state)] + ) + if states: + export_sale_state.delay(env, 'prestashop.sale.order', + record_id, priority=20) + + +@on_tracking_number_added +def delay_export_tracking_number(env, model_name, record_id): + """ + Call a job to export the tracking number to a existing picking that + must be in done state. + """ + picking = env['stock.picking'].browse(record_id) + for binding in picking.sale_id.prestashop_bind_ids: + export_tracking_number.delay(env, + binding._model._name, + binding.id, + priority=20) diff --git a/connector_prestashop/data/cron.xml b/connector_prestashop/data/cron.xml new file mode 100644 index 000000000..73b6d6f1f --- /dev/null +++ b/connector_prestashop/data/cron.xml @@ -0,0 +1,95 @@ + + + + + PrestaShop - Import Sales Orders + + + 1 + days + -1 + + + + + + + + PrestaShop - Export Stock Quantities + + + 1 + days + -1 + + + + + + + + PrestaShop - Import Customers and Groups + + + 1 + days + -1 + + + + + + + + PrestaShop - Import Products and Categories + + + 1 + days + -1 + + + + + + + + PrestaShop - Import suppliers + + + 1 + days + -1 + + + + + + + + PrestaShop - Import Carriers + + + 1 + days + -1 + + + + + + + + PrestaShop - Payment modes + + + 1 + days + -1 + + + + + + + diff --git a/connector_prestashop/data/ecommerce_data.xml b/connector_prestashop/data/ecommerce_data.xml new file mode 100644 index 000000000..d1e52e5f7 --- /dev/null +++ b/connector_prestashop/data/ecommerce_data.xml @@ -0,0 +1,43 @@ + + + + + Total Amount differs from PrestaShop + The amount computed in Odoo doesn't match with the amount in PrestaShop. + +Cause: +The taxes are probably different between Odoo and PrestaShop. A fiscal position could have changed the final price. + +Resolution: +Check your taxes and fiscal positions configuration and correct them if necessary. + 30 + sale + sale.order + if order.prestashop_bind_ids and abs(order.amount_total - order.prestashop_bind_ids[0].total_amount) >= 0.001: + failed = True + + + + + Total Tax Amount differs from PrestaShop + The tax amount computed in Odoo doesn't match with the tax amount in PrestaShop. + +Cause: +The taxes are probably different between Odoo and PrestaShop. A fiscal position could have changed the final price. + +Resolution: +Check your taxes and fiscal positions configuration and correct them if necessary. + 30 + sale + sale.order + # By default, a cent of difference for the tax amount is allowed, feel free to customise it in your own module +if order.prestashop_bind_ids: + ps_amount = order.prestashop_bind_ids[0].total_amount_tax + oerp_amount = order.amount_tax + if (ps_amount == 0.0 and oerp_amount != 0.0) or (ps_amount and abs(1 - oerp_amount / ps_amount) > 0.02): + failed = True + + + + + diff --git a/connector_prestashop/data/product_decimal_precision.xml b/connector_prestashop/data/product_decimal_precision.xml new file mode 100644 index 000000000..b4564658d --- /dev/null +++ b/connector_prestashop/data/product_decimal_precision.xml @@ -0,0 +1,6 @@ + + + + 3 + + diff --git a/connector_prestashop/demo/backend.xml b/connector_prestashop/demo/backend.xml new file mode 100644 index 000000000..e8f1cb8e4 --- /dev/null +++ b/connector_prestashop/demo/backend.xml @@ -0,0 +1,13 @@ + + + + + Prestashop + 1.6.1.2 + http://localhost:8080 + + + + + + diff --git a/connector_prestashop/models/__init__.py b/connector_prestashop/models/__init__.py new file mode 100644 index 000000000..01c7714fc --- /dev/null +++ b/connector_prestashop/models/__init__.py @@ -0,0 +1,28 @@ +# -*- coding: utf-8 -*- + + +from . import binding + +from . import account_invoice +from . import account_payment_mode +from . import account_tax +from . import account_tax_group +from . import delivery_carrier +from . import mail_message +from . import prestashop_backend +from . import product_category +from . import product_image +from . import product_pricelist +from . import product_product +from . import product_supplierinfo +from . import product_template +from . import res_country +from . import res_currency +from . import res_lang +from . import res_partner +from . import res_partner_category +from . import sale_order +from . import sale_order_state +from . import stock_warehouse +from . import stock_move +from . import stock_tracking diff --git a/connector_prestashop/models/account_invoice/__init__.py b/connector_prestashop/models/account_invoice/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/account_invoice/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/account_invoice/common.py b/connector_prestashop/models/account_invoice/common.py new file mode 100644 index 000000000..e8961cdf9 --- /dev/null +++ b/connector_prestashop/models/account_invoice/common.py @@ -0,0 +1,93 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import api, fields, models + +from ...backend import prestashop +from ...unit.backend_adapter import GenericAdapter + + +class AccountInvoice(models.Model): + _inherit = 'account.invoice' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.refund', + inverse_name='odoo_id', + string='PrestaShop Bindings' + ) + + def action_move_create(self): + so_obj = self.env['prestashop.sale.order'] + line_replacement = {} + for invoice in self: + sale_order = so_obj.search([('name', '=', invoice.origin)]) + if not sale_order: + continue + sale_order = sale_order[0] + discount_product_id = sale_order.backend_id.discount_product_id.id + for invoice_line in invoice.invoice_line_ids: + if invoice_line.product_id.id != discount_product_id: + continue + amount = invoice_line.price_subtotal + partner = invoice.partner_id.commercial_partner_id + refund = self._find_refund(-1 * amount, partner) + if refund: + invoice_line.unlink() + line_replacement[invoice] = refund + invoice.button_reset_taxes() + result = super(AccountInvoice, self).action_move_create() + # reconcile invoice with refund + for invoice, refund in line_replacement.items(): + self._reconcile_invoice_refund(invoice, refund) + return result + + @api.model + def _reconcile_invoice_refund(self, invoice, refund): + move_line_obj = self.env['account.move.line'] + move_lines = move_line_obj.search([ + ('move_id', '=', invoice.move_id.id), + ('debit', '!=', 0.0), + ]) + move_lines += move_line_obj.search([ + ('move_id', '=', refund.move_id.id), + ('credit', '!=', 0.0), + ]) + move_lines.reconcile_partial() + + @api.model + def _find_refund(self, amount, partner): + records = self.search([ + ('amount_untaxed', '=', amount), + ('type', '=', 'out_refund'), + ('state', '=', 'open'), + ('partner_id', '=', partner.id), + ]) + return records[:1].id + + +class PrestashopRefund(models.Model): + _name = 'prestashop.refund' + _inherit = 'prestashop.binding.odoo' + _inherits = {'account.invoice': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='account.invoice', + required=True, + ondelete='cascade', + string='Invoice', + oldname='openerp_id', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class RefundAdapter(GenericAdapter): + _model_name = 'prestashop.refund' + + @property + def _prestashop_model(self): + return self.backend_record.get_version_ps_key('order_slip') diff --git a/connector_prestashop/models/account_invoice/importer.py b/connector_prestashop/models/account_invoice/importer.py new file mode 100644 index 000000000..8203c27cc --- /dev/null +++ b/connector_prestashop/models/account_invoice/importer.py @@ -0,0 +1,269 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import _, fields + +from odoo.addons.connector.exception import MappingError +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.mapper import ( + mapping, + ImportMapper, + only_create, +) + +from ...backend import prestashop +from ...unit.importer import ( + PrestashopImporter, + import_batch, + DelayedBatchImporter, +) + + +@prestashop +class RefundImporter(PrestashopImporter): + _model_name = 'prestashop.refund' + + def _import_dependencies(self): + record = self.prestashop_record + self._import_dependency( + record['id_customer'], 'prestashop.res.partner' + ) + self._import_dependency(record['id_order'], 'prestashop.sale.order') + + def _open_refund(self, binding): + invoice = binding.odoo_id + if invoice.amount_total == float(self.prestashop_record['amount']): + invoice.signal_workflow('invoice_open') + else: + self.backend_record.add_checkpoint( + model='account.invoice', + record_id=invoice.id, + message=_('The refund for order %s has a different amount ' + 'in PrestaShop and in Odoo.') % invoice.origin + ) + + def _after_import(self, binding): + super(RefundImporter, self)._after_import(binding) + self._open_refund(binding) + + +@prestashop +class RefundMapper(ImportMapper): + _model_name = 'prestashop.refund' + + direct = [ + ('id', 'name'), + ('date_add', 'date_invoice'), + ] + + @mapping + def journal(self, record): + journal = self.backend_record.refund_journal_id + if not journal: + raise MappingError( + _('The refund journal must be configured on ' + 'the PrestaShop Backend.') + ) + return {'journal_id': journal.id} + + def _get_order(self, record): + binder = self.binder_for('prestashop.sale.order') + return binder.to_internal(record['id_order']) + + @mapping + def from_sale_order(self, record): + sale_order = self._get_order(record) + fiscal_position = None + if sale_order.fiscal_position_id: + fiscal_position = sale_order.fiscal_position_id.id + return { + 'origin': sale_order['name'], + 'fiscal_position_id': fiscal_position, + } + + @mapping + def comment(self, record): + return {'comment': _('PrestaShop amount: %s') % record['amount']} + + @mapping + @only_create + def invoice_lines(self, record): + slip_details = record.get( + 'associations', {} + ).get('order_slip_details', []).get( + self.backend_record.get_version_ps_key('order_slip_detail'), []) + if isinstance(slip_details, dict): + slip_details = [slip_details] + lines = [] + order_binding = self._get_order(record) + fpos = order_binding.fiscal_position_id + shipping_line = self._invoice_line_shipping(record, fpos) + if shipping_line: + lines.append((0, 0, shipping_line)) + for slip_detail in slip_details: + line = self._invoice_line(slip_detail, fpos) + lines.append((0, 0, line)) + return {'invoice_line_ids': lines} + + def _invoice_line_shipping(self, record, fpos): + order_line = self._get_shipping_order_line(record) + if not order_line: + return None + if record['shipping_cost'] == '1': + price_unit = order_line['price_unit'] + else: + price_unit = record['shipping_cost_amount'] + if price_unit in [0.0, '0.00']: + return None + product = self.env['product.product'].browse( + order_line['product_id'][0] + ) + account_id = product.property_account_income_id.id + if not account_id: + account_id = product.categ_id.property_account_income_categ_id.id + if fpos: + fpos_obj = self.env['account.fiscal.position'] + account_id = fpos_obj.map_account( + self.session.cr, + self.session.uid, + fpos, + account_id + ) + return { + 'quantity': 1, + 'product_id': product.id, + 'name': order_line['name'], + 'invoice_line_tax_id': [(6, 0, order_line['tax_id'])], + 'price_unit': price_unit, + 'discount': order_line['discount'], + 'account_id': account_id, + } + + def _get_shipping_order_line(self, record): + binder = self.binder_for('prestashop.sale.order') + sale_order = binder.to_internal(record['id_order'], unwrap=True) + if not sale_order.carrier_id: + return None + sale_order_line_ids = self.env['sale.order.line'].search([ + ('order_id', '=', sale_order.id), + ('product_id', '=', sale_order.carrier_id.product_id.id), + ]) + if not sale_order_line_ids: + return None + return sale_order_line_ids[0].read([]) + + def _invoice_line(self, record, fpos): + order_line = self._get_order_line(record['id_order_detail']) + tax_ids = [] + if order_line is None: + product_id = None + name = "Order line not found" + account_id = None + else: + product = order_line.product_id + product_id = product.id + name = order_line.name + for tax in order_line.tax_id: + tax_ids.append(tax.id) + account_id = product.property_account_income_id.id + if not account_id: + categ = product.categ_id + account_id = categ.property_account_income_categ_id.id + if fpos and account_id: + fpos_obj = self.session.pool['account.fiscal.position'] + account_id = fpos_obj.map_account( + self.session.cr, + self.session.uid, + fpos, + account_id + ) + if record['product_quantity'] == '0': + quantity = 1 + else: + quantity = record['product_quantity'] + + if self.backend_record.taxes_included: + price_unit = record['amount_tax_incl'] + else: + price_unit = record['amount_tax_excl'] + + try: + price_unit = float(price_unit) / float(quantity) + except ValueError: + pass + + discount = False + if price_unit in ['0.00', ''] and order_line is not None: + price_unit = order_line['price_unit'] + discount = order_line['discount'] + return { + 'quantity': quantity, + 'product_id': product_id, + 'name': name, + 'invoice_line_tax_id': [(6, 0, tax_ids)], + 'price_unit': price_unit, + 'discount': discount, + 'account_id': account_id, + } + + def _get_order_line(self, order_details_id): + order_line = self.env['prestashop.sale.order.line'].search([ + ('prestashop_id', '=', order_details_id), + ('backend_id', '=', self.backend_record.id), + ]) + if not order_line: + return None + return order_line.with_context( + company_id=self.backend_record.company_id.id) + + @mapping + def type(self, record): + return {'type': 'out_refund'} + + @mapping + def partner_id(self, record): + binder = self.binder_for('prestashop.res.partner') + partner = binder.to_internal(record['id_customer'], unwrap=True) + return {'partner_id': partner.id} + + @mapping + def account_id(self, record): + binder = self.binder_for('prestashop.sale.order') + binder = self.binder_for('prestashop.res.partner') + partner = binder.to_internal(record['id_customer']) + partner = partner.with_context( + company_id=self.backend_record.company_id.id, + ) + return {'account_id': partner.property_account_receivable.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + +@prestashop +class RefundBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.refund' + + +@job(default_channel='root.prestashop') +def import_refunds(session, backend_id, since_date, **kwargs): + filters = None + if since_date: + filters = {'date': '1', 'filter[date_upd]': '>[%s]' % (since_date)} + now_fmt = fields.Datetime.now() + result = import_batch( + session, + 'prestashop.refund', + backend_id, + filters, + **kwargs + ) + session.env['prestashop.backend'].browse(backend_id).write({ + 'import_refunds_since': now_fmt + }) + return result diff --git a/connector_prestashop/models/account_payment_mode/__init__.py b/connector_prestashop/models/account_payment_mode/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/account_payment_mode/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/account_payment_mode/common.py b/connector_prestashop/models/account_payment_mode/common.py new file mode 100644 index 000000000..ecb525fa4 --- /dev/null +++ b/connector_prestashop/models/account_payment_mode/common.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.connector import Binder +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +@prestashop +class PaymentModeAdapter(GenericAdapter): + _model_name = 'account.payment.mode' + _prestashop_model = 'orders' + _export_node_name = 'order' + + def search(self, filters=None): + res = self.client.get(self._prestashop_model, options=filters) + if not res['orders']: + return [] + methods = res[self._prestashop_model][self._export_node_name] + if isinstance(methods, dict): + return [methods] + return methods + + +@prestashop +class PaymentModeBinder(Binder): + _model_name = 'account.payment.mode' + + _external_field = 'name' + + def to_openerp(self, external_id, unwrap=False, company=None): + if company is None: + company = self.backend_record.company_id + bindings = self.model.with_context(active_test=False).search( + [(self._external_field, '=', external_id), + ('company_id', '=', company.id), + ] + ) + if not bindings: + return self.model.browse() + bindings.ensure_one() + return bindings + + def bind(self, external_id, binding_id): + raise TypeError('%s cannot be synchronized' % self.model._name) diff --git a/connector_prestashop/models/account_payment_mode/importer.py b/connector_prestashop/models/account_payment_mode/importer.py new file mode 100644 index 000000000..ee4c34c23 --- /dev/null +++ b/connector_prestashop/models/account_payment_mode/importer.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from ...unit.importer import BatchImporter +from ...backend import prestashop + + +@prestashop +class PaymentModeBatchImporter(BatchImporter): + _model_name = 'account.payment.mode' + + def run(self, filters=None, **kwargs): + if filters is None: + filters = {} + filters['display'] = '[id,payment]' + return super(PaymentModeBatchImporter, self).run( + filters, **kwargs + ) + + def _import_record(self, record, **kwargs): + """ Create the missing payment method + + If we have only 1 bank journal, we link the payment method to it, + otherwise, the user will have to create manually the payment mode. + """ + if self.binder_for().to_internal(record['payment']): + return # already exists + method_xmlid = 'account.account_payment_method_manual_in' + payment_method = self.env.ref(method_xmlid, raise_if_not_found=False) + if not payment_method: + return + journals = self.env['account.journal'].search( + [('type', '=', 'bank'), + ('company_id', '=', self.backend_record.company_id.id), + ], + ) + if len(journals) != 1: + return + mode = self.model.create({ + 'name': record['payment'], + 'company_id': self.backend_record.company_id.id, + 'bank_account_link': 'fixed', + 'fixed_journal_id': journals.id, + 'payment_method_id': payment_method.id + }) + self.backend_record.add_checkpoint( + model=self.model._name, + record_id=mode.id, + ) diff --git a/connector_prestashop/models/account_tax/__init__.py b/connector_prestashop/models/account_tax/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/account_tax/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/account_tax/common.py b/connector_prestashop/models/account_tax/common.py new file mode 100644 index 000000000..a83c94968 --- /dev/null +++ b/connector_prestashop/models/account_tax/common.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class PrestashopAccountTax(models.Model): + _name = 'prestashop.account.tax' + # Do not inherit from `prestashop.binding.odoo` + # because we do not want the constraint `prestashop_erp_uniq`. + # This allows us to create duplicated taxes. + _inherit = 'prestashop.binding' + _inherits = {'account.tax': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='account.tax', + string='Tax', + required=True, + ondelete='cascade' + ) + + +class AccountTax(models.Model): + _inherit = 'account.tax' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.account.tax', + inverse_name='openerp_id', + string='prestashop Bindings', + readonly=True, + ) + + +@prestashop +class AccountTaxAdapter(GenericAdapter): + _model_name = 'prestashop.account.tax' + _prestashop_model = 'taxes' diff --git a/connector_prestashop/models/account_tax/importer.py b/connector_prestashop/models/account_tax/importer.py new file mode 100644 index 000000000..ecfceae89 --- /dev/null +++ b/connector_prestashop/models/account_tax/importer.py @@ -0,0 +1,25 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from ...unit.auto_matching_importer import AutoMatchingImporter +from ...backend import prestashop + + +@prestashop +class AccountTaxImporter(AutoMatchingImporter): + _model_name = 'prestashop.account.tax' + _erp_field = 'amount' + _ps_field = 'rate' + + def _compare_function(self, ps_val, erp_val, ps_dict, erp_dict): + if self.backend_record.taxes_included and erp_dict['price_include']: + taxes_inclusion_test = True + else: + taxes_inclusion_test = not erp_dict['price_include'] + if not taxes_inclusion_test: + return False + return (erp_dict['type_tax_use'] == 'sale' and + erp_dict['amount_type'] == 'percent' and + abs(erp_val - float(ps_val)) < 0.01 and + self.backend_record.company_id.id == erp_dict['company_id'][0]) diff --git a/connector_prestashop/models/account_tax_group/__init__.py b/connector_prestashop/models/account_tax_group/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/account_tax_group/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/account_tax_group/common.py b/connector_prestashop/models/account_tax_group/common.py new file mode 100644 index 000000000..397f04c4a --- /dev/null +++ b/connector_prestashop/models/account_tax_group/common.py @@ -0,0 +1,53 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class AccountTaxGroup(models.Model): + _inherit = 'account.tax.group' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.account.tax.group', + inverse_name='openerp_id', + string='PrestaShop Bindings', + readonly=True + ) + company_id = fields.Many2one( + comodel_name='res.company', + index=True, + required=True, + string='Company', + ) + tax_ids = fields.One2many( + comodel_name='account.tax', + inverse_name='tax_group_id', + string='Taxes', + ) + + +class PrestashopAccountTaxGroup(models.Model): + _name = 'prestashop.account.tax.group' + _inherit = 'prestashop.binding' + _inherits = {'account.tax.group': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='account.tax.group', + string='Tax Group', + required=True, + ondelete='cascade', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class TaxGroupAdapter(GenericAdapter): + _model_name = 'prestashop.account.tax.group' + _prestashop_model = 'tax_rule_groups' diff --git a/connector_prestashop/models/account_tax_group/importer.py b/connector_prestashop/models/account_tax_group/importer.py new file mode 100644 index 000000000..acbbd895b --- /dev/null +++ b/connector_prestashop/models/account_tax_group/importer.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.unit.mapper import ( + ImportMapper, + mapping, + only_create, +) +from ...unit.importer import PrestashopImporter, DirectBatchImporter +from ...backend import prestashop + + +@prestashop +class TaxGroupMapper(ImportMapper): + _model_name = 'prestashop.account.tax.group' + + direct = [ + ('name', 'name'), + ] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @only_create + @mapping + def odoo_id(self, record): + tax_group = self.env['account.tax.group'].search([ + ('name', '=', record['name']) + ]) + if tax_group: + return {'odoo_id': tax_group.id} + + +@prestashop +class TaxGroupImporter(PrestashopImporter): + _model_name = 'prestashop.account.tax.group' + + +@prestashop +class TaxGroupBatchImporter(DirectBatchImporter): + _model_name = 'prestashop.account.tax.group' diff --git a/connector_prestashop/models/binding/__init__.py b/connector_prestashop/models/binding/__init__.py new file mode 100644 index 000000000..ef553a8fb --- /dev/null +++ b/connector_prestashop/models/binding/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from . import common diff --git a/connector_prestashop/models/binding/common.py b/connector_prestashop/models/binding/common.py new file mode 100644 index 000000000..335a41445 --- /dev/null +++ b/connector_prestashop/models/binding/common.py @@ -0,0 +1,51 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models, fields, api +from odoo.addons.queue_job.job import job +from ...unit.importer import PrestashopImporter, BatchImporter +from ...unit.importer import import_record + + +class PrestashopBinding(models.AbstractModel): + _name = 'prestashop.binding' + _inherit = 'external.binding' + _description = 'PrestaShop Binding (abstract)' + + # 'openerp_id': openerp-side id must be declared in concrete model + backend_id = fields.Many2one( + comodel_name='prestashop.backend', + string='PrestaShop Backend', + required=True, + ondelete='restrict' + ) + prestashop_id = fields.Integer('ID on PrestaShop') + + _sql_constraints = [ + ('prestashop_uniq', 'unique(backend_id, prestashop_id)', + 'A record with same ID on PrestaShop already exists.'), + ] + + @job(default_channel='root.prestashop') + def import_record(self, backend, prestashop_id, **kwargs): + """ Import a record from PrestaShop """ + env = backend.get_environment(self._name) + importer = env.get_connector_unit(PrestashopImporter) + return importer.run(prestashop_id, **kwargs) + + @job(default_channel='root.prestashop') + def import_batch(self, backend=None, filters=None, **kwargs): + """ Prepare a batch import of records from PrestaShop """ + env = backend.get_environment(self._name) + importer = env.get_connector_unit(BatchImporter) + return importer.run(filters=filters, **kwargs) + + @api.multi + def resync(self): + func = import_record + if self.env.context.get('connector_delay'): + func = import_record.delay + for record in self: + func(self.env, self._name, record.backend_id.id, + record.prestashop_id) + return True diff --git a/connector_prestashop/models/delivery_carrier/__init__.py b/connector_prestashop/models/delivery_carrier/__init__.py new file mode 100644 index 000000000..05691dc17 --- /dev/null +++ b/connector_prestashop/models/delivery_carrier/__init__.py @@ -0,0 +1,5 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import exporter +from . import importer diff --git a/connector_prestashop/models/delivery_carrier/common.py b/connector_prestashop/models/delivery_carrier/common.py new file mode 100644 index 000000000..d537d92cc --- /dev/null +++ b/connector_prestashop/models/delivery_carrier/common.py @@ -0,0 +1,69 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging + +from odoo import models, fields + +from ...backend import prestashop +from ...unit.backend_adapter import GenericAdapter + +_logger = logging.getLogger(__name__) + + +class PrestashopDeliveryCarrier(models.Model): + _name = 'prestashop.delivery.carrier' + _inherit = 'prestashop.binding.odoo' + _inherits = {'delivery.carrier': 'odoo_id'} + _description = 'PrestaShop Carrier' + + odoo_id = fields.Many2one( + comodel_name='delivery.carrier', + string='Delivery carrier', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + id_reference = fields.Integer( + string='Reference ID', + help="In PrestaShop, carriers can be copied with the same 'Reference " + "ID' (only the last copied carrier will be synchronized with the " + "ERP)" + ) + name_ext = fields.Char( + string='Name in PrestaShop', + ) + active_ext = fields.Boolean( + string='Active in PrestaShop', + ) + export_tracking = fields.Boolean( + string='Export tracking numbers to PrestaShop', + ) + + +class DeliveryCarrier(models.Model): + _inherit = "delivery.carrier" + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.delivery.carrier', + inverse_name='odoo_id', + string='PrestaShop Bindings', + ) + company_id = fields.Many2one( + comodel_name='res.company', + string='Company', + index=True, + ) + + +@prestashop +class DeliveryCarrierAdapter(GenericAdapter): + _model_name = 'prestashop.delivery.carrier' + _prestashop_model = 'carriers' + + def search(self, filters=None): + if filters is None: + filters = {} + filters['filter[deleted]'] = 0 + + return super(DeliveryCarrierAdapter, self).search(filters) diff --git a/connector_prestashop/models/delivery_carrier/exporter.py b/connector_prestashop/models/delivery_carrier/exporter.py new file mode 100644 index 000000000..2977e4d65 --- /dev/null +++ b/connector_prestashop/models/delivery_carrier/exporter.py @@ -0,0 +1,2 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). diff --git a/connector_prestashop/models/delivery_carrier/importer.py b/connector_prestashop/models/delivery_carrier/importer.py new file mode 100644 index 000000000..842a0c7ed --- /dev/null +++ b/connector_prestashop/models/delivery_carrier/importer.py @@ -0,0 +1,76 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import logging +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.mapper import (mapping, + ImportMapper, + ) +from ...unit.importer import ( + DelayedBatchImporter, + PrestashopImporter, + import_batch, +) +from ...backend import prestashop + +_logger = logging.getLogger(__name__) + + +@prestashop +class DeliveryCarrierImporter(PrestashopImporter): + _model_name = ['prestashop.delivery.carrier'] + + +@prestashop +class CarrierImportMapper(ImportMapper): + _model_name = 'prestashop.delivery.carrier' + direct = [ + ('name', 'name_ext'), + ('name', 'name'), + ('id_reference', 'id_reference'), + ] + + @mapping + def active(self, record): + return {'active_ext': record['active'] == '1'} + + @mapping + def product_id(self, record): + if self.backend_record.shipping_product_id: + return {'product_id': self.backend_record.shipping_product_id.id} + product = self.env.ref('connector_ecommerce.product_product_shipping') + return {'product_id': product.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + +@prestashop +class DeliveryCarrierBatchImporter(DelayedBatchImporter): + """ Import the PrestaShop Carriers. + """ + _model_name = ['prestashop.delivery.carrier'] + + def run(self, filters=None, **kwargs): + """ Run the synchronization """ + record_ids = self.backend_adapter.search(filters=filters) + _logger.info('search for prestashop carriers %s returned %s', + filters, record_ids) + for record_id in record_ids: + self._import_record(record_id, **kwargs) + + +@job(default_channel='root.prestashop') +def import_carriers(session, backend_id, **kwargs): + return import_batch( + session, + 'prestashop.delivery.carrier', + backend_id, + priority=5, + **kwargs + ) diff --git a/connector_prestashop/models/mail_message/__init__.py b/connector_prestashop/models/mail_message/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/mail_message/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/mail_message/common.py b/connector_prestashop/models/mail_message/common.py new file mode 100644 index 000000000..884f60031 --- /dev/null +++ b/connector_prestashop/models/mail_message/common.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import models, fields + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class MailMessage(models.Model): + _inherit = 'mail.message' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.mail.message', + inverse_name='odoo_id', + string='PrestaShop Bindings', + ) + + +class PrestashopMailMessage(models.Model): + _name = "prestashop.mail.message" + _inherit = "prestashop.binding.odoo" + _inherits = {'mail.message': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='mail.message', + required=True, + ondelete='cascade', + string='Message', + oldname='openerp_id', + ) + + +@prestashop +class MailMessageAdapter(GenericAdapter): + _model_name = 'prestashop.mail.message' + + @property + def _prestashop_model(self): + return self.backend_record.get_version_ps_key('messages') diff --git a/connector_prestashop/models/mail_message/importer.py b/connector_prestashop/models/mail_message/importer.py new file mode 100644 index 000000000..ef8f244c6 --- /dev/null +++ b/connector_prestashop/models/mail_message/importer.py @@ -0,0 +1,67 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.unit.mapper import ImportMapper, mapping +from ...unit.importer import PrestashopImporter, DelayedBatchImporter +from ...backend import prestashop + + +@prestashop +class MailMessageMapper(ImportMapper): + _model_name = 'prestashop.mail.message' + + direct = [ + ('message', 'body'), + ] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def type(self, record): + return {'type': 'comment'} + + @mapping + def object_ref(self, record): + binder = self.binder_for('prestashop.sale.order') + order = binder.to_internal(record['id_order'], unwrap=True) + return { + 'model': 'sale.order', + 'res_id': order.id, + } + + @mapping + def author_id(self, record): + if record['id_customer'] != '0': + binder = self.binder_for('prestashop.res.partner') + partner = binder.to_internal(record['id_customer'], unwrap=True) + return {'author_id': partner.id} + return {} + + +@prestashop +class MailMessageImporter(PrestashopImporter): + """ Import one simple record """ + _model_name = 'prestashop.mail.message' + + def _import_dependencies(self): + record = self.prestashop_record + self._import_dependency(record['id_order'], 'prestashop.sale.order') + if record['id_customer'] != '0': + self._import_dependency( + record['id_customer'], 'prestashop.res.partner' + ) + + def _has_to_skip(self): + record = self.prestashop_record + if not record.get('id_order'): + return 'no id_order' + binder = self.binder_for('prestashop.sale.order') + order_binding = binder.to_internal(record['id_order']) + return record['id_order'] == '0' or not order_binding + + +@prestashop +class MailMessageBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.mail.message' diff --git a/connector_prestashop/models/prestashop_backend/__init__.py b/connector_prestashop/models/prestashop_backend/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/prestashop_backend/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/prestashop_backend/common.py b/connector_prestashop/models/prestashop_backend/common.py new file mode 100644 index 000000000..7cee33f8a --- /dev/null +++ b/connector_prestashop/models/prestashop_backend/common.py @@ -0,0 +1,323 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging +from contextlib import contextmanager + +from odoo import models, fields, api, exceptions, _ + +from odoo.addons.connector.connector import ConnectorEnvironment +from ...unit.importer import import_batch, import_record +from ...unit.auto_matching_importer import AutoMatchingImporter +from ...unit.backend_adapter import GenericAdapter, api_handle_errors +from ...unit.version_key import VersionKey +from ...backend import prestashop + +from ..product_template.exporter import export_product_quantities +from ..product_template.importer import import_inventory +from ..res_partner.importer import import_customers_since +from ..delivery_carrier.importer import import_carriers +from ..product_supplierinfo.importer import import_suppliers +from ..account_invoice.importer import import_refunds +from ..product_template.importer import import_products +from ..sale_order.importer import import_orders_since + + +_logger = logging.getLogger(__name__) + + +class PrestashopBackend(models.Model): + _name = 'prestashop.backend' + _description = 'PrestaShop Backend Configuration' + _inherit = 'connector.backend' + + _backend_type = 'prestashop' + + def _select_versions(self): + """ Available versions + + Can be inherited to add custom versions. + """ + return [ + ('1.5', '< 1.6.0.9'), + ('1.6.0.9', '1.6.0.9 - 1.6.0.10'), + ('1.6.0.11', '>= 1.6.0.11 - <1.6.1.2'), + ('1.6.1.2', '=1.6.1.2') + ] + version = fields.Selection( + selection='_select_versions', + string='Version', + required=True, + ) + location = fields.Char('Location') + webservice_key = fields.Char( + string='Webservice key', + help="You have to put it in 'username' of the PrestaShop " + "Webservice api path invite" + ) + warehouse_id = fields.Many2one( + comodel_name='stock.warehouse', + string='Warehouse', + required=True, + help='Warehouse used to compute the stock quantities.' + ) + stock_location_id = fields.Many2one( + comodel_name='stock.location', + string='Stock Location', + help='Location used to import stock quantities.' + ) + pricelist_id = fields.Many2one( + comodel_name='product.pricelist', + string='Pricelist', + required=True, + default=lambda self: self._default_pricelist_id(), + help="Pricelist used in sales orders", + ) + sale_team_id = fields.Many2one( + comodel_name='crm.team', + string='Sales Team', + help="Sales Team assigned to the imported sales orders.", + ) + + refund_journal_id = fields.Many2one( + comodel_name='account.journal', + string='Refund Journal', + ) + + taxes_included = fields.Boolean("Use tax included prices") + import_partners_since = fields.Datetime('Import partners since') + import_orders_since = fields.Datetime('Import Orders since') + import_products_since = fields.Datetime('Import Products since') + import_refunds_since = fields.Datetime('Import Refunds since') + import_suppliers_since = fields.Datetime('Import Suppliers since') + language_ids = fields.One2many( + comodel_name='prestashop.res.lang', + inverse_name='backend_id', + string='Languages', + ) + company_id = fields.Many2one( + comodel_name='res.company', + index=True, + required=True, + default=lambda self: self.env['res.company']._company_default_get( + 'prestashop.backend'), + string='Company', + ) + discount_product_id = fields.Many2one( + comodel_name='product.product', + index=True, + required=True, + string='Discount Product', + ) + shipping_product_id = fields.Many2one( + comodel_name='product.product', + index=True, + required=True, + string='Shipping Product', + ) + + @api.model + def _default_pricelist_id(self): + return self.env['product.pricelist'].search([], limit=1) + + @api.multi + def get_environment(self, model_name,): + self.ensure_one() + return ConnectorEnvironment(self, model_name) + + @api.multi + def synchronize_metadata(self): + for backend in self: + for model_name in [ + 'prestashop.shop.group', + 'prestashop.shop' + ]: + # import directly, do not delay because this + # is a fast operation, a direct return is fine + # and it is simpler to import them sequentially + self.env[model_name].import_batch(backend=backend) + return True + + @api.multi + def synchronize_basedata(self): + for backend in self: + for model_name in [ + 'prestashop.res.lang', + 'prestashop.res.country', + 'prestashop.res.currency', + 'prestashop.account.tax', + ]: + env = backend.get_environment(model_name) + importer = env.get_connector_unit(AutoMatchingImporter) + importer.run() + self.env['prestashop.account.tax.group'].import_batch( + backend=backend) + self.env['prestashop.sale.order.state'].import_batch( + backend=backend) + return True + + @api.multi + def _check_connection(self): + self.ensure_one() + env = self.get_environment(self._name) + adapter = env.get_connector_unit(GenericAdapter) + with api_handle_errors('Connection failed'): + adapter.head() + + @api.multi + def button_check_connection(self): + self._check_connection() + raise exceptions.UserError(_('Connection successful')) + + @api.multi + def import_customers_since(self): + for backend_record in self: + connector_env = backend_record.get_environment('res.partner') + since_date = backend_record.import_partners_since + connector_env.env['res.partner'].with_delay( + priority=10 + ).import_customers_since( + backend_record=backend_record, since_date=since_date) + return True + + @api.multi + def import_products(self): + for backend_record in self: + since_date = backend_record.import_products_since + backend_record.env['prestashop.product.template'].with_delay( + priority=10).import_products(backend_record, since_date) + return True + + @api.multi + def import_carriers(self): + session = ConnectorSession.from_env(self.env) + for backend_record in self: + import_carriers.delay(session, backend_record.id, priority=10) + return True + + @api.multi + def update_product_stock_qty(self): + for backend_record in self: + backend_record.env['prestashop.product.template']\ + .with_delay().export_product_quantities(backend=backend_record) + backend_record.env['prestashop.product.product']\ + .with_delay().export_product_quantities(backend=backend_record) + return True + + @api.multi + def import_stock_qty(self): + session = ConnectorSession.from_env(self.env) + for backend_record in self: + import_inventory.delay(session, backend_record.id) + + @api.multi + def import_sale_orders(self): + session = ConnectorSession.from_env(self.env) + for backend_record in self: + since_date = backend_record.import_orders_since + import_orders_since.delay( + session, + backend_record.id, + since_date, + priority=5, + ) + return True + + @api.multi + def import_payment_modes(self): + session = ConnectorSession.from_env(self.env) + for backend_record in self: + import_batch.delay(session, 'account.payment.mode', + backend_record.id) + return True + + @api.multi + def import_refunds(self): + session = ConnectorSession.from_env(self.env) + for backend_record in self: + since_date = backend_record.import_refunds_since + import_refunds.delay(session, backend_record.id, since_date) + return True + + @api.multi + def import_suppliers(self): + session = ConnectorSession.from_env(self.env) + for backend_record in self: + since_date = backend_record.import_suppliers_since + import_suppliers.delay(session, backend_record.id, since_date) + return True + + def get_version_ps_key(self, key): + self.ensure_one() + env = self.get_environment('_prestashop.version.key') + keys = env.get_connector_unit(VersionKey) + return keys.get_key(key) + + @api.model + def _scheduler_update_product_stock_qty(self, domain=None): + self.search(domain or []).update_product_stock_qty() + + @api.model + def _scheduler_import_sale_orders(self, domain=None): + self.search(domain or []).import_sale_orders() + + @api.model + def _scheduler_import_customers(self, domain=None): + self.search(domain or []).import_customers_since() + + @api.model + def _scheduler_import_products(self, domain=None): + self.search(domain or []).import_products() + + @api.model + def _scheduler_import_carriers(self, domain=None): + self.search(domain or []).import_carriers() + + @api.model + def _scheduler_import_payment_methods(self, domain=None): + backends = self.search(domain or []) + backends.import_payment_methods() + backends.import_refunds() + + @api.model + def _scheduler_import_suppliers(self, domain=None): + self.search(domain or []).import_suppliers() + + @api.multi + def import_record(self, model_name, ext_id): + self.ensure_one() + session = ConnectorSession.from_env(self.env) + import_record(session, model_name, self.id, ext_id) + return True + + +class PrestashopShopGroup(models.Model): + _name = 'prestashop.shop.group' + _inherit = 'prestashop.binding' + _description = 'PrestaShop Shop Group' + + name = fields.Char('Name', required=True) + shop_ids = fields.One2many( + comodel_name='prestashop.shop', + inverse_name='shop_group_id', + readonly=True, + string="Shops", + ) + company_id = fields.Many2one( + related='backend_id.company_id', + comodel_name="res.company", + string='Company' + ) + + +@prestashop +class NoModelAdapter(GenericAdapter): + """ Used to test the connection """ + _model_name = 'prestashop.backend' + _prestashop_model = '' + + +@prestashop +class ShopGroupAdapter(GenericAdapter): + _model_name = 'prestashop.shop.group' + _prestashop_model = 'shop_groups' diff --git a/connector_prestashop/models/prestashop_backend/importer.py b/connector_prestashop/models/prestashop_backend/importer.py new file mode 100644 index 000000000..08204cf53 --- /dev/null +++ b/connector_prestashop/models/prestashop_backend/importer.py @@ -0,0 +1,35 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import _ +from odoo.addons.connector.unit.mapper import ImportMapper, mapping +from ...unit.importer import PrestashopImporter, DirectBatchImporter +from ...backend import prestashop + + +@prestashop +class ShopGroupImportMapper(ImportMapper): + _model_name = 'prestashop.shop.group' + + direct = [('name', 'name')] + + @mapping + def name(self, record): + name = record['name'] + if name is None: + name = _('Undefined') + return {'name': name} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + +@prestashop +class ShopGroupImporter(PrestashopImporter): + _model_name = 'prestashop.shop.group' + + +@prestashop +class ShopGroupBatchImporter(DirectBatchImporter): + _model_name = 'prestashop.shop.group' diff --git a/connector_prestashop/models/product_category/__init__.py b/connector_prestashop/models/product_category/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/product_category/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/product_category/common.py b/connector_prestashop/models/product_category/common.py new file mode 100644 index 000000000..645ad7876 --- /dev/null +++ b/connector_prestashop/models/product_category/common.py @@ -0,0 +1,63 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import models, fields + +from ...unit.backend_adapter import GenericAdapter + +from ...backend import prestashop + + +class ProductCategory(models.Model): + _inherit = 'product.category' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.category', + inverse_name='odoo_id', + string="PrestaShop Bindings", + ) + + +class PrestashopProductCategory(models.Model): + _name = 'prestashop.product.category' + _inherit = 'prestashop.binding.odoo' + _inherits = {'product.category': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='product.category', + required=True, + ondelete='cascade', + string='Product Category', + oldname='openerp_id', + ) + default_shop_id = fields.Many2one(comodel_name='prestashop.shop') + date_add = fields.Datetime( + string='Created At (on PrestaShop)', + readonly=True + ) + date_upd = fields.Datetime( + string='Updated At (on PrestaShop)', + readonly=True + ) + description = fields.Html( + string='Description', translate=True, + help='HTML description from PrestaShop') + link_rewrite = fields.Char(string='Friendly URL', translate=True) + meta_description = fields.Char('Meta description', translate=True) + meta_keywords = fields.Char(string='Meta keywords', translate=True) + meta_title = fields.Char(string='Meta title', translate=True) + active = fields.Boolean(string='Active', default=True) + position = fields.Integer(string='Position') + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class ProductCategoryAdapter(GenericAdapter): + _model_name = 'prestashop.product.category' + _prestashop_model = 'categories' + _export_node_name = 'category' + _export_node_name_res = 'category' diff --git a/connector_prestashop/models/product_category/importer.py b/connector_prestashop/models/product_category/importer.py new file mode 100644 index 000000000..6370e852e --- /dev/null +++ b/connector_prestashop/models/product_category/importer.py @@ -0,0 +1,116 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import _ +from odoo.addons.connector.unit.mapper import (mapping, + ImportMapper) +from odoo.addons.connector.unit.mapper import external_to_m2o +from ...unit.importer import TranslatableRecordImporter, DelayedBatchImporter +from ...backend import prestashop + +import datetime +import logging +_logger = logging.getLogger(__name__) +try: + from prestapyt import PrestaShopWebServiceError +except: + _logger.debug('Cannot import from `prestapyt`') + + +@prestashop +class ProductCategoryMapper(ImportMapper): + _model_name = 'prestashop.product.category' + + direct = [ + ('description', 'description'), + ('link_rewrite', 'link_rewrite'), + ('meta_description', 'meta_description'), + ('meta_keywords', 'meta_keywords'), + ('meta_title', 'meta_title'), + (external_to_m2o('id_shop_default'), 'default_shop_id'), + ('active', 'active'), + ('position', 'position') + ] + + @mapping + def name(self, record): + if record['name'] is None: + return {'name': ''} + return {'name': record['name']} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def parent_id(self, record): + if record['id_parent'] == '0': + return {} + category = self.binder_for('prestashop.product.category').to_internal( + record['id_parent'], unwrap=True) + return { + 'parent_id': category.id, + } + + @mapping + def data_add(self, record): + if record['date_add'] == '0000-00-00 00:00:00': + return {'date_add': datetime.datetime.now()} + return {'date_add': record['date_add']} + + @mapping + def data_upd(self, record): + if record['date_upd'] == '0000-00-00 00:00:00': + return {'date_upd': datetime.datetime.now()} + return {'date_upd': record['date_upd']} + + +@prestashop +class ProductCategoryImporter(TranslatableRecordImporter): + _model_name = [ + 'prestashop.product.category', + ] + + _translatable_fields = { + 'prestashop.product.category': [ + 'name', + 'description', + 'link_rewrite', + 'meta_description', + 'meta_keywords', + 'meta_title' + ], + } + + def _import_dependencies(self): + record = self.prestashop_record + if record['id_parent'] != '0': + try: + self._import_dependency(record['id_parent'], + 'prestashop.product.category') + except PrestaShopWebServiceError, e: + msg = _( + 'Parent category for `%s` ' + 'cannot be imported. ' + 'Error: %s' + ) + binder = self.binder_for() + category = binder.to_internal(record['id']) + if category: + name = category.name + else: + # not imported yet, retrieve name in default lang + values = self._split_per_language( + record, fields=['name', ]) + name = values[self._default_language]['name'] + + self.backend_record.add_checkpoint( + model=category._name, + record_id=category.id, + message=msg % (name, str(e)) + ) + + +@prestashop +class ProductCategoryBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.product.category' diff --git a/connector_prestashop/models/product_image/__init__.py b/connector_prestashop/models/product_image/__init__.py new file mode 100644 index 000000000..be91db619 --- /dev/null +++ b/connector_prestashop/models/product_image/__init__.py @@ -0,0 +1,5 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import deleter +from . import importer diff --git a/connector_prestashop/models/product_image/common.py b/connector_prestashop/models/product_image/common.py new file mode 100644 index 000000000..c6dc40f55 --- /dev/null +++ b/connector_prestashop/models/product_image/common.py @@ -0,0 +1,93 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import base64 + +from odoo import models, fields + +from ...unit.backend_adapter import ( + PrestaShopCRUDAdapter, + PrestaShopWebServiceImage, +) +from ...backend import prestashop + + +class ProductImage(models.Model): + _inherit = 'base_multi_image.image' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.image', + inverse_name='openerp_id', + string='PrestaShop Bindings', + ) + + +class PrestashopProductImage(models.Model): + _name = 'prestashop.product.image' + _inherit = 'prestashop.binding' + _inherits = {'base_multi_image.image': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='base_multi_image.image', + required=True, + ondelete='cascade', + string='Product image', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class ProductImageAdapter(PrestaShopCRUDAdapter): + _model_name = 'prestashop.product.image' + _prestashop_image_model = 'products' + _prestashop_model = '/images/products' + _export_node_name = '/images/products' + _export_node_name_res = 'image' + + def read(self, product_tmpl_id, image_id, options=None): + api = PrestaShopWebServiceImage(self.prestashop.api_url, + self.prestashop.webservice_key) + return api.get_image( + self._prestashop_image_model, + product_tmpl_id, + image_id, + options=options + ) + + def create(self, attributes=None): + api = PrestaShopWebServiceImage( + self.prestashop.api_url, self.prestashop.webservice_key) + # TODO: odoo logic in the adapter? :-( + url = '{}/{}'.format(self._prestashop_model, attributes['id_product']) + return api.add(url, files=[( + 'image', + attributes['filename'].encode('utf-8'), + base64.b64decode(attributes['content']) + )]) + + def write(self, id, attributes=None): + api = PrestaShopWebServiceImage( + self.prestashop.api_url, self.prestashop.webservice_key) + # TODO: odoo logic in the adapter? :-( + url = '{}/{}'.format(self._prestashop_model, attributes['id_product']) + url_del = '{}/{}/{}/{}'.format( + api._api_url, self._prestashop_model, attributes['id_product'], id) + try: + api._execute(url_del, 'DELETE') + except: + pass + return api.add(url, files=[( + 'image', + attributes['filename'].encode('utf-8'), + base64.b64decode(attributes['content']) + )]) + + def delete(self, resource, id): + """ Delete a record on the external system """ + api = PrestaShopWebServiceImage( + self.prestashop.api_url, self.prestashop.webservice_key) + return api.delete(resource, resource_ids=id) diff --git a/connector_prestashop/models/product_image/deleter.py b/connector_prestashop/models/product_image/deleter.py new file mode 100644 index 000000000..c64863822 --- /dev/null +++ b/connector_prestashop/models/product_image/deleter.py @@ -0,0 +1,15 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from ...unit.deleter import PrestashopDeleter +from ...backend import prestashop + + +@prestashop +class ProductImageDelete(PrestashopDeleter): + _model_name = 'prestashop.product.image' + + def delete(self, id): + """ Delete a record on the external system """ + return self._call('%s.delete' % self._prestashop_model, [int(id)]) diff --git a/connector_prestashop/models/product_image/importer.py b/connector_prestashop/models/product_image/importer.py new file mode 100644 index 000000000..12a5e385d --- /dev/null +++ b/connector_prestashop/models/product_image/importer.py @@ -0,0 +1,119 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.mapper import (mapping, + ImportMapper) + +from ...backend import prestashop +from ...unit.importer import PrestashopImporter + +import mimetypes +import logging + +from odoo import _ + +_logger = logging.getLogger(__name__) +try: + from prestapyt import PrestaShopWebServiceError +except: + _logger.debug('Cannot import from `prestapyt`') + + +@prestashop +class ProductImageMapper(ImportMapper): + _model_name = 'prestashop.product.image' + + direct = [ + # ('content', 'file_db_store'), + ] + + @mapping + def from_template(self, record): + binder = self.binder_for('prestashop.product.template') + template = binder.to_internal(record['id_product'], unwrap=True) + name = '%s_%s' % (template.name, record['id_image']) + return {'owner_id': template.id, 'name': name} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def extension(self, record): + return {'extension': mimetypes.guess_extension(record['type'])} + + @mapping + def image_url(self, record): + return {'url': record['full_public_url']} + + @mapping + def filename(self, record): + return {'filename': '%s.jpg' % record['id_image']} + + @mapping + def storage(self, record): + return {'storage': 'url'} + # return {'storage': 'db'} + + @mapping + def owner_model(self, record): + return {'owner_model': 'product.template'} + + +@prestashop +class ProductImageImporter(PrestashopImporter): + _model_name = [ + 'prestashop.product.image', + ] + + def _get_prestashop_data(self): + """ Return the raw PrestaShop data for ``self.prestashop_id`` """ + return self.backend_adapter.read(self.template_id, self.image_id) + + def run(self, template_id, image_id, **kwargs): + self.template_id = template_id + self.image_id = image_id + + try: + super(ProductImageImporter, self).run(image_id, **kwargs) + except PrestaShopWebServiceError as error: + binder = self.binder_for('prestashop.product.template') + template = binder.to_internal(template_id, unwrap=True) + if template: + msg = _( + 'Import of image id `%s` failed. ' + 'Error: `%s`' + ) % (image_id, error.msg) + self.backend_record.add_checkpoint( + model='product.template', + record_id=template.id, + message=msg) + else: + msg = _( + 'Import of image id `%s` of PrestaShop product ' + 'with id `%s` failed. ' + 'Error: `%s`' + ) % (image_id, template_id, error.msg) + self.backend_record.add_checkpoint(message=msg) + + +@job(default_channel='root.prestashop') +def import_product_image(session, model_name, backend_id, product_tmpl_id, + image_id, **kwargs): + """Import a product image""" + backend = session.env['prestashop.backend'].browse(backend_id) + env = backend.get_environment(model_name, session=session) + with env.session.change_context(ctx): + importer = env.get_connector_unit(PrestashopImporter) + return importer.run(product_tmpl_id, image_id) + + +@job(default_channel='root.prestashop') +def set_product_image_variant( + session, model_name, backend_id, combination_ids): + backend = session.env['prestashop.backend'].browse(backend_id) + env = backend.get_environment(model_name, session=session) + importer = env.get_connector_unit(PrestashopImporter) + importer.set_variant_images(combination_ids, **kwargs) diff --git a/connector_prestashop/models/product_pricelist/__init__.py b/connector_prestashop/models/product_pricelist/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/product_pricelist/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/product_pricelist/common.py b/connector_prestashop/models/product_pricelist/common.py new file mode 100644 index 000000000..664bed47f --- /dev/null +++ b/connector_prestashop/models/product_pricelist/common.py @@ -0,0 +1,41 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class ProductPricelist(models.Model): + _inherit = 'product.pricelist' + + prestashop_groups_bind_ids = fields.One2many( + comodel_name='prestashop.groups.pricelist', + inverse_name='openerp_id', + string='PrestaShop user groups', + ) + + +class PrestashopGroupsPricelist(models.Model): + _name = 'prestashop.groups.pricelist' + _inherit = 'prestashop.binding' + _inherits = {'product.pricelist': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='product.pricelist', + required=True, + ondelete='cascade', + string='Openerp Pricelist', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class PricelistAdapter(GenericAdapter): + _model_name = 'prestashop.groups.pricelist' + _prestashop_model = 'groups' diff --git a/connector_prestashop/models/product_pricelist/importer.py b/connector_prestashop/models/product_pricelist/importer.py new file mode 100644 index 000000000..00b8f7999 --- /dev/null +++ b/connector_prestashop/models/product_pricelist/importer.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.unit.mapper import ( + ImportMapper, + mapping, +) +from ...unit.importer import TranslatableRecordImporter +from ...backend import prestashop + + +@prestashop +class ProductPricelistMapper(ImportMapper): + _model_name = 'prestashop.groups.pricelist' + + direct = [ + ('name', 'name'), + ] + + @mapping + def static(self, record): + return {'active': True} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + def versions(self, record): + item = { + 'min_quantity': 0, + 'sequence': 5, + 'base': 'list_price', + 'compute_price': 'percentage', + 'percent_price': float(record['reduction']), + } + return {'item_ids': [(5,), (0, 0, item)]} + + +@prestashop +class ProductPricelistImporter(TranslatableRecordImporter): + _model_name = [ + 'prestashop.groups.pricelist', + ] + + _translatable_fields = { + 'prestashop.groups.pricelist': ['name'], + } diff --git a/connector_prestashop/models/product_product/__init__.py b/connector_prestashop/models/product_product/__init__.py new file mode 100644 index 000000000..b76444be0 --- /dev/null +++ b/connector_prestashop/models/product_product/__init__.py @@ -0,0 +1,6 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import deleter +from . import exporter +from . import importer diff --git a/connector_prestashop/models/product_product/common.py b/connector_prestashop/models/product_product/common.py new file mode 100644 index 000000000..c8ff8a33a --- /dev/null +++ b/connector_prestashop/models/product_product/common.py @@ -0,0 +1,256 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import api, fields, models +from odoo.addons import decimal_precision as dp + +from odoo.addons.queue_job.job import job +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop +from exporter import CombinationInventoryExporter + + +class ProductProduct(models.Model): + _inherit = 'product.product' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.combination', + inverse_name='openerp_id', + copy=False, + string='PrestaShop Bindings', + ) + prestashop_combinations_bind_ids = fields.One2many( + comodel_name='prestashop.product.combination', + inverse_name='odoo_id', + string='PrestaShop Bindings (combinations)', + ) + default_on = fields.Boolean(string='Default On') + impact_price = fields.Float( + string="Price Impact", digits=dp.get_precision('Product Price')) + + @api.multi + def update_prestashop_qty(self): + for product in self: + for combination_binding in product.prestashop_bind_ids: + combination_binding.recompute_prestashop_qty() + + @api.multi + def update_prestashop_quantities(self): + for product in self: + product_template = product.product_tmpl_id + prestashop_combinations = ( + len(product_template.product_variant_ids) > 1 and + product_template.product_variant_ids) or [] + if not prestashop_combinations: + for prestashop_product in product_template.prestashop_bind_ids: + prestashop_product.recompute_prestashop_qty() + else: + for prestashop_combination in prestashop_combinations: + for combination_binding in \ + prestashop_combination.prestashop_bind_ids: + combination_binding.recompute_prestashop_qty() + return True + + @api.multi + @api.depends('impact_price', 'product_tmpl_id.list_price') + def _compute_lst_price(self): + for product in self: + price = product.list_price + product.impact_price + if 'uom' in self.env.context: + # `uos_id` comes from `product_uos` + # which could be not installed + uom = hasattr(product, 'uos_id') \ + and product.uos_id or product.uom_id + price = uom._compute_price( + product.uom_id.id, price, self.env.context['uom']) + product.lst_price = price + + lst_price = fields.Float( + compute='_compute_lst_price') + + @api.multi + def _set_variants_default_on(self, default_on_list=None): + if self.env.context.get('skip_check_default_variant', False): + return True + templates = self.mapped('product_tmpl_id') + for template in templates: + variants = template.with_context( + skip_check_default_variant=True + ).product_variant_ids.filtered('default_on') + if not variants: + active_variants = template.with_context( + skip_check_default_variant=True + ).product_variant_ids.filtered('active') + active_variants[:1].write({'default_on': True}) + elif len(variants) > 1: + if default_on_list: + variants.filtered( + lambda x: x.id not in default_on_list + ).write({'default_on': False}) + else: + variants[1:].write({'default_on': False}) + + @api.model + def create(self, vals): + res = super(ProductProduct, self).create(vals) + res._set_variants_default_on() + return res + + @api.multi + def write(self, vals): + if not vals.get('active', True): + vals['default_on'] = False + res = super(ProductProduct, self).write(vals) + default_on_list = vals.get('default_on', False) and self.ids or [] + self._set_variants_default_on(default_on_list) + return res + + @api.multi + def unlink(self): + self.write({'default_on': False}) + res = super(ProductProduct, self).unlink() + return res + + @api.multi + def open_product_template(self): + """ + Utility method used to add an "Open Product Template" + button in product.product views + """ + self.ensure_one() + return {'type': 'ir.actions.act_window', + 'res_model': 'product.template', + 'view_mode': 'form', + 'res_id': self.product_tmpl_id.id, + 'target': 'new', + 'flags': {'form': {'action_buttons': True}}} + + +class PrestashopProductCombination(models.Model): + _name = 'prestashop.product.combination' + _inherit = 'prestashop.binding.odoo' + _inherits = {'product.product': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='product.product', + string='Product', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + main_template_id = fields.Many2one( + comodel_name='prestashop.product.template', + string='Main Template', + required=True, + ondelete='cascade', + ) + quantity = fields.Float( + string='Computed Quantity', + help='Last computed quantity to send on PrestaShop.' + ) + reference = fields.Char(string='Original reference') + + @api.multi + def recompute_prestashop_qty(self): + for product_binding in self: + if product_binding.quantity != product_binding.qty_available: + product_binding.quantity = product_binding.qty_available + return True + + @api.model + def _prestashop_qty(self, product): + return product.qty_available + + @job(default_channel='root.prestashop') + def export_inventory(self, backend, fields=None, **kwargs): + """ Export the inventory configuration and quantity of a product. """ + env = backend.get_environment(self._name) + inventory_exporter = env.get_connector_unit( + CombinationInventoryExporter) + return inventory_exporter.run(self.id, fields, **kwargs) + + @api.model + @job(default_channel='root.prestashop') + def export_product_quantities(self, backend): + self.search([ + ('backend_id', 'in', backend.ids), + ]).recompute_prestashop_qty() + + +class ProductAttribute(models.Model): + _inherit = 'product.attribute' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.combination.option', + inverse_name='odoo_id', + string='PrestaShop Bindings (combinations)', + ) + + +class PrestashopProductCombinationOption(models.Model): + _name = 'prestashop.product.combination.option' + _inherit = 'prestashop.binding.odoo' + _inherits = {'product.attribute': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='product.attribute', + string='Attribute', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + prestashop_position = fields.Integer('PrestaShop Position') + group_type = fields.Selection([ + ('color', 'Color'), + ('radio', 'Radio'), + ('select', 'Select')], string='Type', default='select') + public_name = fields.Char(string='Public Name', translate=True) + + +class ProductAttributeValue(models.Model): + _inherit = 'product.attribute.value' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.combination.option.value', + inverse_name='odoo_id', + string='PrestaShop Bindings', + ) + + +class PrestashopProductCombinationOptionValue(models.Model): + _name = 'prestashop.product.combination.option.value' + _inherit = 'prestashop.binding' + _inherits = {'product.attribute.value': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='product.attribute.value', + string='Attribute', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + prestashop_position = fields.Integer( + string='PrestaShop Position', + default=1, + ) + id_attribute_group = fields.Many2one( + comodel_name='prestashop.product.combination.option') + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class ProductCombinationAdapter(GenericAdapter): + _model_name = 'prestashop.product.combination' + _prestashop_model = 'combinations' + _export_node_name = 'combination' + + +@prestashop +class ProductCombinationOptionAdapter(GenericAdapter): + _model_name = 'prestashop.product.combination.option' + _prestashop_model = 'product_options' + _export_node_name = 'product_options' diff --git a/connector_prestashop/models/product_product/deleter.py b/connector_prestashop/models/product_product/deleter.py new file mode 100644 index 000000000..790efe7e7 --- /dev/null +++ b/connector_prestashop/models/product_product/deleter.py @@ -0,0 +1,15 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from ...unit.deleter import PrestashopDeleter +from ...backend import prestashop + + +@prestashop +class ProductCombinationDelete(PrestashopDeleter): + _model_name = 'prestashop.product.combination' + + def delete(self, id): + """ Delete a record on the external system """ + return self._call('%s.delete' % self._prestashop_model, [int(id)]) diff --git a/connector_prestashop/models/product_product/exporter.py b/connector_prestashop/models/product_product/exporter.py new file mode 100644 index 000000000..5f6f91c12 --- /dev/null +++ b/connector_prestashop/models/product_product/exporter.py @@ -0,0 +1,16 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from ...backend import prestashop +from ..product_template.exporter import ProductInventoryExporter + + +@prestashop +class CombinationInventoryExporter(ProductInventoryExporter): + _model_name = ['prestashop.product.combination'] + + def get_filter(self, template): + return { + 'filter[id_product]': template.main_template_id.prestashop_id, + 'filter[id_product_attribute]': template.prestashop_id, + } diff --git a/connector_prestashop/models/product_product/importer.py b/connector_prestashop/models/product_product/importer.py new file mode 100644 index 000000000..1c2b33c3e --- /dev/null +++ b/connector_prestashop/models/product_product/importer.py @@ -0,0 +1,396 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models + +from odoo.addons.connector.unit.backend_adapter import BackendAdapter +from odoo.addons.connector.unit.mapper import ( + mapping, + only_create, + ImportMapper, +) +from ...unit.importer import ( + PrestashopImporter, + import_batch, + TranslatableRecordImporter, + DelayedBatchImporter, +) +from ...unit.backend_adapter import GenericAdapter, PrestaShopCRUDAdapter +from ...backend import prestashop + +import logging +_logger = logging.getLogger(__name__) +try: + from prestapyt import PrestaShopWebServiceError +except: + _logger.debug('Cannot import from `prestapyt`') + + +@prestashop +class ProductCombinationImporter(PrestashopImporter): + _model_name = 'prestashop.product.combination' + + def _import_dependencies(self): + record = self.prestashop_record + ps_key = self.backend_record.get_version_ps_key('product_option_value') + option_values = record.get('associations', {}).get( + 'product_option_values', {}).get(ps_key, []) + if not isinstance(option_values, list): + option_values = [option_values] + backend_adapter = self.unit_for( + BackendAdapter, 'prestashop.product.combination.option.value') + for option_value in option_values: + option_value = backend_adapter.read(option_value['id']) + self._import_dependency( + option_value['id_attribute_group'], + 'prestashop.product.combination.option') + self._import_dependency( + option_value['id'], + 'prestashop.product.combination.option.value') + + def _after_import(self, binding): + super(ProductCombinationImporter, self)._after_import(binding) + self.import_supplierinfo(binding) + + def set_variant_images(self, combinations): + backend_adapter = self.unit_for( + PrestaShopCRUDAdapter, 'prestashop.product.combination') + for combination in combinations: + try: + record = backend_adapter.read(combination['id']) + associations = record.get('associations', {}) + ps_images = associations.get('images', {}).get( + self.backend_record.get_version_ps_key('image'), {}) + binder = self.binder_for('prestashop.product.image') + if not isinstance(ps_images, list): + ps_images = [ps_images] + if 'id' in ps_images[0]: + images = [ + binder.to_internal(x.get('id'), unwrap=True) + for x in ps_images + ] + else: + images = [] + if images: + product_binder = self.binder_for( + 'prestashop.product.combination') + product_product = product_binder.to_internal( + combination['id'], unwrap=True) + product_product.with_context( + connector_no_export=True).write( + {'image_ids': [(6, 0, [x.id for x in images])]}) + except PrestaShopWebServiceError: + # TODO: don't we track anything here? Maybe a checkpoint? + pass + + def import_supplierinfo(self, binding): + ps_id = self._get_prestashop_data()['id'] + filters = { + # 'filter[id_product]': ps_id, + 'filter[id_product_attribute]': ps_id + } + import_batch( + self.session, + 'prestashop.product.supplierinfo', + self.backend_record.id, + filters=filters + ) + ps_product_template = binding + ps_supplierinfos = self.env['prestashop.product.supplierinfo']. \ + search([('product_tmpl_id', '=', ps_product_template.id)]) + for ps_supplierinfo in ps_supplierinfos: + try: + ps_supplierinfo.resync() + except PrestaShopWebServiceError: + ps_supplierinfo.odoo_id.unlink() + + +@prestashop +class ProductCombinationMapper(ImportMapper): + _model_name = 'prestashop.product.combination' + + direct = [ + ] + + from_main = [] + + @mapping + def combination_default(self, record): + return {'default_on': bool(int(record['default_on'] or 0))} + + @mapping + def product_tmpl_id(self, record): + template = self.get_main_template_binding(record) + return {'product_tmpl_id': template.openerp_id.id} + + @mapping + def from_main_template(self, record): + main_template = self.get_main_template_binding(record) + result = {} + for attribute in self.from_main: + if attribute not in main_template: + continue + if hasattr(main_template[attribute], 'id'): + result[attribute] = main_template[attribute].id + elif type(main_template[attribute]) is models.BaseModel: + ids = [] + for element in main_template[attribute]: + ids.append(element.id) + result[attribute] = [(6, 0, ids)] + else: + result[attribute] = main_template[attribute] + return result + + def get_main_template_binding(self, record): + template_binder = self.binder_for('prestashop.product.template') + return template_binder.to_internal(record['id_product']) + + def _get_option_value(self, record): + option_values = record.get('associations', {}).get( + 'product_option_values', {}).get( + self.backend_record.get_version_ps_key('product_option_value'), []) + if type(option_values) is dict: + option_values = [option_values] + + for option_value in option_values: + option_value_binder = self.binder_for( + 'prestashop.product.combination.option.value') + option_value_binding = option_value_binder.to_internal( + option_value['id'] + ) + assert option_value_binding, "must have a binding for the option" + yield option_value_binding.odoo_id + + @mapping + def name(self, record): + template = self.get_main_template_binding(record) + options = [] + for option_value_object in self._get_option_value(record): + key = option_value_object.attribute_id.name + value = option_value_object.name + options.append('%s:%s' % (key, value)) + return {'name_template': template.name} + + @mapping + def attribute_value_ids(self, record): + results = [] + for option_value_object in self._get_option_value(record): + results.append(option_value_object.id) + return {'attribute_value_ids': [(6, 0, results)]} + + @mapping + def main_template_id(self, record): + template_binding = self.get_main_template_binding(record) + return {'main_template_id': template_binding.id} + + def _template_code_exists(self, code): + model = self.session.env['product.product'] + combination_binder = self.binder_for('prestashop.product.combination') + template_ids = model.search([ + ('default_code', '=', code), + ('company_id', '=', self.backend_record.company_id.id), + ], limit=1) + return template_ids and not combination_binder.to_external( + template_ids, wrap=True) + + @mapping + def default_code(self, record): + code = record.get('reference') + if not code: + code = "%s_%s" % (record['id_product'], record['id']) + if not self._template_code_exists(code): + return {'default_code': code} + i = 1 + current_code = '%s_%s' % (code, i) + while self._template_code_exists(current_code): + i += 1 + current_code = '%s_%s' % (code, i) + return {'default_code': current_code} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def barcode(self, record): + barcode = record.get('barcode') or record.get('ean13') + check_ean = self.env['barcode.nomenclature'].check_ean + if barcode in ['', '0']: + backend_adapter = self.unit_for( + GenericAdapter, 'prestashop.product.template') + template = backend_adapter.read(record['id_product']) + barcode = template.get('barcode') or template.get('ean13') + if barcode and barcode != '0' and check_ean(barcode): + return {'barcode': barcode} + return {} + + def _get_tax_ids(self, record): + product_tmpl_adapter = self.unit_for( + GenericAdapter, 'prestashop.product.template') + tax_group = product_tmpl_adapter.read(record['id_product']) + tax_group = self.binder_for('prestashop.account.tax.group').to_internal( + tax_group['id_tax_rules_group'], unwrap=True) + return tax_group.tax_ids + + def _apply_taxes(self, tax, price): + if self.backend_record.taxes_included == tax.price_include: + return price + factor_tax = tax.price_include and (1 + tax.amount / 100) or 1.0 + if self.backend_record.taxes_included: + if not tax.price_include: + return price / factor_tax + else: + if tax.price_include: + return price * factor_tax + + @mapping + def specific_price(self, record): + product = self.binder_for( + 'prestashop.product.combination').to_internal( + record['id'], unwrap=True + ) + product_template = self.binder_for( + 'prestashop.product.template').to_internal(record['id_product']) + tax = product.product_tmpl_id.taxes_id[:1] or self._get_tax_ids(record) + impact = float(self._apply_taxes(tax, float(record['price'] or '0.0'))) + cost_price = float(record['wholesale_price'] or '0.0') + return { + 'list_price': product_template.list_price, + 'standard_price': cost_price or product_template.wholesale_price, + 'impact_price': impact + } + + @only_create + @mapping + def odoo_id(self, record): + product = self.env['product.product'].search([ + ('default_code', '=', record['reference']), + ('prestashop_bind_ids', '=', False), + ], limit=1) + if product: + return {'odoo_id': product.id} + + +@prestashop +class ProductCombinationOptionImporter(PrestashopImporter): + _model_name = 'prestashop.product.combination.option' + + def _import_values(self, attribute_binding): + record = self.prestashop_record + option_values = record.get('associations', {}).get( + 'product_option_values', {}).get( + self.backend_record.get_version_ps_key('product_option_value'), []) + if not isinstance(option_values, list): + option_values = [option_values] + for option_value in option_values: + self._import_dependency( + option_value['id'], + 'prestashop.product.combination.option.value' + ) + + def _after_import(self, binding): + super(ProductCombinationOptionImporter, self)._after_import(binding) + self._import_values(binding) + + +@prestashop +class ProductCombinationOptionMapper(ImportMapper): + _model_name = 'prestashop.product.combination.option' + + direct = [] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @only_create + @mapping + def odoo_id(self, record): + name = self.name(record) + binding = self.env['product.attribute'].search( + [('name', '=', name)], + limit=1, + ) + if binding: + return {'odoo_id': binding.id} + + @mapping + def name(self, record): + name = None + if 'language' in record['name']: + language_binder = self.binder_for('prestashop.res.lang') + languages = record['name']['language'] + if not isinstance(languages, list): + languages = [languages] + for lang in languages: + erp_language = language_binder.to_internal( + lang['attrs']['id']) + if not erp_language: + continue + if erp_language.code == 'en_US': + name = lang['value'] + break + if name is None: + name = languages[0]['value'] + else: + name = record['name'] + return {'name': name} + + +@prestashop +class ProductCombinationOptionValueAdapter(GenericAdapter): + _model_name = 'prestashop.product.combination.option.value' + _prestashop_model = 'product_option_values' + _export_node_name = 'product_option_value' + + +@prestashop +class ProductCombinationOptionValueImporter(TranslatableRecordImporter): + _model_name = 'prestashop.product.combination.option.value' + + _translatable_fields = { + 'prestashop.product.combination.option.value': ['name'], + } + + +@prestashop +class ProductCombinationOptionValueMapper(ImportMapper): + _model_name = 'prestashop.product.combination.option.value' + + direct = [ + ('name', 'name'), + ] + + @only_create + @mapping + def odoo_id(self, record): + attribute_binder = self.binder_for( + 'prestashop.product.combination.option' + ) + attribute = attribute_binder.to_internal( + record['id_attribute_group'], + unwrap=True + ) + assert attribute + binding = self.env['product.attribute.value'].search( + [('name', '=', record['name']), + ('attribute_id', '=', attribute.id)], + limit=1, + ) + if binding: + return {'odoo_id': binding.id} + + @mapping + def attribute_id(self, record): + binder = self.binder_for('prestashop.product.combination.option') + attribute = binder.to_internal(record['id_attribute_group'], unwrap=True) + return {'attribute_id': attribute.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + +@prestashop +class ProductProductBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.product.product' diff --git a/connector_prestashop/models/product_supplierinfo/__init__.py b/connector_prestashop/models/product_supplierinfo/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/product_supplierinfo/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/product_supplierinfo/common.py b/connector_prestashop/models/product_supplierinfo/common.py new file mode 100644 index 000000000..e99a919da --- /dev/null +++ b/connector_prestashop/models/product_supplierinfo/common.py @@ -0,0 +1,92 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import models, fields + +from ...unit.backend_adapter import ( + PrestaShopCRUDAdapter, + PrestaShopWebServiceImage, + GenericAdapter, +) +from ...backend import prestashop + + +class ResPartner(models.Model): + _inherit = 'res.partner' + + prestashop_supplier_bind_ids = fields.One2many( + comodel_name='prestashop.supplier', + inverse_name='odoo_id', + string="PrestaShop supplier bindings", + ) + + +class PrestashopSupplier(models.Model): + _name = 'prestashop.supplier' + _inherit = 'prestashop.binding.odoo' + _inherits = {'res.partner': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='res.partner', + string='Partner', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + + +class ProductSupplierinfo(models.Model): + _inherit = 'product.supplierinfo' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.supplierinfo', + inverse_name='odoo_id', + string="PrestaShop bindings", + ) + + +class PrestashopProductSupplierinfo(models.Model): + _name = 'prestashop.product.supplierinfo' + _inherit = 'prestashop.binding.odoo' + _inherits = {'product.supplierinfo': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='product.supplierinfo', + string='Supplier info', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +@prestashop +class SupplierImageAdapter(PrestaShopCRUDAdapter): + _model_name = 'prestashop.supplier.image' + _prestashop_image_model = 'suppliers' + + def read(self, supplier_id, options=None): + client = PrestaShopWebServiceImage(self.prestashop.api_url, + self.prestashop.webservice_key) + res = client.get_image( + self._prestashop_image_model, + supplier_id, + options=options + ) + return res['content'] + + +@prestashop +class SupplierAdapter(GenericAdapter): + _model_name = 'prestashop.supplier' + _prestashop_model = 'suppliers' + + +@prestashop +class SupplierInfoAdapter(GenericAdapter): + _model_name = 'prestashop.product.supplierinfo' + _prestashop_model = 'product_suppliers' diff --git a/connector_prestashop/models/product_supplierinfo/importer.py b/connector_prestashop/models/product_supplierinfo/importer.py new file mode 100644 index 000000000..5f022376b --- /dev/null +++ b/connector_prestashop/models/product_supplierinfo/importer.py @@ -0,0 +1,186 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import fields +from odoo.addons.queue_job.exception import FailedJobError +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.mapper import ImportMapper, mapping + +from ...unit.backend_adapter import PrestaShopCRUDAdapter +from ...unit.importer import ( + PrestashopImporter, + import_batch, + DelayedBatchImporter, +) +from ...backend import prestashop + +import logging +_logger = logging.getLogger(__name__) +try: + from prestapyt import PrestaShopWebServiceError +except: + _logger.debug('Cannot import from `prestapyt`') + + +@prestashop +class SupplierMapper(ImportMapper): + _model_name = 'prestashop.supplier' + + direct = [ + ('name', 'name'), + ('id', 'prestashop_id'), + ('active', 'active'), + ] + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def supplier(self, record): + return { + 'supplier': True, + 'is_company': True, + 'customer': False, + } + + @mapping + def image(self, record): + supplier_image_adapter = self.unit_for( + PrestaShopCRUDAdapter, 'prestashop.supplier.image' + ) + try: + return {'image': supplier_image_adapter.read(record['id'])} + except: + return {} + + +@prestashop +class SupplierImporter(PrestashopImporter): + """ Import one simple record """ + _model_name = 'prestashop.supplier' + + def _create(self, record): + try: + return super(SupplierImporter, self)._create(record) + except ZeroDivisionError: + del record['image'] + return super(SupplierImporter, self)._create(record) + + def _after_import(self, binding): + super(SupplierImporter, self)._after_import(binding) + binder = self.binder_for() + ps_id = binder.to_external(binding) + import_batch( + self.session, + 'prestashop.product.supplierinfo', + self.backend_record.id, + filters={'filter[id_supplier]': '%d' % ps_id}, + priority=10, + ) + + +@prestashop +class SupplierBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.supplier' + + +@prestashop +class SupplierInfoMapper(ImportMapper): + _model_name = 'prestashop.product.supplierinfo' + + direct = [ + ('product_supplier_reference', 'product_code'), + ] + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def name(self, record): + binder = self.binder_for('prestashop.supplier') + partner = binder.to_internal(record['id_supplier'], unwrap=True) + return {'name': partner.id} + + @mapping + def product_id(self, record): + if record['id_product_attribute'] != '0': + binder = self.binder_for('prestashop.product.combination') + product = binder.to_internal( + record['id_product_attribute'], + unwrap=True, + ) + return {'product_id': product.id} + return {} + + @mapping + def product_tmpl_id(self, record): + binder = self.binder_for('prestashop.product.template') + template = binder.to_internal(record['id_product'], unwrap=True) + return {'product_tmpl_id': template.id} + + @mapping + def required(self, record): + return {'min_qty': 0.0, 'delay': 1} + + +@prestashop +class SupplierInfoImporter(PrestashopImporter): + _model_name = 'prestashop.product.supplierinfo' + + def _import_dependencies(self): + record = self.prestashop_record + try: + self._import_dependency( + record['id_supplier'], 'prestashop.supplier' + ) + self._import_dependency( + record['id_product'], 'prestashop.product.template' + ) + + if record['id_product_attribute'] != '0': + self._import_dependency( + record['id_product_attribute'], + 'prestashop.product.combination' + ) + except PrestaShopWebServiceError: + raise FailedJobError('Error fetching a dependency') + + +@prestashop +class SupplierInfoBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.product.supplierinfo' + + +@job(default_channel='root.prestashop') +def import_suppliers(session, backend_id, since_date, **kwargs): + filters = None + if since_date: + filters = {'date': '1', 'filter[date_upd]': '>[%s]' % (since_date)} + now_fmt = fields.Datetime.now() + result = import_batch( + session, + 'prestashop.supplier', + backend_id, + filters, + **kwargs + ) or '' + result += import_batch( + session, + 'prestashop.product.supplierinfo', + backend_id, + **kwargs + ) or '' + session.env['prestashop.backend'].browse(backend_id).write({ + 'import_suppliers_since': now_fmt + }) + return result diff --git a/connector_prestashop/models/product_template/__init__.py b/connector_prestashop/models/product_template/__init__.py new file mode 100644 index 000000000..05691dc17 --- /dev/null +++ b/connector_prestashop/models/product_template/__init__.py @@ -0,0 +1,5 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import exporter +from . import importer diff --git a/connector_prestashop/models/product_template/common.py b/connector_prestashop/models/product_template/common.py new file mode 100644 index 000000000..07da481de --- /dev/null +++ b/connector_prestashop/models/product_template/common.py @@ -0,0 +1,213 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import api, fields, models +from odoo.addons import decimal_precision as dp + +from odoo.addons.queue_job.job import job +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop +from exporter import ProductInventoryExporter + +import logging + +_logger = logging.getLogger(__name__) + +try: + from prestapyt import PrestaShopWebServiceDict +except: + _logger.debug('Cannot import from `prestapyt`') + + +class ProductTemplate(models.Model): + _inherit = 'product.template' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.product.template', + inverse_name='odoo_id', + copy=False, + string='PrestaShop Bindings', + ) + prestashop_default_category_id = fields.Many2one( + comodel_name='product.category', + string='PrestaShop Default Category', + ondelete='restrict' + ) + + @api.multi + def update_prestashop_quantities(self): + for template in self: + # Recompute product template PrestaShop qty + template.mapped('prestashop_bind_ids').recompute_prestashop_qty() + # Recompute variant PrestaShop qty + template.mapped( + 'product_variant_ids.prestashop_bind_ids' + ).recompute_prestashop_qty() + return True + + +class PrestashopProductTemplate(models.Model): + _name = 'prestashop.product.template' + _inherit = 'prestashop.binding.odoo' + _inherits = {'product.template': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='product.template', + required=True, + ondelete='cascade', + string='Template', + oldname='openerp_id', + ) + # TODO FIXME what name give to field present in + # prestashop_product_product and product_product + always_available = fields.Boolean( + string='Active', + default=True, + help='If checked, this product is considered always available') + quantity = fields.Float( + string='Computed Quantity', + help="Last computed quantity to send to PrestaShop." + ) + description_html = fields.Html( + string='Description', + translate=True, + help="HTML description from PrestaShop", + ) + description_short_html = fields.Html( + string='Short Description', + translate=True, + ) + date_add = fields.Datetime( + string='Created at (in PrestaShop)', + readonly=True + ) + date_upd = fields.Datetime( + string='Updated at (in PrestaShop)', + readonly=True + ) + default_shop_id = fields.Many2one( + comodel_name='prestashop.shop', + string='Default shop', + required=True + ) + link_rewrite = fields.Char( + string='Friendly URL', + translate=True, + ) + available_for_order = fields.Boolean( + string='Available for Order Taking', + default=True, + ) + show_price = fields.Boolean(string='Display Price', default=True) + combinations_ids = fields.One2many( + comodel_name='prestashop.product.combination', + inverse_name='main_template_id', + string='Combinations' + ) + reference = fields.Char(string='Original reference') + on_sale = fields.Boolean(string='Show on sale icon') + wholesale_price = fields.Float( + string='Cost Price', + digits=dp.get_precision('Product Price'), + ) + + @api.multi + def recompute_prestashop_qty(self): + for product_binding in self: + new_qty = product_binding._prestashop_qty() + if product_binding.quantity != new_qty: + product_binding.quantity = new_qty + return True + + def _prestashop_qty(self): + locations = self.env['stock.location'].search([ + ('id', 'child_of', self.backend_id.warehouse_id.lot_stock_id.id), + ('prestashop_synchronized', '=', True), + ('usage', '=', 'internal'), + ]) + return self.with_context(location=locations.ids).qty_available + + @job(default_channel='root.prestashop') + def import_products(self, backend, since_date=None, **kwargs): + filters = None + if since_date: + filters = {'date': '1', 'filter[date_upd]': '>[%s]' % (since_date)} + now_fmt = fields.Datetime.now() + self.env['prestashop.product.category'].with_delay( + priority=15 + ).import_batch(backend=backend, filters=filters, **kwargs) + self.env['prestashop.product.template'].with_delay( + priority=15 + ).import_batch(backend, filters, **kwargs) + backend.import_products_since = now_fmt + return True + + @job(default_channel='root.prestashop') + def export_inventory(self, backend, fields=None, **kwargs): + """ Export the inventory configuration and quantity of a product. """ + env = backend.get_environment(self._name) + inventory_exporter = env.get_connector_unit(ProductInventoryExporter) + return inventory_exporter.run(self.id, fields, **kwargs) + + @api.model + @job(default_channel='root.prestashop') + def export_product_quantities(self, backend): + self.search([ + ('backend_id', 'in', self.env.backend.ids), + ]).recompute_prestashop_qty() + + +@prestashop +class ProductInventoryAdapter(GenericAdapter): + _model_name = '_import_stock_available' + _prestashop_model = 'stock_availables' + _export_node_name = 'stock_available' + + def get(self, options=None): + return self.client.get(self._prestashop_model, options=options) + + def export_quantity(self, filters, quantity): + self.export_quantity_url( + filters, + quantity, + ) + + shops = self.env['prestashop.shop'].search([ + ('backend_id', '=', self.backend_record.id), + ('default_url', '!=', False), + ]) + for shop in shops: + url = '%s/api' % shop.default_url + key = self.backend_record.webservice_key + client = PrestaShopWebServiceDict(url, key) + self.export_quantity_url(filters, quantity, client=client) + + def export_quantity_url(self, filters, quantity, client=None): + if client is None: + client = self.client + response = client.search(self._prestashop_model, filters) + for stock_id in response: + res = client.get(self._prestashop_model, stock_id) + first_key = res.keys()[0] + stock = res[first_key] + stock['quantity'] = int(quantity) + client.edit(self._prestashop_model, { + self._export_node_name: stock + }) + + +@prestashop +class PrestashopProductTags(GenericAdapter): + _model_name = '_prestashop_product_tag' + _prestashop_model = 'tags' + _export_node_name = 'tag' + + def search(self, filters=None): + res = self.client.get(self._prestashop_model, options=filters) + tags = res[self._prestashop_model] + if not tags: + return [] + tags = tags[self._export_node_name] + if isinstance(tags, dict): + return [tags] + return tags diff --git a/connector_prestashop/models/product_template/exporter.py b/connector_prestashop/models/product_template/exporter.py new file mode 100644 index 000000000..304a0dcc1 --- /dev/null +++ b/connector_prestashop/models/product_template/exporter.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.synchronizer import Exporter + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +@prestashop +class ProductInventoryExporter(Exporter): + _model_name = ['prestashop.product.template'] + + def get_filter(self, template): + binder = self.binder_for() + prestashop_id = binder.to_external(template.id) + return { + 'filter[id_product]': prestashop_id, + 'filter[id_product_attribute]': 0 + } + + def run(self, binding_id, fields, **kwargs): + """ Export the product inventory to PrestaShop """ + template = self.model.browse(binding_id) + adapter = self.unit_for(GenericAdapter, '_import_stock_available') + filter = self.get_filter(template) + adapter.export_quantity(filter, int(template.quantity)) + + +# TODO: Remove because it has been moved to prestashop product template and +# prestashop product combination +@job(default_channel='root.prestashop') +def export_inventory(session, model_name, record_id, fields=None, **kwargs): + """ Export the inventory configuration and quantity of a product. """ + binding = session.env[model_name].browse(record_id) + backend = binding.backend_id + env = backend.get_environment(model_name, session=session) + inventory_exporter = env.get_connector_unit(ProductInventoryExporter) + return inventory_exporter.run(record_id, fields, **kwargs) + + +@job(default_channel='root.prestashop') +def export_product_quantities(session, ids): + for model in ['template', 'combination']: + model_obj = session.env['prestashop.product.' + model] + model_obj.search([ + ('backend_id', 'in', [ids]), + ]).recompute_prestashop_qty() diff --git a/connector_prestashop/models/product_template/importer.py b/connector_prestashop/models/product_template/importer.py new file mode 100644 index 000000000..e6740f454 --- /dev/null +++ b/connector_prestashop/models/product_template/importer.py @@ -0,0 +1,678 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import _, models, fields +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.mapper import ( + mapping, + only_create, + ImportMapper +) + +from ...unit.importer import ( + DelayedBatchImporter, + import_record, + import_batch, + PrestashopImporter, + PrestashopBaseImporter, + TranslatableRecordImporter, +) +<<<<<<< HEAD +from ...unit.mapper import backend_to_m2o +======= +from odoo.addons.connector.unit.mapper import external_to_m2o +>>>>>>> [MIG] connector_prestashop: Begin of migration to v10 +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop +from ..product_image.importer import ( + import_product_image, + set_product_image_variant, +) + +import datetime +import logging +_logger = logging.getLogger(__name__) + +try: + import html2text +except ImportError: + _logger.debug('Cannot import `html2text`') + +try: + from bs4 import BeautifulSoup +except ImportError: + _logger.debug('Cannot import `bs4`') + +try: + from prestapyt import PrestaShopWebServiceError +except ImportError: + _logger.debug('Cannot import from `prestapyt`') + + +@prestashop +class TemplateMapper(ImportMapper): + _model_name = 'prestashop.product.template' + + direct = [ + ('weight', 'weight'), + ('wholesale_price', 'wholesale_price'), + ('wholesale_price', 'standard_price'), + (external_to_m2o('id_shop_default'), 'default_shop_id'), + ('link_rewrite', 'link_rewrite'), + ('reference', 'reference'), + ('available_for_order', 'available_for_order'), + ('on_sale', 'on_sale'), + ] + + def _apply_taxes(self, tax, price): + if self.backend_record.taxes_included == tax.price_include: + return price + factor_tax = tax.price_include and (1 + tax.amount / 100) or 1.0 + if self.backend_record.taxes_included: + if not tax.price_include: + return price / factor_tax + else: + if tax.price_include: + return price * factor_tax + + @mapping + def list_price(self, record): + price = 0.0 + tax = self._get_tax_ids(record) + if record['price'] != '': + price = float(record['price']) + price = self._apply_taxes(tax, price) + return {'list_price': price} + + @mapping + def tags_to_text(self, record): + associations = record.get('associations', {}) + tags = associations.get('tags', {}).get( + self.backend_record.get_version_ps_key('tag'), []) + tag_adapter = self.unit_for(GenericAdapter, '_prestashop_product_tag') + if not isinstance(tags, list): + tags = [tags] + if tags: + ps_tags = tag_adapter.search(filters={ + 'filter[id]': '[%s]' % '|'.join(x['id'] for x in tags), + 'display': '[name]' + }) + if ps_tags: + return {'tags': ','.join(x['name'] for x in ps_tags)} + + @mapping + def name(self, record): + if record['name']: + return {'name': record['name']} + return {'name': 'noname'} + + @mapping + def date_add(self, record): + if record['date_add'] == '0000-00-00 00:00:00': + return {'date_add': datetime.datetime.now()} + return {'date_add': record['date_add']} + + @mapping + def date_upd(self, record): + if record['date_upd'] == '0000-00-00 00:00:00': + return {'date_upd': datetime.datetime.now()} + return {'date_upd': record['date_upd']} + + def has_combinations(self, record): + associations = record.get('associations', {}) + combinations = associations.get('combinations', {}).get( + self.backend_record.get_version_ps_key('combinations')) + return len(combinations or '') != 0 + + @only_create + @mapping + def odoo_id(self, record): + """ Will bind the product to an existing one with the same code """ + product = self.env['product.template'].search( + [('default_code', '=', record['reference'])], limit=1) + if product: + return {'odoo_id': product.id} + + def _template_code_exists(self, code): + model = self.session.env['product.template'] + template_ids = model.search([ + ('default_code', '=', code), + ('company_id', '=', self.backend_record.company_id.id), + ], limit=1) + return len(template_ids) > 0 + + @mapping + def default_code(self, record): + if self.has_combinations(record): + return {} + code = record.get('reference') + if not code: + code = "backend_%d_product_%s" % ( + self.backend_record.id, record['id'] + ) + if not self._template_code_exists(code): + return {'default_code': code} + i = 1 + current_code = '%s_%d' % (code, i) + while self._template_code_exists(current_code): + i += 1 + current_code = '%s_%d' % (code, i) + return {'default_code': current_code} + + def clear_html_field(self, content): + html = html2text.HTML2Text() + html.ignore_images = True + html.ignore_links = True + return html.handle(content) + + @staticmethod + def sanitize_html(content): + content = BeautifulSoup(content, 'html.parser') + # Prestashop adds both 'lang="fr-ch"' and 'xml:lang="fr-ch"' + # but Odoo tries to parse the xml for the translation and fails + # due to the unknow namespace + for child in content.find_all(lambda tag: tag.has_attr('xml:lang')): + del child['xml:lang'] + return content.prettify() + + @mapping + def descriptions(self, record): + return { + 'description': self.clear_html_field( + record.get('description_short', '')), + 'description_html': self.sanitize_html( + record.get('description', '')), + 'description_short_html': self.sanitize_html( + record.get('description_short', '')), + } + + @mapping + def active(self, record): + return {'always_available': bool(int(record['active']))} + + @mapping + def sale_ok(self, record): + # if this product has combinations, we do not want to sell this + # product, but its combinations (so sale_ok = False in that case). + return {'sale_ok': True} + + @mapping + def purchase_ok(self, record): + return {'purchase_ok': True} + + @mapping + def categ_ids(self, record): + categories = record['associations'].get('categories', {}).get( + self.backend_record.get_version_ps_key('category'), []) + if not isinstance(categories, list): + categories = [categories] + product_categories = self.env['product.category'].browse() + binder = self.binder_for('prestashop.product.category') + for ps_category in categories: + product_categories |= binder.to_internal( + ps_category['id'], + unwrap=True, + ) + + return {'categ_ids': [(6, 0, product_categories.ids)]} + + @mapping + def default_category_id(self, record): + if not int(record['id_category_default']): + return + binder = self.binder_for('prestashop.product.category') + category = binder.to_internal( + record['id_category_default'], + unwrap=True, + ) + if category: + return {'prestashop_default_category_id': category.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + def barcode(self, record): + if self.has_combinations(record): + return {} + barcode = record.get('barcode') or record.get('ean13') + if barcode in ['', '0']: + return {} + if self.env['barcode.nomenclature'].check_ean(barcode): + return {'barcode': barcode} + return {} + + def _get_tax_ids(self, record): + # if record['id_tax_rules_group'] == '0': + # return {} + binder = self.binder_for('prestashop.account.tax.group') + tax_group = binder.to_internal( + record['id_tax_rules_group'], + unwrap=True, + ) + return tax_group.tax_ids + + @mapping + def taxes_id(self, record): + taxes = self._get_tax_ids(record) + return {'taxes_id': [(6, 0, taxes.ids)]} + + @mapping + def type(self, record): + # If the product has combinations, this main product is not a real + # product. So it is set to a 'service' kind of product. Should better + # be a 'virtual' product... but it does not exist... + # The same if the product is a virtual one in prestashop. + if record['type']['value'] and record['type']['value'] == 'virtual': + return {"type": 'service'} + return {"type": 'product'} + + @mapping + def extras_features(self, record): + mapper = self.unit_for(FeaturesProductImportMapper) + return mapper.map_record(record).values(**self.options) + + @mapping + def extras_manufacturer(self, record): + mapper = self.unit_for(ManufacturerProductImportMapper) + return mapper.map_record(record).values(**self.options) + + +@prestashop +class FeaturesProductImportMapper(ImportMapper): + # To extend in connector_prestashop_feature module. In this way we + # dependencies on other modules like product_custom_info + _model_name = 'prestashop.product.template' + + @mapping + def extras_features(self, record): + return {} + + +@prestashop +class ManufacturerProductDependency(PrestashopBaseImporter): + # To extend in connector_prestashop_feature module. In this way we + # dependencies on other modules like product_manufacturer + _model_name = 'prestashop.product.template' + + def import_manufacturer(self, manufacturer_id): + return + + +@prestashop +class ManufacturerProductImportMapper(ImportMapper): + # To extend in connector_prestashop_manufacturer module. In this way we + # dependencies on other modules like product_manufacturer + _model_name = 'prestashop.product.template' + + @mapping + def extras_manufacturer(self, record): + return {} + + +@prestashop +class TemplateAdapter(GenericAdapter): + _model_name = 'prestashop.product.template' + _prestashop_model = 'products' + _export_node_name = 'product' + + +class ImportInventory(models.TransientModel): + # In actual connector version is mandatory use a model + _name = '_import_stock_available' + + +@prestashop +class ProductInventoryBatchImporter(DelayedBatchImporter): + _model_name = ['_import_stock_available'] + + def run(self, filters=None, **kwargs): + if filters is None: + filters = {} + filters['display'] = '[id,id_product,id_product_attribute]' + _super = super(ProductInventoryBatchImporter, self) + return _super.run(filters, **kwargs) + + def _run_page(self, filters, **kwargs): + records = self.backend_adapter.get(filters) + for record in records['stock_availables']['stock_available']: + self._import_record(record['id'], record=record, **kwargs) + return records['stock_availables']['stock_available'] + + def _import_record(self, record_id, record=None, **kwargs): + """ Delay the import of the records""" + assert record + import_record.delay( + self.session, + '_import_stock_available', + self.backend_record.id, + record_id, + record=record, + **kwargs + ) + + +@prestashop +class ProductInventoryImporter(PrestashopImporter): + _model_name = ['_import_stock_available'] + + def _get_quantity(self, record): + filters = { + 'filter[id_product]': record['id_product'], + 'filter[id_product_attribute]': record['id_product_attribute'], + 'display': '[quantity]', + } + quantities = self.backend_adapter.get(filters) + all_qty = 0 + quantities = quantities['stock_availables']['stock_available'] + if isinstance(quantities, dict): + quantities = [quantities] + for quantity in quantities: + all_qty += int(quantity['quantity']) + return all_qty + + def _get_binding(self): + record = self.prestashop_record + if record['id_product_attribute'] == '0': + binder = self.binder_for('prestashop.product.template') + return binder.to_internal(record['id_product']) + binder = self.binder_for('prestashop.product.combination') + return binder.to_internal(record['id_product_attribute']) + + def _import_dependencies(self): + """ Import the dependencies for the record""" + record = self.prestashop_record + self._import_dependency( + record['id_product'], 'prestashop.product.template' + ) + if record['id_product_attribute'] != '0': + self._import_dependency( + record['id_product_attribute'], + 'prestashop.product.combination' + ) + + def _check_in_new_connector_env(self): + # not needed in this importer + return + + def run(self, prestashop_id, record=None, **kwargs): + assert record + self.prestashop_record = record + return super(ProductInventoryImporter, self).run( + prestashop_id, **kwargs + ) + + def _import(self, binding, **kwargs): + record = self.prestashop_record + qty = self._get_quantity(record) + if qty < 0: + qty = 0 + if binding._name == 'prestashop.product.template': + products = binding.odoo_id.product_variant_ids + else: + products = binding.odoo_id + + location = (self.backend_record.stock_location_id or + self.backend_record.warehouse_id.lot_stock_id) + for product in products: + vals = { + 'location_id': location.id, + 'product_id': product.id, + 'new_quantity': qty, + } + template_qty = self.env['stock.change.product.qty'].create(vals) + template_qty.with_context( + active_id=product.id, + connector_no_export=True, + ).change_product_qty() + + +@prestashop +class ProductTemplateImporter(TranslatableRecordImporter): + """ Import one translatable record """ + _model_name = [ + 'prestashop.product.template', + ] + + _base_mapper = TemplateMapper + + _translatable_fields = { + 'prestashop.product.template': [ + 'name', + 'description', + 'link_rewrite', + 'description_short', + 'meta_title', + 'meta_description', + 'meta_keywords', + + ], + } + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(ProductTemplateImporter, self).__init__(environment) + self.default_category_error = False + + def _after_import(self, binding): + super(ProductTemplateImporter, self)._after_import(binding) + self.import_images(binding) + self.import_combinations() + self.attribute_line(binding) + self.deactivate_default_product(binding) + self.checkpoint_default_category_missing(binding) + + def checkpoint_default_category_missing(self, binding): + if self.default_category_error: + msg = _('The default category could not be imported.') + self.backend_record.add_checkpoint( + model='product.template', + record_id=binding.odoo_id.id, + message=msg, + ) + + def deactivate_default_product(self, binding): + if binding.product_variant_count != 1: + for product in binding.product_variant_ids: + if not product.attribute_value_ids: + self.env['product.product'].browse(product.id).write( + {'active': False}) + + def attribute_line(self, binding): + attr_line_value_ids = [] + for attr_line in binding.attribute_line_ids: + attr_line_value_ids.extend(attr_line.value_ids.ids) + template_id = binding.openerp_id.id + products = self.env['product.product'].search([ + ('product_tmpl_id', '=', template_id)] + ) + if products: + attribute_ids = [] + for product in products: + for attribute_value in product.attribute_value_ids: + attribute_ids.append(attribute_value.attribute_id.id) + # filter unique id for create relation + for attribute_id in set(attribute_ids): + values = products.mapped('attribute_value_ids').filtered( + lambda x: (x.attribute_id.id == attribute_id and + x.id not in attr_line_value_ids)) + if values: + self.env['product.attribute.line'].create({ + 'attribute_id': attribute_id, + 'product_tmpl_id': template_id, + 'value_ids': [(6, 0, values.ids)], + }) + + def _import_combination(self, combination, **kwargs): + """ Import a combination + + Can be overriden for instance to forward arguments to the importer + """ + self._import_dependency(combination['id'], + 'prestashop.product.combination', + always=True, + **kwargs) + + def _delay_product_image_variant(self, combinations, **kwargs): + set_product_image_variant.delay( + self.session, + 'prestashop.product.combination', + self.backend_record.id, + combinations, + priority=15, + **kwargs + ) + + def import_combinations(self): + prestashop_record = self._get_prestashop_data() + associations = prestashop_record.get('associations', {}) + + ps_key = self.backend_record.get_version_ps_key('combinations') + combinations = associations.get('combinations', {}).get(ps_key, []) + + if not isinstance(combinations, list): + combinations = [combinations] + if combinations: + first_exec = combinations.pop( + combinations.index({ + 'id': prestashop_record[ + 'id_default_combination']['value']})) + if first_exec: + self._import_combination(first_exec) + + for combination in combinations: + self._import_combination(combination) + + if combinations and associations['images'].get('image'): + self._delay_product_image_variant(combinations) + + def _delay_import_product_image(self, prestashop_record, image, **kwargs): + import_product_image.delay( + self.session, + 'prestashop.product.image', + self.backend_record.id, + prestashop_record['id'], + image['id'], + priority=10, + **kwargs + ) + + def import_images(self, binding): + prestashop_record = self._get_prestashop_data() + associations = prestashop_record.get('associations', {}) + images = associations.get('images', {}).get( + self.backend_record.get_version_ps_key('image'), {}) + if not isinstance(images, list): + images = [images] + for image in images: + if image.get('id'): + self._delay_import_product_image(prestashop_record, image) + + def import_supplierinfo(self, binding): + ps_id = self._get_prestashop_data()['id'] + filters = { + 'filter[id_product]': ps_id, + 'filter[id_product_attribute]': 0 + } + import_batch( + self.session, + 'prestashop.product.supplierinfo', + self.backend_record.id, + filters=filters + ) + ps_product_template = binding + ps_supplierinfos = self.env['prestashop.product.supplierinfo'].\ + search([('product_tmpl_id', '=', ps_product_template.id)]) + for ps_supplierinfo in ps_supplierinfos: + try: + ps_supplierinfo.resync() + except PrestaShopWebServiceError: + ps_supplierinfo.openerp_id.unlink() + + def _import_dependencies(self): + self._import_default_category() + self._import_categories() + self._import_manufacturer() + + def _import_manufacturer(self): + self.unit_for(ManufacturerProductDependency).import_manufacturer( + self.prestashop_record.get('id_manufacturer') + ) + + def get_template_model_id(self): + ir_model = self.env['ir.model'].search([ + ('model', '=', 'product.template')], limit=1) + assert len(ir_model) == 1 + return ir_model.id + + def _import_default_category(self): + record = self.prestashop_record + if int(record['id_category_default']): + try: + self._import_dependency(record['id_category_default'], + 'prestashop.product.category') + except PrestaShopWebServiceError: + # a checkpoint will be added in _after_import (because + # we'll know the binding at this point) + self.default_category_error = True + + def _import_categories(self): + record = self.prestashop_record + associations = record.get('associations', {}) + categories = associations.get('categories', {}).get( + self.backend_record.get_version_ps_key('category'), []) + if not isinstance(categories, list): + categories = [categories] + for category in categories: + self._import_dependency(category['id'], + 'prestashop.product.category') + + +@job(default_channel='root.prestashop') +def import_inventory(session, backend_id): + backend = session.env['prestashop.backend'].browse(backend_id) + env = backend.get_environment('_import_stock_available', session=session) + inventory_importer = env.get_connector_unit(ProductInventoryBatchImporter) + return inventory_importer.run() + + +@job(default_channel='root.prestashop') +def import_products( + session, backend_id, since_date=None, **kwargs): + filters = None + if since_date: + filters = {'date': '1', 'filter[date_upd]': '>[%s]' % (since_date)} + now_fmt = fields.Datetime.now() + result = import_batch( + session, + 'prestashop.product.category', + backend_id, + filters, + priority=15, + **kwargs + ) or '' + result += import_batch( + session, + 'prestashop.product.template', + backend_id, + filters, + priority=15, + **kwargs + ) or '' + session.env['prestashop.backend'].browse(backend_id).write({ + 'import_products_since': now_fmt + }) + return result + + +@prestashop +class ProductTemplateBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.product.template' diff --git a/connector_prestashop/models/res_country/__init__.py b/connector_prestashop/models/res_country/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/res_country/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/res_country/common.py b/connector_prestashop/models/res_country/common.py new file mode 100644 index 000000000..a77d5d984 --- /dev/null +++ b/connector_prestashop/models/res_country/common.py @@ -0,0 +1,42 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo import fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class PrestashopResCountry(models.Model): + _name = 'prestashop.res.country' + _inherit = 'prestashop.binding' + _inherits = {'res.country': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='res.country', + required=True, + ondelete='cascade', + string='Country', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + +class ResCountry(models.Model): + _inherit = 'res.country' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.res.country', + inverse_name='openerp_id', + readonly=True, + string='prestashop Bindings', + ) + + +@prestashop +class ResCountryAdapter(GenericAdapter): + _model_name = 'prestashop.res.country' + _prestashop_model = 'countries' diff --git a/connector_prestashop/models/res_country/importer.py b/connector_prestashop/models/res_country/importer.py new file mode 100644 index 000000000..61200ba89 --- /dev/null +++ b/connector_prestashop/models/res_country/importer.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from ...unit.auto_matching_importer import AutoMatchingImporter +from ...backend import prestashop + + +@prestashop +class CountryImporter(AutoMatchingImporter): + _model_name = 'prestashop.res.country' + _erp_field = 'code' + _ps_field = 'iso_code' + + def _compare_function(self, ps_val, erp_val, ps_dict, erp_dict): + if ( + erp_val and + ps_val and + len(erp_val) >= 2 and + len(ps_val) >= 2 and + erp_val[0:2].lower() == ps_val[0:2].lower() + ): + return True + return False diff --git a/connector_prestashop/models/res_currency/__init__.py b/connector_prestashop/models/res_currency/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/res_currency/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/res_currency/common.py b/connector_prestashop/models/res_currency/common.py new file mode 100644 index 000000000..98da1b982 --- /dev/null +++ b/connector_prestashop/models/res_currency/common.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo import fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class PrestashopResCurrency(models.Model): + _name = 'prestashop.res.currency' + _inherit = 'prestashop.binding' + _inherits = {'res.currency': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='res.currency', + string='Currency', + required=True, + ondelete='cascade', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +class ResCurrency(models.Model): + _inherit = 'res.currency' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.res.currency', + inverse_name='openerp_id', + string='prestashop Bindings', + readonly=True + ) + + +@prestashop +class ResCurrencyAdapter(GenericAdapter): + _model_name = 'prestashop.res.currency' + _prestashop_model = 'currencies' diff --git a/connector_prestashop/models/res_currency/importer.py b/connector_prestashop/models/res_currency/importer.py new file mode 100644 index 000000000..7c7e4245c --- /dev/null +++ b/connector_prestashop/models/res_currency/importer.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from ...unit.auto_matching_importer import AutoMatchingImporter +from ...backend import prestashop + + +@prestashop +class ResCurrencyImporter(AutoMatchingImporter): + _model_name = 'prestashop.res.currency' + _erp_field = 'name' + _ps_field = 'iso_code' + + def _compare_function(self, ps_val, erp_val, ps_dict, erp_dict): + if len(erp_val) == 3 and len(ps_val) == 3 and \ + erp_val[0:3].lower() == ps_val[0:3].lower(): + return True + return False diff --git a/connector_prestashop/models/res_lang/__init__.py b/connector_prestashop/models/res_lang/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/res_lang/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/res_lang/common.py b/connector_prestashop/models/res_lang/common.py new file mode 100644 index 000000000..f73e65de7 --- /dev/null +++ b/connector_prestashop/models/res_lang/common.py @@ -0,0 +1,47 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo import models, fields + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class PrestashopResLang(models.Model): + _name = 'prestashop.res.lang' + _inherit = 'prestashop.binding' + _inherits = {'res.lang': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='res.lang', + required=True, + ondelete='cascade', + string='Lang', + ) + active = fields.Boolean( + string='Active in prestashop', + default=False, + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +class ResLang(models.Model): + _inherit = 'res.lang' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.res.lang', + inverse_name='openerp_id', + readonly=True, + string='PrestaShop Bindings', + ) + + +@prestashop +class ResLangAdapter(GenericAdapter): + _model_name = 'prestashop.res.lang' + _prestashop_model = 'languages' diff --git a/connector_prestashop/models/res_lang/importer.py b/connector_prestashop/models/res_lang/importer.py new file mode 100644 index 000000000..4b7e9e77d --- /dev/null +++ b/connector_prestashop/models/res_lang/importer.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from ...unit.auto_matching_importer import AutoMatchingImporter +from ...backend import prestashop + + +@prestashop +class LangImporter(AutoMatchingImporter): + _model_name = 'prestashop.res.lang' + _erp_field = 'code' + _ps_field = 'language_code' + _copy_fields = [ + ('active', 'active'), + ] + + def _compare_function(self, ps_val, erp_val, ps_dict, erp_dict): + if len(erp_val) >= 2 and len(ps_val) >= 2 and \ + erp_val[0:2].lower() == ps_val[0:2].lower(): + return True + return False diff --git a/connector_prestashop/models/res_partner/__init__.py b/connector_prestashop/models/res_partner/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/res_partner/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/res_partner/common.py b/connector_prestashop/models/res_partner/common.py new file mode 100644 index 000000000..4119695c7 --- /dev/null +++ b/connector_prestashop/models/res_partner/common.py @@ -0,0 +1,172 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import models, fields + +from odoo.addons.queue_job.job import job +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop +from ...unit.importer import import_batch + + +class ResPartner(models.Model): + _inherit = 'res.partner' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.res.partner', + inverse_name='odoo_id', + string='PrestaShop Bindings', + ) + prestashop_address_bind_ids = fields.One2many( + comodel_name='prestashop.address', + inverse_name='odoo_id', + string='PrestaShop Address Bindings', + ) + + # TODO: Implemented here or in prestashop.res.partner model? + @job(default_channel='root.prestashop') + def import_customers_since( + self, backend_record=None, since_date=None, **kwargs): + """ Prepare the import of partners modified on PrestaShop """ + filters = None + if since_date: + filters = { + 'date': '1', + 'filter[date_upd]': '>[%s]' % since_date} + now_fmt = fields.Datetime.now() + self.env['prestashop.res.partner.category'].with_delay( + priority=10 + ).import_batch(backend=backend_record, filters=filters, **kwargs) + self.env['prestashop.res.partner'].with_delay( + priority=15 + ).import_batch(backend=backend_record, filters=filters, **kwargs) + backend_record.import_partners_since = now_fmt + return True + + +class PrestashopPartnerMixin(models.AbstractModel): + _name = 'prestashop.partner.mixin' + + group_ids = fields.Many2many( + comodel_name='prestashop.res.partner.category', + relation='prestashop_category_partner', + column1='partner_id', + column2='category_id', + string='PrestaShop Groups', + ) + date_add = fields.Datetime( + string='Created At (on PrestaShop)', + readonly=True, + ) + date_upd = fields.Datetime( + string='Updated At (on PrestaShop)', + readonly=True, + ) + default_category_id = fields.Many2one( + comodel_name='prestashop.res.partner.category', + string='PrestaShop default category', + help="This field is synchronized with the field " + "'Default customer group' in PrestaShop." + ) + company = fields.Char(string='Company') + + +class PrestashopResPartner(models.Model): + _name = 'prestashop.res.partner' + _inherit = [ + 'prestashop.binding.odoo', + 'prestashop.partner.mixin', + ] + _inherits = {'res.partner': 'odoo_id'} + _rec_name = 'shop_group_id' + + odoo_id = fields.Many2one( + comodel_name='res.partner', + string='Partner', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + backend_id = fields.Many2one( + related='shop_group_id.backend_id', + comodel_name='prestashop.backend', + string='PrestaShop Backend', + store=True, + readonly=True, + ) + shop_group_id = fields.Many2one( + comodel_name='prestashop.shop.group', + string='PrestaShop Shop Group', + required=True, + ondelete='restrict', + ) + shop_id = fields.Many2one( + comodel_name='prestashop.shop', + string='PrestaShop Shop', + ) + newsletter = fields.Boolean(string='Newsletter') + birthday = fields.Date(string='Birthday') + + +class PrestashopAddressMixin(models.AbstractModel): + _name = 'prestashop.address.mixin' + + date_add = fields.Datetime( + string='Created At (on PrestaShop)', + readonly=True, + ) + date_upd = fields.Datetime( + string='Updated At (on PrestaShop)', + readonly=True, + ) + + +class PrestashopAddress(models.Model): + _name = 'prestashop.address' + _inherit = [ + 'prestashop.binding.odoo', + 'prestashop.address.mixin', + ] + _inherits = {'res.partner': 'odoo_id'} + _rec_name = 'odoo_id' + + prestashop_partner_id = fields.Many2one( + comodel_name='prestashop.res.partner', + string='PrestaShop Partner', + required=True, + ondelete='cascade', + ) + backend_id = fields.Many2one( + comodel_name='prestashop.backend', + string='PrestaShop Backend', + related='prestashop_partner_id.backend_id', + store=True, + readonly=True, + ) + odoo_id = fields.Many2one( + comodel_name='res.partner', + string='Partner', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + shop_group_id = fields.Many2one( + comodel_name='prestashop.shop.group', + string='PrestaShop Shop Group', + related='prestashop_partner_id.shop_group_id', + store=True, + readonly=True, + ) + vat_number = fields.Char('PrestaShop VAT') + + +@prestashop +class PartnerAdapter(GenericAdapter): + _model_name = 'prestashop.res.partner' + _prestashop_model = 'customers' + + +@prestashop +class PartnerAddressAdapter(GenericAdapter): + _model_name = 'prestashop.address' + _prestashop_model = 'addresses' diff --git a/connector_prestashop/models/res_partner/importer.py b/connector_prestashop/models/res_partner/importer.py new file mode 100644 index 000000000..fd9fea47c --- /dev/null +++ b/connector_prestashop/models/res_partner/importer.py @@ -0,0 +1,241 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import re + +from odoo import fields, _ +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.mapper import ( + ImportMapper, + mapping, + only_create, +) +from ...unit.importer import ( + PrestashopImporter, + import_batch, + DelayedBatchImporter, +) +from ...backend import prestashop +from odoo.addons.connector.unit.mapper import external_to_m2o + + +@prestashop +class PartnerImportMapper(ImportMapper): + _model_name = 'prestashop.res.partner' + + direct = [ + ('date_add', 'date_add'), + ('date_upd', 'date_upd'), + ('email', 'email'), + ('newsletter', 'newsletter'), + ('company', 'company'), + ('active', 'active'), + ('note', 'comment'), + (external_to_m2o('id_shop_group'), 'shop_group_id'), + (external_to_m2o('id_shop'), 'shop_id'), + (external_to_m2o('id_default_group'), 'default_category_id'), + ] + + @mapping + def pricelist(self, record): + binder = self.binder_for('prestashop.groups.pricelist') + pricelist = binder.to_internal(record['id_default_group'], unwrap=True) + if not pricelist: + return {} + return {'property_product_pricelist': pricelist.id} + + @mapping + def birthday(self, record): + if record['birthday'] in ['0000-00-00', '']: + return {} + return {'birthday': record['birthday']} + + @mapping + def name(self, record): + parts = [record['firstname'], record['lastname']] + name = ' '.join(p.strip() for p in parts if p.strip()) + return {'name': name} + + @mapping + def groups(self, record): + groups = record.get( + 'associations', {}).get('groups', {}).get( + self.backend_record.get_version_ps_key('group'), []) + if not isinstance(groups, list): + groups = [groups] + model_name = 'prestashop.res.partner.category' + partner_category_bindings = self.env[model_name].browse() + binder = self.binder_for(model_name) + for group in groups: + partner_category_bindings |= binder.to_internal(group['id']) + + result = {'group_ids': [(6, 0, partner_category_bindings.ids)], + 'category_id': [(4, b.openerp_id.id) + for b in partner_category_bindings]} + return result + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def lang(self, record): + binder = self.binder_for('prestashop.res.lang') + erp_lang = None + if record.get('id_lang'): + erp_lang = binder.to_internal(record['id_lang']) + if not erp_lang: + erp_lang = self.env.ref('base.lang_en') + return {'lang': erp_lang.code} + + @mapping + def customer(self, record): + return {'customer': True} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + +@prestashop +class ResPartnerImporter(PrestashopImporter): + _model_name = 'prestashop.res.partner' + + def _import_dependencies(self): + groups = self.prestashop_record.get('associations', {}) \ + .get('groups', {}).get( + self.backend_record.get_version_ps_key('group'), []) + if not isinstance(groups, list): + groups = [groups] + for group in groups: + self._import_dependency(group['id'], + 'prestashop.res.partner.category') + + def _after_import(self, binding): + super(ResPartnerImporter, self)._after_import(binding) + binder = self.binder_for() + ps_id = binder.to_external(binding) + self.env['prestashop.address'].with_delay(priority=10).import_batch( + backend=self.backend_record, + filters={'filter[id_customer]': '%d' % (ps_id,)}) + + +@prestashop +class PartnerBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.res.partner' + + +@prestashop +class AddressImportMapper(ImportMapper): + _model_name = 'prestashop.address' + + direct = [ + ('address1', 'street'), + ('address2', 'street2'), + ('city', 'city'), + ('other', 'comment'), + ('phone', 'phone'), + ('phone_mobile', 'mobile'), + ('postcode', 'zip'), + ('date_add', 'date_add'), + ('date_upd', 'date_upd'), + (external_to_m2o('id_customer'), 'prestashop_partner_id'), + ] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def parent_id(self, record): + binder = self.binder_for('prestashop.res.partner') + parent = binder.to_internal(record['id_customer'], unwrap=True) + return {'parent_id': parent.id} + + @mapping + def name(self, record): + parts = [record['firstname'], record['lastname']] + if record['alias']: + parts.append('(%s)' % record['alias']) + name = ' '.join(p.strip() for p in parts if p.strip()) + return {'name': name} + + @mapping + def customer(self, record): + return {'customer': True} + + @mapping + def country(self, record): + if record.get('id_country'): + binder = self.binder_for('prestashop.res.country') + country = binder.to_internal(record['id_country'], unwrap=True) + return {'country_id': country.id} + return {} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @only_create + @mapping + def type(self, record): + # do not set 'contact', otherwise the address fields are shared with + # the parent + return {'type': 'other'} + + +@prestashop +class AddressImporter(PrestashopImporter): + _model_name = 'prestashop.address' + + def _check_vat(self, vat): + vat_country, vat_number = vat[:2].lower(), vat[2:] + partner_model = self.env['res.partner'] + return partner_model.simple_vat_check(vat_country, vat_number) + + def _after_import(self, binding): + record = self.prestashop_record + vat_number = None + if record['vat_number']: + vat_number = record['vat_number'].replace('.', '').replace(' ', '') + # TODO move to custom localization module + elif not record['vat_number'] and record.get('dni'): + vat_number = record['dni'].replace('.', '').replace( + ' ', '').replace('-', '') + if vat_number: + # TODO: move to custom module + regexp = re.compile('^[a-zA-Z]{2}') + if not regexp.match(vat_number): + vat_number = 'ES' + vat_number + if self._check_vat(vat_number): + binding.parent_id.write({'vat': vat_number}) + else: + msg = _('Please, check the VAT number: %s') % vat_number + self.backend_record.add_checkpoint( + model=binding.parent_id._name, + record_id=binding.parent_id.id, + message=msg, + ) + + +@prestashop +class AddressBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.address' + + +@job(default_channel='root.prestashop') +def import_customers_since(env, since_date=None, **kwargs): + """ Prepare the import of partners modified on PrestaShop """ + filters = None + if since_date: + filters = { + 'date': '1', + 'filter[date_upd]': '>[%s]' % since_date} + now_fmt = fields.Datetime.now() + result = import_batch(env, filters, **kwargs) or '' + result += import_batch(env, filters, priority=15, **kwargs) or '' + env.backend_record.import_partners_since = now_fmt + # env['prestashop.backend'].browse(backend_id).write({ + # 'import_partners_since': now_fmt, + # }) + return result diff --git a/connector_prestashop/models/res_partner_category/__init__.py b/connector_prestashop/models/res_partner_category/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/res_partner_category/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/res_partner_category/common.py b/connector_prestashop/models/res_partner_category/common.py new file mode 100644 index 000000000..b26753065 --- /dev/null +++ b/connector_prestashop/models/res_partner_category/common.py @@ -0,0 +1,53 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class ResPartnerCategory(models.Model): + _inherit = 'res.partner.category' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.res.partner.category', + inverse_name='openerp_id', + string='PrestaShop Bindings', + readonly=True, + ) + + +class PrestashopResPartnerCategory(models.Model): + _name = 'prestashop.res.partner.category' + _inherit = 'prestashop.binding' + _inherits = {'res.partner.category': 'openerp_id'} + + openerp_id = fields.Many2one( + comodel_name='res.partner.category', + string='Partner Category', + required=True, + ondelete='cascade', + ) + date_add = fields.Datetime( + string='Created At (on PrestaShop)', + readonly=True, + ) + date_upd = fields.Datetime( + string='Updated At (on PrestaShop)', + readonly=True, + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + # TODO add prestashop shop when the field will be available in the api. + # we have reported the bug for it + # see http://forge.prestashop.com/browse/PSCFV-8284 + + +@prestashop +class PartnerCategoryAdapter(GenericAdapter): + _model_name = 'prestashop.res.partner.category' + _prestashop_model = 'groups' diff --git a/connector_prestashop/models/res_partner_category/importer.py b/connector_prestashop/models/res_partner_category/importer.py new file mode 100644 index 000000000..7fcdfc7b3 --- /dev/null +++ b/connector_prestashop/models/res_partner_category/importer.py @@ -0,0 +1,57 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.unit.mapper import ImportMapper, mapping +from ...unit.importer import ( + TranslatableRecordImporter, + import_record, + DelayedBatchImporter, +) +from ...backend import prestashop + + +@prestashop +class PartnerCategoryImportMapper(ImportMapper): + _model_name = 'prestashop.res.partner.category' + + direct = [ + ('name', 'name'), + ('date_add', 'date_add'), + ('date_upd', 'date_upd'), + ] + + @mapping + def prestashop_id(self, record): + return {'prestashop_id': record['id']} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + +@prestashop +class PartnerCategoryImporter(TranslatableRecordImporter): + """ Import one translatable record """ + _model_name = [ + 'prestashop.res.partner.category', + ] + + _translatable_fields = { + 'prestashop.res.partner.category': ['name'], + } + + def _after_import(self, binding): + super(PartnerCategoryImporter, self)._after_import(binding) + record = self.prestashop_record + if float(record['reduction']): + import_record( + self.session, + 'prestashop.groups.pricelist', + self.backend_record.id, + record['id'] + ) + + +@prestashop +class PartnerCategoryBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.res.partner.category' diff --git a/connector_prestashop/models/sale_order/__init__.py b/connector_prestashop/models/sale_order/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/sale_order/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/sale_order/common.py b/connector_prestashop/models/sale_order/common.py new file mode 100644 index 000000000..10b771032 --- /dev/null +++ b/connector_prestashop/models/sale_order/common.py @@ -0,0 +1,169 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import openerp.addons.decimal_precision as dp + +from odoo import models, fields, api + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + +import logging +_logger = logging.getLogger(__name__) + + +class SaleOrder(models.Model): + _inherit = 'sale.order' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.sale.order', + inverse_name='odoo_id', + string='PrestaShop Bindings', + ) + + +class PrestashopSaleOrder(models.Model): + _name = 'prestashop.sale.order' + _inherit = 'prestashop.binding.odoo' + _inherits = {'sale.order': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='sale.order', + string='Sale Order', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + prestashop_order_line_ids = fields.One2many( + comodel_name='prestashop.sale.order.line', + inverse_name='prestashop_order_id', + string='PrestaShop Order Lines', + ) + prestashop_discount_line_ids = fields.One2many( + comodel_name='prestashop.sale.order.line.discount', + inverse_name='prestashop_order_id', + string='PrestaShop Discount Lines', + ) + prestashop_invoice_number = fields.Char('PrestaShop Invoice Number') + prestashop_delivery_number = fields.Char('PrestaShop Delivery Number') + total_amount = fields.Float( + string='Total amount in PrestaShop', + digits=dp.get_precision('Account'), + readonly=True, + ) + total_amount_tax = fields.Float( + string='Total tax in PrestaShop', + digits=dp.get_precision('Account'), + readonly=True, + ) + total_shipping_tax_included = fields.Float( + string='Total shipping in PrestaShop', + digits=dp.get_precision('Account'), + readonly=True, + ) + total_shipping_tax_excluded = fields.Float( + string='Total shipping in PrestaShop', + digits=dp.get_precision('Account'), + readonly=True, + ) + + +class SaleOrderLine(models.Model): + _inherit = 'sale.order.line' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.sale.order.line', + inverse_name='odoo_id', + string='PrestaShop Bindings', + ) + prestashop_discount_bind_ids = fields.One2many( + comodel_name='prestashop.sale.order.line.discount', + inverse_name='odoo_id', + string='PrestaShop Discount Bindings', + ) + + +class PrestashopSaleOrderLine(models.Model): + _name = 'prestashop.sale.order.line' + _inherit = 'prestashop.binding.odoo' + _inherits = {'sale.order.line': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='sale.order.line', + string='Sale Order line', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + prestashop_order_id = fields.Many2one( + comodel_name='prestashop.sale.order', + string='PrestaShop Sale Order', + required=True, + ondelete='cascade', + index=True, + ) + + @api.model + def create(self, vals): + ps_sale_order = self.env['prestashop.sale.order'].search([ + ('id', '=', vals['prestashop_order_id']) + ], limit=1) + vals['order_id'] = ps_sale_order.odoo_id.id + return super(PrestashopSaleOrderLine, self).create(vals) + + +class PrestashopSaleOrderLineDiscount(models.Model): + _name = 'prestashop.sale.order.line.discount' + _inherit = 'prestashop.binding.odoo' + _inherits = {'sale.order.line': 'odoo_id'} + + odoo_id = fields.Many2one( + comodel_name='sale.order.line', + string='Sale Order line', + required=True, + ondelete='cascade', + oldname='openerp_id', + ) + prestashop_order_id = fields.Many2one( + comodel_name='prestashop.sale.order', + string='PrestaShop Sale Order', + required=True, + ondelete='cascade', + index=True, + ) + + @api.model + def create(self, vals): + ps_sale_order = self.env['prestashop.sale.order'].search([ + ('id', '=', vals['prestashop_order_id']) + ], limit=1) + vals['order_id'] = ps_sale_order.odoo_id.id + return super(PrestashopSaleOrderLineDiscount, self).create(vals) + + +@prestashop +class SaleOrderAdapter(GenericAdapter): + _model_name = 'prestashop.sale.order' + _prestashop_model = 'orders' + _export_node_name = 'order' + + def update_sale_state(self, prestashop_id, datas): + return self.client.add('order_histories', datas) + + +@prestashop +class SaleOrderLineAdapter(GenericAdapter): + _model_name = 'prestashop.sale.order.line' + _prestashop_model = 'order_details' + + +@prestashop +class OrderPaymentAdapter(GenericAdapter): + _model_name = '__not_exist_prestashop.payment' + _prestashop_model = 'order_payments' + + +@prestashop +class OrderDiscountAdapter(GenericAdapter): + _model_name = 'prestashop.sale.order.line.discount' + _prestashop_model = 'order_discounts' diff --git a/connector_prestashop/models/sale_order/importer.py b/connector_prestashop/models/sale_order/importer.py new file mode 100644 index 000000000..c4c951065 --- /dev/null +++ b/connector_prestashop/models/sale_order/importer.py @@ -0,0 +1,504 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import _, fields +from odoo.addons.queue_job.job import job +from odoo.addons.connector.connector import ConnectorUnit +from odoo.addons.queue_job.exception import FailedJobError, NothingToDoJob +from odoo.addons.connector.unit.mapper import ImportMapper, mapping +from odoo.addons.connector_ecommerce.unit.sale_order_onchange import ( + SaleOrderOnChange, +) +from ...unit.backend_adapter import GenericAdapter +from ...unit.importer import ( + PrestashopImporter, + import_batch, + DelayedBatchImporter, +) +from ...unit.exception import OrderImportRuleRetry +from ...backend import prestashop + +from datetime import datetime, timedelta +from decimal import Decimal +import logging +_logger = logging.getLogger(__name__) + +try: + from prestapyt import PrestaShopWebServiceError +except: + _logger.debug('Cannot import from `prestapyt`') + + +@prestashop +class PrestaShopSaleOrderOnChange(SaleOrderOnChange): + _model_name = 'prestashop.sale.order' + + +@prestashop +class SaleImportRule(ConnectorUnit): + _model_name = ['prestashop.sale.order'] + + def _rule_always(self, record, mode): + """ Always import the order """ + return True + + def _rule_never(self, record, mode): + """ Never import the order """ + raise NothingToDoJob('Orders with payment modes %s ' + 'are never imported.' % + record['payment']['method']) + + def _rule_paid(self, record, mode): + """ Import the order only if it has received a payment """ + if self._get_paid_amount(record) == 0.0: + raise OrderImportRuleRetry('The order has not been paid.\n' + 'The import will be retried later.') + + def _get_paid_amount(self, record): + payment_adapter = self.unit_for( + GenericAdapter, + '__not_exist_prestashop.payment' + ) + payment_ids = payment_adapter.search({ + 'filter[order_reference]': record['reference'] + }) + paid_amount = 0.0 + for payment_id in payment_ids: + payment = payment_adapter.read(payment_id) + paid_amount += float(payment['amount']) + return paid_amount + + _rules = { + 'always': _rule_always, + 'paid': _rule_paid, + 'authorized': _rule_paid, + 'never': _rule_never, + } + + def check(self, record): + """ Check whether the current sale order should be imported + or not. It will actually use the payment mode configuration + and see if the chosen rule is fullfilled. + + :returns: True if the sale order should be imported + :rtype: boolean + """ + ps_payment_method = record['payment'] + mode_binder = self.binder_for('account.payment.mode') + payment_mode = mode_binder.to_internal(ps_payment_method) + if not payment_mode: + raise FailedJobError(_( + "The configuration is missing for the Payment Mode '%s'.\n\n" + "Resolution:\n" + " - Use the automatic import in 'Connectors > PrestaShop " + "Backends', button 'Import payment modes', or:\n" + "\n" + "- Go to 'Invoicing > Configuration > Management " + "> Payment Modes'\n" + "- Create a new Payment Mode with name '%s'\n" + "-Eventually link the Payment Method to an existing Workflow " + "Process or create a new one.") % (ps_payment_method, + ps_payment_method)) + self._rule_global(record, payment_mode) + self._rules[payment_mode.import_rule](self, record, payment_mode) + + def _rule_global(self, record, mode): + """ Rule always executed, whichever is the selected rule """ + order_id = record['id'] + max_days = mode.days_before_cancel + if not max_days: + return + if self._get_paid_amount(record) != 0.0: + return + fmt = '%Y-%m-%d %H:%M:%S' + order_date = datetime.strptime(record['date_add'], fmt) + if order_date + timedelta(days=max_days) < datetime.now(): + raise NothingToDoJob('Import of the order %s canceled ' + 'because it has not been paid since %d ' + 'days' % (order_id, max_days)) + + +@prestashop +class SaleOrderMapper(ImportMapper): + _model_name = 'prestashop.sale.order' + + direct = [ + ('date_add', 'date_order'), + ('invoice_number', 'prestashop_invoice_number'), + ('delivery_number', 'prestashop_delivery_number'), + ('total_paid', 'total_amount'), + ('total_shipping_tax_incl', 'total_shipping_tax_included'), + ('total_shipping_tax_excl', 'total_shipping_tax_excluded') + ] + + def _get_sale_order_lines(self, record): + orders = record['associations'].get( + 'order_rows', {}).get( + self.backend_record.get_version_ps_key('order_row'), []) + if isinstance(orders, dict): + return [orders] + return orders + + def _get_discounts_lines(self, record): + if record['total_discounts'] == '0.00': + return [] + adapter = self.unit_for( + GenericAdapter, 'prestashop.sale.order.line.discount') + discount_ids = adapter.search({'filter[id_order]': record['id']}) + discount_mappers = [] + for discount_id in discount_ids: + discount_mappers.append({'id': discount_id}) + return discount_mappers + + children = [ + (_get_sale_order_lines, + 'prestashop_order_line_ids', 'prestashop.sale.order.line'), + (_get_discounts_lines, + 'prestashop_discount_line_ids', 'prestashop.sale.order.line.discount') + ] + + def _map_child(self, map_record, from_attr, to_attr, model_name): + source = map_record.source + # TODO patch ImportMapper in connector to support callable + if callable(from_attr): + child_records = from_attr(self, source) + else: + child_records = source[from_attr] + + children = [] + for child_record in child_records: + adapter = self.unit_for(GenericAdapter, model_name) + detail_record = adapter.read(child_record['id']) + + mapper = self._get_map_child_unit(model_name) + items = mapper.get_items( + [detail_record], map_record, to_attr, options=self.options + ) + children.extend(items) + return children + + def _sale_order_exists(self, name): + sale_order = self.env['sale.order'].search([ + ('name', '=', name), + ('company_id', '=', self.backend_record.company_id.id), + ], limit=1) + return len(sale_order) == 1 + + @mapping + def name(self, record): + basename = record['reference'] + if not self._sale_order_exists(basename): + return {"name": basename} + i = 1 + name = basename + '_%d' % (i) + while self._sale_order_exists(name): + i += 1 + name = basename + '_%d' % (i) + return {"name": name} + + @mapping + def partner_id(self, record): + binder = self.binder_for('prestashop.res.partner') + partner = binder.to_internal(record['id_customer'], unwrap=True) + return {'partner_id': partner.id} + + @mapping + def partner_invoice_id(self, record): + binder = self.binder_for('prestashop.address') + address = binder.to_internal(record['id_address_invoice'], unwrap=True) + return {'partner_invoice_id': address.id} + + @mapping + def partner_shipping_id(self, record): + binder = self.binder_for('prestashop.address') + shipping = binder.to_internal(record['id_address_delivery'], unwrap=True) + return {'partner_shipping_id': shipping.id} + + @mapping + def pricelist_id(self, record): + return {'pricelist_id': self.backend_record.pricelist_id.id} + + @mapping + def sale_team(self, record): + if self.backend_record.sale_team_id: + return {'team_id': self.backend_record.sale_team_id.id} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def payment(self, record): + binder = self.binder_for('account.payment.mode') + mode = binder.to_internal(record['payment']) + assert mode, ("import of error fail in SaleImportRule.check " + "when the payment mode is missing") + return {'payment_mode_id': mode.id} + + @mapping + def carrier_id(self, record): + if record['id_carrier'] == '0': + return {} + binder = self.binder_for('prestashop.delivery.carrier') + carrier = binder.to_internal(record['id_carrier'], unwrap=True) + return {'carrier_id': carrier.id} + + @mapping + def total_tax_amount(self, record): + tax = (float(record['total_paid_tax_incl']) - + float(record['total_paid_tax_excl'])) + return {'total_amount_tax': tax} + + def finalize(self, map_record, values): + onchange = self.unit_for(SaleOrderOnChange) + return onchange.play(values, values['prestashop_order_line_ids']) + + +@prestashop +class SaleOrderImporter(PrestashopImporter): + _model_name = ['prestashop.sale.order'] + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(SaleOrderImporter, self).__init__(environment) + self.line_template_errors = [] + + def _import_dependencies(self): + record = self.prestashop_record + self._import_dependency( + record['id_customer'], 'prestashop.res.partner' + ) + self._import_dependency( + record['id_address_invoice'], 'prestashop.address' + ) + self._import_dependency( + record['id_address_delivery'], 'prestashop.address' + ) + + if record['id_carrier'] != '0': + self._import_dependency(record['id_carrier'], + 'prestashop.delivery.carrier') + + rows = record['associations'] \ + .get('order_rows', {}) \ + .get(self.backend_record.get_version_ps_key('order_row'), []) + if isinstance(rows, dict): + rows = [rows] + for row in rows: + try: + self._import_dependency(row['product_id'], + 'prestashop.product.template') + except PrestaShopWebServiceError as err: + # we ignore it, the order line will be imported without product + _logger.error('PrestaShop product %s could not be imported, ' + 'error: %s', row['product_id'], err) + self.line_template_errors.push(row) + + def _add_shipping_line(self, binding): + shipping_total = (binding.total_shipping_tax_included + if self.backend_record.taxes_included + else binding.total_shipping_tax_excluded) + # when we have a carrier_id, even with a 0.0 price, + # Odoo will adda a shipping line in the SO when the picking + # is done, so we better add the line directly even when the + # price is 0.0 + if binding.odoo_id.carrier_id: + binding.odoo_id._create_delivery_line( + binding.odoo_id.carrier_id, + shipping_total + ) + binding.odoo_id.recompute() + + def _after_import(self, binding): + super(SaleOrderImporter, self)._after_import(binding) + self._add_shipping_line(binding) + self.checkpoint_line_without_template(binding) + + def checkpoint_line_without_template(self, binding): + if not self.line_template_errors: + return + msg = _('Product(s) used in the sales order could not be imported.') + self.backend_record.add_checkpoint( + model='sale.order', + record_id=binding.odoo_id.id, + message=msg, + ) + + def _has_to_skip(self): + """ Return True if the import can be skipped """ + if self._get_binding(): + return True + rules = self.unit_for(SaleImportRule) + try: + return rules.check(self.prestashop_record) + except NothingToDoJob as err: + # we don't let the NothingToDoJob exception let go out, because if + # we are in a cascaded import, it would stop the whole + # synchronization and set the whole job to done + return err.message + + +@prestashop +class SaleOrderBatchImporter(DelayedBatchImporter): + _model_name = 'prestashop.sale.order' + + +@prestashop +class SaleOrderLineMapper(ImportMapper): + _model_name = 'prestashop.sale.order.line' + + direct = [ + ('product_name', 'name'), + ('id', 'sequence'), + ('product_quantity', 'product_uom_qty'), + ('reduction_percent', 'discount'), + ] + + @mapping + def prestashop_id(self, record): + return {'prestashop_id': record['id']} + + @mapping + def price_unit(self, record): + if self.backend_record.taxes_included: + key = 'unit_price_tax_incl' + else: + key = 'unit_price_tax_excl' + if record['reduction_percent']: + reduction = Decimal(record['reduction_percent']) + price = Decimal(record[key]) + price_unit = price / ((100 - reduction) / 100) + else: + price_unit = record[key] + return {'price_unit': price_unit} + + @mapping + def product_id(self, record): + if int(record.get('product_attribute_id', 0)): + combination_binder = self.binder_for( + 'prestashop.product.combination' + ) + product = combination_binder.to_internal( + record['product_attribute_id'], + unwrap=True, + ) + else: + binder = self.binder_for('prestashop.product.template') + template = binder.to_internal(record['product_id'], unwrap=True) + product = self.env['product.product'].search([ + ('product_tmpl_id', '=', template.id), + ('company_id', '=', self.backend_record.company_id.id)], + limit=1, + ) + if not product: + return {} + return { + 'product_id': product.id, + 'product_uom': product and product.uom_id.id, + } + + def _find_tax(self, ps_tax_id): + binder = self.binder_for('prestashop.account.tax') + return binder.to_internal(ps_tax_id, unwrap=True) + + @mapping + def tax_id(self, record): + taxes = record.get('associations', {}).get('taxes', {}).get( + self.backend_record.get_version_ps_key('tax'), []) + if not isinstance(taxes, list): + taxes = [taxes] + result = self.env['account.tax'].browse() + for ps_tax in taxes: + result |= self._find_tax(ps_tax['id']) + if result: + return {'tax_id': [(6, 0, result.ids)]} + return {} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + +@prestashop +class SaleOrderLineDiscountImporter(ImportMapper): + _model_name = 'prestashop.sale.order.line.discount' + + direct = [] + + @mapping + def discount(self, record): + return { + 'name': record['name'], + 'product_uom_qty': 1, + } + + @mapping + def price_unit(self, record): + if self.backend_record.taxes_included: + price_unit = record['value'] + else: + price_unit = record['value_tax_excl'] + if price_unit[0] != '-': + price_unit = '-' + price_unit + return {'price_unit': price_unit} + + @mapping + def product_id(self, record): + if self.backend_record.discount_product_id: + return {'product_id': self.backend_record.discount_product_id.id} + product_discount = self.session.env.ref( + 'connector_ecommerce.product_product_discount') + return {'product_id': product_discount.id} + + @mapping + def tax_id(self, record): + return {'tax_id': [ + (6, 0, self.backend_record.discount_product_id.taxes_id.ids) + ]} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def prestashop_id(self, record): + return {'prestashop_id': record['id']} + + +@job(default_channel='root.prestashop') +def import_orders_since(session, backend_id, since_date=None, **kwargs): + """ Prepare the import of orders modified on PrestaShop """ + backend_record = session.env['prestashop.backend'].browse(backend_id) + filters = None + if since_date: + filters = {'date': '1', 'filter[date_upd]': '>[%s]' % (since_date)} + result = import_batch( + session, + 'prestashop.sale.order', + backend_id, + filters, + priority=10, + max_retries=0, + **kwargs + ) + if since_date: + filters = {'date': '1', 'filter[date_add]': '>[%s]' % since_date} + try: + import_batch(session, 'prestashop.mail.message', backend_id, filters) + except Exception as error: + msg = _( + 'Mail messages import failed with filters `%s`. ' + 'Error: `%s`' + ) % (str(filters), str(error)) + backend_record.add_checkpoint( + message=msg + ) + + now_fmt = fields.Datetime.now() + backend_record.write({ + 'import_orders_since': now_fmt + }) + return result diff --git a/connector_prestashop/models/sale_order_state/__init__.py b/connector_prestashop/models/sale_order_state/__init__.py new file mode 100644 index 000000000..05691dc17 --- /dev/null +++ b/connector_prestashop/models/sale_order_state/__init__.py @@ -0,0 +1,5 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import exporter +from . import importer diff --git a/connector_prestashop/models/sale_order_state/common.py b/connector_prestashop/models/sale_order_state/common.py new file mode 100644 index 000000000..5783d9136 --- /dev/null +++ b/connector_prestashop/models/sale_order_state/common.py @@ -0,0 +1,77 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models, fields +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class SaleOrderState(models.Model): + _name = 'sale.order.state' + + name = fields.Char('Name', translate=True) + company_id = fields.Many2one( + comodel_name='res.company', + string='Company', + required=True, + ) + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.sale.order.state', + inverse_name='openerp_id', + string='PrestaShop Bindings', + ) + + +class PrestashopSaleOrderState(models.Model): + _name = 'prestashop.sale.order.state' + _inherit = 'prestashop.binding' + _inherits = {'sale.order.state': 'openerp_id'} + + openerp_state_ids = fields.One2many( + comodel_name='sale.order.state.list', + inverse_name='prestashop_state_id', + string='Odoo States', + ) + openerp_id = fields.Many2one( + comodel_name='sale.order.state', + required=True, + ondelete='cascade', + string='Sale Order State', + ) + + _sql_constraints = [ + ('prestashop_erp_uniq', 'unique(backend_id, openerp_id)', + 'A erp record with same ID on PrestaShop already exists.'), + ] + + +class SaleOrderStateList(models.Model): + _name = 'sale.order.state.list' + + name = fields.Selection( + [ + ('draft', 'Quotation'), + ('sent', 'Quotation Sent'), + ('cancel', 'Cancelled'), + ('sale', 'Sale Order'), + ('done', 'Done') + ], + string='Odoo Sales State', + required=True, + ) + prestashop_state_id = fields.Many2one( + comodel_name='prestashop.sale.order.state', + string='PrestaShop State', + ) + prestashop_id = fields.Integer( + related='prestashop_state_id.prestashop_id', + readonly=True, + store=True, + string='PrestaShop ID', + ) + + +@prestashop +class SaleOrderStateAdapter(GenericAdapter): + _model_name = 'prestashop.sale.order.state' + _prestashop_model = 'order_states' diff --git a/connector_prestashop/models/sale_order_state/exporter.py b/connector_prestashop/models/sale_order_state/exporter.py new file mode 100644 index 000000000..f973f42e9 --- /dev/null +++ b/connector_prestashop/models/sale_order_state/exporter.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.synchronizer import Exporter +from ...backend import prestashop + + +@prestashop +class SaleStateExporter(Exporter): + _model_name = ['prestashop.sale.order'] + + def run(self, prestashop_id, state, **kwargs): + datas = { + 'order_history': { + 'id_order': prestashop_id, + 'id_order_state': state, + } + } + self.backend_adapter.update_sale_state(prestashop_id, datas) + + +def find_prestashop_state(session, sale_state, backend): + state_list_model = session.env['sale.order.state.list'] + state_lists = state_list_model.search( + [('name', '=', sale_state)] + ) + for state_list in state_lists: + if state_list.prestashop_state_id.backend_id == backend: + return state_list.prestashop_state_id.prestashop_id + return None + + +@job +def export_sale_state(session, model_name, record_id): + binding_model = session.env[model_name] + sales = binding_model.search([('openerp_id', '=', record_id)]) + for sale in sales: + backend = sale.backend_id + new_state = find_prestashop_state(session, sale.state, backend) + if not new_state: + continue + env = backend.get_environment(binding_model._name, session=session) + sale_exporter = env.get_connector_unit(SaleStateExporter) + sale_exporter.run(sale.prestashop_id, new_state) diff --git a/connector_prestashop/models/sale_order_state/importer.py b/connector_prestashop/models/sale_order_state/importer.py new file mode 100644 index 000000000..87472f0d5 --- /dev/null +++ b/connector_prestashop/models/sale_order_state/importer.py @@ -0,0 +1,42 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.unit.mapper import ImportMapper, mapping +from ...unit.importer import TranslatableRecordImporter, DirectBatchImporter +from ...backend import prestashop + + +@prestashop +class SaleOrderStateMapper(ImportMapper): + _model_name = 'prestashop.sale.order.state' + + direct = [ + ('name', 'name'), + ] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + +@prestashop +class SaleOrderStateImporter(TranslatableRecordImporter): + """ Import one translatable record """ + _model_name = [ + 'prestashop.sale.order.state', + ] + + _translatable_fields = { + 'prestashop.sale.order.state': [ + 'name', + ], + } + + +@prestashop +class SaleOrderStateBatchImporter(DirectBatchImporter): + _model_name = 'prestashop.sale.order.state' diff --git a/connector_prestashop/models/stock_move/__init__.py b/connector_prestashop/models/stock_move/__init__.py new file mode 100644 index 000000000..aa9c3f5d9 --- /dev/null +++ b/connector_prestashop/models/stock_move/__init__.py @@ -0,0 +1,3 @@ +# -*- coding: utf-8 -*- + +from . import common diff --git a/connector_prestashop/models/stock_move/common.py b/connector_prestashop/models/stock_move/common.py new file mode 100644 index 000000000..5f3f4cc3e --- /dev/null +++ b/connector_prestashop/models/stock_move/common.py @@ -0,0 +1,53 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import api, fields, models + + +class StockLocation(models.Model): + _inherit = 'stock.location' + + prestashop_synchronized = fields.Boolean( + string='Sync with PrestaShop', + help='Check this option to synchronize this location with PrestaShop') + + @api.model + def get_prestashop_stock_locations(self): + prestashop_locations = self.search([ + ('prestashop_synchronized', '=', True), + ('usage', '=', 'internal'), + ]) + return prestashop_locations + + +class StockQuant(models.Model): + _inherit = 'stock.quant' + + @api.model + def create(self, vals): + location_obj = self.env['stock.location'] + ps_locations = location_obj.get_prestashop_stock_locations() + quant = super(StockQuant, self).create(vals) + if quant.location_id in ps_locations: + quant.product_id.update_prestashop_qty() + return quant + + @api.multi + def write(self, vals): + location_obj = self.env['stock.location'] + ps_locations = location_obj.get_prestashop_stock_locations() + for quant in self: + location = quant.location_id + res = super(StockQuant, self).write(vals) + if location in ps_locations: + quant.invalidate_cache() + quant.product_id.update_prestashop_qty() + return res + + @api.multi + def unlink(self): + ps_locations = self.env['stock.location'].\ + get_prestashop_stock_locations() + self.filtered(lambda x: x.location_id in ps_locations).mapped( + 'product_id').update_prestashop_qty() + return super(StockQuant, self).unlink() diff --git a/connector_prestashop/models/stock_tracking/__init__.py b/connector_prestashop/models/stock_tracking/__init__.py new file mode 100644 index 000000000..25fd124e2 --- /dev/null +++ b/connector_prestashop/models/stock_tracking/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import exporter diff --git a/connector_prestashop/models/stock_tracking/common.py b/connector_prestashop/models/stock_tracking/common.py new file mode 100644 index 000000000..77fec3f20 --- /dev/null +++ b/connector_prestashop/models/stock_tracking/common.py @@ -0,0 +1,12 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +@prestashop +class OrderCarriers(GenericAdapter): + _model_name = '__not_exit_prestashop.order_carrier' + _prestashop_model = 'order_carriers' + _export_node_name = 'order_carrier' diff --git a/connector_prestashop/models/stock_tracking/exporter.py b/connector_prestashop/models/stock_tracking/exporter.py new file mode 100644 index 000000000..dc16096ff --- /dev/null +++ b/connector_prestashop/models/stock_tracking/exporter.py @@ -0,0 +1,61 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import logging +from odoo import _ +from odoo.addons.connector.unit.synchronizer import Exporter +from odoo.exceptions import UserError +from odoo.addons.queue_job.job import job +from ...backend import prestashop +from ...unit.backend_adapter import PrestaShopCRUDAdapter + +_logger = logging.getLogger(__name__) + + +@prestashop +class PrestashopTrackingExporter(Exporter): + _model_name = ['prestashop.sale.order'] + + def _get_tracking(self): + trackings = [] + for picking in self.binding.picking_ids: + if picking.carrier_tracking_ref: + trackings.append(picking.carrier_tracking_ref) + return ';'.join(trackings) if trackings else None + + def run(self, binding_id, **kwargs): + """ Export the tracking number of a picking to Magento """ + # verify the picking is done + magento id exists + tracking_adapter = self.unit_for( + PrestaShopCRUDAdapter, '__not_exit_prestashop.order_carrier') + + self.binding = self.model.browse(binding_id) + tracking = self._get_tracking() + if tracking: + prestashop_order_id = self.binder.to_external(self.binding) + filters = { + 'filter[id_order]': prestashop_order_id, + } + order_carrier_id = tracking_adapter.search(filters) + if order_carrier_id: + order_carrier_id = order_carrier_id[0] + vals = tracking_adapter.read(order_carrier_id) + vals['tracking_number'] = tracking + tracking_adapter.write(order_carrier_id, vals) + return "Tracking %s exported" % tracking + else: + raise exceptions.Warning( + _('PrestaShop Error'), + _('No carrier found on sale order')) + else: + return "No tracking to export" + + +@job +def export_tracking_number(session, model_name, record_id): + """ Export the tracking number of a delivery order. """ + order = session.env[model_name].browse(record_id) + backend = order.backend_id + env = backend.get_environment(model_name, session=session) + tracking_exporter = env.get_connector_unit(PrestashopTrackingExporter) + return tracking_exporter.run(record_id) diff --git a/connector_prestashop/models/stock_warehouse/__init__.py b/connector_prestashop/models/stock_warehouse/__init__.py new file mode 100644 index 000000000..5c10a1d51 --- /dev/null +++ b/connector_prestashop/models/stock_warehouse/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- + +from . import common +from . import importer diff --git a/connector_prestashop/models/stock_warehouse/common.py b/connector_prestashop/models/stock_warehouse/common.py new file mode 100644 index 000000000..e219f7344 --- /dev/null +++ b/connector_prestashop/models/stock_warehouse/common.py @@ -0,0 +1,61 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import api, fields, models + +from ...unit.backend_adapter import GenericAdapter +from ...backend import prestashop + + +class StockWarehouse(models.Model): + _inherit = 'stock.warehouse' + + prestashop_bind_ids = fields.One2many( + comodel_name='prestashop.shop', + inverse_name='openerp_id', + readonly=True, + string='PrestaShop Bindings', + ) + + +class PrestashopShop(models.Model): + _name = 'prestashop.shop' + _inherit = 'prestashop.binding' + _description = 'PrestaShop Shop' + + @api.multi + @api.depends('shop_group_id', 'shop_group_id.backend_id') + def _compute_backend_id(self): + self.backend_id = self.shop_group_id.backend_id.id + + name = fields.Char( + string='Name', + help="The name of the method on the backend", + required=True + ) + shop_group_id = fields.Many2one( + comodel_name='prestashop.shop.group', + string='PrestaShop Shop Group', + required=True, + ondelete='cascade', + ) + openerp_id = fields.Many2one( + comodel_name='stock.warehouse', + string='WareHouse', + required=True, + readonly=True, + ondelete='cascade', + ) + backend_id = fields.Many2one( + compute='_compute_backend_id', + comodel_name='prestashop.backend', + string='PrestaShop Backend', + store=True, + ) + default_url = fields.Char('Default url') + + +@prestashop +class ShopAdapter(GenericAdapter): + _model_name = 'prestashop.shop' + _prestashop_model = 'shops' diff --git a/connector_prestashop/models/stock_warehouse/importer.py b/connector_prestashop/models/stock_warehouse/importer.py new file mode 100644 index 000000000..510e42d3b --- /dev/null +++ b/connector_prestashop/models/stock_warehouse/importer.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.unit.mapper import ImportMapper, mapping +from ...unit.importer import PrestashopImporter, DirectBatchImporter +from odoo.addons.connector.unit.mapper import external_to_m2o +from ...backend import prestashop + + +@prestashop +class ShopImportMapper(ImportMapper): + _model_name = 'prestashop.shop' + + direct = [ + ('name', 'name'), + (external_to_m2o('id_shop_group'), 'shop_group_id'), + ] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + def warehouse_id(self, record): + return {'warehouse_id': self.backend_record.warehouse_id.id} + + @mapping + def opener_id(self, record): + return {'openerp_id': self.backend_record.warehouse_id.id} + + +@prestashop +class ShopImporter(PrestashopImporter): + _model_name = 'prestashop.shop' + + +@prestashop +class ShopBatchImporter(DirectBatchImporter): + _model_name = 'prestashop.shop' diff --git a/connector_prestashop/security/ir.model.access.csv b/connector_prestashop/security/ir.model.access.csv new file mode 100644 index 000000000..7303207a1 --- /dev/null +++ b/connector_prestashop/security/ir.model.access.csv @@ -0,0 +1,43 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_prestashop_backend_full,Full access on prestashop.backend,model_prestashop_backend,connector.group_connector_manager,1,1,1,1 +access_prestashop_res_lang_full,Full access on prestashop.res.lang,model_prestashop_res_lang,connector.group_connector_manager,1,1,1,1 +access_prestashop_res_country_full,Full access on prestashop.res.country,model_prestashop_res_country,connector.group_connector_manager,1,1,1,1 +access_prestashop_res_currency_full,Full access on prestashop.res.currency,model_prestashop_res_currency,connector.group_connector_manager,1,1,1,1 +access_prestashop_binding_full,Full access on prestashop.binding,model_prestashop_binding,connector.group_connector_manager,1,1,1,1 +access_prestashop_shop_group_full,Full access on prestashop.shop.group,model_prestashop_shop_group,connector.group_connector_manager,1,1,1,1 +access_prestashop_shop_full,Full access on prestashop.shop,model_prestashop_shop,connector.group_connector_manager,1,1,1,1 +access_prestashop_prestashop_res_partner_user,User access on prestashop.res.partner,model_prestashop_res_partner,base.group_user,1,0,0,0 +access_prestashop_prestashop_res_partner_full,Full access on prestashop.res.partner,model_prestashop_res_partner,connector.group_connector_manager,1,1,1,1 +access_prestashop_prestashop_address_full,Full access on prestashop.address,model_prestashop_address,connector.group_connector_manager,1,1,1,1 +access_prestashop_prestashop_res_partner_category_user,User access on prestashop.res.partner.category,model_prestashop_res_partner_category,base.group_user,1,0,0,0 +access_prestashop_prestashop_res_partner_category_full,Full access on prestashop.res.partner.category,model_prestashop_res_partner_category,connector.group_connector_manager,1,1,1,1 +access_prestashop_account_tax_full,Full access on prestashop.account.tax,model_prestashop_account_tax,connector.group_connector_manager,1,1,1,1 +access_prestashop_account_tax_group_full,Full access on prestashop.account.tax.group,model_prestashop_account_tax_group,connector.group_connector_manager,1,1,1,1 +access_sale_order_state_full,Full access on sale.order.state,model_sale_order_state,connector.group_connector_manager,1,1,1,1 +access_prestashop_sale_order_state_full,Full access on prestashop.sale.order.state,model_prestashop_sale_order_state,connector.group_connector_manager,1,1,1,1 +access_sale_order_state_list_full,Full access on sale.order.state.list,model_sale_order_state_list,connector.group_connector_manager,1,1,1,1 +access_prestashop_sale_order_user,User access on prestashop.sale.order,model_prestashop_sale_order,base.group_user,1,0,0,0 +access_prestashop_sale_order_full,Full access on prestashop.sale.order,model_prestashop_sale_order,connector.group_connector_manager,1,1,1,1 +access_prestashop_sale_order_line_user,User access on prestashop.sale.order.line,model_prestashop_sale_order_line,base.group_user,1,0,0,0 +access_prestashop_sale_order_line_full,Full access on prestashop.sale.order.line,model_prestashop_sale_order_line,connector.group_connector_manager,1,1,1,1 +access_prestashop_sale_order_line_discount_user,User access on prestashop.sale.order.line.discount,model_prestashop_sale_order_line_discount,base.group_user,1,0,0,0 +access_prestashop_sale_order_line_discount_full,Full access on prestashop.sale.order.line.discount,model_prestashop_sale_order_line_discount,connector.group_connector_manager,1,1,1,1 +access_prestashop_delivery_carrier_full,Full access on prestashop.delivery.carrier,model_prestashop_delivery_carrier,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_category_full,Full access on prestashop.product.category,model_prestashop_product_category,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_category_user,User access on prestashop.product.category,model_prestashop_product_category,base.group_user,1,0,0,0 +access_prestashop_product_image_full,Full access on prestashop.product.image,model_prestashop_product_image,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_template_user,User access on prestashop.product.template,model_prestashop_product_template,base.group_user,1,0,0,0 +access_prestashop_product_template,Full access on prestashop.product.template,model_prestashop_product_template,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_combination_user,User access on prestashop.product.combination,model_prestashop_product_combination,base.group_user,1,0,0,0 +access_prestashop_product_combination_full,Full access on prestashop.product.combination,model_prestashop_product_combination,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_combination_option_user,User access on prestashop.product.combination.option,model_prestashop_product_combination_option,base.group_user,1,0,0,0 +access_prestashop_product_combination_option_full,Full access on prestashop.product.combination.option,model_prestashop_product_combination_option,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_combination_option_value_user,User access on prestashop.product.combination.option.value,model_prestashop_product_combination_option_value,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_combination_option_value_full,Full access on prestashop.product.combination.option.value,model_prestashop_product_combination_option_value,base.group_user,1,0,0,0 +access_prestashop_refund,Full access on prestashop.refund,model_prestashop_refund,connector.group_connector_manager,1,1,1,1 +access_prestashop_supplier_user,User access on prestashop.supplier,model_prestashop_supplier,base.group_user,1,0,0,0 +access_prestashop_supplier,Full access on prestashop.supplier,model_prestashop_supplier,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_supplierinfo_user,User access on prestashop.product.supplierinfo,model_prestashop_product_supplierinfo,base.group_user,1,0,0,0 +access_prestashop_product_supplierinfo,Full access on prestashop.product.supplierinfo,model_prestashop_product_supplierinfo,connector.group_connector_manager,1,1,1,1 +access_mail_message,Full access on prestashop.mail.message,model_prestashop_mail_message,connector.group_connector_manager,1,1,1,1 +access_prestashop_groups_pricelist,Full access on prestashop.groups.pricelist,model_prestashop_groups_pricelist,connector.group_connector_manager,1,1,1,1 diff --git a/connector_prestashop/security/prestashop_security.xml b/connector_prestashop/security/prestashop_security.xml new file mode 100644 index 000000000..c111abe80 --- /dev/null +++ b/connector_prestashop/security/prestashop_security.xml @@ -0,0 +1,60 @@ + + + + + PrestaShop backend multi-company + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + PrestaShop shop group multi-company + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + PrestaShop account tax group multi-company + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + Account tax group multi-company + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + Delivery carrier multi-company + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + PrestaShop delivery carrier multi-company + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + Sale order state + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + + Refund + + + ['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)] + + + diff --git a/connector_prestashop/static/description/icon.png b/connector_prestashop/static/description/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..37d9c4834a0f5c68ebc085ac3a12ead2335aee02 GIT binary patch literal 7665 zcmVut2qebu zi;%d0xa2b?MgiF+rW5u7!6h+bq9Pi93B-Jf8?wlZ5cP{nTnH#c9TpjseTHGWr@QN( z-ygFuGYrs6^(f9tAgpSWpfO9_>#otOCLW1Jti=J2!?F>6UwLu*lZxKl*tSHC z%DWLyWcY0>rtOVZq{RX1VQKFC3^0ENhBme>aqyY3WyqKnlRk^);uZ&}!_zs7+IW27 zHH!9WY+DlG3)^G&zv4usQMcu)NN8ME?b}cT1-VuM7HAz!&`MoiF*zqLq7Q;KHuhp&tm`?()FW z5!;yFH?5iadEGA>DVE)Iup_zvw{E_$(x|zA%*v@7;t{`P?f6~5LPZxnH#qOR2)|Ug zzy-@P9LstXj(x?Q(lx-dL+9kEvDT9K@304pyGFk@`7dtRRmHLq%j{rD;m=TJ0vU@Rd0wyZWy)l{@rfaRUb=+%H))l=0@Ne5UuXl{St z()cy#Kb%n64@WK^>9}T86pUUq@kqINuLVhDj$n_p4hKh6eK;i@KyA4t0r3O2$MXZX z=jKJr9V^ElFk-F;qV8VSMUmU8{(s6jz_NY|(?l6@@+<2{VSF@$EXicd$|;)^CdMl- z%78x%TkthF1sx!e=?n#0$0@#k^r}hqM${Ub!pj4X1MkHtZaI<24R8uN0GNSsOQO>S zQ8%rL7r)EfZ8caRxZP%<#i5kQ%G3BHw5h zuK-n*f`Wn*hHay9fFmF7<=~2KF_$l}Zq%yDSH~>aKrGFjyBcIr?2_`^W>EvIU%&nm z+qS<2AQHdNn&R-uFRBMc5)Hv78CeU&;Q)GGqdUM&H{H}~=gys-%FD}J1%ts>s@l#N zV?;z%HEi2<*_JI^ZtUK@dqOuKAXFTPPf*#CP{Bz?(GMiP_WWrL>Hs-8IjQ^h?Hg8J zUVfo5rkCS5=dD|}uBYQTCv4Gg+qRAD?CgZgj|AeY0mOE;C0uwCF_wO8o7f#dA*(?g zpl{#4oems0Fs-n#aAY_f?i{PU&*vi$i1X>?=xf6%kIw;6yCm+y8-R?g@}gjIni69J zR~o_rdiCn{!`-`gFNj1UUE|de4u|7%fV!^?2|009lww(p68Ddmk<0y|rMYttgS3iK zG(D*f(5qLkyNip9A2P-q({HcBuf*WmzSF8e>ucY}=MdByw3G5Qym= zP+xl?RrJ^ZLKJAFElnGV$HqX?9N_%(&mUD>T>P*xrdGJw=ksm#`F#It+xGkI+qeIu zOP4PHTE2Yw35QiXcI-Ge5C}vS_B>HT(JM||4q(uD#||2VW&IYW1qsKKq~dT=9N>Zr zF6gm;|NezFZ@z8Y#jRSknm%I0h{r18*wGUR1Wq~$BAOmTIySyIUILbpvw-}V1sjM^ zMyO|8@hwS`0~|hlc(&s>9jZRtwtcWon>N>N+_-VwrcIk-*0+EE{x#|8=?8#z^?e_0 z_pn@2NRK0%i;77~?jN^MoAcudaEtP#>!X2v`t&(37z}>D=DDn_tO*-8Zd@0y&P9tB z1pHvNF_U*lM=g#x0K6}01eH}Y?e8nyOOO`AN0uNRmadBDhyzM~um<5$P z6n(gP1y+#iMQ8 zj(hP!G7;gK1jI9J>_1lAghoQmZ-MjU7U$^S?{*DPE5xg+O>)|KYF6N7U}pj>=mq}IY6yYo8vf5GP~x;<^B+`AVD?5cBG`e@N|y9!A1(79WrmS zz%LThq6=$g6Lr-AM5I=R%5XTG_%xm*k$TwsJK)Pibck}T?Mr+0sc+Bj=#p9WvTTIk zw=_5JF;$K`D>_Q{hg0P@HBY$h0JYZ1MoXP;|N6QbNLM4Q zS(=;oho^_m>5;fTST<;G>!rE#W{PcpL_$m1t9hsJis0|+o^*9xz-5bu_W_gj1WuW#!^T8Gf$-wb+vznk_% z%hKGrGeD-huUS3;eNB{n$0M84Gka{Sn^fZe4W4(J1Lqs`Diz5U=!@HHHdQB&UOgqR zUJG3<2oAT5~%3aq$!)uiFa8^m(GpYHW~ zSJ(U;4u^jLfFk1y2K^|4@7IcTp&hcWUo>FNz(oUAUB76+>hm3oA&PtptN@no9{0we z$A7x!8rPCHo`{jlM>=AKZ>-pqDXDmYw!oP{N0NN=75;69?9nG0!F0U_7&2r?yUm+7 zf9^O=^+d|-?CkFhT-5O!i1m(9=cPaUYk8!;QSh;fL0iVzJ*P7=}8)!cq3CS8%hdBZ7 z+~Zd5f-W4eYNDv=+_`q*-d)ki z=k)6A|OR=9uks!0ptnXi~s2N;__Xu^hHA2=Z%X35LTw;v% zYupLTx`MzuNAxFSR!)h1warl-?&DuJ!dKF%xD&?AF<9Gz2g2VkFNvIE`NT?V>JL?|sh|xvJxtjy$f8KNY_VIZY7>5^ zNkxjXTVl>mkOUMxy&=k}oKUjV@Ap4<##`yb5WP{9?~$DCWrGMWq55pMaB#(d0{?N_ zO!1Jg1E^AzVCo(h(YTXP#6#sO=a+$(m*w~~1HSa(qM8GG6(Z*o|1(htnlH#&%WGb} z>6NKTi%BHx0G3eHRF=vp(jYZJeT*#dmjZvPJa|55L5Gkp@^!)LDQHhbyMSb%v;lme zVW1e5GO^gJ@Nd*?)kw;g%Dsacgv7fwV(mg>TJE1Tq!AsUE;klT*axhuJen*CH^&_# z$sR$Afre=V{3nsH1B4~mVAWL=bZcw_ni~l_z+(dnN(&JfHt81SDlDRy=q$wWT2#C2r2miupAl2)#P=V@Qut zoZs#e*9>V121SpXvs{Zf!M1Moar4)wa$$B3CKSQy;bBGL5>{`2K4C*tT6zM};#v(L zF$RN9&pMk6vvb(CDTG{|n;$969<9I;GR7`3WPeo#mKv6|*h%OmD61PQKVgb?OVhs@6 z%%FXNip$fwv<0C2t3znSp>xL9+%Tub0iwh;2Z%Kqcp&g4MjcW+S5*1x7=m9NYH@%D z#ytm+P)vwV%%EJ?NHo4&OQRc5=F1Pnsu_G*2d%bRJCaj#pw^ zQFUB8`14P`0JQ}dyMY;Rk{B{s$H7xLk_-?4GZ652?6RTkcFSuZ3fx_#8Dm#)U!VwIht^o$%AUZkik`s!w>}1i@;${Af3%H5 z9~2TUDWh!r9`>yL2oyF>d4><}d4jS}zvB9Hes+xRmS9kHxSJ|gH6{nx8`y!mdBRMc2%pbjv!YmTs$MSU4(NPIz$q zi6K2&eVyyhzKf1&UD+Sl&8vk=s=I=zo!b%kVn3!l%>I9DAzX5Fqv$VJY(Tt6lX#XD ze#M^GKSZnw-!0j^11AvT{Pvf!^Kgw!wJI&apeS(J0d#kL>mj>l_T;V$<`Mk&UiNO- zK&xKexuf?CRunF&=nB^834HqSi?w7!2TN;xF5g!|;qO-+EzvQQe!82kU212f)s|pT zR5VBpa6$G}NI>~y_Hs-p!tR&f;q(z#GW@#RKp?G4V&UK5mj`LxqfSmqp``|h0(ZBJ zIZiOBuy_+zx{ot{Gz75(6uwxtp3feC6%(#q1H?nP_y`@+PTMEKNDI9ZN6%`l;VTkS zdWzs`4d7T(WY;q>X!HJmuw>J(7KIr0)zkB|JLVAH_iT6oBroGJ#Ia^w?g<}Dc;r@*y$gJ^YvEX2tpVm<`O3lZYX{$lut$}hmdIBUV&{S(t155KYHrtG4(c@c!k5CuWvRPf zc#9+3_VCr}_pwvGIA!te?(J)r1@M(?f5<6Bqa=4x)$4#4wmr4l`pSi*Ugu36LF?W< zo)wYNiCcGS(J0%xiO64p$vtizMElFmO;}%A*Y*IPCamZbq|x^E6OjdoJbva+hSRE7 z{Ci8;=_ysOfKOaA?i8Z2H+H9s`!2aoZqLJDoVslh_ui zo!ZdmTW64YZdYiD0mMy{N%9Jys;z+yrT;EEYqS4(Jgw46@795o>^7uiw1Id3HvTWHhdvjr7Cr{Wbkx0qz%E_Iz@Xw#0of3(pXJlmTzUQ8M zY6a{cdE}9l($dmeo%oQ?r~U~OYAqM{FIdpQ7otNbRQkE!?+^L?{&b(umq9)B?Ai0c z$dMIWtor?rv;xQS`^OzR-XAgkjofY;Hr_7|wB5dZ*+fO6jIWm%kmT`JLbIw+;<_yOZNscKbK_7S;C~ zHCL>ypKdGhII;^X@`cBjUN&=1-itG5K3JV{b>{5(uX)1ym7{iHNolZb=Ip$WX3aXf zReH&h;B^Mio|=azWWK2Se)jAIU!OHQ?;TIb>@}E=J-+m!g$oy^d3@>P>&jIfpM3uL zHvm*sJicI|#}__0Yu2nzb&VgFKWNan{K184bO*M4c6!I+^;O@Md*tQvNN9b{>$6JR z=XjjRox`0)V?>o1~mgQ(m91Qgz^`fP$J z+W}_g<()^x4%$H@p1w898@FcAnTY%i*ltvZs>m==^LVU3Kr!CAii}j1J5X{E_NtoY z_vPnwsBu|3$lolLiv{il?Jqd5`tx&|;wDlt;Q>%g(F0Q_ZvZyTnlmp;Rpxp;X%_+S z0ias;z|<+5fK9V!=N&NccVn#o0v@bVWU$`;`SgheHI%Si!x-zbY;MjFT zx?s#*D33ifaMe=)W7iJ;9})g;@Z15+J$kk7esJLG4ZwzR1-a>{E-W#=OM$oIDZ8m~ zOdLQ|{th5wopbEv5DJx5>_IPb#>tec(e3~mHgPrLMD%iy4^`Qy(65$m)$X8yMRDGI z0LwVvLGdYC-GzK;;OaMly}+>J$r+r#S18bWf1~EaF%IAeSpY_~q&|Vv)YNPML{1uf zvCxkIERS9vr+xiIWFsOQ1upjc{nb^jh<*f;b?@3iL*mqps$7I(eBSg8HO~wD6Rfk3 zCnt_w@f&IVzfp6dz8YXS5OHj+ccw;It$ToosMMN&Cuql+Gau|WbLNBHX3w785n$T1 zNd>@KRhczoR^GA8cTRwR!GaDb=NQ!u7WzJr;q|8XuKGSm{Hn=p)AY zFVG)@Jno-7sk$XENT->z^QHq=pj-ud+q7vDYLCAw%di{(44!;opor+4IdiUe)P7Bb zM`p~)yR>yi>K%2vlJy!E(JKIPyz-uNb^awA8#OB0mN4BB3MWYF?xjE%6b+)xhS6O@3WPs@#n+S76K)#xm7U z`_!pZ54Oroy$bY6QEo0i68wEsmKnWVVTXU>#65n$zZ7K)7MIn$ zD$jT<=Yh6u+wQ*e&O5`$UZz{7Pn&$v%$W7un8f&dQ=DA?!E&ly&XcfE-Ga?1MQ zPu2+jl+>ImeqTZEAyZ?Wp{kaE96J-mNETp@bl7+F)gbb`MU!G==-8Pn$Gy`m{+Sv8?+5?69f-1`7u& z{yDMkni%090JddS2bui&IUbbWz`N1vY0kv#0Af5JR!GW4vC7&Z{eDHE`u2&gQ#F?Z z>iDec*F+>(`W_IGihxjkmVF;^BI=3y#-)0^uL4Jm#qCw+4vBXJkSW5lX!SH_Vh&|a zpFV!q%-MN+)kvROU#Pij#+0P766hRqqDvC89r%gvy53oxUaTi9q#@GiWDNSJbsd)p|{!z2EP*P(BAP z6}TH{BdWJNboJ^9HFR!MshuOp!6^kk7CGAWYg2H=EEOI=^%_x~2)q<>obOhRDppbm f+GLVpyUG6t_?I~<)B9BO00000NkvXXu0mjfTJQCk literal 0 HcmV?d00001 diff --git a/connector_prestashop/static/description/icon.svg b/connector_prestashop/static/description/icon.svg new file mode 100644 index 000000000..49e396ddf --- /dev/null +++ b/connector_prestashop/static/description/icon.svg @@ -0,0 +1,230 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/connector_prestashop/tests/.gitignore b/connector_prestashop/tests/.gitignore new file mode 100644 index 000000000..2d9d0f479 --- /dev/null +++ b/connector_prestashop/tests/.gitignore @@ -0,0 +1 @@ +secret.txt diff --git a/connector_prestashop/tests/__init__.py b/connector_prestashop/tests/__init__.py new file mode 100644 index 000000000..99fd87223 --- /dev/null +++ b/connector_prestashop/tests/__init__.py @@ -0,0 +1,12 @@ +# -*- coding: utf-8 -*- + +from . import test_auth +from . import test_export_stock_qty +from . import test_export_stock_qty_job +from . import test_export_tracking +from . import test_import_carrier +from . import test_import_backend_data +from . import test_import_inventory +from . import test_import_partner +from . import test_import_products +from . import test_import_sale diff --git a/connector_prestashop/tests/common.py b/connector_prestashop/tests/common.py new file mode 100644 index 000000000..86e97acf6 --- /dev/null +++ b/connector_prestashop/tests/common.py @@ -0,0 +1,355 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import functools + +import openerp.tests.common as common +from odoo.addons.connector.connector import ConnectorEnvironment + +from contextlib import contextmanager +from os.path import dirname, exists, join +import os + +from vcr import VCR +import logging +import urlparse +_logger = logging.getLogger(__name__) +try: + from prestapyt.xml2dict import xml2dict +except: + _logger.debug('Cannot import from `prestapyt`') + +# secret.txt is a file which can be placed by the developer in the +# 'tests' directory. It contains the Prestashop URL on the first line +# and the API token on the second line. +# The secret.txt file must not be committed. +# The API token will be used to record the requests with vcr, but will not be +# stored in the fixtures files +prestashop_url = 'http://localhost:8080' +token = 'xxx' +filename = join(dirname(__file__), 'secret.txt') +if not exists(filename): + filename = os.environ.get('PS_TEST_WS_CREDENTIALS', '') +if exists(filename): + _logger.debug('Using credentials file %s', filename) + with open(filename, 'r') as fp: + assert len(fp.readlines()) == 2,\ + "secret.txt must have 2 lines: url, token" + fp.seek(0) + prestashop_url = next(fp).strip() + token = next(fp).strip() + + +def get_recorder(**kw): + defaults = dict( + record_mode='once', + cassette_library_dir=join(dirname(__file__), 'fixtures/cassettes'), + path_transformer=VCR.ensure_suffix('.yaml'), + match_on=['method', 'path', 'query'], + filter_headers=['Authorization'], + decode_compressed_response=True, + ) + defaults.update(kw) + return VCR(**defaults) + + +recorder = get_recorder() + + +@contextmanager +def quiet_logger(logger_path): + logger = logging.getLogger(logger_path) + level = logger.level + logger.setLevel(logging.ERROR) + yield + logger.setLevel(level) + + +def assert_no_job_delayed(func): + def _decorated(self, *args, **kwargs): + job_count = self.env['queue.job'].search_count([]) + result = func(self, *args, **kwargs) + self.assertEqual(job_count, self.env['queue.job'].search_count([]), + "New jobs have been delayed during the test, this " + "is unexpected.") + return result + return functools.wraps(func)(_decorated) + + +class PrestashopTransactionCase(common.TransactionCase): + """ Base class for Tests with Prestashop """ + + def setUp(self): + super(PrestashopTransactionCase, self).setUp() + self.backend_record = self.env.ref( + 'connector_prestashop.prestashop_backend_demo' + ) + self.backend_record.write({ + 'location': prestashop_url, + 'webservice_key': token, + }) + self.configure() + + def configure(self): + # Default Prestashop currency is GBP + self.env.ref('base.GBP').active = True + + def base_mapping(self): + self.create_binding_no_export('prestashop.res.lang', 1, 1) + countries = [ + (self.env.ref('base.fr'), 8), + (self.env.ref('base.uk'), 17), + (self.env.ref('base.ch'), 19), + (self.env.ref('base.us'), 21), + ] + for odoo_country, ps_country_id in countries: + self.create_binding_no_export( + 'prestashop.res.country', odoo_country.id, ps_country_id + ) + + def assert_records(self, expected_records, records): + """ Assert that a recordset matches with expected values. + + The expected records are a list of nametuple, the fields of the + namedtuple must have the same name than the recordset's fields. + + The expected values are compared to the recordset and records that + differ from the expected ones are show as ``-`` (missing) or ``+`` + (extra) lines. + + Example:: + + ExpectedShop = namedtuple('ExpectedShop', + 'name company_id') + expected = [ + ExpectedShop( + name='Shop1', + company_id=self.company_ch + ), + ExpectedShop( + name='Shop2', + company_id=self.company_ch + ), + ] + self.assert_records(expected, shops) + + Possible output: + + - prestashop.shop(name: Shop1, company_id: res.company(2,)) + - prestashop.shop(name: Shop2, company_id: res.company(2,)) + + prestashop.shop(name: Shop3, company_id: res.company(1,)) + + The expected fields can follow record relations with the dotted + notation style, but using '__' instead of '.'. Example:: + + ExpectedShop = namedtuple('ExpectedShop', + 'name company_id__name') + expected = [ + ExpectedShop( + name='Shop1', + company__name='Swiss Company', + ), + ] + self.assert_records(expected, shops) + + + :param expected_records: list of namedtuple with matching values + for the records + :param records: the recordset to check + :raises: AssertionError if the values do not match + """ + + def get_record_field(record, field): + attrs = field.split('__') + for attr in attrs: + record = record[attr] + return record + + model_name = records._model._name + records = list(records) + assert len(expected_records) > 0, "must have > 0 expected record" + fields = expected_records[0]._fields + not_found = [] + equals = [] + for expected in expected_records: + for record in records: + for field, expected_value in expected._asdict().iteritems(): + record_value = get_record_field(record, field) + if not record_value == expected_value: + break + else: + records.remove(record) + equals.append(record) + break + else: + not_found.append(expected) + message = [] + for record in equals: + # same records + message.append( + u' ✓ {}({})'.format( + model_name, + u', '.join(u'%s: %s' % ( + field.replace('__', '.'), + get_record_field(record, field)) + for field in fields + ) + ) + ) + for expected in not_found: + # missing records + message.append( + u' - {}({})'.format( + model_name, + u', '.join(u'%s: %s' % (field.replace('__', '.'), v) for + field, v in expected._asdict().iteritems()) + ) + ) + for record in records: + # extra records + message.append( + u' + {}({})'.format( + model_name, + u', '.join(u'%s: %s' % ( + field.replace('__', '.'), + get_record_field(record, field)) + for field in fields) + ) + ) + if not_found or records: + raise AssertionError(u'Records do not match:\n\n{}'.format( + '\n'.join(message) + )) + + def sync_metadata(self): + with recorder.use_cassette('sync_metadata'): + self.backend_record.synchronize_metadata() + + def sync_basedata(self): + with recorder.use_cassette('sync_basedata'): + self.backend_record.synchronize_basedata() + + def create_binding_no_export(self, model_name, openerp_id, + prestashop_id=None, **cols): + values = { + 'backend_id': self.backend_record.id, + 'openerp_id': openerp_id, + 'prestashop_id': prestashop_id, + } + if cols: + values.update(cols) + return self.env[model_name].with_context( + connector_no_export=True + ).create(values) + + @staticmethod + def parse_path(url): + return urlparse.urlparse(url).path + + @staticmethod + def parse_qs(url): + return urlparse.parse_qs(urlparse.urlparse(url).query) + + def configure_taxes(self): + company = self.env.ref('base.main_company') + self.journal = self.env['account.journal'].create({ + 'name': 'Test journal', + 'code': 'TEST', + 'type': 'general'}) + income_type = self.env.ref('account.data_account_type_revenue') + expense_type = self.env.ref('account.data_account_type_expenses') + receivable_type = self.env.ref('account.data_account_type_receivable') + self.debit_account = self.env['account.account'].create({ + 'company_id': company.id, + 'code': 'DB', + 'name': 'Debit Account', + 'user_type_id': income_type.id, + 'reconcile': False, + }) + self.credit_account = self.env['account.account'].create({ + 'company_id': company.id, + 'code': 'CR', + 'name': 'Credit Account', + 'user_type_id': expense_type.id, + 'reconcile': False, + }) + self.receivable_account = self.env['account.account'].create({ + 'company_id': company.id, + 'code': 'RA', + 'name': 'Receivable Account', + 'user_type_id': receivable_type.id, + 'reconcile': True, + }) + self.env['ir.property'].search( + [('name', '=', 'property_account_receivable_id'), + ('res_id', '=', False)] + ).value_reference = "account.account,%s" % self.receivable_account.id + liabilities_account = self.env.ref( + 'account.data_account_type_current_liabilities' + ) + self.tax_account = self.env['account.account'].create({ + 'company_id': company.id, + 'code': 'tax', + 'name': 'Tax Account', + 'user_type_id': liabilities_account.id, + 'reconcile': False, + }) + self.tax_20 = self.env['account.tax'].create({ + 'name': '20.0%', + 'amount_type': 'percent', + 'amount': 20.0, + 'type_tax_use': 'sale', + 'company_id': company.id, + 'tax_group_id': self.env.ref('account.tax_group_taxes').id, + 'account_id': self.tax_account.id, + 'price_include': False, + }) + + def _create_product_binding(self, name=None, + template_ps_id=None, + variant_ps_id=None): + product = self.env['product.product'].create({ + 'name': name + }) + template = product.product_tmpl_id + template_binding = self.create_binding_no_export( + 'prestashop.product.template', + template.id, + prestashop_id=template_ps_id, + default_shop_id=self.shop.id, + ) + return self.create_binding_no_export( + 'prestashop.product.combination', + product.id, + prestashop_id=variant_ps_id, + main_template_id=template_binding.id, + ) + + @staticmethod + def xmltodict(xml): + return xml2dict(xml) + + +class ExportStockQuantityCase(PrestashopTransactionCase): + + def setUp(self): + super(ExportStockQuantityCase, self).setUp() + self.sync_metadata() + self.base_mapping() + self.shop_group = self.env['prestashop.shop.group'].search([]) + self.shop = self.env['prestashop.shop'].search([]) + + def _change_product_qty(self, product, qty): + location = (self.backend_record.stock_location_id or + self.backend_record.warehouse_id.lot_stock_id) + vals = { + 'location_id': location.id, + 'product_id': product.id, + 'new_quantity': qty, + } + qty_change = self.env['stock.change.product.qty'].create(vals) + qty_change.with_context( + active_id=product.id, + connector_no_export=True, + ).change_product_qty() diff --git a/connector_prestashop/tests/fixtures/cassettes/sync_metadata.yaml b/connector_prestashop/tests/fixtures/cassettes/sync_metadata.yaml new file mode 100644 index 000000000..4dd4e120a --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/sync_metadata.yaml @@ -0,0 +1,144 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shop_groups?limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['208'] + content-sha1: [0f090b5d7569487fd9bef70d0b65d1a4abb856ce] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shop_groups/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['392'] + content-sha1: [642ab8bb0e0a7a5e3ab2c97cdfd2f17b6a373774] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shops?limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['184'] + content-sha1: [cfe7ba62d5e3d94c7e193f34b99da1531a46bee8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shops/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['424'] + content-sha1: [ee0abcbb07dbe84a8f2c50e593702622a3ffd57e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_auth_failure.yaml b/connector_prestashop/tests/fixtures/cassettes/test_auth_failure.yaml new file mode 100644 index 000000000..3b7cd78d1 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_auth_failure.yaml @@ -0,0 +1,28 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: HEAD + uri: http://172.24.0.3/api/ + response: + body: {string: !!python/unicode ''} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078; + expires=Mon, 03-Oct-2016 10:46:11 GMT; Max-Age=1728000; path=/; httponly'] + www-authenticate: ['Basic realm="Welcome to PrestaShop Webservice, please enter + the authentication key as the login. No password required."'] + x-powered-by: [PrestaShop Webservice] + status: {code: 401, message: Unauthorized} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_auth_success.yaml b/connector_prestashop/tests/fixtures/cassettes/test_auth_success.yaml new file mode 100644 index 000000000..83e91b0a5 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_auth_success.yaml @@ -0,0 +1,25 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: HEAD + uri: http://172.24.0.3/api/ + response: + body: {string: !!python/unicode ''} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-sha1: [d2357b59b19acaa550f3073323b54743ad80f413] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.001'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_export_stock_quantity.yaml b/connector_prestashop/tests/fixtures/cassettes/test_export_stock_quantity.yaml new file mode 100644 index 000000000..a1cab0660 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_export_stock_quantity.yaml @@ -0,0 +1,109 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/stock_availables?filter%5Bid_product_attribute%5D=0&filter%5Bid_product%5D=1 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1481297840'] + connection: [Keep-Alive] + content-length: ['228'] + content-sha1: [c4eb6e71ad4d4392eadb18b268f8c869c9585e93] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 15:37:20 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TefxaDQeKRvH4iskMptWR8Ao0kKwTQ%2BHn74qCsABs2oIgh1NPrPv59GgeUjPVxKZOHRsmUHT3M%2BW%2FfrbuB4NBJU%3D000078; + expires=Thu, 29-Dec-2016 15:37:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TefxaDQeKRvH4iskMptWR8Ao0kKwTQ%2BHn74qCsABs2oIgh1NPrPv59GgeUjPVxKZOHRsmUHT3M%2BW%2FfrbuB4NBJU%3D000078] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/stock_availables/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481297840'] + connection: [Keep-Alive] + content-length: ['574'] + content-sha1: [f39843fa8f134f222dc8709d64387969b6ed1f47] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 15:37:20 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: !!python/unicode '01210010' + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Content-Length: ['322'] + Content-Type: [text/xml] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TefxaDQeKRvH4iskMptWR8Ao0kKwTQ%2BHn74qCsABs2oIgh1NPrPv59GgeUjPVxKZOHRsmUHT3M%2BW%2FfrbuB4NBJU%3D000078] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: PUT + uri: http://172.22.0.4/api/stock_availables + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481297840'] + connection: [Keep-Alive] + content-length: ['571'] + content-sha1: [7ac7bc79ecf4a5c25ab21bfe67ffe68d72d8e086] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 15:37:20 GMT'] + execution-time: ['0.009'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_export_tracking_number.yaml b/connector_prestashop/tests/fixtures/cassettes/test_export_tracking_number.yaml new file mode 100644 index 000000000..c7b13db94 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_export_tracking_number.yaml @@ -0,0 +1,112 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_carriers?filter%5Bid_order%5D=2 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473775010'] + connection: [Keep-Alive] + content-length: ['220'] + content-sha1: [45a0fe9a60581f394413f9412c495b188b305c7b] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 13:56:50 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkdV3taYp5U8ee8JE2MZ4ahqZurApm1q0zNi86k20DjmlLBZx5FFQ5pElTk%2F2IYMXUF1X5YTLlZ%2FPxVTEBrS2s%2B0%3D000079; + expires=Mon, 03-Oct-2016 13:56:50 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkdV3taYp5U8ee8JE2MZ4ahqZurApm1q0zNi86k20DjmlLBZx5FFQ5pElTk%2F2IYMXUF1X5YTLlZ%2FPxVTEBrS2s%2B0%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_carriers/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\n\n"} + headers: + access-time: ['1473775010'] + connection: [Keep-Alive] + content-length: ['672'] + content-sha1: [58d1914d4b9b27ca2c7dd63a1a26a8004281335f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 13:56:50 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: !!python/unicode '2016-09-02 + 14:37:222.00000020.000000xyz2222.000000' + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Content-Length: ['407'] + Content-Type: [text/xml] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkdV3taYp5U8ee8JE2MZ4ahqZurApm1q0zNi86k20DjmlLBZx5FFQ5pElTk%2F2IYMXUF1X5YTLlZ%2FPxVTEBrS2s%2B0%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: PUT + uri: http://172.24.0.3/api/order_carriers + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\n\n"} + headers: + access-time: ['1473775010'] + connection: [Keep-Alive] + content-length: ['671'] + content-sha1: [ce0bdc6073a4876212c7673d686d5904b667c5b1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 13:56:50 GMT'] + execution-time: ['0.011'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_basedata.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_basedata.yaml new file mode 100644 index 000000000..f6cd223fd --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_basedata.yaml @@ -0,0 +1,10909 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/languages + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['200'] + content-sha1: [f84639e268b14e09245ab3038c41a5e49cb52969] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078; + expires=Mon, 03-Oct-2016 10:46:11 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/languages/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['469'] + content-sha1: [4d78168ff0dc408b2ae4a522f1d900b0441d2b65] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['16754'] + content-sha1: [ac973b2d404b69ecd3e58a42eb87e4cbbc76645f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [03e1b0e369a51eb465a063fd74fd615971b9a076] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078; + expires=Mon, 03-Oct-2016 10:46:11 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [7f6b0e14b0907aac6b1b20376d3fd18352ac3a81] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [7a0cefe0f834d056ac9876413b9c30b3d9e213a9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=97'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/6 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['768'] + content-sha1: [92f465da040c11abe5ec320ac0b1a2529cb53f34] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=96'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/7 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [8f1cd3b34139513b6c66cbed74c62dec012fec14] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=95'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/8 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [5cd1a1b256cd2dff5263a546679694f77b87123c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=94'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/9 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763571'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [e2230c6eae46961a0c9e64fb9e8679a75295aa96] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=93'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/10 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [5c5a1b6950d8a26ee03044d0d7041c695f2db3ae] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:11 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=92'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/12 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [1b070c466b5e407cd1ca7197788008c83729293f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=91'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['777'] + content-sha1: [e73968c65ae8422897428cb1cc257fdbb2950811] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=90'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [9879c4f7a81745c7ee3105c67efb311008b47747] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=89'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/15 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['776'] + content-sha1: [96a388538f831e0367149b9bbaee188daf5c1163] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=88'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/16 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['780'] + content-sha1: [21064399f52edf615c929ebe7015f4789b6c0688] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=87'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/17 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [1375540edbd8aac83aef05e4e78ecf3e985526ed] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=86'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/18 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [9e2b99824b631ef2d5cb615541b2e51fe48b0261] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=85'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/20 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [ef257f1e3f70deba1bc382e649e6074aaa73ec7e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=84'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/26 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [c02664cc410f80d6eb63a2b36e2904631fd61997] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=83'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/36 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [817aaa40928f2a35569e436c406fd34e0112c9d3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=82'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/37 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [2f4d2aabdd85d7d22026738c6f76eb00cf275bcc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=81'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/76 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [5c781b825a9b175bd2f2a3bc42f850a64be9d3fb] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=80'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/86 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [320104fc193282bb8330f94a28df1405cedb84b0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=79'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/125 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [e4da31409db0893c3adedc61b59f839002a59851] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=78'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/130 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['778'] + content-sha1: [6fdd0f54a91fa3a8b97f83f3608537e180ef7c05] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=77'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/131 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [2f248e4b4e78ffd321f96eb9e179b79ba0928157] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=76'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/139 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [d3cce56b83928e22b18396627cc0dccf97aafdb5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=75'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/143 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [beb478356f0c961949ea04a9b6e4dab505c01991] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=74'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/193 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [461b550200920bd0dd957f6f235e0da3e40b19a2] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=73'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/216 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [b4372bb40ae0baece99e938b2e2ec9435efd91bd] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=72'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/233 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [70db1e9fedfaa4a35a99acd2293c03d97d819f89] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=71'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/236 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [bdca3c2b6b07c5237499af0cb69eebad3f8724c8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=70'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [4c8eb7fd917ecae99e72df225357c20ee7aea373] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=69'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/21 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['776'] + content-sha1: [3c6371899c7a8be8ba20485069bcfad2d5f63a79] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=68'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/39 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['760'] + content-sha1: [b5d6185f23a2761c3bad6f244ff3c98cdf51c9a2] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=67'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/43 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['765'] + content-sha1: [a438f032d8d3dfe9e00d18fe293d3b506540e299] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=66'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/48 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [5b164aabec26a9598feadf22e74a95e8b32c265d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=65'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/51 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [bf37860368b23fdf23de008e8b02aa0605aa650f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=64'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/55 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [367056b8f39af55b67bb038f9c39f154c2e3efc9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=63'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/145 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [31dcd59c256c566ed03bd92b4bacdf09623240c5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=62'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/223 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['788'] + content-sha1: [ca3c742003b33a23f8f932b2d8d9bae78ecad5b2] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=61'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/224 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['768'] + content-sha1: [b83b7795826cb9fa34a2d29c1f950d5753205b63] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=60'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [793d783d68aee54fe025c29127172ca19097d21e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=59'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/11 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [f012819413681c4fea60e71683769198e8866d53] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=58'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/22 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [c3dc9c058d23351b1a45f7556b09a4ab43c4f5bf] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=57'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/25 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [2b459db1bac2e19133c334feadfc628ec4bce07c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=56'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/28 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['777'] + content-sha1: [7203b3368b31c4392234d76c8ec78c6527ac1a22] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=55'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/29 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [1f58b353c660eec73db6bca8cb9aed70d6595e9f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=54'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/45 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763572'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [99963ef6ab012b590ee9fe5008f40d82879f3660] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:12 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=53'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/47 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [a74aad53978174617e9ef91b75da663bdd955d32] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=52'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/49 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [fc63437c4cd1068c37756af545554fe3fe9055a3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=51'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/50 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [8f344e49fb7a45691c6d9e780865811085bf1825] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=50'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/56 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [41da9138bf110605cff0882d075c6a94d895da11] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=49'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/59 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [266ab55c169a4a95a7c71092bdce36d22a2d45dd] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=48'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/61 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['762'] + content-sha1: [de55e1f7898306725a48d3c98219c34623d12742] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=47'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/63 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [0bc97be17a72305b99f395a02b395df63707f268] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=46'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/80 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['758'] + content-sha1: [0b726c6b6ada5e7a803b91f18f7a318b20532649] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=45'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/93 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [0cb207f15087f6e7b54f8af6db7e6e108d6188ad] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=44'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/110 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [7d3e5d0d3ac4a8275a01403b299d2c7ea85d8c3f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=43'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/111 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [f6e578dbc6e9d7b57ec8b7ac5c771ced24f2725d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=42'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/112 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [e2a5a49ede6b46b0f16f6cd07f3e976379f4a52f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=41'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/113 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [425ec686ad9faedd4deabc03553956276652b35b] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=40'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/117 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [e10ff4ebeddb8b92868f26012f05c40e5c8b6b4b] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=39'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/118 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [c7d11e84907f2a82c65ace902cce27bebb97adc1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=38'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/121 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [2aa1e6ab8d376da6e141ae9ad26af132aeee39dd] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=37'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/122 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [f688e77e90cf217f010dc53a08415baaf9e1a733] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=36'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/123 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [8e1dd6747cc99fd1f04d54217052a520cc2c9fdc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=35'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/124 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [b3ede33590da4b65452b523de2e4c98e2c18226c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=34'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/126 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [fbf2da658616290b7b0416bdafdbb4b7d6914261] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=33'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/132 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [c0c88f29191247f0700af83b6689b0e428df746d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=32'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/136 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [f3cae4188916eb80baa9abd1f3d5ca820b63ed79] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=31'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/137 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [41ff353a3300b2a194759ca09898968886909d45] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=30'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/149 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [455086ac653417c0a862717946210c836827771d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=29'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/156 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [6bc5a030261209aeb12158d6cd6846585272f69a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=28'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/164 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [4b1184807a80d0b32b62b12c330290aa88432bd1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=27'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/165 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [99c043a43384d5defe02ac8719a0dab9583745a8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=26'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/167 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [c77e9f4174796c63f60eba940e433000f1343223] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=25'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/172 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [93db21c1d12c1bd49a27bf23336db1cfab74277d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=24'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/175 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [1ce44d72464d486bc2861108e8d2c1136434d66e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=23'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/188 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [d32f6bf57258d2b92f4b08aab02c7eafce14db9e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=22'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/197 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [e5667f8054736786b2b5d259239dea384071aeab] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=21'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/202 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [bf9f16f3dda63758cd231d4444c04d84360be9e0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=20'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/203 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [bc019f46739f9c4c82f7e0d0b93059406a282bca] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=19'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/204 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [b9571731471fc335d3cde9419e018aa02962e6d3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=18'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/206 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [5a119d2a5d22be96b30138dd380e002a31b618ea] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=17'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/212 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [b7d87c6d56de997cdffc4757e240822de66f578a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=16'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/217 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [d8348cd2130c7f3322c9b27190e7c0caa36715be] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=15'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/219 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763573'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [d356c4168b9c64d300e8b01046b146c9f744c6a4] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=14'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/222 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [2f2faf15fec90a51d5a98526afdaa721faf7d6e0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=13'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/227 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [1de804019ef77cde5d48950abc690b3bcef3d88e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=12'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/231 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [ac125162958e2a195d524d3e1034d59bf08bd034] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=11'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/238 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['763'] + content-sha1: [3c5f653c11ab9f8a7b8dd1448ad50fc54b03762a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=10'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/239 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['770'] + content-sha1: [8edce613533f65a4a6c34bbbc0cbbbe80a39f9d9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=9'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/30 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [6c48004e8b573923606336dd4ee8ab54a1af3a3e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=8'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/31 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [e8c183019d059ee50cf53019d90b9062be73280f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=7'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/32 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [390f216388841dfc113f4f03db9436dd610e6fcf] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=6'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/33 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['752'] + content-sha1: [b8da064031c8f2f3e4486f18e2a20e064b31a685] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=5'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/35 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [7a9d731d49d5ee5d529d273aaeb032d7e593661f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=4'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/38 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [04b9058e9f54179f74d24acc01f26f91235b2267] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=3'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/41 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [e1e6915cd8aeccfbafb7625eb48a4efd3173e9e4] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=2'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/54 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [5ef18f114f75bb46cd2e0578a179dc6246c3e6d5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=1'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/57 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [close] + content-length: ['756'] + content-sha1: [84d53afdd5fc5482d08d05ee8ded8c6ec7ac801d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/60 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['760'] + content-sha1: [fe31f86b4687197dcf7e8af7f174fa8fe826ce83] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/62 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [c66a0b8017bd256ee80a454dc1620a0b9f69ada7] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/64 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [96c090f949e80d679758313c2d7c5338360db8eb] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/65 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [8e9c2bc8b819d627b479c9c9be9f0e793c41f17d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=97'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/66 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [c9bd9584bfca6cecbbd0042c907619f9ea333b66] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=96'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/67 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['752'] + content-sha1: [02a2e11aad3227831be535b33173505f8ad2c0ec] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=95'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/70 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [0fe6625f9218d89b39c843cfa8a73b4b73da16b1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=94'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/71 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['768'] + content-sha1: [72a2ff60f208024c8ea986a24c204bc78bf4cb55] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=93'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/72 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['763'] + content-sha1: [2605937c68410979ea0154b998d6d74adb13cca0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=92'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/77 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [3e6aba67517d6bdfa651f11df1c3f72344c4d9bc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=91'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/82 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['752'] + content-sha1: [f1943933a13deec1c3ceb74875b191f91a1d5aa4] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=90'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/84 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['765'] + content-sha1: [2a1a9af36651f6bad9e06db8791d2dc4397106bf] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=89'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/85 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [6d1a8f4500b5bca7b8663b00cefdad1dabefc7a3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=88'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/87 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [e558ee441acc62aea19a6903ab38a50b4cb19b98] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=87'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/91 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [36b1c6ba5521f5fb05c70f3527fb449bc0959168] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=86'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/92 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [1b568de26c6b62ceb925f19bad856f5fa6d83a4e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=85'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/94 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [727c873434ac4c46a324376acf4d36c8e48653ad] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=84'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/102 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [7d754c5dda3bcb59c2cd4b29a8f480ade5e7725b] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=83'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/103 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['762'] + content-sha1: [da900d47493dbd0a0c06b6590a2b5100f5cf8ba7] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=82'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/119 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [3b7cfccc7c1e1fb8460170fdc090a9b9cfe90759] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=81'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/127 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [69cbd1e9d709d014a641a224982e5dc144ac4be6] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=80'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/128 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [2013ee39b73333fbe7b06afb131f9a0fec307f6e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.005'] + keep-alive: ['timeout=5, max=79'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/129 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763574'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [a50cea7f9b2ed4291251315928bd73d9609eb2a7] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=78'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/134 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [851384c4e388ac1712238c8b48c6616de365e769] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:14 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=77'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/135 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [101446b8a98d9e7f28daffd2cf1bf0c259233e5a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=76'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/138 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [962ddba56a473c4263e200cc8492a4ee66c51b60] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=75'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/142 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [2dcebd7a22d451f87171b04559b87b2c20e42dcf] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=74'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/144 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [67cad3a95cd881287dd47c7d02b80d4c2e9253a6] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=73'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/152 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [7bc96fec7a192e9c27880715755049c51b5fc810] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=72'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/153 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [0ed88d9c6d3aa30449885ff1d7a9f2228c50e7f6] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=71'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/154 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [5c579bb82f7f9b1ea7b6da954f87d002af1aec90] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=70'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/160 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [4494f17fbfa3ce95aa3659a44da5abc6b607ccac] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=69'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/176 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['763'] + content-sha1: [af7e682856944ace12643bdad3ff54ff6932756c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=68'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/178 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [d4eb153a430fb4a0b13380ae9b044f275c94e249] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=67'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/187 + response: + body: {string: "\n\n\n\t\n\t\ + \n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [6f345bae9d4985f3c7ccb9f1d0717932da817bc6] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=66'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/189 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [484c6874dbed09512d2b64734d670a2ce525a1dd] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=65'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/191 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [ef3b81f085bb66e836b2afeb256d1e3dee5bfa2e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=64'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/192 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [9829583cd7ab5fc4e827271696246320195b8dea] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=63'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/195 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [eea2e91b37a8ce5119714fd2059ba36f1ac0a338] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=62'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/198 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [3930f317a5c7838a0fd2b15e76fbc19697851686] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=61'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/201 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['758'] + content-sha1: [ca622684c81efc69b4cc21fd1cc45d52863578aa] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=60'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/205 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [822109d93ae9e735c0d539e4e6d811ee57c7348f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=59'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/210 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [8c0c6b3aac0f3ea211742a4fec329c5f7f02abc4] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=58'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/215 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [5ea397d8f467f0b5f3cc406912d271c06175e015] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=57'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/226 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [d92a8b9801d79bfe5b600ac2789387bc43fe1725] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=56'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/228 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [080825e0edf67d649e676d08ef7f4032192864eb] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=55'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/229 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [32527eb77d96200c66bd0784e24f07a1fe4ab814] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=54'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/24 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [4306acb0d6eaad7610f8647d2441ee651f88bfa2] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=53'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/27 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [862731a765f054f1286f58b701b9d20b45bf2047] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=52'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/90 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['752'] + content-sha1: [2c2d98d32ff65a8656c21b5a8cd5a1f8a4031765] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=51'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/99 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['750'] + content-sha1: [9e8ae2c091930a86d604e6342b3a3df6fa6f946f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=50'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/106 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['780'] + content-sha1: [55321bd4eee973d74532683892a5cd9a19346909] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=49'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/120 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [869df56046e108bce456fb637262cc2c0684cbd0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=48'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/140 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['765'] + content-sha1: [077971ad0a3cdde1a28af9860f709357403225fb] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=47'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/146 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [1f4486bec89bc3a87893de03a42ac6317a1cd484] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=46'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/155 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [ade45605e37f18ed1fc0a15468eb9c8399d2de1d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=45'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/158 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['762'] + content-sha1: [d275aa82cdaeaaa3ef0b565924246e6369e4a432] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=44'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/161 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [5d417368bfe9748397ad3317d58627521a6ebc80] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=43'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/162 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [be9a89d3582df298fbdea944a7d1a2bd46f0b241] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=42'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/163 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [eb0082c19f15ad4341da36a8eb11493e17373a26] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=41'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/166 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763575'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [f6176bca10998642b7cb50d06a333ff64b91720e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:15 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=40'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/169 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['765'] + content-sha1: [d8f7c8b913737438de7d9da96f90ed159456992d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=39'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/173 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [df201ba70b9eced17edc0a79020f6124b1b4c3d9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=38'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/185 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [1063a16358f8a87bacc7ab37c2a5f77be090b03d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=37'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/194 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['764'] + content-sha1: [c022377bc9ac8245d1edda12baae16dca959740a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=36'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/207 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [c31bfb24b7cdcf01546ac4d30255ce48d14fa842] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=35'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/208 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [4661fdbb3515fc728a3cff6893ae78991a0b62dc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=34'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/214 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [eb1f2cb33fbe29f01b900e3aa2d060bec6d7d3f8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=33'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/220 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [4e49b2c1e63cdbd33276d5685c81ade2761f1e73] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=32'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/225 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['766'] + content-sha1: [8b5bfe59238eedb1989c9c441d23f8a851256eda] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=31'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/232 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [2f2ac93908cd6c96e1e4140f8eb08feed344fbc1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=30'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/234 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['760'] + content-sha1: [903c9e4c9c8ab91df7a54320508f3a0a01aed743] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=29'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/235 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\ + \n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['797'] + content-sha1: [c45d04d867c17ef77abbd88b58b9f15fbc294ab5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=28'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/240 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [9a3c6b96e149c3ad710f432c9caf3761bc232d0a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=27'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/242 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['765'] + content-sha1: [1ee0dbfa8c6c81359be9d1531f2dbd7b7de6f6c1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=26'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/243 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [024a6593d971aab300b665d0ccde819513c7817d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=25'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/34 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [4aeb62cf498c2d7992e3ad88045b0e51a57ce497] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=24'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/44 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [6913a9f01333b18587f66f65a208957016e82e19] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=23'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/58 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [44c41194308a365af44ae4eea9fe117c5943c24a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=22'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/68 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [2f014ccb9b1a7ee76df5c0f593f44a8f7926d5ed] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=21'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/69 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [df293b0d157cbcc63f76ecb1d622fd883da32976] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=20'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/81 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [8e97123257e150626cba4ac92cd02347481e1c24] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=19'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/104 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['755'] + content-sha1: [89a3210ee90c4d0465699726ae1670f5e5530c96] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=18'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/170 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [717c116be13d3b746b67c39a23552f965b13336d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=17'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/171 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['752'] + content-sha1: [6b5fff6e494b495d216dc170ae021b38ac15a321] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=16'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/209 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['766'] + content-sha1: [78e3de068da2510dfbfc3685345aae7cdcd6a114] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=15'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/218 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['756'] + content-sha1: [72a58ec33c4c5954a79ae37af121daa2d63cbbe7] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=14'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/221 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [e2dc623fa4aa520857f21230eab22e99c185f9e5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=13'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/241 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['762'] + content-sha1: [e54beae8bb3b9ae5b05bea4831a3f4ec628d8366] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=12'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/19 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [cf3c1e942379cb207e237d7103c15192190e015c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=11'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/23 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [7a0b84e582abda985c1fe177a0ecbdd07ccd94ed] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=10'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/40 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [b8a416a2b0e8d15f12b99970be748f18971fb994] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=9'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/52 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [a91d210263aaa00dca136b715f446d54f212326a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=8'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/74 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [2c4981fd353ab6cece476e7c904a6ef194018b67] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=7'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/89 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [9d9e50ef478372331cf4fac907db0f23ed3f2af9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=6'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/96 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [7f52bbf14c0c62aa06ca230ce5622c45b2cfa916] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=5'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/97 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763576'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [b5cebdcda9500332ad13278062c6a5f67c24df79] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=4'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/101 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [3b66d444425b04552b6aca7c5d9cc6d26abdbd59] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=3'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/107 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['784'] + content-sha1: [3d835a5d543e53bb0512cbc8ebc3db8be0668af1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=2'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/109 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [27aeb9f0ebae680fade5eadf394b3313135fbaf7] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=1'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/114 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [close] + content-length: ['775'] + content-sha1: [2abf5ce5738c75785fd3542d7d2455754c69cbb0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/116 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [0c75c7e697db6d06a66cc823bcc025c76f08e178] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/133 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['758'] + content-sha1: [17aed1c5f7bc805529dd570d87544498c9f041b6] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/147 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [85dc3b49eb77fc5b84cd77db2be3e41c9265a930] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/148 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [30c3abd71e6376fa963bd2d44659b98f7b0384cb] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=97'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/150 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['776'] + content-sha1: [d9dfb6f5749a1d2657baf415a94c7406860d3e43] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=96'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/177 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['783'] + content-sha1: [3c7e399ff748ac7f062795da49dd36d50e493ff8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=95'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/186 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['776'] + content-sha1: [05fa85d7571c86591ba00bf1f7dd5857d14880de] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=94'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/190 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [677097211b202bf28458e05d3fab4f109f9bbf91] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=93'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/200 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [57baf0b43ce8ca475427a1c74b7372eb70fa9b72] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=92'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/211 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['771'] + content-sha1: [6fcf02d99e0451e61b2b64c404cc3f85774669fc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=91'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/230 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['772'] + content-sha1: [d3b5fdb7566ef37aa7bb9179e07fa839f5793c6e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=90'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/244 + response: + body: {string: "\n\n\n\t\n\t\ + \n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['778'] + content-sha1: [ce2a0aec10ca085442464cd75240aa8e3243c069] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=89'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/42 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [0417947eb610b2047fe2ad2316654e8e52ad69fc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=88'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/46 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [5d5c39e0006e98efb114c3642c5cb738fdf89cc2] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=87'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/53 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [b141b3153a52c4fadb07da21f2f98d2a936c0ecc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=86'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/73 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [d4856d7858a5a6b032da8c14fd95b8c91ba55d40] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=85'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/75 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['751'] + content-sha1: [625ae5afcd24a8d8d86c6eaf517f5457c35c5601] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=84'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/78 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [5bd306298724ccd14657b8595ce104e7dd8e5674] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=83'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/79 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['764'] + content-sha1: [a68b5ee5e55ffbb725ff37a863a22487de865433] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=82'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/83 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [81aa54f22c827873b29f5b99b0f656464a716215] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=81'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/88 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['782'] + content-sha1: [7eec8d41811d523ca689ed84812d78dd09aa325a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=80'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/95 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['753'] + content-sha1: [b05086b9aef643edc33d1bea4041bf74dcd9f856] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=79'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/98 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['758'] + content-sha1: [2691d14b058741bfbda6c17349c62db2ec5d2fe1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=78'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/100 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['758'] + content-sha1: [cca20859c52da4a8e0b3eb482f0c7b02b2a60525] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=77'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/105 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [f311507511a984c35da2dbb1b8f50a80c90da1fe] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=76'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/108 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [f8fb623769eaff495e62dd9de369ac989f6c9ea3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=75'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/115 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['754'] + content-sha1: [65a0c53c1f0da1c07f2cc1833ca0d3275c066fbf] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=74'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/141 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [d9a76ab38e6e92f7d22eb3800f0d9d3e15cb346c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=73'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/151 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [0ebe7ec7169f23aca8444119ba5863594bc6790b] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=72'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/157 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['769'] + content-sha1: [583ffffd43995516f8573732b78a4f0387a06759] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=71'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/159 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['776'] + content-sha1: [a49c50639dd0717475d8ad70469bc9114df71033] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=70'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/168 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763577'] + connection: [Keep-Alive] + content-length: ['773'] + content-sha1: [d02a232979931e9e18ea7c84dbbc7b8be0480ecc] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=69'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/174 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['775'] + content-sha1: [c205fde3e8fda94d488c7333fef675cf3e33f3e5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=68'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/179 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['763'] + content-sha1: [8f423bd77dedb25a8751a0ec07966d050b92a15d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=67'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/180 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['768'] + content-sha1: [a2ee5740544a1e1e74531e224ffa610d2cbdeb9e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=66'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/181 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['758'] + content-sha1: [d0558819280de100b7cc5d97f9ef5027b3f84384] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=65'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/182 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['759'] + content-sha1: [3328a1b746b30c15f88becabd8bf80e0e3fdcae9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=64'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/183 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['774'] + content-sha1: [526b44f4cab25350afdaffa40cbb8495380b2693] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=63'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/184 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['779'] + content-sha1: [bc754229e6bb0e289438e9d675f437e81a6a8d22] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=62'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/196 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['811'] + content-sha1: [8b9eaf139b2e9592c99aeef55cf7765105d17d49] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=61'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/199 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['757'] + content-sha1: [6997550da7c311a08267addedd5ad9d0ebd18af3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=60'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/213 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['791'] + content-sha1: [62728101eea43057ebb3ead913731f9f54b40ed9] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=59'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZcN91QeAaPITR8VwDx9iwuaPleiE5gYiGXgXDEjtwf7IhDj4QPHCM2HJ6HrCDQpz5Z62QwG4krJzkNhLULxyPU%3D000078] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/countries/237 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['761'] + content-sha1: [6add0339ab9c836c54422cba69c2c19e4908c4a3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=58'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/currencies + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['203'] + content-sha1: [01b1ccc9ad3bb3ede4da7bfd06777389fb5681a0] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079; + expires=Mon, 03-Oct-2016 10:46:18 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/currencies/1 + response: + body: {string: "\n\n\n\t\n\t\ + \n\t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['522'] + content-sha1: [db3638fd738c599bb9167029ff50dc9ae89a33e8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['1819'] + content-sha1: [9d79736580aa5b29913460bffdb1aefd0bb8db59] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079; + expires=Mon, 03-Oct-2016 10:46:18 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['357'] + content-sha1: [634c257cf570ebe88fa938bae99e6f486891595e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['355'] + content-sha1: [ef722ff221d330c37236333c70216cf73ef7d00f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [a07a00a2141c00188caf403e79cfd9eb90ff0b99] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=97'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['357'] + content-sha1: [3f09d1859538832b8b4eb12193180715831ca415] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=96'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/5 + response: + body: {string: "\n\n\n\t\n\t\n\ + \t\n\t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['360'] + content-sha1: [8a1662ba82224eaec3fad370c72b4ccc9d1c9e94] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=95'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/6 + response: + body: {string: "\n\n\n\t\n\t\n\ + \t\n\t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['360'] + content-sha1: [9370c5112a3bbbcee0a748a7f4bf10f9bbb292d8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=94'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/7 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['357'] + content-sha1: [e827ba1bd3b4e4f04b2f36ed98f2ac967c4dde2a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=93'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/8 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['359'] + content-sha1: [bbbc3561d3402cf50277c9698b15494d8d85ed85] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=92'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/9 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [0f2ec498a53bca71fb9c055041aa6f5ef8aed484] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=91'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/10 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['357'] + content-sha1: [330050a60c897a6ba2504aee91b7e7822fa694e4] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=90'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/11 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [0712a71a0e0a29d57436ba0301768cfe40877f38] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=89'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/12 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [3172cc4dd7afe0a3d47e0408481b8b2debfbbda4] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=88'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [46240a3844b3c7c4d1634573f49f0a7f0855d8fe] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=87'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/14 + response: + body: {string: "\n\n\n\t\n\t\n\ + \t\n\t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['361'] + content-sha1: [5eede8b4b8287a78fe7a84c2b93458d841b8a910] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=86'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/15 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['363'] + content-sha1: [41b4ead184c310d8511df3f553e7eb78764ad105] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=85'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/16 + response: + body: {string: "\n\n\n\t\n\t\n\ + \t\n\t\n\t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['359'] + content-sha1: [45543599f3954597b4737f52d7f801c9b3eeb247] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=84'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/17 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [e3dea69755014d9b29961cbe74aa155a33af4584] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=83'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/18 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [84fd0fa6463d43c51c6a1f98c88b7f9c2d22ec45] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=82'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/19 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763578'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [2c256ca54ae92d3709d8537f2ec43a2f4eefb986] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=81'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/20 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [7060b6efc6387bb30b98eaf66b817b2615e4293e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=80'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/21 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [c6a0f22551e5082400c942f34c5aea7d9ef92286] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=79'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/22 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [e011bb764cb6d56cc2f10210d3d02c952941218c] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=78'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/23 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [6fc5c0b9d43b5aeddb859e189b2c1d9c5661e66d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=77'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/24 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [5376bda7b8e6bf59796e5d32d6e69f91fe2462fe] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=76'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/25 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [dc85cfb80e0cc89de8e2e302634c1f5ddcd1eeca] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=75'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/26 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [651e126a089e4458d9cc2f04274b6bfb7824fa02] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=74'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/27 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['359'] + content-sha1: [1c7f624d9dbb87d3812e98c3693a9cc4b1570f65] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=73'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/28 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [021b747ac1f11197a3581f36079678a0a4a98ef6] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=72'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQ4zBemTNaQH4TsoClmue6KuzNcbLln0%2BRfnuwd%2FQCExEoW%2F6zp2TN8AZQG3u5jPx%2BgGcTpIXlFCJf%2BDHgn6Das%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/taxes/29 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['358'] + content-sha1: [1e72092395fe00faebd2a19dc2b6fac018c5bac7] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=71'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/tax_rule_groups?limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['380'] + content-sha1: [add855ca786d548611f056f9be9caa29a254a5ec] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/tax_rule_groups/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['391'] + content-sha1: [b2df9a691d6f90fe216343d90aa63db2f8714bba] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/tax_rule_groups/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['389'] + content-sha1: [06b8eba9a027e4c31b814c5c91f29cce9f050c07] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/tax_rule_groups/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['396'] + content-sha1: [78460d02afdaf040bcf2c3343d7b28dcf37fee0a] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states?limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['1158'] + content-sha1: [7fe715d33561e098ffe891980b14960af41986f5] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['862'] + content-sha1: [3039e436df620961ce1896b61175341731f180fb] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['872'] + content-sha1: [56813c10577fdde84aaafceec6e2591c7c48b435] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763579'] + connection: [Keep-Alive] + content-length: ['853'] + content-sha1: [11b3f08004eccf1f9e3b472e819146527db51ec1] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkfds1KuPmE97r4nMt97C%2BZtdfkfxyxpE6rrEt8g0Vy9xs9y6D7KkGOgNekwAi6G4Hz9TdZ5YCFCdsyRn6rAaVAo%3D000079; + expires=Mon, 03-Oct-2016 10:46:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1473763580'] + connection: [Keep-Alive] + content-length: ['848'] + content-sha1: [bcf7ca169848950e9e631eee8224f6440468d888] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQKYsuoUmV4BSAtk6HfbL0yOm%2B87oQGS3oNgaJDUEBSpblYnvY13%2FVBc0HONABA4drJSaibT2HXbIrRg43c9nBA%3D000079; + expires=Mon, 03-Oct-2016 10:46:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/6 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763580'] + connection: [Keep-Alive] + content-length: ['861'] + content-sha1: [05f4091410ca68d9af03dcfb79aa7c5c13bac413] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:20 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkQKYsuoUmV4BSAtk6HfbL0yOm%2B87oQGS3oNgaJDUEBSpblYnvY13%2FVBc0HONABA4drJSaibT2HXbIrRg43c9nBA%3D000079; + expires=Mon, 03-Oct-2016 10:46:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/7 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763581'] + connection: [Keep-Alive] + content-length: ['853'] + content-sha1: [2f7266dca6ccdbf271091a1c3f40300890ca3106] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkdAWPDzvlnGLNpu0pBb0jTZ5RnXDpKReAKBpuH297HZGmrBpv9HAbYhNLlx068qFf7qdOhhOY2CTawFOsfcTom8%3D000079; + expires=Mon, 03-Oct-2016 10:46:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/8 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763581'] + connection: [Keep-Alive] + content-length: ['865'] + content-sha1: [dd7dcb29c53304a2429c15555bcd7874cd278d50] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkdAWPDzvlnGLNpu0pBb0jTZ5RnXDpKReAKBpuH297HZGmrBpv9HAbYhNLlx068qFf7qdOhhOY2CTawFOsfcTom8%3D000079; + expires=Mon, 03-Oct-2016 10:46:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/9 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763581'] + connection: [Keep-Alive] + content-length: ['868'] + content-sha1: [1cb0e6da5385d0e765ce05009f261071c20a39ca] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:21 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkdAWPDzvlnGLNpu0pBb0jTZ5RnXDpKReAKBpuH297HZGmrBpv9HAbYhNLlx068qFf7qdOhhOY2CTawFOsfcTom8%3D000079; + expires=Mon, 03-Oct-2016 10:46:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/11 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763582'] + connection: [Keep-Alive] + content-length: ['863'] + content-sha1: [e60102659f4fbac103a63d96bbf833b48c6acbf2] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkXZFv7ndzI%2B8ErXnRmmEco8AR3GzzqYbPTTjuZyhYNZjbOvH%2FWTYf2zCjD5tkkE9eI%2BuNREs7Em8TGgH0fQDGuE%3D000078; + expires=Mon, 03-Oct-2016 10:46:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/12 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763582'] + connection: [Keep-Alive] + content-length: ['870'] + content-sha1: [98ce2a9fa72496b5ed765ecea25cbf1a1c22df28] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:22 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkXZFv7ndzI%2B8ErXnRmmEco8AR3GzzqYbPTTjuZyhYNZjbOvH%2FWTYf2zCjD5tkkE9eI%2BuNREs7Em8TGgH0fQDGuE%3D000078; + expires=Mon, 03-Oct-2016 10:46:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763582'] + connection: [Keep-Alive] + content-length: ['873'] + content-sha1: [1faa5dcdfd9d0193cdbb366650564eab6627a32e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkXZFv7ndzI%2B8ErXnRmmEco8AR3GzzqYbPTTjuZyhYNZjbOvH%2FWTYf2zCjD5tkkE9eI%2BuNREs7Em8TGgH0fQDGuE%3D000078; + expires=Mon, 03-Oct-2016 10:46:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/10 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763582'] + connection: [Keep-Alive] + content-length: ['894'] + content-sha1: [0303a7fab6bba1ee38c7412d00ef162f4f80823f] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkXZFv7ndzI%2B8ErXnRmmEco8AR3GzzqYbPTTjuZyhYNZjbOvH%2FWTYf2zCjD5tkkE9eI%2BuNREs7Em8TGgH0fQDGuE%3D000078; + expires=Mon, 03-Oct-2016 10:46:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763583'] + connection: [Keep-Alive] + content-length: ['916'] + content-sha1: [61b7e7659e057d179b386a814c51945de191ebe3] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:23 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkTOayhQrVitHJaa3B0JHunNaMDXU47gT5GxsDBOwEwigiMGI3kSRqQkcZOz1URufde2vOjOrORe9lmHkBGEtlZw%3D000078; + expires=Mon, 03-Oct-2016 10:46:23 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/order_states/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763583'] + connection: [Keep-Alive] + content-length: ['885'] + content-sha1: [a110aa067008dded517a517c38050aec60d6581d] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:23 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkTOayhQrVitHJaa3B0JHunNaMDXU47gT5GxsDBOwEwigiMGI3kSRqQkcZOz1URufde2vOjOrORe9lmHkBGEtlZw%3D000078; + expires=Mon, 03-Oct-2016 10:46:23 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_carrier_batch.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_carrier_batch.yaml new file mode 100644 index 000000000..befef9732 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_carrier_batch.yaml @@ -0,0 +1,43 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/carriers?filter%5Bdeleted%5D=0 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + '} + headers: + access-time: ['1481190114'] + connection: [Keep-Alive] + content-length: ['260'] + content-sha1: [6f793d7ddaee6da33e133b445c00ef53c3a0607c] + content-type: [text/xml;charset=utf-8] + date: ['Thu, 08 Dec 2016 09:41:54 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TR%2FOLUU5VRDWtKVoZze2PAI%2FCTcBu%2FZQLB0b4MgNW9lDz6xcXxqLYypnZSfJafIP342RPhIrLhkZsGC7BbfXL%2Fs%3D000078; + expires=Wed, 28-Dec-2016 09:41:54 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_carrier_record_2.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_carrier_record_2.yaml new file mode 100644 index 000000000..1a4004cb6 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_carrier_record_2.yaml @@ -0,0 +1,43 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/carriers/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481190114'] + connection: [Keep-Alive] + content-length: ['1160'] + content-sha1: [3eb63c012374844e65081f0322dcf3881704c4df] + content-type: [text/xml;charset=utf-8] + date: ['Thu, 08 Dec 2016 09:41:54 GMT'] + execution-time: ['0.009'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TR%2FOLUU5VRDWtKVoZze2PAI%2FCTcBu%2FZQLB0b4MgNW9lDz6xcXxqLYypnZSfJafIP342RPhIrLhkZsGC7BbfXL%2Fs%3D000078; + expires=Wed, 28-Dec-2016 09:41:54 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_batch.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_batch.yaml new file mode 100644 index 000000000..800e919a7 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_batch.yaml @@ -0,0 +1,185 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/stock_availables?limit=0%2C1000&display=%5Bid%2Cid_product%2Cid_product_attribute%5D + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \n\t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\ + \t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \t\n\t\n\t\n\n\n\ + \n"} + headers: + access-time: ['1481290492'] + connection: [Keep-Alive] + content-length: ['13277'] + content-sha1: [7e59ece6cb6ac8781aee1e5491bf305858ed8201] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 13:34:52 GMT'] + execution-time: ['0.008'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_template_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_template_1.yaml new file mode 100644 index 000000000..67b5c537e --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_template_1.yaml @@ -0,0 +1,32 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/stock_availables?filter%5Bid_product_attribute%5D=0&filter%5Bid_product%5D=1&display=%5Bquantity%5D + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \n\t\n\n\ + \n\n"} + headers: + access-time: ['1481293390'] + connection: [Keep-Alive] + content-length: ['224'] + content-sha1: [fc056b14c97c4c0e6eec0c3b197cd87c2e40fc65] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 14:23:10 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tc5%2F25YbtlPp6Qp5D8d5rsOdA7SSrCgwsQjUULayWhLEb0NyFh1lymvNC7fb5yrMkZH9wBL6PJNw%2Bf5dIgFRXmE%3D000078; + expires=Thu, 29-Dec-2016 14:23:10 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_variant_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_variant_1.yaml new file mode 100644 index 000000000..199ce3d8f --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_inventory_record_variant_1.yaml @@ -0,0 +1,32 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/stock_availables?filter%5Bid_product_attribute%5D=1&filter%5Bid_product%5D=1&display=%5Bquantity%5D + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \n\t\n\n\ + \n\n"} + headers: + access-time: ['1481293390'] + connection: [Keep-Alive] + content-length: ['223'] + content-sha1: [7c35cfa05f88b825e373e85e8a3d675daeaeb9db] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 14:23:10 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tc5%2F25YbtlPp6Qp5D8d5rsOdA7SSrCgwsQjUULayWhLEb0NyFh1lymvNC7fb5yrMkZH9wBL6PJNw%2Bf5dIgFRXmE%3D000078; + expires=Thu, 29-Dec-2016 14:23:10 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_metadata.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_metadata.yaml new file mode 100644 index 000000000..32e604252 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_metadata.yaml @@ -0,0 +1,144 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shop_groups?limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['208'] + content-sha1: [0f090b5d7569487fd9bef70d0b65d1a4abb856ce] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shop_groups/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['392'] + content-sha1: [642ab8bb0e0a7a5e3ab2c97cdfd2f17b6a373774] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shops?limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + '} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['184'] + content-sha1: [cfe7ba62d5e3d94c7e193f34b99da1531a46bee8] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/shops/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \n\n"} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['424'] + content-sha1: [ee0abcbb07dbe84a8f2c50e593702622a3ffd57e] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_batch.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_batch.yaml new file mode 100644 index 000000000..0fe38cebe --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_batch.yaml @@ -0,0 +1,43 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/addresses?filter%5Bid_customer%5D=1&limit=0%2C1000 + response: + body: {string: !!python/unicode ' + + + + + +
+ +
+ + + + + + '} + headers: + access-time: ['1473765071'] + connection: [Keep-Alive] + content-length: ['264'] + content-sha1: [d3d14485f112356569480861ab6b22114b7ced34] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 11:11:11 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkUpqgXRa7IQkt6J6JkvEiajHzMclkHkt5VyQBsMcl%2BdYxNLlxQ%2FQbqbzsVvSmAdL8vSgcHP2GkeeRfaVlDYtw7c%3D000079; + expires=Mon, 03-Oct-2016 11:11:11 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_record_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_record_1.yaml new file mode 100644 index 000000000..e965d7b48 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_address_record_1.yaml @@ -0,0 +1,42 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/addresses/1 + response: + body: {string: !!python/unicode "\n\ + \n
\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\ + \n\t\n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ +
\n
\n"} + headers: + access-time: ['1473765540'] + connection: [Keep-Alive] + content-length: ['1076'] + content-sha1: [42ea80e7561153f663f05ccb4da183a5c1e6e106] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 11:19:00 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkW96S5y6P1Cj2eE4D0MlyGo0TCCQpU2aaufrN6zBe2bp3C0Cr3Iq5VdUosLnSieB8cSRqNfnkvwkpQy3YlPyLr0%3D000079; + expires=Mon, 03-Oct-2016 11:19:00 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_partner_batch.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_batch.yaml new file mode 100644 index 000000000..850eb790c --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_batch.yaml @@ -0,0 +1,86 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/groups?date=1&limit=0%2C1000&filter%5Bdate_upd%5D=%3E%5B2016-09-01+00%3A00%3A00%5D + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['308'] + content-sha1: [a5545130ec5a47d3433c89f70cbd315176fae3fe] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/customers?date=1&limit=0%2C1000&filter%5Bdate_upd%5D=%3E%5B2016-09-01+00%3A00%3A00%5D + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + '} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['266'] + content-sha1: [88d5a7f196da4d4cb07b3a7724c74664683944bd] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_partner_category_record_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_category_record_1.yaml new file mode 100644 index 000000000..21430cf66 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_category_record_1.yaml @@ -0,0 +1,67 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/groups/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473766107'] + connection: [Keep-Alive] + content-length: ['513'] + content-sha1: [6c3a89b7b622cfa1e433280bb5293ab2870e3c11] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 11:28:27 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZ9f4N2AzajiN9rcmsoHuxuPxyPU7k0iPsxJlxTv%2B%2FLiwVo%2F4yLnJBtDgT6d3gclXyKctDUrTRt4r96Qnfy7jqQ%3D000079; + expires=Mon, 03-Oct-2016 11:28:27 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkZ9f4N2AzajiN9rcmsoHuxuPxyPU7k0iPsxJlxTv%2B%2FLiwVo%2F4yLnJBtDgT6d3gclXyKctDUrTRt4r96Qnfy7jqQ%3D000079] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/groups/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1473766107'] + connection: [Keep-Alive] + content-length: ['513'] + content-sha1: [6c3a89b7b622cfa1e433280bb5293ab2870e3c11] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 11:28:27 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_partner_record_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_record_1.yaml new file mode 100644 index 000000000..bdc23e6b8 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_partner_record_1.yaml @@ -0,0 +1,49 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.4.3 CPython/2.7.9 Linux/4.4.0-36-generic] + method: GET + uri: http://172.24.0.3/api/customers/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\t\n\ + \n\n\t\n\t\n\t\n\ + \n\n\n\n"} + headers: + access-time: ['1473763584'] + connection: [Keep-Alive] + content-length: ['1710'] + content-sha1: [b210b90bbd5da68baab23e4fc642347377dc959b] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 13 Sep 2016 10:46:24 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.6] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-5d8d433970511c3f73f62801a1af4b33=1FIe2YdPik06ZunxEubtkc%2B6NOanWA%2BLNql8jnO6Fa5RirOCE9bVBUKNzl31LGue13WDLnljyDfOp04pU3EFOz2zE66WXzccKAMzLH%2BL25M%3D000079; + expires=Mon, 03-Oct-2016 10:46:24 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_product_batch.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_product_batch.yaml new file mode 100644 index 000000000..fc5912504 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_product_batch.yaml @@ -0,0 +1,112 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.11.1] + method: GET + uri: http://172.20.0.4/api/categories?date=1&limit=0%2C1000&filter%5Bdate_upd%5D=%3E%5B2016-09-01+00%3A00%3A00%5D + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1476774086'] + connection: [Keep-Alive] + content-length: ['877'] + content-sha1: [c4d129c8aae2c59cd4cbfc6769e107f5edf79e32] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 18 Oct 2016 07:01:26 GMT'] + execution-time: ['0.069'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.7] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-bfbe109d475f74a42c8014cc428afcb4=K5cSFnGZ1qrhoBa0L%2F2UqE0IUzQLmgI12bys4v6ciASEImo%2FlQ%2BWt3RpVwk1fnlWGBFBgK99oHtGMqGwEYKZJAH%2BfUwVeE7eIvLioStDrMo%3D000079; + expires=Mon, 07-Nov-2016 07:01:26 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.11.1] + method: GET + uri: http://172.20.0.4/api/products?date=1&limit=0%2C1000&filter%5Bdate_upd%5D=%3E%5B2016-09-01+00%3A00%3A00%5D + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1476774086'] + connection: [Keep-Alive] + content-length: ['580'] + content-sha1: [6134ad7d5e7ecb72a43c9e2580584666957aa118] + content-type: [text/xml;charset=utf-8] + date: ['Tue, 18 Oct 2016 07:01:26 GMT'] + execution-time: ['0.017'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.7] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-bfbe109d475f74a42c8014cc428afcb4=K5cSFnGZ1qrhoBa0L%2F2UqE0IUzQLmgI12bys4v6ciASEImo%2FlQ%2BWt3RpVwk1fnlWGBFBgK99oHtGMqGwEYKZJAH%2BfUwVeE7eIvLioStDrMo%3D000079; + expires=Mon, 07-Nov-2016 07:01:26 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_product_category_record_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_product_category_record_1.yaml new file mode 100644 index 000000000..7e70cd6d2 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_product_category_record_1.yaml @@ -0,0 +1,262 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/categories/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\t\ + \n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \tThe must have of your wardrobe, take a look at our different\ + \ colors,

\r\n

shapes and style of our collection!

]]>
\n\ + \t\n\t\n\ + \t\n\n\n\n\t\n\t\n\ + \t\n\n\n
\n
\n"} + headers: + access-time: ['1481126065'] + connection: [Keep-Alive] + content-length: ['1707'] + content-sha1: [1be41e3521f71a55307ec239da5d7df98b55919e] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:54:25 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVg4WbxGIqX%2B5U3DAgMJ1t0Pr7pBorWw3fnVRmrjAFlmpNKjkKOIx3%2FFRkqOjZ0uEnswvng%2F50iOW1nVRkv0EYA%3D000079; + expires=Tue, 27-Dec-2016 15:54:25 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/categories/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\t\ + \n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \tChoose from t-shirts, tops, blouses, short sleeves, long sleeves,\ + \ tank tops, 3/4 sleeves and more.

\r\n

Find the cut that suits you the\ + \ best!

]]>
\n\t\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\ +
\n
\n"} + headers: + access-time: ['1481126065'] + connection: [Keep-Alive] + content-length: ['2032'] + content-sha1: [072873031c121847fe4aca62bfdcbe1fc47bbb65] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:54:25 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVg4WbxGIqX%2B5U3DAgMJ1t0Pr7pBorWw3fnVRmrjAFlmpNKjkKOIx3%2FFRkqOjZ0uEnswvng%2F50iOW1nVRkv0EYA%3D000079; + expires=Tue, 27-Dec-2016 15:54:25 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/categories/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\t\ + \n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \tYou will find here all woman fashion collections.

\r\ + \n

This category includes all the basics of your wardrobe and much more:

\r\ + \n

shoes, accessories, printed t-shirts, feminine dresses, women's jeans!

]]>
\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\ +
\n
\n"} + headers: + access-time: ['1481126065'] + connection: [Keep-Alive] + content-length: ['2578'] + content-sha1: [a16c00036b738aeae3697d4bc29567451b6f95dc] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:54:25 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVg4WbxGIqX%2B5U3DAgMJ1t0Pr7pBorWw3fnVRmrjAFlmpNKjkKOIx3%2FFRkqOjZ0uEnswvng%2F50iOW1nVRkv0EYA%3D000079; + expires=Tue, 27-Dec-2016 15:54:25 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/categories/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\t\ + \n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\n\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\ + \n\n"} + headers: + access-time: ['1481126065'] + connection: [Keep-Alive] + content-length: ['2249'] + content-sha1: [a89d0c5f48e203024a3a90fbd20bcf2defddf0f2] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:54:25 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVg4WbxGIqX%2B5U3DAgMJ1t0Pr7pBorWw3fnVRmrjAFlmpNKjkKOIx3%2FFRkqOjZ0uEnswvng%2F50iOW1nVRkv0EYA%3D000079; + expires=Tue, 27-Dec-2016 15:54:25 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/categories/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\ + \n\t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\n\n\n\n\n"} + headers: + access-time: ['1481126066'] + connection: [Keep-Alive] + content-length: ['1539'] + content-sha1: [252be92fe7c9855cac04c8393e6f435122ac4d66] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:54:25 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TRgwTXsdGnjewzMN4nzfxZlrCz08rDFP4pzKy9cM9ynZmD2StFv7ZEPrE40HC26xa3q%2B%2FP%2FbKzjWRbS2Dz4T%2Flw%3D000078; + expires=Tue, 27-Dec-2016 15:54:26 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_product_template_record_1.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_product_template_record_1.yaml new file mode 100644 index 000000000..588a43a35 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_product_template_record_1.yaml @@ -0,0 +1,3886 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124135'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:15 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124135'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:15 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124135'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:15 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=98'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['1449'] + content-sha1: [9b47f2be4bfbadeb0a8cd2b0727d58ae7b4a7ed8] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [fb64cb999986c7ba3f51bf301e2d417dc06ce9df] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_options/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['1191'] + content-sha1: [341b60036143ca55a43924a5783c4438b6d7ab53] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [fb64cb999986c7ba3f51bf301e2d417dc06ce9df] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [1fd3af8a89f9801e5af10b533e50795fa9686f6f] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [ad3ccf7a72979f99a423bd834b2a51bf72ec999a] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['452'] + content-sha1: [6540ae9572d545230f26f381349fea18a761dec7] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['470'] + content-sha1: [2f50c03f3f43ac7bd85afbb2ec590425b65ba14c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_options/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['2530'] + content-sha1: [6aa0e4dabe8371387f0249b76f20efbef32c89aa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['467'] + content-sha1: [c4f00103fb0232c6bd64f790aac32ab05fadaf6c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/6 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124136'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [09bfff781ed5c1d60cc759f9eb1fee7b3ec75e05] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:16 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079; + expires=Tue, 27-Dec-2016 15:22:16 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/7 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124137'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [491480187b13b5afe8ddef7b3e888237a7414463] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:17 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZdGRY1kbbNPmOolODWCWPFPLTgXgkrV4r5BCRfJoUvNeC9m6GkDxrTBoCmL8bIKNc6sj5XMW%2Fy9PX16%2F0qG7rE%3D000079; + expires=Tue, 27-Dec-2016 15:22:17 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/8 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124137'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [04366e14c268e90a1ec1bc574d49769a15a16dc3] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:17 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZdGRY1kbbNPmOolODWCWPFPLTgXgkrV4r5BCRfJoUvNeC9m6GkDxrTBoCmL8bIKNc6sj5XMW%2Fy9PX16%2F0qG7rE%3D000079; + expires=Tue, 27-Dec-2016 15:22:17 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/9 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124138'] + connection: [Keep-Alive] + content-length: ['472'] + content-sha1: [31f55e1fdf29f126d64d2435a0bb9ed01b1a65f6] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:18 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TV7HtfyWD6hEGkkbhhMsvT%2FqdUwiMJl4fwuoaFQP0Hp7JmyDdM1bO0Gs0b5oIxEDeRJp%2FPppAcOKtPQkKZAlJ3I%3D000079; + expires=Tue, 27-Dec-2016 15:22:18 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/10 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124138'] + connection: [Keep-Alive] + content-length: ['467'] + content-sha1: [1b99100135728ad983cbe7cab98314dc1b16b9e7] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TV7HtfyWD6hEGkkbhhMsvT%2FqdUwiMJl4fwuoaFQP0Hp7JmyDdM1bO0Gs0b5oIxEDeRJp%2FPppAcOKtPQkKZAlJ3I%3D000079; + expires=Tue, 27-Dec-2016 15:22:18 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/11 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124138'] + connection: [Keep-Alive] + content-length: ['469'] + content-sha1: [cfd2e8afc747e33a3ebd05a9aa034608e1bd59e5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TV7HtfyWD6hEGkkbhhMsvT%2FqdUwiMJl4fwuoaFQP0Hp7JmyDdM1bO0Gs0b5oIxEDeRJp%2FPppAcOKtPQkKZAlJ3I%3D000079; + expires=Tue, 27-Dec-2016 15:22:18 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/12 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124138'] + connection: [Keep-Alive] + content-length: ['469'] + content-sha1: [fc1695db542fbeb3ececdded37676ad38f278726] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:18 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TV7HtfyWD6hEGkkbhhMsvT%2FqdUwiMJl4fwuoaFQP0Hp7JmyDdM1bO0Gs0b5oIxEDeRJp%2FPppAcOKtPQkKZAlJ3I%3D000079; + expires=Tue, 27-Dec-2016 15:22:18 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['470'] + content-sha1: [2f50c03f3f43ac7bd85afbb2ec590425b65ba14c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVbuLHEc0uVTOBEbXID3OZ52VSbw3HLVtB3w382JVbLSpWX0%2FmQHsi75hZzebKhrOyzl2dWivlqYYj3T5WVYYTM%3D000079; + expires=Tue, 27-Dec-2016 15:22:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [c9cab2d96a92b86ecb73c7e46fafabc57e4461f3] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVbuLHEc0uVTOBEbXID3OZ52VSbw3HLVtB3w382JVbLSpWX0%2FmQHsi75hZzebKhrOyzl2dWivlqYYj3T5WVYYTM%3D000079; + expires=Tue, 27-Dec-2016 15:22:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/15 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['470'] + content-sha1: [d8efb2ca49d2c2d31262679a2583ab71e29a092e] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVbuLHEc0uVTOBEbXID3OZ52VSbw3HLVtB3w382JVbLSpWX0%2FmQHsi75hZzebKhrOyzl2dWivlqYYj3T5WVYYTM%3D000079; + expires=Tue, 27-Dec-2016 15:22:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/16 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['471'] + content-sha1: [5b724fc75952035d9e39bf7bc88ba71cdcc6e059] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVbuLHEc0uVTOBEbXID3OZ52VSbw3HLVtB3w382JVbLSpWX0%2FmQHsi75hZzebKhrOyzl2dWivlqYYj3T5WVYYTM%3D000079; + expires=Tue, 27-Dec-2016 15:22:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/17 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['470'] + content-sha1: [662e57fb4774ecb40e4ed8c95d95c4ea2645518a] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVbuLHEc0uVTOBEbXID3OZ52VSbw3HLVtB3w382JVbLSpWX0%2FmQHsi75hZzebKhrOyzl2dWivlqYYj3T5WVYYTM%3D000079; + expires=Tue, 27-Dec-2016 15:22:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/24 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['469'] + content-sha1: [e2e62cec7d535d055b2ecfbf20aaf9f10cfcca01] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TVbuLHEc0uVTOBEbXID3OZ52VSbw3HLVtB3w382JVbLSpWX0%2FmQHsi75hZzebKhrOyzl2dWivlqYYj3T5WVYYTM%3D000079; + expires=Tue, 27-Dec-2016 15:22:19 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.005'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124139'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:19 GMT'] + execution-time: ['0.005'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tf1jdxttAL6plvD1h30vZ1cYEC33Gzf61IOPEmPMhHyZE6xcgof6pk0ECbbmtkZGlZwwdwOOcicn6OLXVAyr9Pk%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['1449'] + content-sha1: [9b47f2be4bfbadeb0a8cd2b0727d58ae7b4a7ed8] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_suppliers?limit=0%2C1000&filter%5Bid_product_attribute%5D=1 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [5268145c9506f6b45ffd7281d32a796dd6156bd5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079; + expires=Tue, 27-Dec-2016 15:22:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [7665fdcbaa6e2da5035fb89303bead3a25262d3d] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079; + expires=Tue, 27-Dec-2016 15:22:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [fb64cb999986c7ba3f51bf301e2d417dc06ce9df] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079; + expires=Tue, 27-Dec-2016 15:22:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [c9cab2d96a92b86ecb73c7e46fafabc57e4461f3] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [7665fdcbaa6e2da5035fb89303bead3a25262d3d] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_suppliers?limit=0%2C1000&filter%5Bid_product_attribute%5D=2 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [5268145c9506f6b45ffd7281d32a796dd6156bd5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079; + expires=Tue, 27-Dec-2016 15:22:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [a3f6f4b33d409db9eb3ac187fa93ce050cc2518e] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079; + expires=Tue, 27-Dec-2016 15:22:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124140'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [1fd3af8a89f9801e5af10b533e50795fa9686f6f] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:20 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079; + expires=Tue, 27-Dec-2016 15:22:20 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['470'] + content-sha1: [2f50c03f3f43ac7bd85afbb2ec590425b65ba14c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TZ%2Bv2tPDUEJlMY9Z5Yfu0PL3tYYP5Qh9ca1vp2iJlBK4A1EvoPWyjZi81TLWoOpB2XuVadOc7c6hRXZxS4c4l0U%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [a3f6f4b33d409db9eb3ac187fa93ce050cc2518e] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_suppliers?limit=0%2C1000&filter%5Bid_product_attribute%5D=3 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [5268145c9506f6b45ffd7281d32a796dd6156bd5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079; + expires=Tue, 27-Dec-2016 15:22:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [e999bc7c78e0e4e03cdaef93f979bfafee2f12de] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079; + expires=Tue, 27-Dec-2016 15:22:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/2 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [1fd3af8a89f9801e5af10b533e50795fa9686f6f] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079; + expires=Tue, 27-Dec-2016 15:22:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [c9cab2d96a92b86ecb73c7e46fafabc57e4461f3] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/4 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [e999bc7c78e0e4e03cdaef93f979bfafee2f12de] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_suppliers?limit=0%2C1000&filter%5Bid_product_attribute%5D=4 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [5268145c9506f6b45ffd7281d32a796dd6156bd5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079; + expires=Tue, 27-Dec-2016 15:22:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [a8f7b1bd3cd851fa1651b6d05d9925279421762c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079; + expires=Tue, 27-Dec-2016 15:22:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [ad3ccf7a72979f99a423bd834b2a51bf72ec999a] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079; + expires=Tue, 27-Dec-2016 15:22:21 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \n\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['470'] + content-sha1: [2f50c03f3f43ac7bd85afbb2ec590425b65ba14c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TYr4m1ALxkhSsm6p5OJyRX0y7Ips3VsF%2Fkv2ZqHUjcZqBdyC8Q036H%2BammS0ndBBUo93uvKMs4t4i6FjkkixECM%3D000079] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124141'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [a8f7b1bd3cd851fa1651b6d05d9925279421762c] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_suppliers?limit=0%2C1000&filter%5Bid_product_attribute%5D=5 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [5268145c9506f6b45ffd7281d32a796dd6156bd5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:21 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TW1ygHw5IizBRt%2BtxZGnq9AwoS425q1qXAB9JNvvavDaeOjHg2Q8DwKe6Vyx1t6EtvQTJZs863l%2B13GVo%2FMgdeQ%3D000078; + expires=Tue, 27-Dec-2016 15:22:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/6 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [45238a946d461c5640ed3e91bef1c761fcf03f47] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TW1ygHw5IizBRt%2BtxZGnq9AwoS425q1qXAB9JNvvavDaeOjHg2Q8DwKe6Vyx1t6EtvQTJZs863l%2B13GVo%2FMgdeQ%3D000078; + expires=Tue, 27-Dec-2016 15:22:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/3 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n"} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['445'] + content-sha1: [ad3ccf7a72979f99a423bd834b2a51bf72ec999a] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TW1ygHw5IizBRt%2BtxZGnq9AwoS425q1qXAB9JNvvavDaeOjHg2Q8DwKe6Vyx1t6EtvQTJZs863l%2B13GVo%2FMgdeQ%3D000078; + expires=Tue, 27-Dec-2016 15:22:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TW1ygHw5IizBRt%2BtxZGnq9AwoS425q1qXAB9JNvvavDaeOjHg2Q8DwKe6Vyx1t6EtvQTJZs863l%2B13GVo%2FMgdeQ%3D000078] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_option_values/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\ + \t\n\t\n\n\ + \n"} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['468'] + content-sha1: [c9cab2d96a92b86ecb73c7e46fafabc57e4461f3] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/products/1 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\tFashion\ + \ has been creating well-designed collections since 2010. The brand offers\ + \ feminine designs delivering stylish separates and statement dresses which\ + \ have since evolved into a full ready-to-wear collection in which every item\ + \ is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks\ + \ with youthful elegance and unmistakable signature style. All the beautiful\ + \ pieces are made in Italy and manufactured with the greatest attention. Now\ + \ Fashion extends to a range of accessories including shoes, hats, belts and\ + \ more!

]]>
\n\tFaded short\ + \ sleeves t-shirt with high neckline. Soft and stretchy material for a comfortable\ + \ fit. Accessorize with a straw hat and you're ready for summer!

]]>
\n\ + \t\n\t\n\ + \n\n\t\ + \n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\n\ + \n\ + \t\n\t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\n\n\n\n
\n
\n"} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['9416'] + content-sha1: [62b83a7adcd684959caba9de33f6a03a951df6fa] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.004'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + Cookie: [PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TW1ygHw5IizBRt%2BtxZGnq9AwoS425q1qXAB9JNvvavDaeOjHg2Q8DwKe6Vyx1t6EtvQTJZs863l%2B13GVo%2FMgdeQ%3D000078] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/combinations/6 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\ + \n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\ + \n\t\n\t\n\t\n\t\n\t\n\ + \t\n\n\n\t\n\t\n\t\n\t\n\t\n\t\n\n\n\n\ + \n"} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['1436'] + content-sha1: [45238a946d461c5640ed3e91bef1c761fcf03f47] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=99'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/product_suppliers?limit=0%2C1000&filter%5Bid_product_attribute%5D=6 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481124142'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [5268145c9506f6b45ffd7281d32a796dd6156bd5] + content-type: [text/xml;charset=utf-8] + date: ['Wed, 07 Dec 2016 15:22:22 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TW1ygHw5IizBRt%2BtxZGnq9AwoS425q1qXAB9JNvvavDaeOjHg2Q8DwKe6Vyx1t6EtvQTJZs863l%2B13GVo%2FMgdeQ%3D000078; + expires=Tue, 27-Dec-2016 15:22:22 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_sale_batch.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_sale_batch.yaml new file mode 100644 index 000000000..ceb27029f --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_sale_batch.yaml @@ -0,0 +1,86 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/orders?date=1&limit=0%2C1000&filter%5Bdate_upd%5D=%3E%5B2016-12-01+00%3A00%3A00%5D + response: + body: {string: !!python/unicode ' + + + + + + + + + + + + + + + + + + + + '} + headers: + access-time: ['1481279649'] + connection: [Keep-Alive] + content-length: ['428'] + content-sha1: [3cdffda12e242f64c9988d1659653b619a5a0fec] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 10:34:09 GMT'] + execution-time: ['0.01'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TUudwQS8kEjsMfUuhE39VPxmVm9HstDaGd1I0cr5wBOpSKwT4%2Buhk3GJTIxujKbBlpvmFJUxyjsWeaNoGE7e6LM%3D000079; + expires=Thu, 29-Dec-2016 10:34:09 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/customer_messages?date=1&limit=0%2C1000&filter%5Bdate_add%5D=%3E%5B2016-12-01+00%3A00%3A00%5D + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481279649'] + connection: [Keep-Alive] + content-length: ['150'] + content-sha1: [f785adb02abb8a8536247bfb654e6e7d2304a891] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 10:34:09 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5TUudwQS8kEjsMfUuhE39VPxmVm9HstDaGd1I0cr5wBOpSKwT4%2Buhk3GJTIxujKbBlpvmFJUxyjsWeaNoGE7e6LM%3D000079; + expires=Thu, 29-Dec-2016 10:34:09 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/fixtures/cassettes/test_import_sale_record_5.yaml b/connector_prestashop/tests/fixtures/cassettes/test_import_sale_record_5.yaml new file mode 100644 index 000000000..59162c298 --- /dev/null +++ b/connector_prestashop/tests/fixtures/cassettes/test_import_sale_record_5.yaml @@ -0,0 +1,320 @@ +interactions: +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/orders/5 + response: + body: {string: !!python/unicode "\n\ + \n\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \n\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\n\n\n\n"} + headers: + access-time: ['1481288293'] + connection: [Keep-Alive] + content-length: ['4766'] + content-sha1: [b0a5f9e0abd4472586374d8ebbb44c3f5fb262f3] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 12:58:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/order_payments?filter%5Border_reference%5D=KHWLILZLL + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481288293'] + connection: [Keep-Alive] + content-length: ['144'] + content-sha1: [1e5e8b6f80106cd18c5dddd6e65ef612feb28673] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 12:58:13 GMT'] + execution-time: ['0.002'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tb45G5tfuoewgFOGXCa0zqjmkA9hhHGyvwxvbnN6cWseoA1XiyfSBRNxfbcRDI13Wayf7uzmWqLeeredNQhXw5U%3D000078; + expires=Thu, 29-Dec-2016 12:58:13 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/order_details/13 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\ + \n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \n\n\n\ + \n\n"} + headers: + access-time: ['1481288293'] + connection: [Keep-Alive] + content-length: ['2844'] + content-sha1: [9868fe35e73e166c81546b44825f8af2f6598ddb] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 12:58:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tb45G5tfuoewgFOGXCa0zqjmkA9hhHGyvwxvbnN6cWseoA1XiyfSBRNxfbcRDI13Wayf7uzmWqLeeredNQhXw5U%3D000078; + expires=Thu, 29-Dec-2016 12:58:13 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/order_details/14 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \n\n\n\ + \n\n"} + headers: + access-time: ['1481288293'] + connection: [Keep-Alive] + content-length: ['2822'] + content-sha1: [7ef075c1027edc3db00d770095791ca896794057] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 12:58:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tb45G5tfuoewgFOGXCa0zqjmkA9hhHGyvwxvbnN6cWseoA1XiyfSBRNxfbcRDI13Wayf7uzmWqLeeredNQhXw5U%3D000078; + expires=Thu, 29-Dec-2016 12:58:13 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/order_details/15 + response: + body: {string: !!python/unicode "\n\ + \n\n\ + \t\n\t\n\t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\t\n\ + \t\n\ + \t\n\ + \t\n\ + \t\n\ + \n\n\n\ + \n\n"} + headers: + access-time: ['1481288293'] + connection: [Keep-Alive] + content-length: ['2832'] + content-sha1: [3319a1c2d924abff869980befca3fd405d00ca50] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 12:58:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tb45G5tfuoewgFOGXCa0zqjmkA9hhHGyvwxvbnN6cWseoA1XiyfSBRNxfbcRDI13Wayf7uzmWqLeeredNQhXw5U%3D000078; + expires=Thu, 29-Dec-2016 12:58:13 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python-requests/2.6.0 CPython/2.7.9 Linux/4.4.0-51-generic] + method: GET + uri: http://172.22.0.4/api/order_discounts?filter%5Bid_order%5D=5 + response: + body: {string: !!python/unicode ' + + + + + + + + + + '} + headers: + access-time: ['1481288293'] + connection: [Keep-Alive] + content-length: ['148'] + content-sha1: [ede4524a81f46f4c60454b06a47e324a43fc7c35] + content-type: [text/xml;charset=utf-8] + date: ['Fri, 09 Dec 2016 12:58:13 GMT'] + execution-time: ['0.003'] + keep-alive: ['timeout=5, max=100'] + psws-version: [1.6.1.9] + server: [Apache/2.4.10 (Debian)] + set-cookie: ['PrestaShop-095ca4fa56f569ddf56f692e2249251a=DYHr6QQHnOuI4%2BKs9hL5Tb45G5tfuoewgFOGXCa0zqjmkA9hhHGyvwxvbnN6cWseoA1XiyfSBRNxfbcRDI13Wayf7uzmWqLeeredNQhXw5U%3D000078; + expires=Thu, 29-Dec-2016 12:58:13 GMT; Max-Age=1728000; path=/; httponly'] + vary: [Accept-Encoding] + x-powered-by: [PrestaShop Webservice] + status: {code: 200, message: OK} +version: 1 diff --git a/connector_prestashop/tests/test_auth.py b/connector_prestashop/tests/test_auth.py new file mode 100644 index 000000000..5b6d7aa19 --- /dev/null +++ b/connector_prestashop/tests/test_auth.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + + +from odoo import exceptions + +from .common import recorder, PrestashopTransactionCase + + +class TestAuth(PrestashopTransactionCase): + + @recorder.use_cassette + def test_auth_success(self): + with self.assertRaisesRegexp(exceptions.UserError, + u'Connection successful'): + self.backend_record.button_check_connection() + + @recorder.use_cassette + def test_auth_failure(self): + self.backend_record.webservice_key = 'xyz' + with self.assertRaisesRegexp(exceptions.UserError, + u'Connection failed'): + self.backend_record.button_check_connection() diff --git a/connector_prestashop/tests/test_export_stock_qty.py b/connector_prestashop/tests/test_export_stock_qty.py new file mode 100644 index 000000000..a57ae8cb1 --- /dev/null +++ b/connector_prestashop/tests/test_export_stock_qty.py @@ -0,0 +1,61 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import mock + +from ..models.product_template.exporter import export_product_quantities +from .common import ( + ExportStockQuantityCase, + assert_no_job_delayed +) + + +class TestExportStockQuantity(ExportStockQuantityCase): + + @assert_no_job_delayed + def test_export_stock_qty_delay(self): + """ Backend button delay a job to delay stock quantities export """ + export_job = ('openerp.addons.connector_prestashop.models' + '.prestashop_backend.common' + '.export_product_quantities') + with mock.patch(export_job) as export_mock: + self.backend_record.update_product_stock_qty() + export_mock.delay.assert_called_with( + mock.ANY, self.backend_record.id, + ) + + @assert_no_job_delayed + def test_job_recompute_prestashop_qty(self): + export_job_path = ('openerp.addons.connector_prestashop.consumer' + '.export_inventory') + + variant_binding = self._create_product_binding( + name='Faded Short Sleeves T-shirt', + template_ps_id=1, + variant_ps_id=1, + ) + base_qty = variant_binding.qty_available + base_prestashop_qty = variant_binding.quantity + self.assertEqual(0, base_qty) + self.assertEqual(0, base_prestashop_qty) + + with mock.patch(export_job_path) as export_record_mock: + export_product_quantities(self.conn_session, + self.backend_record.ids) + # no job delayed because no quantity has been changed + self.assertEqual(0, export_record_mock.delay.call_count) + + self._change_product_qty(variant_binding.odoo_id, 42) + + with mock.patch(export_job_path) as export_record_mock: + export_product_quantities(self.conn_session, + self.backend_record.ids) + self.assertEqual(1, export_record_mock.delay.call_count) + export_record_mock.delay.assert_called_with( + mock.ANY, + 'prestashop.product.template', + variant_binding.main_template_id.id, + fields=['quantity'], + priority=20, + ) diff --git a/connector_prestashop/tests/test_export_stock_qty_job.py b/connector_prestashop/tests/test_export_stock_qty_job.py new file mode 100644 index 000000000..5456baddd --- /dev/null +++ b/connector_prestashop/tests/test_export_stock_qty_job.py @@ -0,0 +1,74 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import mock + +from ..models.product_template.exporter import export_inventory +from .common import ( + ExportStockQuantityCase, + assert_no_job_delayed, + recorder +) + + +class TestExportStockQuantity(ExportStockQuantityCase): + + @assert_no_job_delayed + def test_job_export_qty(self): + """ Export a qty on PrestaShop """ + variant_binding = self._create_product_binding( + name='Faded Short Sleeves T-shirt', + template_ps_id=1, + variant_ps_id=1, + ) + base_qty = variant_binding.qty_available + base_prestashop_qty = variant_binding.quantity + self.assertEqual(0, base_qty) + self.assertEqual(0, base_prestashop_qty) + + export_job_path = ('openerp.addons.connector_prestashop.consumer' + '.export_inventory') + with mock.patch(export_job_path): + self._change_product_qty(variant_binding.odoo_id, 42) + + cassette_name = 'test_export_stock_quantity' + with recorder.use_cassette(cassette_name) as cassette: + export_inventory( + self.conn_session, 'prestashop.product.template', + variant_binding.main_template_id.id, + fields=['quantity'], + ) + self.assertEqual(len(cassette.requests), 3) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/stock_availables', + self.parse_path(request.uri)) + expected_query = {'filter[id_product]': ['1'], + 'filter[id_product_attribute]': ['0']} + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + request = cassette.requests[1] + self.assertEqual('GET', request.method) + self.assertEqual('/api/stock_availables/1', + self.parse_path(request.uri)) + self.assertDictEqual({}, self.parse_qs(request.uri)) + + request = cassette.requests[2] + self.assertEqual('PUT', request.method) + self.assertEqual('/api/stock_availables', + self.parse_path(request.uri)) + body = self.xmltodict(request.body) + + self.assertTrue( + set({'depends_on_stock': '0', + 'id': '1', + 'id_product': '1', + 'id_product_attribute': '0', + 'id_shop': '1', + 'id_shop_group': '0', + 'out_of_stock': '2', + 'quantity': '0'}.items()) + .issubset(set(body['prestashop']['stock_available'].items()))) + self.assertDictEqual({}, self.parse_qs(request.uri)) diff --git a/connector_prestashop/tests/test_export_tracking.py b/connector_prestashop/tests/test_export_tracking.py new file mode 100644 index 000000000..92cb1de8d --- /dev/null +++ b/connector_prestashop/tests/test_export_tracking.py @@ -0,0 +1,157 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +import mock + +from odoo.addons.connector_prestashop.models.stock_tracking.\ + exporter import export_tracking_number +from .common import recorder, PrestashopTransactionCase, assert_no_job_delayed + + +class TestExportPicking(PrestashopTransactionCase): + + def setUp(self): + super(TestExportPicking, self).setUp() + self.sync_metadata() + + self.mock_delay_export = mock.MagicMock() + self.patch_delay = mock.patch( + 'openerp.addons.connector_prestashop' + '.consumer.export_tracking_number.delay', + new=self.mock_delay_export + ) + self.patch_delay.start() + + stock_loc = self.ref('stock.stock_location_stock') + customer_loc = self.ref('stock.stock_location_customers') + + self.customer_partner = self.env['res.partner'].create({ + 'name': 'Unittest customer partner', + }) + + self.shop = self.env['prestashop.shop'].search([]) + + self.product_1 = self.env['product.product'].create({ + 'name': 'Blouse' + }) + product_tmpl_1 = self.product_1.product_tmpl_id + template_binding = self.create_binding_no_export( + 'prestashop.product.template', + product_tmpl_1.id, + prestashop_id=2, + default_shop_id=self.shop.id, + ) + self.create_binding_no_export( + 'prestashop.product.combination', + self.product_1.id, + prestashop_id=7, + main_template_id=template_binding.id, + ) + + self.sale = self.env['sale.order'].create({ + 'partner_id': self.customer_partner.id, + 'partner_invoice_id': self.customer_partner.id, + 'partner_shipping_id': self.customer_partner.id, + 'order_line': [(0, 0, { + 'name': self.product_1.name, + 'product_id': self.product_1.id, + 'product_uom_qty': 1.0, + 'product_uom': self.product_1.uom_id.id, + })], + 'pricelist_id': self.env.ref('product.list0').id, + }) + + procurement_group = self.env['procurement.group'].create( + {'name': 'Test', + 'move_type': 'direct', + } + ) + + procurement = self.env['procurement.order'].create({ + 'name': "Unittest P1 procurement", + 'product_id': self.product_1.id, + 'product_uom': self.product_1.uom_id.id, + 'product_qty': 1, + 'sale_line_id': self.sale.order_line[0].id, + 'group_id': procurement_group.id, + }) + + self.picking = self.env['stock.picking'].create({ + 'picking_type_id': self.ref('stock.picking_type_out'), + 'location_id': stock_loc, + 'location_dest_id': customer_loc, + 'move_lines': [ + (0, 0, { + 'name': 'Test move', + 'procurement_id': procurement.id, + 'product_id': self.product_1.id, + 'product_uom': self.ref('product.product_uom_unit'), + 'product_uom_qty': 1, + 'location_id': stock_loc, + 'location_dest_id': customer_loc, + 'group_id': procurement_group.id, + }) + ] + }) + self.sale.procurement_group_id = procurement_group.id + + def tearDown(self): + super(TestExportPicking, self).tearDown() + self.patch_delay.stop() + + @assert_no_job_delayed + def test_event_tracking_number__not_prestashop_sale(self): + """ Test that nothing is exported """ + self.picking.carrier_tracking_ref = 'xyz' + self.assertEqual(0, self.mock_delay_export.call_count) + + @assert_no_job_delayed + def test_event_tracking_number__prestashop_sale(self): + """ Test that tracking number is exported """ + sale_binding = self.create_binding_no_export( + 'prestashop.sale.order', self.sale.id, prestashop_id=2 + ) + + self.picking.carrier_tracking_ref = 'xyz' + self.mock_delay_export.assert_called_once_with( + mock.ANY, 'prestashop.sale.order', sale_binding.id, + priority=mock.ANY + ) + + @assert_no_job_delayed + def test_export_tracking_number(self): + sale_binding = self.create_binding_no_export( + 'prestashop.sale.order', self.sale.id, prestashop_id=2 + ) + self.picking.carrier_tracking_ref = 'xyz' + cassette_name = 'test_export_tracking_number' + with recorder.use_cassette(cassette_name) as cassette: + export_tracking_number( + self.conn_session, 'prestashop.sale.order', sale_binding.id, + ) + self.assertEqual(len(cassette.requests), 3) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/order_carriers', + self.parse_path(request.uri)) + expected_query = {'filter[id_order]': ['2']} + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + request = cassette.requests[1] + self.assertEqual('GET', request.method) + self.assertEqual('/api/order_carriers/2', + self.parse_path(request.uri)) + self.assertDictEqual({}, self.parse_qs(request.uri)) + + request = cassette.requests[2] + self.assertEqual('PUT', request.method) + self.assertEqual('/api/order_carriers', + self.parse_path(request.uri)) + body = self.xmltodict(request.body) + self.assertTrue( + set({'id': '2', + 'tracking_number': 'xyz'}.items()) + .issubset(set(body['prestashop']['order_carrier'].items()))) + self.assertDictEqual({}, self.parse_qs(request.uri)) diff --git a/connector_prestashop/tests/test_import_backend_data.py b/connector_prestashop/tests/test_import_backend_data.py new file mode 100644 index 000000000..973ea6876 --- /dev/null +++ b/connector_prestashop/tests/test_import_backend_data.py @@ -0,0 +1,78 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from collections import namedtuple + +from .common import ( + recorder, PrestashopTransactionCase, quiet_logger, assert_no_job_delayed +) + +ExpectedShopGroup = namedtuple('ExpectedShopGroup', + 'name prestashop_id backend_id') + +ExpectedShop = namedtuple('ExpectedShop', + 'name prestashop_id openerp_id shop_group_id ' + 'backend_id') + + +class TestImportBackendData(PrestashopTransactionCase): + + def setUp(self): + super(TestImportBackendData, self).setUp() + + @recorder.use_cassette + @assert_no_job_delayed + def test_import_metadata(self): + """ Import shop groups and shops """ + self.backend_record.synchronize_metadata() + + shop_groups = self.env['prestashop.shop.group'].search([]) + self.assertEqual(len(shop_groups), 1) + expected = [ + ExpectedShopGroup( + name='Default', + prestashop_id=1, + backend_id=self.backend_record, + ), + ] + self.assert_records(expected, shop_groups) + + shops = self.env['prestashop.shop'].search([]) + self.assertEqual(len(shops), 1) + expected = [ + ExpectedShop( + name='PrestaShop', + prestashop_id=1, + openerp_id=self.backend_record.warehouse_id, + shop_group_id=shop_groups, + backend_id=self.backend_record, + ), + ] + self.assert_records(expected, shops) + + @recorder.use_cassette + @assert_no_job_delayed + def test_import_basedata(self): + """ Import base data (langs, countries, currencies, taxes) """ + # ensure it is created afresh from the sync + self.env['prestashop.res.lang'].search([]).unlink() + self.configure_taxes() + auto_import_logger = ( + 'openerp.addons.connector_prestashop.unit.auto_matching_importer' + ) + with quiet_logger('vcr'), quiet_logger('urllib3'): + with quiet_logger(auto_import_logger): + self.backend_record.synchronize_basedata() + + langs = self.env['prestashop.res.lang'].search([]) + self.assertEqual(len(langs), 1) + + countries = self.env['prestashop.res.country'].search([]) + self.assertEqual(len(countries), 243) + + currencies = self.env['prestashop.res.currency'].search([]) + self.assertEqual(len(currencies), 1) + + taxes = self.env['prestashop.account.tax'].search([]) + self.assertEqual(len(taxes), 7) diff --git a/connector_prestashop/tests/test_import_carrier.py b/connector_prestashop/tests/test_import_carrier.py new file mode 100644 index 000000000..9838e6f4c --- /dev/null +++ b/connector_prestashop/tests/test_import_carrier.py @@ -0,0 +1,95 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from collections import namedtuple + +import mock + +from odoo.addons.connector_prestashop.unit.importer import ( + import_record, +) +from odoo.addons.connector_prestashop.models.\ + delivery_carrier.importer import ( + import_carriers + ) + +from .common import recorder, PrestashopTransactionCase, assert_no_job_delayed + + +ExpectedCarrier = namedtuple( + 'ExpectedCarrier', + 'name partner_id product_id company_id' +) + + +class TestImportCarrier(PrestashopTransactionCase): + """ Test the import of partner from PrestaShop """ + + def setUp(self): + super(TestImportCarrier, self).setUp() + self.sync_metadata() + self.base_mapping() + self.shop_group = self.env['prestashop.shop.group'].search([]) + self.shop = self.env['prestashop.shop'].search([]) + + @assert_no_job_delayed + def test_import_carriers(self): + import_job = ('openerp.addons.connector_prestashop.models' + '.prestashop_backend.common' + '.import_carriers') + with mock.patch(import_job) as import_mock: + self.backend_record.import_carriers() + import_mock.delay.assert_called_with( + mock.ANY, self.backend_record.id, + priority=10, + ) + + @assert_no_job_delayed + def test_import_products_batch(self): + record_job_path = ('openerp.addons.connector_prestashop.unit' + '.importer.import_record') + # execute the batch job directly and replace the record import + # by a mock (individual import is tested elsewhere) + with recorder.use_cassette('test_import_carrier_batch') as cassette, \ + mock.patch(record_job_path) as import_record_mock: + + import_carriers( + self.conn_session, + self.backend_record.id, + ) + expected_query = { + 'filter[deleted]': ['0'], + } + self.assertEqual(1, len(cassette.requests)) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/carriers', self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + self.assertEqual(2, import_record_mock.delay.call_count) + + @assert_no_job_delayed + def test_import_carrier_record(self): + """ Import a carrier """ + with recorder.use_cassette('test_import_carrier_record_2'): + import_record(self.conn_session, 'prestashop.delivery.carrier', + self.backend_record.id, 2) + + domain = [('prestashop_id', '=', 2), + ('backend_id', '=', self.backend_record.id)] + binding = self.env['prestashop.delivery.carrier'].search(domain) + binding.ensure_one() + + ship_product_xmlid = 'connector_ecommerce.product_product_shipping' + ship_product = self.env.ref(ship_product_xmlid) + expected = [ + ExpectedCarrier( + name='My carrier', + partner_id=self.backend_record.company_id.partner_id, + product_id=ship_product, + company_id=self.backend_record.company_id, + )] + + self.assert_records(expected, binding) diff --git a/connector_prestashop/tests/test_import_inventory.py b/connector_prestashop/tests/test_import_inventory.py new file mode 100644 index 000000000..695cbf268 --- /dev/null +++ b/connector_prestashop/tests/test_import_inventory.py @@ -0,0 +1,113 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from collections import namedtuple + +import mock + +from odoo.addons.connector_prestashop.unit.importer import ( + import_record, +) +from odoo.addons.connector_prestashop.models.\ + product_template.importer import ( + import_inventory + ) + +from .common import recorder, PrestashopTransactionCase, assert_no_job_delayed + + +ExpectedCarrier = namedtuple( + 'ExpectedCarrier', + 'name partner_id product_id company_id' +) + + +class TestImportInventory(PrestashopTransactionCase): + """ Test the import of partner from PrestaShop """ + + def setUp(self): + super(TestImportInventory, self).setUp() + self.sync_metadata() + self.base_mapping() + self.shop_group = self.env['prestashop.shop.group'].search([]) + self.shop = self.env['prestashop.shop'].search([]) + + @assert_no_job_delayed + def test_import_inventory_delay(self): + """ Backend button delay a job to delay inventory import """ + import_job = ('openerp.addons.connector_prestashop.models' + '.prestashop_backend.common' + '.import_inventory') + with mock.patch(import_job) as import_mock: + self.backend_record.import_stock_qty() + import_mock.delay.assert_called_with( + mock.ANY, self.backend_record.id, + ) + + @assert_no_job_delayed + def test_import_inventory_batch(self): + record_job_path = ('openerp.addons.connector_prestashop.models' + '.product_template.importer.import_record') + # execute the batch job directly and replace the record import + # by a mock (individual import is tested elsewhere) + with recorder.use_cassette('test_import_inventory_batch') as cassette,\ + mock.patch(record_job_path) as import_record_mock: + + import_inventory(self.conn_session, self.backend_record.id) + expected_query = { + 'display': ['[id,id_product,id_product_attribute]'], + 'limit': ['0,1000'], + } + self.assertEqual(1, len(cassette.requests)) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/stock_availables', + self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + self.assertEqual(52, import_record_mock.delay.call_count) + + @assert_no_job_delayed + def test_import_inventory_record_template(self): + """ Import the inventory for a template""" + variant_binding = self._create_product_binding( + name='Faded Short Sleeves T-shirt', + template_ps_id=1, + variant_ps_id=1, + ) + + template = variant_binding.odoo_id.product_tmpl_id + + self.assertEqual(0, template.qty_available) + with recorder.use_cassette('test_import_inventory_record_template_1'): + import_record(self.conn_session, '_import_stock_available', + self.backend_record.id, 1, + # id_product_attribute='0' means we + # import the template quantity + record={'id_product_attribute': '0', + 'id': '1', + 'id_product': '1'}) + # cumulative stock of all the variants + self.assertEqual(1799, template.qty_available) + + @assert_no_job_delayed + def test_import_inventory_record_variant(self): + """ Import the inventory for a variant""" + variant_binding = self._create_product_binding( + name='Faded Short Sleeves T-shirt', + template_ps_id=1, + variant_ps_id=1, + ) + + template = variant_binding.odoo_id.product_tmpl_id + + self.assertEqual(0, template.qty_available) + with recorder.use_cassette('test_import_inventory_record_variant_1'): + import_record(self.conn_session, '_import_stock_available', + self.backend_record.id, 1, + record={'id_product_attribute': '1', + 'id': '1', + 'id_product': '1'}) + self.assertEqual(299, template.qty_available) diff --git a/connector_prestashop/tests/test_import_partner.py b/connector_prestashop/tests/test_import_partner.py new file mode 100644 index 000000000..c70f9490a --- /dev/null +++ b/connector_prestashop/tests/test_import_partner.py @@ -0,0 +1,228 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from collections import namedtuple + +import mock + +from freezegun import freeze_time + +from odoo.addons.connector_prestashop.models.res_partner.importer import ( + import_customers_since +) +from odoo.addons.connector_prestashop.unit.importer import ( + import_record, + import_batch, +) + +from .common import recorder, PrestashopTransactionCase, assert_no_job_delayed + + +ExpectedCategory = namedtuple( + 'ExpectedCategory', + 'name' +) + +ExpectedPartner = namedtuple( + 'ExpectedPartner', + 'name email newsletter company active shop_group_id shop_id ' + 'default_category_id birthday' +) + +ExpectedAddress = namedtuple( + 'ExpectedAddress', + 'name parent_id street street2 city zip country_id phone mobile type' +) + + +class TestImportPartner(PrestashopTransactionCase): + """ Test the import of partner from PrestaShop """ + + def setUp(self): + super(TestImportPartner, self).setUp() + self.sync_metadata() + self.base_mapping() + + self.shop_group = self.env['prestashop.shop.group'].search([]) + self.shop = self.env['prestashop.shop'].search([]) + + @freeze_time('2016-09-13 00:00:00') + @assert_no_job_delayed + def test_import_partner_since(self): + from_date = '2016-09-01 00:00:00' + self.backend_record.import_partners_since = from_date + import_since_job = ('openerp.addons.connector_prestashop.models' + '.prestashop_backend.common' + '.import_customers_since') + with mock.patch(import_since_job) as import_mock: + self.backend_record.import_customers_since() + import_mock.delay.assert_called_with( + mock.ANY, self.backend_record.id, + since_date='2016-09-01 00:00:00', + priority=10, + ) + + @freeze_time('2016-09-13 00:00:00') + @assert_no_job_delayed + def test_import_partner_batch(self): + from_date = '2016-09-01 00:00:00' + self.backend_record.import_res_partner_from_date = from_date + record_job_path = ('openerp.addons.connector_prestashop.unit' + '.importer.import_record') + # execute the batch job directly and replace the record import + # by a mock (individual import is tested elsewhere) + with recorder.use_cassette('test_import_partner_batch') as cassette, \ + mock.patch(record_job_path) as import_record_mock: + + import_customers_since( + self.conn_session, + self.backend_record.id, + since_date=from_date, + ) + expected_query = { + 'date': ['1'], + 'limit': ['0,1000'], + 'filter[date_upd]': ['>[2016-09-01 00:00:00]'], + } + self.assertEqual(2, len(cassette.requests)) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/groups', self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + request = cassette.requests[1] + self.assertEqual('GET', request.method) + self.assertEqual('/api/customers', self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + self.assertEqual(5, import_record_mock.delay.call_count) + + @assert_no_job_delayed + def test_import_partner_category_record(self): + """ Import a partner category """ + with recorder.use_cassette('test_import_partner_category_record_1'): + import_record(self.conn_session, 'prestashop.res.partner.category', + self.backend_record.id, 3) + + domain = [('prestashop_id', '=', 3)] + category_model = self.env['prestashop.res.partner.category'] + category_bindings = category_model.search(domain) + category_bindings.ensure_one() + + expected = [ + ExpectedCategory( + name='Customer A', + )] + + self.assert_records(expected, category_bindings) + + @assert_no_job_delayed + def test_import_partner_record(self): + """ Import a partner """ + + category = self.env['res.partner.category'].create( + {'name': 'Customer'} + ) + category_binding = self.create_binding_no_export( + 'prestashop.res.partner.category', category.id, 3 + ) + + batch_job_path = ('openerp.addons.connector_prestashop.models' + '.res_partner.importer.import_batch') + with recorder.use_cassette('test_import_partner_record_1'), \ + mock.patch(batch_job_path) as address_batch_mock: + import_record(self.conn_session, 'prestashop.res.partner', + self.backend_record.id, 1) + address_batch_mock.delay.assert_called_with( + mock.ANY, + 'prestashop.address', + self.backend_record.id, + filters={'filter[id_customer]': '1'}, + priority=10, + ) + + domain = [('prestashop_id', '=', 1)] + partner_bindings = self.env['prestashop.res.partner'].search(domain) + partner_bindings.ensure_one() + + expected = [ + ExpectedPartner( + name='John DOE', + email='pub@prestashop.com', + newsletter=True, + company=False, + active=True, + shop_group_id=self.shop_group, + shop_id=self.shop, + default_category_id=category_binding, + birthday='1970-01-15', + )] + + self.assert_records(expected, partner_bindings) + + @assert_no_job_delayed + def test_import_partner_address_batch(self): + record_job_path = ('openerp.addons.connector_prestashop.unit' + '.importer.import_record') + # execute the batch job directly and replace the record import + # by a mock (individual import is tested elsewhere) + cassette_name = 'test_import_partner_address_batch' + with recorder.use_cassette(cassette_name) as cassette, \ + mock.patch(record_job_path) as import_record_mock: + + import_batch( + self.conn_session, + 'prestashop.address', + self.backend_record.id, + filters={'filter[id_customer]': '1'} + ) + expected_query = { + 'limit': ['0,1000'], + 'filter[id_customer]': ['1'], + } + self.assertEqual(1, len(cassette.requests)) + self.assertEqual('GET', cassette.requests[0].method) + self.assertEqual('/api/addresses', + self.parse_path(cassette.requests[0].uri)) + query = self.parse_qs(cassette.requests[0].uri) + self.assertDictEqual(expected_query, query) + + self.assertEqual(2, import_record_mock.delay.call_count) + + @assert_no_job_delayed + def test_import_partner_address_record(self): + """ Import a partner address """ + + partner = self.env['res.partner'].create( + {'name': 'Customer'} + ) + self.create_binding_no_export( + 'prestashop.res.partner', partner.id, 1, + shop_group_id=self.shop_group.id, + shop_id=self.shop.id, + ) + with recorder.use_cassette('test_import_partner_address_record_1'): + import_record(self.conn_session, 'prestashop.address', + self.backend_record.id, 1) + + domain = [('prestashop_id', '=', 1)] + address_bindings = self.env['prestashop.address'].search(domain) + address_bindings.ensure_one() + + expected = [ + ExpectedAddress( + name='John DOE (My address)', + parent_id=partner, + street='16, Main street', + street2='2nd floor', + city='Paris', + zip='75002', + country_id=self.env.ref('base.fr'), + phone='0102030405', + mobile=False, + type='other', + )] + + self.assert_records(expected, address_bindings) diff --git a/connector_prestashop/tests/test_import_products.py b/connector_prestashop/tests/test_import_products.py new file mode 100644 index 000000000..38ea5acc0 --- /dev/null +++ b/connector_prestashop/tests/test_import_products.py @@ -0,0 +1,236 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from collections import namedtuple + +import mock + +from freezegun import freeze_time + +from odoo.addons.connector_prestashop.unit.importer import ( + import_record, +) +from odoo.addons.connector_prestashop.models.\ + product_template.importer import ( + import_products + ) + +from .common import recorder, PrestashopTransactionCase, assert_no_job_delayed + + +ExpectedProductCategory = namedtuple( + 'ExpectedProductCategory', + 'name odoo_id__display_name' +) + +ExpectedTemplate = namedtuple( + 'ExpectedProduct', + 'name categ_id categ_ids list_price' +) + +ExpectedVariant = namedtuple( + 'ExpectedVariant', + 'default_code standard_price attribute_value_ids' +) + + +class TestImportProduct(PrestashopTransactionCase): + """ Test the import of partner from PrestaShop """ + + def setUp(self): + super(TestImportProduct, self).setUp() + self.sync_metadata() + self.base_mapping() + + self.shop_group = self.env['prestashop.shop.group'].search([]) + self.shop = self.env['prestashop.shop'].search([]) + + self.mock_delay_import_image = mock.MagicMock() + self.patch_delay_import_image = mock.patch( + 'openerp.addons.connector_prestashop.models.product_template' + '.importer.set_product_image_variant', + new=self.mock_delay_import_image + ) + self.patch_delay_import_image.start() + + self.mock_delay_import_image = mock.MagicMock() + self.patch_delay_import_image = mock.patch( + 'openerp.addons.connector_prestashop.models.product_template' + '.importer.import_product_image', + new=self.mock_delay_import_image + ) + self.patch_delay_import_image.start() + + self.mock_delay_set_image = mock.MagicMock() + self.patch_delay_set_image = mock.patch( + 'openerp.addons.connector_prestashop.models.product_template' + '.importer.set_product_image_variant', + new=self.mock_delay_set_image + ) + self.patch_delay_set_image.start() + + def tearDown(self): + super(TestImportProduct, self).tearDown() + self.patch_delay_import_image.stop() + self.patch_delay_set_image.stop() + + @freeze_time('2016-09-13 00:00:00') + @assert_no_job_delayed + def test_import_products(self): + from_date = '2016-09-01 00:00:00' + self.backend_record.import_products_since = from_date + import_job = ('openerp.addons.connector_prestashop.models' + '.prestashop_backend.common' + '.import_products') + with mock.patch(import_job) as import_mock: + self.backend_record.import_products() + import_mock.delay.assert_called_with( + mock.ANY, self.backend_record.id, + from_date, + priority=10, + ) + + @freeze_time('2016-09-13 00:00:00') + @assert_no_job_delayed + def test_import_products_batch(self): + from_date = '2016-09-01 00:00:00' + self.backend_record.import_products_since = from_date + record_job_path = ('openerp.addons.connector_prestashop.unit' + '.importer.import_record') + # execute the batch job directly and replace the record import + # by a mock (individual import is tested elsewhere) + with recorder.use_cassette('test_import_product_batch') as cassette, \ + mock.patch(record_job_path) as import_record_mock: + + import_products( + self.conn_session, + self.backend_record.id, + from_date, + ) + expected_query = { + 'date': ['1'], + 'limit': ['0,1000'], + 'filter[date_upd]': ['>[2016-09-01 00:00:00]'], + } + self.assertEqual(2, len(cassette.requests)) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/categories', self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + request = cassette.requests[1] + self.assertEqual('GET', request.method) + self.assertEqual('/api/products', self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + self.assertEqual(18, import_record_mock.delay.call_count) + + @assert_no_job_delayed + def test_import_product_record_category(self): + """ Import a product category """ + with recorder.use_cassette('test_import_product_category_record_1'): + import_record(self.conn_session, 'prestashop.product.category', + self.backend_record.id, 5) + + domain = [('prestashop_id', '=', 5), + ('backend_id', '=', self.backend_record.id)] + binding = self.env['prestashop.product.category'].search(domain) + binding.ensure_one() + + expected = [ + ExpectedProductCategory( + name='T-shirts', + odoo_id__display_name='Root / Home / Women / Tops / T-shirts', + )] + + self.assert_records(expected, binding) + + @assert_no_job_delayed + def test_import_product_record(self): + """ Import a product """ + # product 1 is assigned to categories 1-5 on PrestaShop + categs = self.env['product.category'] + for idx in range(1, 6): + cat = self.env['product.category'].create( + {'name': 'ps_categ_%d' % idx} + ) + self.create_binding_no_export( + 'prestashop.product.category', cat.id, idx, + ) + categs |= cat + + with recorder.use_cassette('test_import_product_template_record_1'): + import_record(self.conn_session, 'prestashop.product.template', + self.backend_record.id, 1) + + domain = [('prestashop_id', '=', 1), + ('backend_id', '=', self.backend_record.id)] + binding = self.env['prestashop.product.template'].search(domain) + binding.ensure_one() + + expected = [ + ExpectedTemplate( + name='Faded Short Sleeves T-shirt', + # For the categories, this is what I observed, not + # necessarily what is wanted. + categ_id=self.env.ref('product.product_category_all'), + categ_ids=categs.filtered(lambda r: r.name != 'ps_categ_1'), + list_price=16.51, + )] + + self.assert_records(expected, binding) + + variants = binding.product_variant_ids + + PSValue = self.env['prestashop.product.combination.option.value'] + value_s = PSValue.search([('backend_id', '=', self.backend_record.id), + ('name', '=', 'S')]).odoo_id + value_m = PSValue.search([('backend_id', '=', self.backend_record.id), + ('name', '=', 'M')]).odoo_id + value_l = PSValue.search([('backend_id', '=', self.backend_record.id), + ('name', '=', 'L')]).odoo_id + value_orange = PSValue.search( + [('backend_id', '=', self.backend_record.id), + ('name', '=', 'Orange')] + ).odoo_id + value_blue = PSValue.search( + [('backend_id', '=', self.backend_record.id), + ('name', '=', 'Blue')] + ).odoo_id + + expected_variants = [ + ExpectedVariant( + default_code='1_1', + standard_price=4.95, + attribute_value_ids=value_s + value_orange, + ), + ExpectedVariant( + default_code='1_2', + standard_price=4.95, + attribute_value_ids=value_s + value_blue, + ), + ExpectedVariant( + default_code='1_3', + standard_price=4.95, + attribute_value_ids=value_m + value_orange, + ), + ExpectedVariant( + default_code='1_4', + standard_price=4.95, + attribute_value_ids=value_m + value_blue, + ), + ExpectedVariant( + default_code='1_5', + standard_price=4.95, + attribute_value_ids=value_l + value_orange, + ), + ExpectedVariant( + default_code='1_6', + standard_price=4.95, + attribute_value_ids=value_l + value_blue, + ), + ] + + self.assert_records(expected_variants, variants) diff --git a/connector_prestashop/tests/test_import_sale.py b/connector_prestashop/tests/test_import_sale.py new file mode 100644 index 000000000..49bb39678 --- /dev/null +++ b/connector_prestashop/tests/test_import_sale.py @@ -0,0 +1,230 @@ +# -*- coding: utf-8 -*- +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from collections import namedtuple + +import mock + +from freezegun import freeze_time + +from odoo.addons.connector_prestashop.unit.importer import ( + import_record, +) +from odoo.addons.connector_prestashop.models.\ + sale_order.importer import ( + import_orders_since + ) + +from .common import recorder, PrestashopTransactionCase, assert_no_job_delayed + + +ExpectedSale = namedtuple( + 'ExpectedSale', + 'name carrier_id total_amount partner_id partner_invoice_id ' + 'partner_shipping_id pricelist_id payment_mode_id' +) + +ExpectedSaleLine = namedtuple( + 'ExpectedSaleLine', + 'name product_id price_unit product_uom_qty' +) + + +class TestImportSale(PrestashopTransactionCase): + """ Test the import of partner from PrestaShop """ + + def setUp(self): + super(TestImportSale, self).setUp() + self.sync_metadata() + self.base_mapping() + + self.shop_group = self.env['prestashop.shop.group'].search([]) + self.shop = self.env['prestashop.shop'].search([]) + + @freeze_time('2016-12-09 00:00:00') + @assert_no_job_delayed + def test_import_sales(self): + from_date = '2016-12-01 00:00:00' + self.backend_record.import_orders_since = from_date + import_job = ('openerp.addons.connector_prestashop.models' + '.prestashop_backend.common' + '.import_orders_since') + with mock.patch(import_job) as import_mock: + self.backend_record.import_sale_orders() + import_mock.delay.assert_called_with( + mock.ANY, self.backend_record.id, + from_date, + priority=5, + ) + + @freeze_time('2016-12-09 00:00:00') + @assert_no_job_delayed + def test_import_sale_batch(self): + from_date = '2016-12-01 00:00:00' + self.backend_record.import_res_partner_from_date = from_date + record_job_path = ('openerp.addons.connector_prestashop.unit' + '.importer.import_record') + # execute the batch job directly and replace the record import + # by a mock (individual import is tested elsewhere) + with recorder.use_cassette('test_import_sale_batch') as cassette, \ + mock.patch(record_job_path) as import_record_mock: + + import_orders_since( + self.conn_session, + self.backend_record.id, + from_date, + ) + + expected_query = { + 'date': ['1'], + 'limit': ['0,1000'], + 'filter[date_upd]': ['>[2016-12-01 00:00:00]'], + } + self.assertEqual(2, len(cassette.requests)) + + request = cassette.requests[0] + self.assertEqual('GET', request.method) + self.assertEqual('/api/orders', self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + expected_query = { + 'date': ['1'], + 'limit': ['0,1000'], + 'filter[date_add]': ['>[2016-12-01 00:00:00]'], + } + request = cassette.requests[1] + self.assertEqual('GET', request.method) + self.assertEqual('/api/customer_messages', + self.parse_path(request.uri)) + self.assertDictEqual(expected_query, self.parse_qs(request.uri)) + + self.assertEqual(5, import_record_mock.delay.call_count) + + @assert_no_job_delayed + def test_import_sale_record(self): + """ Import a sale order """ + # setup for sale order with id 5, create the dependencies + mode_journal = self.env['account.journal'].search([], limit=1) + payment_method_xmlid = 'account.account_payment_method_manual_in' + payment_method = self.env.ref(payment_method_xmlid) + payment_mode = self.env['account.payment.mode'].create({ + 'name': 'Bank wire', + 'company_id': self.backend_record.company_id.id, + 'bank_account_link': 'fixed', + 'fixed_journal_id': mode_journal.id, + 'payment_type': 'inbound', + 'payment_method_id': payment_method.id, + }) + + ship_product = self.env.ref( + 'connector_ecommerce.product_product_shipping' + ) + + carrier = self.env['delivery.carrier'].create({ + 'name': 'My carrier', + 'product_id': ship_product.id, + 'partner_id': self.env.ref('base.main_company').partner_id.id, + }) + self.create_binding_no_export( + 'prestashop.delivery.carrier', carrier.id, prestashop_id=2, + ) + + variant_tshirt_orange_s_binding = self._create_product_binding( + name='Faded Short Sleeve T-shirts', + template_ps_id=1, + variant_ps_id=1, + ) + variant_tshirt_orange_s = variant_tshirt_orange_s_binding.odoo_id + variant_blouse_black_s_binding = self._create_product_binding( + name='Blouse', + template_ps_id=2, + variant_ps_id=7, + ) + variant_blouse_black_s = variant_blouse_black_s_binding.odoo_id + variant_dress_orange_s_binding = self._create_product_binding( + name='Printed Dress', + template_ps_id=3, + variant_ps_id=13, + ) + variant_dress_orange_s = variant_dress_orange_s_binding.odoo_id + + partner = self.env['res.partner'].create({ + 'name': 'John DOE', + }) + partner_binding = self.create_binding_no_export( + 'prestashop.res.partner', partner.id, prestashop_id=1, + shop_group_id=self.shop.id, + ) + address = self.env['res.partner'].create({ + 'name': 'John DOE', + 'parent_id': partner.id, + }) + self.create_binding_no_export( + 'prestashop.address', address.id, prestashop_id=4, + prestashop_partner_id=partner_binding.id + ) + + # import of the sale order + with recorder.use_cassette('test_import_sale_record_5'): + result = import_record( + self.conn_session, 'prestashop.sale.order', + self.backend_record.id, 5) + + error_msg = ('Import of the order 5 canceled ' + 'because it has not been paid since 30 days') + self.assertEqual(result, error_msg) + + with recorder.use_cassette('test_import_sale_record_5'): + with freeze_time("2016-12-08"): + import_record( + self.conn_session, 'prestashop.sale.order', + self.backend_record.id, 5) + + domain = [('prestashop_id', '=', 5), + ('backend_id', '=', self.backend_record.id)] + binding = self.env['prestashop.sale.order'].search(domain) + binding.ensure_one() + + expected = [ + ExpectedSale( + name='KHWLILZLL', + partner_id=partner, + partner_invoice_id=address, + partner_shipping_id=address, + total_amount=71.51, + carrier_id=carrier, + payment_mode_id=payment_mode, + pricelist_id=self.backend_record.pricelist_id, + )] + + self.assert_records(expected, binding) + + expected = [ + ExpectedSaleLine( + name='Faded Short Sleeve T-shirts - Color : Orange, Size : S', + product_id=variant_tshirt_orange_s, + price_unit=16.51, + product_uom_qty=1.0, + ), + ExpectedSaleLine( + name='Blouse - Color : Black, Size : S', + product_id=variant_blouse_black_s, + price_unit=27.0, + product_uom_qty=1.0, + ), + ExpectedSaleLine( + name='Printed Dress - Color : Orange, Size : S', + product_id=variant_dress_orange_s, + price_unit=26.0, + product_uom_qty=1.0, + ), + ExpectedSaleLine( + name='My carrier', + product_id=ship_product, + price_unit=2.0, + product_uom_qty=1.0, + ), + ] + + self.assert_records(expected, binding.order_line) diff --git a/connector_prestashop/unit/__init__.py b/connector_prestashop/unit/__init__.py new file mode 100644 index 000000000..45aa2f239 --- /dev/null +++ b/connector_prestashop/unit/__init__.py @@ -0,0 +1,13 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +# ConnectorUnit needs to be registered +from . import auto_matching_importer +from . import mapper +from . import binder +from . import importer +from . import exporter +from . import deleter +from . import backend_adapter +from . import exception +from . import version_key diff --git a/connector_prestashop/unit/auto_matching_importer.py b/connector_prestashop/unit/auto_matching_importer.py new file mode 100644 index 000000000..bb980e86b --- /dev/null +++ b/connector_prestashop/unit/auto_matching_importer.py @@ -0,0 +1,118 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging + +from odoo.addons.connector.connector import ConnectorUnit +from odoo.addons.connector.unit.backend_adapter import BackendAdapter + +from odoo import _, exceptions + +_logger = logging.getLogger(__name__) + + +class AutoMatchingImporter(ConnectorUnit): + _model_name = None + _erp_field = None + _ps_field = None + _copy_fields = [] + + def _compare_function(ps_val, erp_val, ps_dict, erp_dict): + raise NotImplementedError + + def run(self): + _logger.debug( + "[%s] Starting synchro between Odoo and PrestaShop" + % self.model._name + ) + nr_ps_already_mapped = 0 + nr_ps_mapped = 0 + nr_ps_not_mapped = 0 + erp_model_name = self.model._inherits.iterkeys().next() + erp_rec_name = self.env[erp_model_name]._rec_name + model = self.env[erp_model_name].with_context(active_test=False) + erp_ids = model.search([]) + erp_list_dict = erp_ids.read() + adapter = self.unit_for(BackendAdapter) + # Get the IDS from PS + ps_ids = adapter.search() + if not ps_ids: + raise exceptions.Warning( + _('Error :'), + _('Failed to query %s via PS webservice') + % adapter.prestashop_model + ) + + binder = self.binder_for() + # Loop on all PS IDs + for ps_id in ps_ids: + # Check if the PS ID is already mapped to an OE ID + record = binder.to_internal(ps_id) + if record: + # Do nothing for the PS IDs that are already mapped + _logger.debug( + "[%s] PrestaShop ID %s is already mapped to Odoo ID %s" + % (self.model._name, ps_id, record.id) + ) + nr_ps_already_mapped += 1 + else: + # PS IDs not mapped => I try to match between the PS ID and + # the OE ID. First, I read field in PS + ps_dict = adapter.read(ps_id) + mapping_found = False + # Loop on OE IDs + for erp_dict in erp_list_dict: + # Search for a match + erp_val = erp_dict[self._erp_field] + ps_val = ps_dict[self._ps_field] + if self._compare_function( + ps_val, erp_val, ps_dict, erp_dict): + # it matches, so I write the external ID + data = { + 'odoo_id': erp_dict['id'], + 'backend_id': self.backend_record.id, + } + for oe_field, ps_field in self._copy_fields: + data[oe_field] = erp_dict[ps_field] + record = self.model.create(data) + binder.bind(ps_id, record) + _logger.debug( + "[%s] Mapping PrestaShop '%s' (%s) " + "to Odoo '%s' (%s) " % + (self.model._name, + ps_dict['name'], # not hardcode if needed + ps_dict[self._ps_field], + erp_dict[erp_rec_name], + erp_dict[self._erp_field])) + nr_ps_mapped += 1 + mapping_found = True + break + if not mapping_found: + # if it doesn't match, I just print a warning + _logger.warning( + "[%s] PrestaShop '%s' (%s) was not mapped " + "to any Odoo entry" % + (self.model._name, + ps_dict['name'], + ps_dict[self._ps_field])) + + nr_ps_not_mapped += 1 + + _logger.info( + "[%s] Synchro between Odoo and PrestaShop successfull" + % self.model._name + ) + _logger.info( + "[%s] Number of PrestaShop entries already mapped = %s" + % (self.model._name, nr_ps_already_mapped) + ) + _logger.info( + "[%s] Number of PrestaShop entries mapped = %s" + % (self.model._name, nr_ps_mapped) + ) + _logger.info( + "[%s] Number of PrestaShop entries not mapped = %s" + % (self.model._name, nr_ps_not_mapped) + ) + + return True diff --git a/connector_prestashop/unit/backend_adapter.py b/connector_prestashop/unit/backend_adapter.py new file mode 100644 index 000000000..de39d4484 --- /dev/null +++ b/connector_prestashop/unit/backend_adapter.py @@ -0,0 +1,222 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import exceptions, _ +from odoo.addons.connector.exception import NetworkRetryableError +from odoo.addons.connector.unit.backend_adapter import CRUDAdapter + +from contextlib import contextmanager +from requests.exceptions import HTTPError, RequestException, ConnectionError +import base64 +import logging +_logger = logging.getLogger(__name__) +try: + from prestapyt import PrestaShopWebServiceDict, PrestaShopWebServiceError +except: + _logger.debug('Cannot import from `prestapyt`') + + +@contextmanager +def api_handle_errors(message=''): + """ Handle error when calling the API + + It is meant to be used when a model does a direct + call to a job using the API (not using job.delay()). + Avoid to have unhandled errors raising on front of the user, + instead, they are presented as :class:`openerp.exceptions.UserError`. + """ + if message: + message = message + u'\n\n' + try: + yield + except NetworkRetryableError as err: + raise exceptions.UserError( + _(u'{}Network Error:\n\n{}').format(message, err) + ) + except (HTTPError, RequestException, ConnectionError) as err: + raise exceptions.UserError( + _(u'{}API / Network Error:\n\n{}').format(message, err) + ) + except PrestaShopWebServiceError as err: + raise exceptions.UserError( + _(u'{}Authentication Error:\n\n{}').format(message, err) + ) + except PrestaShopWebServiceError as err: + raise exceptions.UserError( + _(u'{}Error during synchronization with ' + 'PrestaShop:\n\n{}').format(message, unicode(err)) + ) + + +class PrestaShopWebServiceImage(PrestaShopWebServiceDict): + + def get_image(self, resource, resource_id=None, image_id=None, + options=None): + full_url = self._api_url + 'images/' + resource + if resource_id is not None: + full_url += "/%s" % (resource_id,) + if image_id is not None: + full_url += "/%s" % (image_id) + if options is not None: + self._validate_query_options(options) + full_url += "?%s" % (self._options_to_querystring(options),) + response = self._execute(full_url, 'GET') + if response.content: + image_content = base64.b64encode(response.content) + else: + image_content = '' + + record = { + 'type': response.headers['content-type'], + 'content': image_content, + 'id_' + resource[:-1]: resource_id, + 'id_image': image_id, + } + record['full_public_url'] = self.get_image_public_url(record) + return record + + def get_image_public_url(self, record): + url = self._api_url.replace('/api', '') + url += '/img/p/' + '/'.join(list(record['id_image'])) + extension = '' + if record['type'] == 'image/jpeg': + extension = '.jpg' + url += '/' + record['id_image'] + extension + return url + + +class PrestaShopLocation(object): + + def __init__(self, location, webservice_key): + self.location = location + self.webservice_key = webservice_key + if not location.endswith('/api'): + location = location + '/api' + if not location.startswith('http'): + location = 'http://' + location + self.api_url = location + + +class PrestaShopCRUDAdapter(CRUDAdapter): + """ External Records Adapter for PrestaShop """ + + def __init__(self, environment): + """ + + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(PrestaShopCRUDAdapter, self).__init__(environment) + self.prestashop = PrestaShopLocation( + self.backend_record.location.encode(), + self.backend_record.webservice_key + ) + self.client = PrestaShopWebServiceDict( + self.prestashop.api_url, + self.prestashop.webservice_key, + ) + + def search(self, filters=None): + """ Search records according to some criterias + and returns a list of ids """ + raise NotImplementedError + + def read(self, id, attributes=None): + """ Returns the information of a record """ + raise NotImplementedError + + def search_read(self, filters=None): + """ Search records according to some criterias + and returns their information""" + raise NotImplementedError + + def create(self, data): + """ Create a record on the external system """ + raise NotImplementedError + + def write(self, id, data): + """ Update records on the external system """ + raise NotImplementedError + + def delete(self, id): + """ Delete a record on the external system """ + raise NotImplementedError + + def head(self): + """ HEAD """ + raise NotImplementedError + + +class GenericAdapter(PrestaShopCRUDAdapter): + + _model_name = None + _prestashop_model = None + # PS WS key for exporting + _export_node_name = '' + # PS WS key response + # When you create a record in PS + # you get back a result that is wrapped like this: + # {'prestashop': _export_node_name_res: {...}} + # For instance: for `manufacturers` + # _export_node_name="manufacturers" + # _export_node_name_res = "manufacturer" + _export_node_name_res = '' + + def search(self, filters=None): + """ Search records according to some criterias + and returns a list of ids + + :rtype: list + """ + _logger.debug( + 'method search, model %s, filters %s', + self._prestashop_model, unicode(filters)) + return self.client.search(self._prestashop_model, filters) + + def read(self, id, attributes=None): + """ Returns the information of a record + + :rtype: dict + """ + _logger.debug( + 'method read, model %s id %s, attributes %s', + self._prestashop_model, str(id), unicode(attributes)) + res = self.client.get(self._prestashop_model, id, options=attributes) + first_key = res.keys()[0] + return res[first_key] + + def create(self, attributes=None): + """ Create a record on the external system """ + _logger.debug( + 'method create, model %s, attributes %s', + self._prestashop_model, unicode(attributes)) + res = self.client.add(self._prestashop_model, { + self._export_node_name: attributes + }) + if self._export_node_name_res: + return res['prestashop'][self._export_node_name_res]['id'] + return res + + def write(self, id, attributes=None): + """ Update records on the external system """ + attributes['id'] = id + _logger.debug( + 'method write, model %s, attributes %s', + self._prestashop_model, + unicode(attributes) + ) + res = self.client.edit( + self._prestashop_model, {self._export_node_name: attributes}) + if self._export_node_name_res: + return res['prestashop'][self._export_node_name_res]['id'] + return res + + def delete(self, resource, ids): + _logger.debug('method delete, model %s, ids %s', + resource, unicode(ids)) + # Delete a record(s) on the external system + return self.client.delete(resource, ids) + + def head(self, id=None): + """ HEAD """ + return self.client.head(self._prestashop_model, resource_id=id) diff --git a/connector_prestashop/unit/binder.py b/connector_prestashop/unit/binder.py new file mode 100644 index 000000000..22638c7b2 --- /dev/null +++ b/connector_prestashop/unit/binder.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo.addons.connector.connector import Binder +from ..backend import prestashop + + +@prestashop +class PrestashopBinder(Binder): + """ Generic Binder for Prestshop """ + + _external_field = 'prestashop_id' + + _model_name = [ + 'prestashop.shop.group', + 'prestashop.shop', + 'prestashop.res.partner', + 'prestashop.address', + 'prestashop.res.partner.category', + 'prestashop.res.lang', + 'prestashop.res.country', + 'prestashop.res.currency', + 'prestashop.account.tax', + 'prestashop.account.tax.group', + 'prestashop.product.category', + 'prestashop.product.image', + 'prestashop.product.template', + 'prestashop.product.combination', + 'prestashop.product.combination.option', + 'prestashop.product.combination.option.value', + 'prestashop.sale.order', + 'prestashop.sale.order.state', + 'prestashop.delivery.carrier', + 'prestashop.refund', + 'prestashop.supplier', + 'prestashop.product.supplierinfo', + 'prestashop.mail.message', + 'prestashop.groups.pricelist', + ] + + def to_odoo(self, external_id, unwrap=False): + # Make alias to to_openerp, remove in v10 + return self.to_openerp(external_id, unwrap) diff --git a/connector_prestashop/unit/deleter.py b/connector_prestashop/unit/deleter.py new file mode 100644 index 000000000..9fde3f0e9 --- /dev/null +++ b/connector_prestashop/unit/deleter.py @@ -0,0 +1,29 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo.tools.translate import _ +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.synchronizer import Deleter + + +class PrestashopDeleter(Deleter): + """ Base deleter for PrestaShop """ + + def run(self, resource, external_id): + """ Run the synchronization, delete the record on PrestaShop + + :param external_id: identifier of the record to delete + """ + self.backend_adapter.delete(resource, external_id) + return _('Record %s deleted on PrestaShop on resource %s') % ( + external_id, resource) + + +@job(default_channel='root.prestashop') +def export_delete_record( + session, model_name, backend_id, external_id, resource): + """ Delete a record on PrestaShop """ + backend = session.env['prestashop.backend'].browse(backend_id) + env = backend.get_environment(model_name, session=session) + deleter = env.get_connector_unit(PrestashopDeleter) + return deleter.run(resource, external_id) diff --git a/connector_prestashop/unit/exception.py b/connector_prestashop/unit/exception.py new file mode 100644 index 000000000..b099dc3b9 --- /dev/null +++ b/connector_prestashop/unit/exception.py @@ -0,0 +1,8 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo.addons.connector.exception import RetryableJobError + + +class OrderImportRuleRetry(RetryableJobError): + """ The sale order import will be retried later. """ diff --git a/connector_prestashop/unit/export_synchronizer.py b/connector_prestashop/unit/export_synchronizer.py new file mode 100644 index 000000000..03bd66e48 --- /dev/null +++ b/connector_prestashop/unit/export_synchronizer.py @@ -0,0 +1,198 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging +from openerp import _, exceptions +from openerp.addons.connector.queue.job import job +from openerp.addons.connector.queue.job import related_action +from openerp.addons.connector.unit.synchronizer import Exporter +from .mapper import TranslationPrestashopExportMapper +from ..connector import get_environment + + +_logger = logging.getLogger(__name__) + + +# Exporters for PrestaShop. +# In addition to its export job, an exporter has to: +# * check in PrestaShop if the record has been updated more recently than the +# last sync date and if yes, delay an import +# * call the ``bind`` method of the binder to update the last sync date + + +class PrestashopBaseExporter(Exporter): + """ Base exporter for PrestaShop """ + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(PrestashopBaseExporter, self).__init__(environment) + self.binding_id = None + self.prestashop_id = None + + def _get_openerp_data(self): + """ Return the raw OpenERP data for ``self.binding_id`` """ + return self.env[self.model._name].browse(self.binding_id) + + def run(self, binding_id, *args, **kwargs): + """ Run the synchronization + + :param binding_id: identifier of the binding record to export + """ + self.binding_id = binding_id + self.erp_record = self._get_openerp_data() + + self.prestashop_id = self.binder.to_backend(self.binding_id) + result = self._run(*args, **kwargs) + + self.binder.bind(self.prestashop_id, self.binding_id) + return result + + def _run(self): + """ Flow of the synchronization, implemented in inherited classes""" + raise NotImplementedError + + +class PrestashopExporter(PrestashopBaseExporter): + """ A common flow for the exports to PrestaShop """ + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(PrestashopExporter, self).__init__(environment) + self.erp_record = None + + def _has_to_skip(self): + """ Return True if the export can be skipped """ + return False + + def _export_dependencies(self): + """ Export the dependencies for the record""" + return + + def _map_data(self, fields=None): + """ Convert the external record to Odoo """ + self.mapper.map_record(self.erp_record) + + def _validate_data(self, data): + """ Check if the values to import are correct + + Pro-actively check before the ``Model.create`` or + ``Model.update`` if some fields are missing + + Raise `InvalidDataError` + """ + return + + def _after_export(self): + """Create records of dependants prestashop objects""" + return + + def _create(self, data): + """ Create the PrestaShop record """ + return self.backend_adapter.create(data) + + def _update(self, data): + """ Update an PrestaShop record """ + assert self.prestashop_id + return self.backend_adapter.write(self.prestashop_id, data) + + def _run(self, fields=None): + """ Flow of the synchronization, implemented in inherited classes""" + assert self.binding_id + assert self.erp_record + + # should be created with all the fields + if not self.prestashop_id: + fields = None + + if self._has_to_skip(): + return + + # export the missing linked resources + self._export_dependencies() + map_record = self.mapper.map_record(self.erp_record) + + if self.prestashop_id: + record = map_record.values() + if not record: + return _('Nothing to export.') + # special check on data before export + self._validate_data(record) + self._update(record) + else: + record = map_record.values(for_create=True) + if fields is None: + fields = {} + record.update(fields) + if not record: + return _('Nothing to export.') + # special check on data before export + self._validate_data(record) + self.prestashop_id = self._create(record) + if self.prestashop_id == 0: + raise exceptions.Warning( + _("Record on PrestaShop have not been created")) + self._after_export() + message = _('Record exported with ID %s on PrestaShop.') + return message % self.prestashop_id + + +class TranslationPrestashopExporter(PrestashopExporter): + + @property + def mapper(self): + if self._mapper is None: + self._mapper = self.connector_env.get_connector_unit( + TranslationPrestashopExportMapper) + return self._mapper + + def _map_data(self, fields=None): + """ Convert the external record to OpenERP """ + self.mapper.convert(self.get_record_by_lang(), fields=fields) + + def get_record_by_lang(self, record_id): + # get the backend's languages + languages = self.backend_record.language_ids + records = {} + # for each languages: + for language in languages: + # get the translated record + record = self.model.with_context( + lang=language['code']).browse(record_id) + # put it in the dict + records[language['prestashop_id']] = record + return records + + +def related_action_record(session, job): + binding_model = job.args[0] + binding_id = job.args[1] + record = session.env[binding_model].browse(binding_id) + odoo_name = record.odoo_id._name + + action = { + 'name': _(odoo_name), + 'type': 'ir.actions.act_window', + 'res_model': odoo_name, + 'view_type': 'form', + 'view_mode': 'form', + 'res_id': record.odoo_id.id, + } + return action + + +@job(default_channel='root.prestashop') +@related_action(action=related_action_record) +def export_record(session, model_name, binding_id, fields=None): + """ Export a record on PrestaShop """ + # TODO: FIX PRESTASHOP do not support partial edit + fields = None + record = session.env[model_name].browse(binding_id) + env = get_environment(session, model_name, record.backend_id.id) + exporter = env.get_connector_unit(PrestashopExporter) + return exporter.run(binding_id, fields=fields) diff --git a/connector_prestashop/unit/exporter.py b/connector_prestashop/unit/exporter.py new file mode 100644 index 000000000..52f4942cf --- /dev/null +++ b/connector_prestashop/unit/exporter.py @@ -0,0 +1,350 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging +from contextlib import contextmanager + +import psycopg2 + + +from odoo import _, exceptions +from odoo.addons.queue_job.job import job +from odoo.addons.queue_job.job import related_action +from odoo.addons.connector.unit.synchronizer import Exporter +from odoo.addons.connector.exception import RetryableJobError +from .mapper import TranslationPrestashopExportMapper + + +_logger = logging.getLogger(__name__) + + +# Exporters for PrestaShop. +# In addition to its export job, an exporter has to: +# * check in PrestaShop if the record has been updated more recently than the +# last sync date and if yes, delay an import +# * call the ``bind`` method of the binder to update the last sync date + + +class PrestashopBaseExporter(Exporter): + """ Base exporter for PrestaShop """ + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(PrestashopBaseExporter, self).__init__(environment) + self.prestashop_id = None + self.binding_id = None + + def _get_binding(self): + """ Return the raw Odoo data for ``self.binding_id`` """ + return self.model.browse(self.binding_id) + + def run(self, binding_id, *args, **kwargs): + """ Run the synchronization + + :param binding_id: identifier of the binding record to export + """ + self.binding_id = binding_id + self.binding = self._get_binding() + self.prestashop_id = self.binder.to_external(self.binding) + result = self._run(*args, **kwargs) + + self.binder.bind(self.prestashop_id, self.binding) + # commit so we keep the external ID if several cascading exports + # are called and one of them fails + self.session.commit() + self._after_export() + return result + + def _run(self, *args, **kwargs): + """ Flow of the synchronization, implemented in inherited classes""" + raise NotImplementedError + + def _after_export(self): + """Create records of dependants prestashop objects""" + return + + +class PrestashopExporter(PrestashopBaseExporter): + """ A common flow for the exports to PrestaShop """ + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(PrestashopExporter, self).__init__(environment) + self.binding = None + + def _has_to_skip(self): + """ Return True if the export can be skipped """ + return False + + @contextmanager + def _retry_unique_violation(self): + """ Context manager: catch Unique constraint error and retry the + job later. + + When we execute several jobs workers concurrently, it happens + that 2 jobs are creating the same record at the same time (binding + record created by :meth:`_export_dependency`), resulting in: + + IntegrityError: duplicate key value violates unique + constraint "prestashop_product_template_openerp_uniq" + DETAIL: Key (backend_id, openerp_id)=(1, 4851) already exists. + + In that case, we'll retry the import just later. + + """ + try: + yield + except psycopg2.IntegrityError as err: + if err.pgcode == psycopg2.errorcodes.UNIQUE_VIOLATION: + raise RetryableJobError( + 'A database error caused the failure of the job:\n' + '%s\n\n' + 'Likely due to 2 concurrent jobs wanting to create ' + 'the same record. The job will be retried later.' % err) + else: + raise + + def _get_or_create_binding( + self, relation, binding_model, + binding_field_name='prestashop_bind_ids', + bind_values=None): + binding = None + # wrap is typically True if the relation is a 'product.product' + # record but the binding model is 'prestashop.product.product' + wrap = relation._model._name != binding_model + if wrap and hasattr(relation, binding_field_name): + domain = [(self._openerp_field, '=', relation.id), + ('backend_id', '=', self.backend_record.id)] + model = self.env[binding_model].with_context(active_test=False) + binding = model.search(domain) + if binding: + binding.ensure_one() + else: + # we are working with a unwrapped record (e.g. + # product.template) and the binding does not exist yet. + # Example: I created a product.product and its binding + # prestashop.product.product, it is exported, but we need to + # create the binding for the template. + + _bind_values = {'backend_id': self.backend_record.id, + self._openerp_field: relation.id} + _bind_values.update(bind_values or {}) + # If 2 jobs create it at the same time, retry + # one later. A unique constraint (backend_id, + # odoo_id) should exist on the binding model + with self._retry_unique_violation(): + model_c = self.env[binding_model].sudo().with_context( + connector_no_export=True + ) + binding = model_c.create(_bind_values) + # Eager commit to avoid having 2 jobs + # exporting at the same time. + self.session.commit() + else: + # If prestashop_bind_ids does not exist we are typically in a + # "direct" binding (the binding record is the same record). + # If wrap is True, relation is already a binding record. + binding = relation + return binding + + def _export_dependency(self, relation, binding_model, + exporter_class=None, + binding_field_name='prestashop_bind_ids', + bind_values=None, force_sync=False): + """ + Export a dependency. The exporter class is a subclass of + ``PrestashopExporter``. A more precise class can be defined. + + When a binding does not exist yet, it is automatically created. + + .. warning:: a commit is done at the end of the export of each + dependency. The reason for that is that we pushed a record + on the backend and we absolutely have to keep its ID. + + So you *must* take care to not modify the Odoo database + except when writing back the external ID or eventual + external data to keep on this side. + + You should call this method only in the beginning of the + exporter synchronization (in `~._export_dependencies`) + and do not write data which should be rollbacked in case + of error. + + :param relation: record to export if not already exported + :type relation: :py:class:`openerp.models.BaseModel` + :param binding_model: name of the binding model for the relation + :type binding_model: str | unicode + :param exporter_cls: :py:class:`openerp.addons.connector.\ + connector.ConnectorUnit` + class or parent class to use for the export. + By default: PrestashopExporter + :type exporter_cls: :py:class:`openerp.addons.connector.\ + connector.MetaConnectorUnit` + :param binding_field_name: name of the one2many towards the bindings + default is 'prestashop_bind_ids' + :type binding_field_name: str | unicode + :param bind_values: override values used to create a new binding + :type bind_values: dict + :param force_sync: force update of already sync'ed item + :type force_sync: bool + """ + if not relation: + return + + binding = self._get_or_create_binding( + relation, binding_model, + binding_field_name=binding_field_name, + bind_values=bind_values) + + rel_binder = self.binder_for(binding_model) + + if not rel_binder.to_external(binding) or force_sync: + exporter = self.unit_for( + exporter_class or PrestashopExporter, binding_model) + exporter.run(binding.id) + return binding + + def _export_dependencies(self): + """ Export the dependencies for the record""" + return + + def _map_data(self): + """ Convert the external record to Odoo """ + return self.mapper.map_record(self.binding) + + def _validate_data(self, data): + """ Check if the values to import are correct + + Pro-actively check before the ``Model.create`` or + ``Model.update`` if some fields are missing + + Raise `InvalidDataError` + """ + return + + def _create(self, data): + """ Create the PrestaShop record """ + return self.backend_adapter.create(data) + + def _update(self, data): + """ Update an PrestaShop record """ + assert self.prestashop_id + return self.backend_adapter.write(self.prestashop_id, data) + + def _lock(self): + """ Lock the binding record. + + Lock the binding record so we are sure that only one export + job is running for this record if concurrent jobs have to export the + same record. + + When concurrent jobs try to export the same record, the first one + will lock and proceed, the others will fail to lock and will be + retried later. + + This behavior works also when the export becomes multilevel + with :meth:`_export_dependencies`. Each level will set its own lock + on the binding record it has to export. + + Uses "NO KEY UPDATE", to avoid FK accesses + being blocked in PSQL > 9.3. + """ + sql = ("SELECT id FROM %s WHERE ID = %%s FOR NO KEY UPDATE NOWAIT" % + self.model._table) + try: + self.env.cr.execute(sql, (self.binding_id,), + log_exceptions=False) + except psycopg2.OperationalError: + _logger.info('A concurrent job is already exporting the same ' + 'record (%s with id %s). Job delayed later.', + self.model._name, self.binding_id) + raise RetryableJobError( + 'A concurrent job is already exporting the same record ' + '(%s with id %s). The job will be retried later.' % + (self.model._name, self.binding_id)) + + def _run(self, fields=None, **kwargs): + """ Flow of the synchronization, implemented in inherited classes""" + assert self.binding_id + assert self.binding + + if not self.binding.exists(): + return _('Record to export does no longer exist.') + + if self._has_to_skip(): + return + + # export the missing linked resources + self._export_dependencies() + + # prevent other jobs to export the same record + # will be released on commit (or rollback) + self._lock() + + map_record = self._map_data() + + if self.prestashop_id: + record = map_record.values() + if not record: + return _('Nothing to export.') + # special check on data before export + self._validate_data(record) + self._update(record) + else: + record = map_record.values(for_create=True) + if not record: + return _('Nothing to export.') + # special check on data before export + self._validate_data(record) + self.prestashop_id = self._create(record) + if self.prestashop_id == 0: + raise exceptions.Warning( + _("Record on PrestaShop have not been created")) + + message = _('Record exported with ID %s on PrestaShop.') + return message % self.prestashop_id + + +class TranslationPrestashopExporter(PrestashopExporter): + + @property + def mapper(self): + if self._mapper is None: + self._mapper = self.connector_env.get_connector_unit( + TranslationPrestashopExportMapper) + return self._mapper + + +def related_action_record(session, job): + binding_model = job.args[0] + binding_id = job.args[1] + record = session.env[binding_model].browse(binding_id) + odoo_name = record.odoo_id._name + + action = { + 'name': _(odoo_name), + 'type': 'ir.actions.act_window', + 'res_model': odoo_name, + 'view_type': 'form', + 'view_mode': 'form', + 'res_id': record.odoo_id.id, + } + return action + + +@job(default_channel='root.prestashop') +@related_action(action=related_action_record) +def export_record(session, model_name, binding_id, fields=None, **kwargs): + """ Export a record on PrestaShop """ + # TODO: FIX PRESTASHOP do not support partial edit + fields = None + record = session.env[model_name].browse(binding_id) + env = record.backend_id.get_environment(model_name, session=session) + exporter = env.get_connector_unit(PrestashopExporter) + return exporter.run(binding_id, fields=fields, **kwargs) diff --git a/connector_prestashop/unit/importer.py b/connector_prestashop/unit/importer.py new file mode 100644 index 000000000..71eb7f489 --- /dev/null +++ b/connector_prestashop/unit/importer.py @@ -0,0 +1,504 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +import logging +from contextlib import closing, contextmanager + +import odoo +from odoo import _ + +from odoo.addons.queue_job.job import job +from odoo.addons.connector.unit.synchronizer import Importer +from odoo.addons.connector.connector import ConnectorUnit, Binder +from odoo.addons.connector.connector import ConnectorEnvironment +from odoo.addons.queue_job.exception import ( + RetryableJobError, + FailedJobError, +) + + +_logger = logging.getLogger(__name__) + +RETRY_ON_ADVISORY_LOCK = 1 # seconds +RETRY_WHEN_CONCURRENT_DETECTED = 1 # seconds + + +class PrestashopBaseImporter(Importer): + + def _import_dependency(self, prestashop_id, binding_model, + importer_class=None, always=False, + **kwargs): + """ + Import a dependency. The importer class is a subclass of + ``PrestashopImporter``. A specific class can be defined. + + :param prestashop_id: id of the prestashop id to import + :param binding_model: name of the binding model for the relation + :type binding_model: str | unicode + :param importer_cls: :py:class:`openerp.addons.connector.\ + connector.ConnectorUnit` + class or parent class to use for the export. + By default: PrestashopImporter + :type importer_cls: :py:class:`openerp.addons.connector.\ + connector.MetaConnectorUnit` + :param always: if True, the record is updated even if it already + exists, + it is still skipped if it has not been modified on + PrestaShop + :type always: boolean + :param kwargs: additional keyword arguments are passed to the importer + """ + if not prestashop_id: + return + if importer_class is None: + importer_class = PrestashopImporter + binder = self.binder_for(binding_model) + if always or not binder.to_internal(prestashop_id): + importer = self.unit_for(importer_class, model=binding_model) + importer.run(prestashop_id, **kwargs) + + +class PrestashopImporter(PrestashopBaseImporter): + """ Base importer for PrestaShop """ + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(PrestashopImporter, self).__init__(environment) + self.prestashop_id = None + self.prestashop_record = None + + def _get_prestashop_data(self): + """ Return the raw prestashop data for ``self.prestashop_id`` """ + return self.backend_adapter.read(self.prestashop_id) + + def _has_to_skip(self): + """ Return True if the import can be skipped """ + return False + + def _import_dependencies(self): + """ Import the dependencies for the record""" + return + + def _map_data(self): + """ Returns an instance of + :py:class:`~openerp.addons.connector.unit.mapper.MapRecord` + + """ + return self.mapper.map_record(self.prestashop_record) + + def _validate_data(self, data): + """ Check if the values to import are correct + + Pro-actively check before the ``Model.create`` or + ``Model.update`` if some fields are missing + + Raise `InvalidDataError` + """ + return + + def _get_binding(self): + """Return the openerp id from the prestashop id""" + return self.binder.to_internal(self.prestashop_id) + + def _context(self, **kwargs): + return dict(self.session.context, connector_no_export=True, **kwargs) + + def _create_context(self): + return {'connector_no_export': True} + + def _create_data(self, map_record): + return map_record.values(for_create=True) + + def _update_data(self, map_record): + return map_record.values() + + def _create(self, data): + """ Create the OpenERP record """ + # special check on data before import + self._validate_data(data) + binding = self.model.with_context( + **self._create_context() + ).create(data) + _logger.debug( + '%d created from prestashop %s', binding, self.prestashop_id) + return binding + + def _update(self, binding, data): + """ Update an OpenERP record """ + # special check on data before import + self._validate_data(data) + binding.with_context(connector_no_export=True).write(data) + _logger.debug( + '%d updated from prestashop %s', binding, self.prestashop_id) + return + + def _before_import(self): + """ Hook called before the import, when we have the PrestaShop + data""" + return + + def _after_import(self, binding): + """ Hook called at the end of the import """ + return + + @contextmanager + def do_in_new_connector_env(self, model_name=None): + """ Context manager that yields a new connector environment + + Using a new Odoo Environment thus a new PG transaction. + + This can be used to make a preemptive check in a new transaction, + for instance to see if another transaction already made the work. + """ + with odoo.api.Environment.manage(): + registry = odoo.modules.registry.RegistryManager.get( + self.env.cr.dbname + ) + with closing(registry.cursor()) as cr: + try: + new_env = odoo.api.Environment(cr, self.env.uid, + self.env.context) + connector_env = self.connector_env.create_environment( + self.backend_record.with_env(new_env), + model_name or self.model._name, + connector_env=self.connector_env + ) + yield connector_env + except: + cr.rollback() + raise + else: + # Despite what pylint says, this a perfectly valid + # commit (in a new cursor). Disable the warning. + cr.commit() # pylint: disable=invalid-commit + + def _check_in_new_connector_env(self): + with self.do_in_new_connector_env() as new_connector_env: + # Even when we use an advisory lock, we may have + # concurrent issues. + # Explanation: + # We import Partner A and B, both of them import a + # partner category X. + # + # The squares represent the duration of the advisory + # lock, the transactions starts and ends on the + # beginnings and endings of the 'Import Partner' + # blocks. + # T1 and T2 are the transactions. + # + # ---Time---> + # > T1 /------------------------\ + # > T1 | Import Partner A | + # > T1 \------------------------/ + # > T1 /-----------------\ + # > T1 | Imp. Category X | + # > T1 \-----------------/ + # > T2 /------------------------\ + # > T2 | Import Partner B | + # > T2 \------------------------/ + # > T2 /-----------------\ + # > T2 | Imp. Category X | + # > T2 \-----------------/ + # + # As you can see, the locks for Category X do not + # overlap, and the transaction T2 starts before the + # commit of T1. So no lock prevents T2 to import the + # category X and T2 does not see that T1 already + # imported it. + # + # The workaround is to open a new DB transaction at the + # beginning of each import (e.g. at the beginning of + # "Imp. Category X") and to check if the record has been + # imported meanwhile. If it has been imported, we raise + # a Retryable error so T2 is rollbacked and retried + # later (and the new T3 will be aware of the category X + # from the its inception). + binder = new_connector_env.get_connector_unit(Binder) + if binder.to_internal(self.prestashop_id): + raise RetryableJobError( + 'Concurrent error. The job will be retried later', + seconds=RETRY_WHEN_CONCURRENT_DETECTED, + ignore_retry=True + ) + + def run(self, prestashop_id, **kwargs): + """ Run the synchronization + + :param prestashop_id: identifier of the record on PrestaShop + """ + self.prestashop_id = prestashop_id + lock_name = 'import({}, {}, {}, {})'.format( + self.backend_record._name, + self.backend_record.id, + self.model._name, + self.prestashop_id, + ) + # Keep a lock on this import until the transaction is committed + self.advisory_lock_or_retry(lock_name, + retry_seconds=RETRY_ON_ADVISORY_LOCK) + if not self.prestashop_record: + self.prestashop_record = self._get_prestashop_data() + + binding = self._get_binding() + if not binding: + self._check_in_new_connector_env() + + skip = self._has_to_skip() + if skip: + return skip + + # import the missing linked resources + self._import_dependencies() + + self._import(binding, **kwargs) + + def _import(self, binding, **kwargs): + """ Import the external record. + + Can be inherited to modify for instance the session + (change current user, values in context, ...) + + """ + + map_record = self._map_data() + + if binding: + record = self._update_data(map_record) + else: + record = self._create_data(map_record) + + # special check on data before import + self._validate_data(record) + + if binding: + self._update(binding, record) + else: + binding = self._create(record) + + self.binder.bind(self.prestashop_id, binding) + + self._after_import(binding) + + +class BatchImporter(Importer): + """ The role of a BatchImporter is to search for a list of + items to import, then it can either import them directly or delay + the import of each item separately. + """ + page_size = 1000 + + def run(self, filters=None, **kwargs): + """ Run the synchronization """ + if filters is None: + filters = {} + if 'limit' in filters: + self._run_page(filters, **kwargs) + return + page_number = 0 + filters['limit'] = '%d,%d' % ( + page_number * self.page_size, self.page_size) + record_ids = self._run_page(filters, **kwargs) + while len(record_ids) == self.page_size: + page_number += 1 + filters['limit'] = '%d,%d' % ( + page_number * self.page_size, self.page_size) + record_ids = self._run_page(filters, **kwargs) + + def _run_page(self, filters, **kwargs): + record_ids = self.backend_adapter.search(filters) + + for record_id in record_ids: + self._import_record(record_id, **kwargs) + return record_ids + + def _import_record(self, record): + """ Import a record directly or delay the import of the record """ + raise NotImplementedError + + +# TODO 2016-10-25: is this used at all somewhere??? +class AddCheckpoint(ConnectorUnit): + """ Add a connector.checkpoint on the underlying model + (not the prestashop.* but the _inherits'ed model) """ + + _model_name = [] + + def run(self, binding_id): + record = self.model.browse(binding_id) + self.backend_record.add_checkpoint( + session=self.session, + model=record._model._name, + record_id=record.id, + ) + + +class DirectBatchImporter(BatchImporter): + """ Import the PrestaShop Shop Groups + Shops + + They are imported directly because this is a rare and fast operation, + performed from the UI. + """ + _model_name = None + + def _import_record(self, record): + """ Import the record directly """ + self.env[self.model._name].with_delay().import_record( + backend=self.backend_record, + prestashop_id=record) + + +class DelayedBatchImporter(BatchImporter): + """ Delay import of the records """ + _model_name = None + + def _import_record(self, record, **kwargs): + """ Delay the import of the records""" + self.env[self.model._name].with_delay().import_record( + backend=self.backend_record, + prestashop_id=record, + **kwargs) + + +class TranslatableRecordImporter(PrestashopImporter): + """ Import one translatable record """ + _model_name = [] + + _translatable_fields = {} + # TODO set default language on the backend + _default_language = 'en_US' + + def __init__(self, environment): + """ + :param environment: current environment (backend, session, ...) + :type environment: :py:class:`connector.connector.ConnectorEnvironment` + """ + super(TranslatableRecordImporter, self).__init__(environment) + self.main_lang_data = None + self.main_lang = None + self.other_langs_data = None + + def _get_odoo_language(self, prestashop_id): + language_binder = self.binder_for('prestashop.res.lang') + erp_language = language_binder.to_internal(prestashop_id) + return erp_language + + def find_each_language(self, record): + languages = {} + for field in self._translatable_fields[self.connector_env.model_name]: + # TODO FIXME in prestapyt + if not isinstance(record[field]['language'], list): + record[field]['language'] = [record[field]['language']] + for language in record[field]['language']: + if not language or language['attrs']['id'] in languages: + continue + erp_lang = self._get_odoo_language(language['attrs']['id']) + if erp_lang: + languages[language['attrs']['id']] = erp_lang.code + return languages + + def _split_per_language(self, record, fields=None): + """Split record values by language. + + @param record: a record from PS + @param fields: fields whitelist + @return a dictionary with the following structure: + + 'en_US': { + 'field1': value_en, + 'field2': value_en, + }, + 'it_IT': { + 'field1': value_it, + 'field2': value_it, + } + """ + split_record = {} + languages = self.find_each_language(record) + if not languages: + raise FailedJobError( + _('No language mapping defined. ' + 'Run "Synchronize base data".') + ) + model_name = self.connector_env.model_name + for language_id, language_code in languages.iteritems(): + split_record[language_code] = record.copy() + _fields = self._translatable_fields[model_name] + if fields: + _fields = [x for x in _fields if x in fields] + for field in _fields: + for language in record[field]['language']: + current_id = language['attrs']['id'] + code = languages.get(current_id) + if not code: + # TODO: be nicer here. + # Currently if you have a language in PS + # that is not present in odoo + # the basic metadata sync is broken. + # We should present skip the language + # and maybe show a message to users. + raise FailedJobError( + _('No language could be found for the Prestashop lang ' + 'with id "%s". Run "Synchronize base data" again.') % + (current_id,) + ) + split_record[code][field] = language['value'] + return split_record + + def _create_context(self): + context = super(TranslatableRecordImporter, self)._create_context() + if self.main_lang: + context['lang'] = self.main_lang + return context + + def _map_data(self): + """ Returns an instance of + :py:class:`~openerp.addons.connector.unit.mapper.MapRecord` + + """ + return self.mapper.map_record(self.main_lang_data) + + def _import(self, binding, **kwargs): + """ Import the external record. + + Can be inherited to modify for instance the session + (change current user, values in context, ...) + + """ + # split prestashop data for every lang + split_record = self._split_per_language(self.prestashop_record) + if self._default_language in split_record: + self.main_lang_data = split_record[self._default_language] + self.main_lang = self._default_language + del split_record[self._default_language] + else: + self.main_lang, self.main_lang_data = split_record.popitem() + + self.other_langs_data = split_record + + super(TranslatableRecordImporter, self)._import(binding) + + def _after_import(self, binding): + """ Hook called at the end of the import """ + for lang_code, lang_record in self.other_langs_data.iteritems(): + map_record = self.mapper.map_record(lang_record) + binding.with_context( + lang=lang_code, + connector_no_export=True, + ).write(map_record.values()) + +# TODO: Remove when all imports has been changed +@job(default_channel='root.prestashop') +def import_batch(env, filters=None, **kwargs): + """ Prepare a batch import of records from PrestaShop """ + importer = env.get_connector_unit(BatchImporter) + return importer.run(filters=filters, **kwargs) + + +@job(default_channel='root.prestashop') +def import_record(env, model_name, backend_id, prestashop_id, **kwargs): + """ Import a record from PrestaShop """ + importer = env.get_connector_unit(PrestashopImporter) + return importer.run(prestashop_id, **kwargs) diff --git a/connector_prestashop/unit/mapper.py b/connector_prestashop/unit/mapper.py new file mode 100644 index 000000000..ce256f532 --- /dev/null +++ b/connector_prestashop/unit/mapper.py @@ -0,0 +1,128 @@ +# -*- coding: utf-8 -*- +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo.addons.connector.unit.mapper import ExportMapper +from odoo.addons.connector.unit.mapper import mapping + + +class PrestashopExportMapper(ExportMapper): + + def _map_direct(self, record, from_attr, to_attr): + res = super(PrestashopExportMapper, self)._map_direct(record, + from_attr, + to_attr) or '' + if isinstance(from_attr, basestring): + column = self.model._all_columns[from_attr].column + if column._type == 'boolean': + return res and 1 or 0 + elif column._type == 'float': + res = str(res) + return res + + +class TranslationPrestashopExportMapper(PrestashopExportMapper): + + @mapping + def translatable_fields(self, record): + fields = getattr(self, '_translatable_fields', []) + if fields: + translated_fields = self._convert_languages( + self._get_record_by_lang(record), fields) + return translated_fields + return {} + + def _get_record_by_lang(self, record): + # get the backend's languages + languages = self.backend_record.language_ids + records = {} + # for each languages: + for language in languages: + # get the translated record + record = record.with_context( + lang=language['code']) + # put it in the dict + records[language['prestashop_id']] = record + return records + + def _convert_languages(self, records_by_language, translatable_fields): + res = {} + for from_attr, to_attr in translatable_fields: + value = {'language': []} + for language_id, record in records_by_language.iteritems(): + value['language'].append({ + 'attrs': {'id': str(language_id)}, + 'value': record[from_attr] or '' + }) + res[to_attr] = value + return res + + +@prestashop +class MailMessageMapper(ImportMapper): + _model_name = 'prestashop.mail.message' + + direct = [ + ('message', 'body'), + ] + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def type(self, record): + return {'type': 'comment'} + + @mapping + def object_ref(self, record): + binder = self.binder_for('prestashop.sale.order') + order_id = binder.to_odoo(record['id_order'], unwrap=True) + return { + 'model': 'sale.order', + 'res_id': order_id, + } + + @mapping + def author_id(self, record): + if record['id_customer'] != '0': + binder = self.binder_for('prestashop.res.partner') + partner_id = binder.to_odoo(record['id_customer'], unwrap=True) + return {'author_id': partner_id} + return {} + + +@prestashop +class ProductPricelistMapper(ImportMapper): + _model_name = 'prestashop.groups.pricelist' + + direct = [ + ('name', 'name'), + ] + + @mapping + def static(self, record): + return {'active': True, 'type': 'sale'} + + @mapping + def backend_id(self, record): + return {'backend_id': self.backend_record.id} + + @mapping + def company_id(self, record): + return {'company_id': self.backend_record.company_id.id} + + @mapping + @only_create + def versions(self, record): + item = { + 'min_quantity': 0, + 'sequence': 5, + 'base': 1, + 'price_discount': - float(record['reduction']) / 100.0, + } + version = { + 'name': 'Version', + 'active': True, + 'items_id': [(0, 0, item)], + } + return {'version_id': [(0, 0, version)]} diff --git a/connector_prestashop/unit/version_key.py b/connector_prestashop/unit/version_key.py new file mode 100644 index 000000000..dcde1670d --- /dev/null +++ b/connector_prestashop/unit/version_key.py @@ -0,0 +1,59 @@ +# -*- coding: utf-8 -*- +# Copyright 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.connector.connector import ConnectorUnit +from ..backend import prestashop, prestashop_1_6_0_9, prestashop_1_6_1_2 + + +@prestashop +class VersionKey(ConnectorUnit): + _model_name = '_prestashop.version.key' + + keys = {} + + def get_key(self, key): + return self.keys.get(key) or key + + +@prestashop_1_6_0_9 +class VersionKey_1_6_0_9(VersionKey): + + keys = { + 'product_option_value': 'product_option_values', + 'category': 'categories', + 'order_slip': 'order_slips', + 'order_slip_detail': 'order_slip_details', + 'group': 'groups', + 'order_row': 'order_rows', + 'tax': 'taxes', + 'image': 'images', + 'combinations': 'combinations', + 'tag': 'tags', + 'manufacturers': 'manufacturers', + } + + +@prestashop_1_6_1_2 +class VersionKey_1_6_1_2(VersionKey): + + # keys checked in 1.6.1.9: + # * customer_messages + # * order_slip + # * order_slip_detail + + keys = { + 'product_option_value': 'product_option_value', + 'category': 'category', + 'image': 'image', + 'order_slip': 'order_slip', + 'order_slip_detail': 'order_slip_detail', + 'group': 'group', + 'order_row': 'order_rows', + 'tax': 'taxes', + 'combinations': 'combination', + 'product_features': 'product_feature', + 'tag': 'tag', + 'messages': 'customer_messages', + 'manufacturers': 'manufacturers', + } diff --git a/connector_prestashop/views/account_view.xml b/connector_prestashop/views/account_view.xml new file mode 100644 index 000000000..0c769d203 --- /dev/null +++ b/connector_prestashop/views/account_view.xml @@ -0,0 +1,52 @@ + + + + + + prestashop.account.tax.group + + + + + + + + + + account.tax.group + account.tax.group + + + + + + + + + + account.tax.group + +
+ + + + + + + +
+ + + Tax Groups + account.tax.group + form + tree,form + + + + +
diff --git a/connector_prestashop/views/connector_prestashop_menu.xml b/connector_prestashop/views/connector_prestashop_menu.xml new file mode 100644 index 000000000..5c1b02e4e --- /dev/null +++ b/connector_prestashop/views/connector_prestashop_menu.xml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + diff --git a/connector_prestashop/views/delivery_view.xml b/connector_prestashop/views/delivery_view.xml new file mode 100644 index 000000000..d68311d14 --- /dev/null +++ b/connector_prestashop/views/delivery_view.xml @@ -0,0 +1,50 @@ + + + + + prestashop.delivery.carrier + +
+

+ +

+ + + + + + + +
+ + + + + +
+
+
+ + + prestashop.delivery.carrier + + + + + + + + + + + + + + + PrestaShop Carriers + prestashop.delivery.carrier + form + tree,form + + +
diff --git a/connector_prestashop/views/image_view.xml b/connector_prestashop/views/image_view.xml new file mode 100644 index 000000000..fd81515ce --- /dev/null +++ b/connector_prestashop/views/image_view.xml @@ -0,0 +1,20 @@ + + + + + + Multi image prestashop binding form + prestashop.product.image + + + + + + + + + + + diff --git a/connector_prestashop/views/partner_view.xml b/connector_prestashop/views/partner_view.xml new file mode 100644 index 000000000..46726e1d1 --- /dev/null +++ b/connector_prestashop/views/partner_view.xml @@ -0,0 +1,136 @@ + + + + + + + res.partner.form + res.partner + + + + 0 + + + + + + + + + + + prestashop.res.partner.form + prestashop.res.partner + +
+ + + + + + + + + +
+
+
+ + + prestashop.res.partner.tree + prestashop.res.partner + + + + + + +

@@ -62,7 +71,7 @@ - +

By clicking on the buttons, From e8ababb225530c497ba7eb71eb8d482ae5131261 Mon Sep 17 00:00:00 2001 From: Benoit Date: Fri, 27 Apr 2018 17:10:10 +0200 Subject: [PATCH 12/99] [IMP+FIX] connector_prestashop: Refinements: * [IMP] migrate export of inventory, sale state and tracking number * [IMP] fixes and add no_export field * [FIX] listener * [FIX] temprorary remove unfinished fonctionality * [IMP] continue migration * [FIX] various fixes * [FIX] stock export --- connector_prestashop/__init__.py | 1 - connector_prestashop/components/__init__.py | 1 + .../components/backend_adapter.py | 2 +- connector_prestashop/components/deleter.py | 10 --- connector_prestashop/components/exporter.py | 49 +++---------- connector_prestashop/components/listener.py | 55 ++++++++++++++ connector_prestashop/components/mapper.py | 20 ++++- .../components/version_key.py | 4 +- connector_prestashop/consumer.py | 69 ------------------ connector_prestashop/models/__init__.py | 2 +- connector_prestashop/models/binding/common.py | 4 +- .../models/delivery_carrier/importer.py | 7 -- .../models/mail_message/common.py | 18 ++++- .../models/prestashop_backend/common.py | 22 +++--- .../models/product_image/common.py | 22 ++++-- .../models/product_product/common.py | 21 ++---- .../models/product_product/exporter.py | 20 +++-- .../models/product_product/importer.py | 6 +- .../models/product_template/common.py | 59 +++++++++++++-- .../models/product_template/exporter.py | 46 ++++-------- .../models/product_template/importer.py | 17 +---- .../models/sale_order/common.py | 73 ++++++++++++++++--- .../models/sale_order/importer.py | 22 ++++-- .../models/sale_order_state/common.py | 10 +-- .../models/sale_order_state/exporter.py | 41 +++-------- .../models/stock_move/common.py | 11 +++ .../models/stock_tracking/exporter.py | 36 +++------ .../security/ir.model.access.csv | 12 ++- .../views/prestashop_backend_view.xml | 9 ++- connector_prestashop/views/product_view.xml | 6 +- 30 files changed, 359 insertions(+), 316 deletions(-) create mode 100644 connector_prestashop/components/listener.py delete mode 100644 connector_prestashop/consumer.py diff --git a/connector_prestashop/__init__.py b/connector_prestashop/__init__.py index d1917fe6a..eefba89b7 100644 --- a/connector_prestashop/__init__.py +++ b/connector_prestashop/__init__.py @@ -3,7 +3,6 @@ from . import backend from . import connector -from . import consumer from . import components from . import models diff --git a/connector_prestashop/components/__init__.py b/connector_prestashop/components/__init__.py index aa3d50c54..5ffaedbf5 100644 --- a/connector_prestashop/components/__init__.py +++ b/connector_prestashop/components/__init__.py @@ -7,6 +7,7 @@ from . import binder from . import importer from . import exporter +from . import listener from . import mapper from . import deleter from . import auto_matching_importer diff --git a/connector_prestashop/components/backend_adapter.py b/connector_prestashop/components/backend_adapter.py index b0bf4cd62..e0f01fdba 100644 --- a/connector_prestashop/components/backend_adapter.py +++ b/connector_prestashop/components/backend_adapter.py @@ -122,7 +122,7 @@ def __init__(self, environment): self.prestashop.api_url, self.prestashop.webservice_key, debug=self.backend_record.debug, - verbose=self.backend_record.verbose +# verbose=self.backend_record.verbose ) def search(self, filters=None): diff --git a/connector_prestashop/components/deleter.py b/connector_prestashop/components/deleter.py index 8d2324188..0787e0101 100644 --- a/connector_prestashop/components/deleter.py +++ b/connector_prestashop/components/deleter.py @@ -24,13 +24,3 @@ def run(self, resource, external_id): self.backend_adapter.delete(resource, external_id) return _('Record %s deleted on PrestaShop on resource %s') % ( external_id, resource) - - -@job(default_channel='root.prestashop') -def export_delete_record( - session, model_name, backend_id, external_id, resource): - """ Delete a record on PrestaShop """ - backend = session.env['prestashop.backend'].browse(backend_id) - env = backend.get_environment(model_name, session=session) - deleter = env.get_connector_unit(PrestashopDeleter) - return deleter.run(resource, external_id) diff --git a/connector_prestashop/components/exporter.py b/connector_prestashop/components/exporter.py index 5e8e6a2b4..a4fe77a63 100644 --- a/connector_prestashop/components/exporter.py +++ b/connector_prestashop/components/exporter.py @@ -46,20 +46,20 @@ def _get_binding(self): """ Return the raw Odoo data for ``self.binding_id`` """ return self.model.browse(self.binding_id) - def run(self, binding_id, *args, **kwargs): + def run(self, binding, *args, **kwargs): """ Run the synchronization :param binding_id: identifier of the binding record to export """ - self.binding_id = binding_id - self.binding = self._get_binding() + self.binding_id = binding.id + self.binding = binding self.prestashop_id = self.binder.to_external(self.binding) result = self._run(*args, **kwargs) self.binder.bind(self.prestashop_id, self.binding) # commit so we keep the external ID if several cascading exports # are called and one of them fails - self._cr.commit() + self.env.cr.commit() self._after_export() return result @@ -325,42 +325,11 @@ def _run(self, fields=None, **kwargs): class TranslationPrestashopExporter(AbstractComponent): - _name = 'translation.prestashop.exporter' _inherit = 'prestashop.exporter' - @property - def mapper(self): - if self._mapper is None: - self._mapper = self.connector_env.get_connector_unit( - TranslationPrestashopExportMapper) - return self._mapper - - -def related_action_record(session, job): - binding_model = job.args[0] - binding_id = job.args[1] - record = session.env[binding_model].browse(binding_id) - odoo_name = record.odoo_id._name - - action = { - 'name': _(odoo_name), - 'type': 'ir.actions.act_window', - 'res_model': odoo_name, - 'view_type': 'form', - 'view_mode': 'form', - 'res_id': record.odoo_id.id, - } - return action - - -@job(default_channel='root.prestashop') -@related_action(action=related_action_record) -def export_record(session, model_name, binding_id, fields=None, **kwargs): - """ Export a record on PrestaShop """ - # TODO: FIX PRESTASHOP do not support partial edit - fields = None - record = session.env[model_name].browse(binding_id) - env = record.backend_id.get_environment(model_name, session=session) - exporter = env.get_connector_unit(PrestashopExporter) - return exporter.run(binding_id, fields=fields, **kwargs) +# @property +# def mapper(self): +# if self._mapper is None: +# self._mapper = self.component(usage='translation.export.mapper') +# return self._mapper diff --git a/connector_prestashop/components/listener.py b/connector_prestashop/components/listener.py new file mode 100644 index 000000000..e44a8f011 --- /dev/null +++ b/connector_prestashop/components/listener.py @@ -0,0 +1,55 @@ +# -*- coding: utf-8 -*- +# Copyright 2013-2017 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) +import logging +from odoo.addons.component.core import AbstractComponent + +_logger = logging.getLogger(__name__) + + +class PrestashopListener(AbstractComponent): + """ Base Backend Adapter for the connectors """ + + _name = 'prestashop.connector.listener' + _inherit = 'base.connector.listener' + + def need_to_export(self, record, fields=None): + """ Check if the record has to be exported to prestashop. + It depends on the written fields and if the record has flag no_export + + To be used with :func:`odoo.addons.component_event.skip_if` + on Events:: + + from odoo.addons.component.core import Component + from odoo.addons.component_event import skip_if + + + class MyEventListener(Component): + _name = 'my.event.listener' + _inherit = 'base.connector.event.listener' + _apply_on = ['magento.res.partner'] + + @skip_if(lambda: self, record, *args, **kwargs: + self.need_to_export(record, fields=fields)) + def on_record_write(self, record, fields=None): + record.with_delay().export_record() + + """ + if not record or not record.backend_id: + return True + with record.backend_id.work_on(record._name) as work: + mapper = work.component(usage='export.mapper') + exported_fields = mapper.changed_by_fields() + if fields: + if not exported_fields & set(fields): + _logger.debug( + "Skip export of %s because modified fields: %s are not part " + "of exported fields %s", + record, fields, list(exported_fields)) + return True + if record.no_export: + _logger.debug( + "Skip export of %s because export is disable for it", + record) + return True + return False diff --git a/connector_prestashop/components/mapper.py b/connector_prestashop/components/mapper.py index 12dfbf5e3..4a57f6d94 100644 --- a/connector_prestashop/components/mapper.py +++ b/connector_prestashop/components/mapper.py @@ -26,10 +26,10 @@ def _map_direct(self, record, from_attr, to_attr): from_attr, to_attr) or '' if isinstance(from_attr, basestring): - column = self.model._all_columns[from_attr].column - if column._type == 'boolean': + column = self.model.fields_get()[from_attr] + if column['type'] == 'boolean': return res and 1 or 0 - elif column._type == 'float': + elif column['type'] == 'float': res = str(res) return res @@ -37,6 +37,19 @@ def _map_direct(self, record, from_attr, to_attr): class TranslationPrestashopExportMapper(AbstractComponent): _name = 'translation.prestashop.export.mapper' _inherit = 'prestashop.export.mapper' +# _usage = 'translation.export.mapper' + + def changed_by_fields(self): + """ Build a set of fields used by the mapper + + It adds the translatable fields in the set. + """ + changed_by = super(TranslationPrestashopExportMapper, self).changed_by_fields() + if getattr(self, '_translatable_fields', None): + for from_attr, __ in self._translatable_fields: + fieldname = self._direct_source_field_name(from_attr) + changed_by.add(fieldname) + return changed_by @mapping def translatable_fields(self, record): @@ -70,6 +83,7 @@ def _convert_languages(self, records_by_language, translatable_fields): 'value': record[from_attr] or '' }) res[to_attr] = value + return res diff --git a/connector_prestashop/components/version_key.py b/connector_prestashop/components/version_key.py index 049f17599..b72b709ca 100644 --- a/connector_prestashop/components/version_key.py +++ b/connector_prestashop/components/version_key.py @@ -24,7 +24,9 @@ class VersionKey(ConnectorUnit): _model_name = '_prestashop.version.key' >>>>>>> e218fce... ADD WIP for PR Akretion - keys = {} + keys = { + 'messages': 'customer_messages', + } def get_key(self, key): return self.keys.get(key) or key diff --git a/connector_prestashop/consumer.py b/connector_prestashop/consumer.py deleted file mode 100644 index 6e43a5b1d..000000000 --- a/connector_prestashop/consumer.py +++ /dev/null @@ -1,69 +0,0 @@ -# -*- coding: utf-8 -*- -# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) - - -from odoo.addons.connector.event import on_record_write -from odoo.addons.connector_ecommerce.models.event import ( - on_tracking_number_added, -) -from .models.sale_order_state.exporter import export_sale_state -from .models.stock_tracking.exporter import export_tracking_number - -def delay_export(session, model_name, record_id, fields=None, priority=20): - """ Delay a job which export a binding record. - - (A binding record being a ``external.res.partner``, - ``external.product.product``, ...) - """ - if session.context.get('connector_no_export'): - return - export_record.delay( - session, model_name, record_id, fields=fields, priority=priority) - - -def delay_export_all_bindings( - session, model_name, record_id, fields=None, priority=20): - """ Delay a job which export all the bindings of a record. - -@on_record_write(model_names=[ - 'prestashop.product.template', - 'prestashop.product.combination' -]) -def prestashop_product_stock_updated( - env, model_name, record_id, fields=None): - if env.context.get('connector_no_export'): - return - inventory_fields = list(set(fields).intersection(INVENTORY_FIELDS)) - if inventory_fields: - env[model_name].browse(record_id).with_delay( - priority=20).export_inventory(fields=inventory_fields) - - -@on_record_write(model_names='sale.order') -def prestashop_sale_state_modified(env, model_name, record_id, - fields=None): - if 'state' in fields: - sale = env[model_name].browse(record_id) - if not sale.prestashop_bind_ids: - return - # a quick test to see if it is worth trying to export sale state - states = env['sale.order.state.list'].search( - [('name', '=', sale.state)] - ) - if states: - export_sale_state.delay(env, 'prestashop.sale.order', - record_id, priority=20) - - -@on_tracking_number_added -def delay_export_tracking_number(env, model_name, record_id): - """ - Call a job to export the tracking number to a existing picking that - must be in done state. - """ - picking = env['stock.picking'].browse(record_id) - for binding in picking.sale_id.prestashop_bind_ids: - export_tracking_number.delay(env, - binding._model._name, - binding.id, - priority=20) diff --git a/connector_prestashop/models/__init__.py b/connector_prestashop/models/__init__.py index aac20238c..df1c97da7 100644 --- a/connector_prestashop/models/__init__.py +++ b/connector_prestashop/models/__init__.py @@ -16,9 +16,9 @@ from . import product_category from . import product_image from . import product_pricelist +from . import product_template from . import product_product from . import product_supplierinfo -from . import product_template from . import res_country from . import res_currency from . import res_lang diff --git a/connector_prestashop/models/binding/common.py b/connector_prestashop/models/binding/common.py index b7eb1446d..248c2d32f 100644 --- a/connector_prestashop/models/binding/common.py +++ b/connector_prestashop/models/binding/common.py @@ -24,6 +24,7 @@ class PrestashopBinding(models.AbstractModel): default=True ) prestashop_id = fields.Integer('ID on PrestaShop') + no_export = fields.Boolean('No export to PrestaShop') _sql_constraints = [ ('prestashop_uniq', 'unique(backend_id, prestashop_id)', @@ -37,7 +38,6 @@ def check_active(self, backend): 'The job will be retried later.' % (backend.name,)) - @job(default_channel='root.prestashop') @api.model def import_record(self, backend, prestashop_id, force=False): @@ -64,7 +64,7 @@ def import_batch(self, backend, filters=None): def export_record(self, fields=None): """ Export a record on PrestaShop """ self.ensure_one() - self.check_active(backend) + self.check_active(self.backend_id) with self.backend_id.work_on(self._name) as work: exporter = work.component(usage='record.exporter') return exporter.run(self, fields) diff --git a/connector_prestashop/models/delivery_carrier/importer.py b/connector_prestashop/models/delivery_carrier/importer.py index 61f934307..4efc21b01 100644 --- a/connector_prestashop/models/delivery_carrier/importer.py +++ b/connector_prestashop/models/delivery_carrier/importer.py @@ -56,13 +56,6 @@ def id_reference(self, record): def active(self, record): return {'active_ext': record['active'] == '1'} - @mapping - def product_id(self, record): - if self.backend_record.shipping_product_id: - return {'product_id': self.backend_record.shipping_product_id.id} - product = self.env.ref('connector_ecommerce.product_product_shipping') - return {'product_id': product.id} - @mapping def backend_id(self, record): return {'backend_id': self.backend_record.id} diff --git a/connector_prestashop/models/mail_message/common.py b/connector_prestashop/models/mail_message/common.py index 479166085..72680e0a2 100644 --- a/connector_prestashop/models/mail_message/common.py +++ b/connector_prestashop/models/mail_message/common.py @@ -34,8 +34,22 @@ class MailMessageAdapter(Component): _inherit = 'prestashop.adapter' _apply_on = 'prestashop.mail.message' - _model_name = 'prestashop.mail.message' - @property def _prestashop_model(self): return self.backend_record.get_version_ps_key('messages') + + def read(self, id, attributes=None): + """ Merge message and thread datas + + :rtype: dict + """ + api = self.client + res = api.get(self._prestashop_model, id, options=attributes) + first_key = res.keys()[0] + message_data = res[first_key] + thread_data = api.get('customer_threads', message_data['id_customer_thread'], options=attributes) + first_key = thread_data.keys()[0] + del thread_data[first_key]['id'] + del thread_data[first_key]['date_add'] + message_data.update(thread_data[first_key]) + return message_data diff --git a/connector_prestashop/models/prestashop_backend/common.py b/connector_prestashop/models/prestashop_backend/common.py index 173f60fdf..31f6edba4 100644 --- a/connector_prestashop/models/prestashop_backend/common.py +++ b/connector_prestashop/models/prestashop_backend/common.py @@ -12,6 +12,7 @@ from ...components.version_key import VersionKey from ...backend import prestashop from odoo.addons.connector.checkpoint import checkpoint +from odoo.addons.base.res.res_partner import _tz_get _logger = logging.getLogger(__name__) @@ -147,8 +148,8 @@ def _select_state(self): matching_customer = fields.Boolean(string="Matching Customer", help="The selected fields will be matched to the ref field \ of the partner. Please adapt your datas consequently.") - matching_customer_ch = fields.Many2one(comodel_name='prestashop.partner.field' - , string="Matched field", help="Field that will be matched.") +# matching_customer_ch = fields.Many2one(comodel_name='prestashop.partner.field' +# , string="Matched field", help="Field that will be matched.") quantity_field = fields.Selection( @@ -161,29 +162,30 @@ def _select_state(self): modules you'll have to install by yourself from https://github.com/OCA/stock-logistics-warehouse/tree/10.0 """, - string='Field use for quantity update', - required=True, - default='virtual_available' + required=True, + default='virtual_available' ) + tz = fields.Selection(_tz_get, 'Timezone', size=64, + help="The timezone of the backend. Used to synchronize the sale order date.") @api.onchange("matching_customer") def change_matching_customer(self): #Update the field list so that if you API change you could find the new fields to map if self._origin.id: self.fill_matched_fields(self._origin.id) - - + + @api.multi def fill_matched_fields(self, backend_id): self.ensure_one() - + options={'limit': 1,'display': 'full'} #TODO : Unse new adapter pattern to get a simple partner json # prestashop = PrestaShopLocation( # self.location.encode(), # self.webservice_key, # ) -# +# # client = PrestaShopWebServiceDict( # prestashop.api_url, # prestashop.webservice_key) @@ -297,7 +299,7 @@ def update_product_stock_qty(self): for backend_record in self: backend_record.env['prestashop.product.template']\ .with_delay().export_product_quantities(backend=backend_record) - backend_record.env['prestashop.product.product']\ + backend_record.env['prestashop.product.combination']\ .with_delay().export_product_quantities(backend=backend_record) return True diff --git a/connector_prestashop/models/product_image/common.py b/connector_prestashop/models/product_image/common.py index 64f2c86c7..999d8ac71 100644 --- a/connector_prestashop/models/product_image/common.py +++ b/connector_prestashop/models/product_image/common.py @@ -2,6 +2,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) import base64 +from odoo.tools import config from odoo import models, fields, api from odoo.addons.queue_job.job import job from odoo.addons.component.core import Component @@ -54,9 +55,17 @@ class ProductImageAdapter(Component): _export_node_name = '/images/products' _export_node_name_res = 'image' + + def connect(self): + debug = False + if config['log_level'] == 'debug': + debug = True + return PrestaShopWebServiceImage(self.prestashop.api_url, + self.prestashop.webservice_key, + debug=debug) + def read(self, product_tmpl_id, image_id, options=None): - api = PrestaShopWebServiceImage(self.prestashop.api_url, - self.prestashop.webservice_key) + api = self.connect() return api.get_image( self._prestashop_image_model, product_tmpl_id, @@ -65,8 +74,7 @@ def read(self, product_tmpl_id, image_id, options=None): ) def create(self, attributes=None): - api = PrestaShopWebServiceImage( - self.prestashop.api_url, self.prestashop.webservice_key) + api = self.connect() # TODO: odoo logic in the adapter? :-( url = '{}/{}'.format(self._prestashop_model, attributes['id_product']) return api.add(url, files=[( @@ -76,8 +84,7 @@ def create(self, attributes=None): )]) def write(self, id, attributes=None): - api = PrestaShopWebServiceImage( - self.prestashop.api_url, self.prestashop.webservice_key) + api = self.connect() # TODO: odoo logic in the adapter? :-( url = '{}/{}'.format(self._prestashop_model, attributes['id_product']) url_del = '{}/{}/{}/{}'.format( @@ -94,6 +101,5 @@ def write(self, id, attributes=None): def delete(self, resource, id): """ Delete a record on the external system """ - api = PrestaShopWebServiceImage( - self.prestashop.api_url, self.prestashop.webservice_key) + api = self.connect() return api.delete(resource, resource_ids=id) diff --git a/connector_prestashop/models/product_product/common.py b/connector_prestashop/models/product_product/common.py index e7338c35b..d121d9574 100644 --- a/connector_prestashop/models/product_product/common.py +++ b/connector_prestashop/models/product_product/common.py @@ -14,12 +14,6 @@ class ProductProduct(models.Model): _inherit = 'product.product' - prestashop_bind_ids = fields.One2many( - comodel_name='prestashop.product.combination', - inverse_name='openerp_id', - copy=False, - string='PrestaShop Bindings', - ) prestashop_combinations_bind_ids = fields.One2many( comodel_name='prestashop.product.combination', inverse_name='odoo_id', @@ -62,8 +56,7 @@ def _compute_lst_price(self): # which could be not installed uom = hasattr(product, 'uos_id') \ and product.uos_id or product.uom_id - price = uom._compute_price( - product.uom_id.id, price, self.env.context['uom']) + price = uom._compute_price(price, product.uom_id) product.lst_price = price lst_price = fields.Float( @@ -178,18 +171,18 @@ def _prestashop_qty(self): return self.qty_available @job(default_channel='root.prestashop') - def export_inventory(self, backend, fields=None, **kwargs): + def export_inventory(self, fields=None): """ Export the inventory configuration and quantity of a product. """ - env = backend.get_environment(self._name) - inventory_exporter = env.get_connector_unit( - CombinationInventoryExporter) - return inventory_exporter.run(self.id, fields, **kwargs) + backend = self.backend_id + with backend.work_on('prestashop.product.combination') as work: + exporter = work.component(usage='inventory.exporter') + return exporter.run(self, fields) @api.model @job(default_channel='root.prestashop') def export_product_quantities(self, backend): self.search([ - ('backend_id', 'in', backend.ids), + ('backend_id', '=', backend.id), ]).recompute_prestashop_qty() @job(default_channel='root.prestashop') diff --git a/connector_prestashop/models/product_product/exporter.py b/connector_prestashop/models/product_product/exporter.py index 976cbfe2e..831dbfc1f 100644 --- a/connector_prestashop/models/product_product/exporter.py +++ b/connector_prestashop/models/product_product/exporter.py @@ -1,14 +1,22 @@ # -*- coding: utf-8 -*- # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) -from ..product_template.exporter import ProductInventoryExporter +from odoo.addons.component.core import Component -class CombinationInventoryExporter(ProductInventoryExporter): - _model_name = ['prestashop.product.combination'] +class CombinationInventoryExporter(Component): + _name = 'prestashop.product.combination.inventory.exporter' + _inherit = 'prestashop.product.template.inventory.exporter' + _apply_on = 'prestashop.product.combination' - def get_filter(self, template): + def get_filter(self, product): return { - 'filter[id_product]': template.main_template_id.prestashop_id, - 'filter[id_product_attribute]': template.prestashop_id, + 'filter[id_product]': product.main_template_id.prestashop_id, + 'filter[id_product_attribute]': product.prestashop_id, + } + + def get_quantity_vals(self, product): + return { + 'quantity': int(product.quantity), + 'out_of_stock': int(product.main_template_id.out_of_stock), } diff --git a/connector_prestashop/models/product_product/importer.py b/connector_prestashop/models/product_product/importer.py index 90e614776..8454792e8 100644 --- a/connector_prestashop/models/product_product/importer.py +++ b/connector_prestashop/models/product_product/importer.py @@ -280,7 +280,7 @@ def odoo_id(self, record): product = self.env['product.product'].search( [('default_code', '=', code)], limit=1) if product: - return {'openerp_id': product.id} + return {'odoo_id': product.id} if self.backend_record.matching_product_ch == 'barcode': if code: product = self.env['product.product'].search( @@ -418,6 +418,6 @@ def backend_id(self, record): class ProductProductBatchImporter(Component): - _name = 'prestashop.product.product.batch.importer' + _name = 'prestashop.product.combination.batch.importer' _inherit = 'prestashop.delayed.batch.importer' - _apply_on = 'prestashop.product.product' + _apply_on = 'prestashop.product.combination' diff --git a/connector_prestashop/models/product_template/common.py b/connector_prestashop/models/product_template/common.py index 5d3df474e..8a0667c05 100644 --- a/connector_prestashop/models/product_template/common.py +++ b/connector_prestashop/models/product_template/common.py @@ -8,7 +8,7 @@ from odoo.addons.queue_job.job import job from odoo.addons.component.core import Component -from exporter import ProductInventoryExporter +from odoo.addons.component_event import skip_if import logging @@ -42,7 +42,7 @@ def update_prestashop_quantities(self): template.mapped('prestashop_bind_ids').recompute_prestashop_qty() # Recompute variant PrestaShop qty template.mapped( - 'product_variant_ids.prestashop_bind_ids' + 'product_variant_ids.prestashop_combination_bind_ids' ).recompute_prestashop_qty() return True @@ -111,6 +111,12 @@ class PrestashopProductTemplate(models.Model): string='Cost Price', digits=dp.get_precision('Product Price'), ) + out_of_stock = fields.Selection( + [('0', 'Refuse order'), + ('1', 'Accept order'), + ('2', 'Default prestashop')], + string='If stock shortage' + ) @api.multi def recompute_prestashop_qty(self): @@ -130,11 +136,13 @@ def _recompute_prestashop_qty_backend(self, backend): self_loc = self.with_context(location=locations.ids, compute_child=False) for product in self_loc: - new_qty = product._prestashop_qty() - if product.quantity != new_qty: - product.quantity = new_qty + if product.type == 'product': + new_qty = product._prestashop_qty() + if product.quantity != new_qty: + product.quantity = new_qty return True + @api.multi def _prestashop_qty(self): return self.qty_available @@ -154,12 +162,27 @@ def import_products(self, backend, since_date=None, **kwargs): return True @job(default_channel='root.prestashop') - def import_inventory(sel, backend): + def import_inventory(self, backend): with backend.work_on('_import_stock_available') as work: importer = work.component(usage='batch.importer') return importer.run() + @job(default_channel='root.prestashop') + def export_inventory(self, fields=None): + """ Export the inventory configuration and quantity of a product. """ + backend = self.backend_id + with backend.work_on('prestashop.product.template') as work: + exporter = work.component(usage='inventory.exporter') + return exporter.run(self, fields) + + + @job(default_channel='root.prestashop') + def export_product_quantities(self, backend=None): + self.search([('backend_id', '=', backend.id)] + ).recompute_prestashop_qty() + + class TemplateAdapter(Component): _name = 'prestashop.product.template.adapter' _inherit = 'prestashop.adapter' @@ -202,7 +225,8 @@ def export_quantity_url(self, filters, quantity, client=None): res = client.get(self._prestashop_model, stock_id) first_key = res.keys()[0] stock = res[first_key] - stock['quantity'] = int(quantity) + stock['quantity'] = int(quantity['quantity']) + stock['out_of_stock'] = int(quantity['out_of_stock']) client.edit(self._prestashop_model, { self._export_node_name: stock }) @@ -229,3 +253,24 @@ def search(self, filters=None): if isinstance(tags, dict): return [tags] return tags + + +class PrestashopProductQuantityListener(Component): + _name = 'prestashop.product.quantity.listener' + _inherit = 'base.connector.listener' + _apply_on = ['prestashop.product.combination', 'prestashop.product.template'] + + def _get_inventory_fields(self): + # fields which should not trigger an export of the products + # but an export of their inventory + return ('quantity', 'out_of_stock') + + @skip_if(lambda self, record, **kwargs: self.no_connector_export(record)) + def on_record_write(self, record, fields=None): + inventory_fields = list( + set(fields).intersection(self._get_inventory_fields()) + ) + if inventory_fields: + record.with_delay(priority=20).export_inventory( + fields=inventory_fields + ) diff --git a/connector_prestashop/models/product_template/exporter.py b/connector_prestashop/models/product_template/exporter.py index 65c43ba1f..201effdf1 100644 --- a/connector_prestashop/models/product_template/exporter.py +++ b/connector_prestashop/models/product_template/exporter.py @@ -1,50 +1,34 @@ # -*- coding: utf-8 -*- # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) - -from odoo.addons.queue_job.job import job -from odoo.addons.connector.unit.synchronizer import Exporter - from odoo.addons.component.core import Component -class ProductInventoryExporter(Exporter): - _model_name = ['prestashop.product.template'] +class ProductInventoryExporter(Component): + _name = 'prestashop.product.template.inventory.exporter' + _inherit = 'prestashop.exporter' + _apply_on = 'prestashop.product.template' + _usage = 'inventory.exporter' def get_filter(self, template): binder = self.binder_for() - prestashop_id = binder.to_external(template.id) + prestashop_id = binder.to_external(template) return { 'filter[id_product]': prestashop_id, 'filter[id_product_attribute]': 0 } - def run(self, binding_id, fields, **kwargs): + def get_quantity_vals(self, template): + return { + 'quantity': int(template.quantity), + 'out_of_stock': int(template.out_of_stock), + } + + def run(self, template, fields): """ Export the product inventory to PrestaShop """ - template = self.model.browse(binding_id) adapter = self.component( usage='backend.adapter', model_name='_import_stock_available' ) filter = self.get_filter(template) - adapter.export_quantity(filter, int(template.quantity)) - - -# TODO: Remove because it has been moved to prestashop product template and -# prestashop product combination -@job(default_channel='root.prestashop') -def export_inventory(session, model_name, record_id, fields=None, **kwargs): - """ Export the inventory configuration and quantity of a product. """ - binding = session.env[model_name].browse(record_id) - backend = binding.backend_id - env = backend.get_environment(model_name, session=session) - inventory_exporter = env.get_connector_unit(ProductInventoryExporter) - return inventory_exporter.run(record_id, fields, **kwargs) - - -@job(default_channel='root.prestashop') -def export_product_quantities(session, ids): - for model in ['template', 'combination']: - model_obj = session.env['prestashop.product.' + model] - model_obj.search([ - ('backend_id', 'in', [ids]), - ]).recompute_prestashop_qty() + quantity_vals = self.get_quantity_vals(template) + adapter.export_quantity(filter, quantity_vals) diff --git a/connector_prestashop/models/product_template/importer.py b/connector_prestashop/models/product_template/importer.py index 936f8517c..e83cc5d9a 100644 --- a/connector_prestashop/models/product_template/importer.py +++ b/connector_prestashop/models/product_template/importer.py @@ -122,13 +122,10 @@ def odoo_id(self, record): # [('default_code', '=', record['reference'])], limit=1) # if product: # return {'odoo_id': product.id} - - if self.backend_record.matching_product_template: if self.has_combinations(record): #Browse combinations for matching products and find if there #is a potential template to be matched - template = self.env['product.template'] associations = record.get('associations', {}) combinations = associations.get('combinations', {}).get( @@ -141,17 +138,14 @@ def odoo_id(self, record): BackendAdapter, 'prestashop.product.combination') variant = backend_adapter.read(int(prod['id'])) code = variant.get(self.backend_record.matching_product_ch) - if self.backend_record.matching_product_ch == 'reference': product = self.env['product.product'].search( [('default_code', '=', code)]) - if len(product) > 1 : raise ValidationError(_('Error! Multiple products ' 'found with combinations reference %s.' 'Maybe consider to update you datas') % code) template |= product.product_tmpl_id - if self.backend_record.matching_product_ch == 'barcode': product = self.env['product.product'].search( [('barcode', '=', code)]) @@ -160,7 +154,6 @@ def odoo_id(self, record): 'found with combinations reference %s.' 'Maybe consider to update you datas') % code) template |= product.product_tmpl_id - _logger.debug('template %s' % template) if len(template) == 1: return {'odoo_id': template.id} @@ -168,10 +161,9 @@ def odoo_id(self, record): raise ValidationError(_('Error! Multiple templates are ' 'found with combinations reference.' 'Maybe consider to change matching option')) - else: code = record.get(self.backend_record.matching_product_ch) - if self.backend_record.matching_product_ch == 'reference': + if self.backend_record.matching_product_ch == 'reference': if code: if self._template_code_exists(code): product = self.env['product.template'].search( @@ -186,12 +178,7 @@ def odoo_id(self, record): [('barcode', '=', code)], limit=1) if product: return {'odoo_id': product.id} - - - return {} - - - + return {} def _template_code_exists(self, code): model = self.session.env['product.template'] diff --git a/connector_prestashop/models/sale_order/common.py b/connector_prestashop/models/sale_order/common.py index 918f1555a..94c73834f 100644 --- a/connector_prestashop/models/sale_order/common.py +++ b/connector_prestashop/models/sale_order/common.py @@ -2,9 +2,8 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). import openerp.addons.decimal_precision as dp - from odoo import models, fields, api, _ - +from odoo.addons.queue_job.job import job, related_action from odoo.addons.component.core import Component import logging @@ -76,20 +75,47 @@ def import_orders_since(self, backend, since_date=None, **kwargs): priority=5, max_retries=0).import_batch(backend, filters=filters) if since_date: filters = {'date': '1', 'filter[date_add]': '>[%s]' % since_date} -# try: -# self.env['prestashop.mail.message'].import_batch(backend, filters) -# except Exception as error: -# msg = _( -# 'Mail messages import failed with filters `%s`. ' -# 'Error: `%s`' -# ) % (str(filters), str(error)) -# backend.add_checkpoint( -# message=msg -# ) + self.env['prestashop.mail.message'].import_batch(backend, filters) backend.import_orders_since = now_fmt return True + @job(default_channel='root.prestashop') + @related_action(action='related_action_unwrap_binding') + @api.multi + def export_tracking_number(self): + """ Export the tracking number of a delivery order. """ + self.ensure_one() + with self.backend_id.work_on(self._name) as work: + exporter = work.component(usage='tracking.exporter') + return exporter.run(self) + + @api.multi + def find_prestashop_state(self): + self.ensure_one() + state_list_model = self.env['sale.order.state.list'] + state_lists = state_list_model.search( + [('name', '=', self.state)] + ) + for state_list in state_lists: + if state_list.prestashop_state_id.backend_id == self.backend_id: + return state_list.prestashop_state_id.prestashop_id + return None + + + @job(default_channel='root.prestashop') + @related_action(action='related_action_unwrap_binding') + @api.multi + def export_sale_state(self): + for sale in self: + backend = sale.backend_id + new_state = sale.find_prestashop_state() + if not new_state: + continue + with sale.backend_id.work_on(self._name) as work: + exporter = work.component(usage='sale.order.state.exporter') + return exporter.run(self, new_state) + class SaleOrderLine(models.Model): _inherit = 'sale.order.line' @@ -169,6 +195,11 @@ class OrderPaymentModel(models.TransientModel): _name = '__not_exist_prestashop.payment' +class OrderCarrierModel(models.TransientModel): + # In actual connector version is mandatory use a model + _name = '__not_exit_prestashop.order_carrier' + + class SaleOrderAdapter(Component): _name = 'prestashop.sale.order.adapter' _inherit = 'prestashop.adapter' @@ -199,3 +230,21 @@ class OrderDiscountAdapter(Component): _inherit = 'prestashop.adapter' _apply_on = 'prestashop.sale.order.line.discount' _prestashop_model = 'order_discounts' + + +class PrestashopSaleOrderListener(Component): + _name = 'prestashop.sale.order.listener' + _inherit = 'base.event.listener' + _apply_on = ['sale.order'] + + def on_record_write(self, record, fields=None): + if 'state' in fields: + if not record.prestashop_bind_ids: + return + # a quick test to see if it is worth trying to export sale state + states = self.env['sale.order.state.list'].search( + [('name', '=', record.state)] + ) + if states: + for binding in record.prestashop_bind_ids: + binding.with_delay(priority=20).export_sale_state() diff --git a/connector_prestashop/models/sale_order/importer.py b/connector_prestashop/models/sale_order/importer.py index 5367bb1ae..259b827d8 100644 --- a/connector_prestashop/models/sale_order/importer.py +++ b/connector_prestashop/models/sale_order/importer.py @@ -1,15 +1,13 @@ # -*- coding: utf-8 -*- # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) - +import pytz from odoo import _, fields -from odoo.addons.queue_job.job import job from odoo.addons.component.core import Component from odoo.addons.connector.components.mapper import mapping from odoo.addons.queue_job.exception import FailedJobError, NothingToDoJob from odoo.addons.connector_ecommerce.components.sale_order_onchange import ( SaleOrderOnChange, ) -from ...components.importer import import_batch from ...components.exception import OrderImportRuleRetry from datetime import datetime, timedelta @@ -145,7 +143,6 @@ class SaleOrderImportMapper(Component): _apply_on = 'prestashop.sale.order' direct = [ - ('date_add', 'date_order'), ('invoice_number', 'prestashop_invoice_number'), ('delivery_number', 'prestashop_delivery_number'), ('total_paid', 'total_amount'), @@ -275,6 +272,14 @@ def total_tax_amount(self, record): float(record['total_paid_tax_excl'])) return {'total_amount_tax': tax} + @mapping + def date_order(self, record): + local = pytz.timezone(self.backend_record.tz) + naive = fields.Datetime.from_string(record['date_add']) + local_dt = local.localize(naive, is_dst=None) + date_order = fields.Datetime.to_string(local_dt.astimezone(pytz.utc)) + return {'date_order': date_order} + def finalize(self, map_record, values): onchange = self.component('ecommerce.onchange.manager.sale.order') return onchange.play(values, values['prestashop_order_line_ids']) @@ -339,6 +344,12 @@ def _add_shipping_line(self, binding): ) binding.odoo_id.recompute() + def _create(self, data): + binding = super(SaleOrderImporter, self)._create(data) + if binding.fiscal_position_id: + binding.odoo_id._compute_tax_id() + return binding + def _after_import(self, binding): super(SaleOrderImporter, self)._after_import(binding) self._add_shipping_line(binding) @@ -418,7 +429,8 @@ def product_id(self, record): template = binder.to_internal(record['product_id'], unwrap=True) product = self.env['product.product'].search([ ('product_tmpl_id', '=', template.id), - ('company_id', '=', self.backend_record.company_id.id)], + '|', ('company_id', '=', self.backend_record.company_id.id), + ('company_id', '=', False)], limit=1, ) if not product: diff --git a/connector_prestashop/models/sale_order_state/common.py b/connector_prestashop/models/sale_order_state/common.py index 8102a1711..30571fdf5 100644 --- a/connector_prestashop/models/sale_order_state/common.py +++ b/connector_prestashop/models/sale_order_state/common.py @@ -48,12 +48,12 @@ class SaleOrderStateList(models.Model): _name = 'sale.order.state.list' name = fields.Selection( - [ + selection=[ ('draft', 'Quotation'), ('sent', 'Quotation Sent'), + ('sale', 'Sales Order'), + ('done', 'Locked'), ('cancel', 'Cancelled'), - ('sale', 'Sale Order'), - ('done', 'Done') ], string='Odoo Sales State', required=True, @@ -74,6 +74,6 @@ class SaleOrderStateAdapter(Component): _name = 'prestashop.sale.order.state.adapter' _inherit = 'prestashop.adapter' _apply_on = 'prestashop.sale.order.state' - - + + _prestashop_model = 'order_states' diff --git a/connector_prestashop/models/sale_order_state/exporter.py b/connector_prestashop/models/sale_order_state/exporter.py index 13d104f46..9ac9f7e48 100644 --- a/connector_prestashop/models/sale_order_state/exporter.py +++ b/connector_prestashop/models/sale_order_state/exporter.py @@ -3,42 +3,21 @@ from odoo.addons.queue_job.job import job -from odoo.addons.connector.unit.synchronizer import Exporter +from odoo.addons.component.core import Component -class SaleStateExporter(Exporter): - _model_name = ['prestashop.sale.order'] +class SaleStateExporter(Component): + _name = 'prestashop.sale.order.state.exporter' + _inherit = 'prestashop.exporter' + _apply_on = ['prestashop.sale.order'] + _usage = 'sale.order.state.exporter' - def run(self, prestashop_id, state, **kwargs): + + def run(self, binding, state, **kwargs): datas = { 'order_history': { - 'id_order': prestashop_id, + 'id_order': binding.prestashop_id, 'id_order_state': state, } } - self.backend_adapter.update_sale_state(prestashop_id, datas) - - -def find_prestashop_state(session, sale_state, backend): - state_list_model = session.env['sale.order.state.list'] - state_lists = state_list_model.search( - [('name', '=', sale_state)] - ) - for state_list in state_lists: - if state_list.prestashop_state_id.backend_id == backend: - return state_list.prestashop_state_id.prestashop_id - return None - - -@job -def export_sale_state(session, model_name, record_id): - binding_model = session.env[model_name] - sales = binding_model.search([('openerp_id', '=', record_id)]) - for sale in sales: - backend = sale.backend_id - new_state = find_prestashop_state(session, sale.state, backend) - if not new_state: - continue - env = backend.get_environment(binding_model._name, session=session) - sale_exporter = env.get_connector_unit(SaleStateExporter) - sale_exporter.run(sale.prestashop_id, new_state) + self.backend_adapter.update_sale_state(binding.prestashop_id, datas) diff --git a/connector_prestashop/models/stock_move/common.py b/connector_prestashop/models/stock_move/common.py index f5407d1ca..e1fc5a233 100644 --- a/connector_prestashop/models/stock_move/common.py +++ b/connector_prestashop/models/stock_move/common.py @@ -2,6 +2,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). from odoo import api, fields, models +from odoo.addons.component.core import Component class StockLocation(models.Model): @@ -51,3 +52,13 @@ def unlink(self): self.filtered(lambda x: x.location_id in ps_locations).mapped( 'product_id').update_prestashop_qty() return super(StockQuant, self).unlink() + + +class PrestashopStockPickingListener(Component): + _name = 'prestashop.stock.picking.listener' + _inherit = 'base.event.listener' + _apply_on = ['stock.picking'] + + def on_tracking_number_added(self, record): + for binding in record.sale_id.prestashop_bind_ids: + binding.with_delay().export_tracking_number() diff --git a/connector_prestashop/models/stock_tracking/exporter.py b/connector_prestashop/models/stock_tracking/exporter.py index a70730043..18bb33a1f 100644 --- a/connector_prestashop/models/stock_tracking/exporter.py +++ b/connector_prestashop/models/stock_tracking/exporter.py @@ -1,18 +1,15 @@ # -*- coding: utf-8 -*- # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) -import logging -from odoo import _ -from odoo.addons.connector.unit.synchronizer import Exporter -from odoo.exceptions import UserError -from odoo.addons.queue_job.job import job -from ...components.backend_adapter import PrestaShopCRUDAdapter +from odoo.addons.component.core import Component +from odoo.addons.queue_job.exception import FailedJobError -_logger = logging.getLogger(__name__) - -class PrestashopTrackingExporter(Exporter): - _model_name = ['prestashop.sale.order'] +class PrestashopTrackingExporter(Component): + _name = 'prestashop.stock.tracking.exporter' + _inherit = 'prestashop.exporter' + _apply_on = ['prestashop.sale.order'] + _usage = 'tracking.exporter' def _get_tracking(self): trackings = [] @@ -21,14 +18,13 @@ def _get_tracking(self): trackings.append(picking.carrier_tracking_ref) return ';'.join(trackings) if trackings else None - def run(self, binding_id, **kwargs): + def run(self, binding, **kwargs): """ Export the tracking number of a picking to PrestaShop """ # verify the picking is done + prestashop id exists tracking_adapter = self.component( usage='backend.adapter', model_name='__not_exit_prestashop.order_carrier') - - self.binding = self.model.browse(binding_id) + self.binding = binding tracking = self._get_tracking() if tracking: prestashop_order_id = self.binder.to_external(self.binding) @@ -43,18 +39,6 @@ def run(self, binding_id, **kwargs): tracking_adapter.write(order_carrier_id, vals) return "Tracking %s exported" % tracking else: - raise exceptions.Warning( - _('PrestaShop Error'), - _('No carrier found on sale order')) + raise FailedJobError('No carrier found on sale order') else: return "No tracking to export" - - -@job -def export_tracking_number(session, model_name, record_id): - """ Export the tracking number of a delivery order. """ - order = session.env[model_name].browse(record_id) - backend = order.backend_id - env = backend.get_environment(model_name, session=session) - tracking_exporter = env.get_connector_unit(PrestashopTrackingExporter) - return tracking_exporter.run(record_id) diff --git a/connector_prestashop/security/ir.model.access.csv b/connector_prestashop/security/ir.model.access.csv index 7303207a1..94950dd40 100644 --- a/connector_prestashop/security/ir.model.access.csv +++ b/connector_prestashop/security/ir.model.access.csv @@ -23,8 +23,9 @@ access_prestashop_sale_order_line_full,Full access on prestashop.sale.order.line access_prestashop_sale_order_line_discount_user,User access on prestashop.sale.order.line.discount,model_prestashop_sale_order_line_discount,base.group_user,1,0,0,0 access_prestashop_sale_order_line_discount_full,Full access on prestashop.sale.order.line.discount,model_prestashop_sale_order_line_discount,connector.group_connector_manager,1,1,1,1 access_prestashop_delivery_carrier_full,Full access on prestashop.delivery.carrier,model_prestashop_delivery_carrier,connector.group_connector_manager,1,1,1,1 -access_prestashop_product_category_full,Full access on prestashop.product.category,model_prestashop_product_category,connector.group_connector_manager,1,1,1,1 access_prestashop_product_category_user,User access on prestashop.product.category,model_prestashop_product_category,base.group_user,1,0,0,0 +access_prestashop_product_category_full,Full access on prestashop.product.category,model_prestashop_product_category,connector.group_connector_manager,1,1,1,1 +access_prestashop_product_image_user,User access on prestashop.product.image,model_prestashop_product_image,base.group_user,1,0,0,0 access_prestashop_product_image_full,Full access on prestashop.product.image,model_prestashop_product_image,connector.group_connector_manager,1,1,1,1 access_prestashop_product_template_user,User access on prestashop.product.template,model_prestashop_product_template,base.group_user,1,0,0,0 access_prestashop_product_template,Full access on prestashop.product.template,model_prestashop_product_template,connector.group_connector_manager,1,1,1,1 @@ -41,3 +42,12 @@ access_prestashop_product_supplierinfo_user,User access on prestashop.product.su access_prestashop_product_supplierinfo,Full access on prestashop.product.supplierinfo,model_prestashop_product_supplierinfo,connector.group_connector_manager,1,1,1,1 access_mail_message,Full access on prestashop.mail.message,model_prestashop_mail_message,connector.group_connector_manager,1,1,1,1 access_prestashop_groups_pricelist,Full access on prestashop.groups.pricelist,model_prestashop_groups_pricelist,connector.group_connector_manager,1,1,1,1 +access_prestashop_backend_user,User access on prestashop.backend,model_prestashop_backend,base.group_user,1,0,0,0 +access_prestashop_address_user,prestashop_address user,model_prestashop_address,base.group_user,1,0,0,0 +access_sale_order_state_user,sale_order_state user,model_sale_order_state,base.group_user,1,0,0,0 +access_sale_order_state_list_user,sale_order_state_list user,model_sale_order_state_list,base.group_user,1,0,0,0 +access_prestashop_sale_order_state_user,prestashop_sale_order_state user,model_prestashop_sale_order_state,base.group_user,1,0,0,0 +access_prestashop_account_tax_user,User access on prestashop.account.tax,model_prestashop_account_tax,base.group_user,1,0,0,0 +access_prestashop_account_tax_group_user,User access on prestashop.account.tax.group,model_prestashop_account_tax_group,base.group_user,1,0,0,0 +access_prestashop_res_lang_user,User access on prestashop.res.lang,model_prestashop_res_lang,base.group_user,1,0,0,0 +access_prestashop_shop_user,User access on prestashop.shop,model_prestashop_shop,base.group_user,1,0,0,0 diff --git a/connector_prestashop/views/prestashop_backend_view.xml b/connector_prestashop/views/prestashop_backend_view.xml index a8e6bf3b1..a155f4e8a 100644 --- a/connector_prestashop/views/prestashop_backend_view.xml +++ b/connector_prestashop/views/prestashop_backend_view.xml @@ -55,6 +55,7 @@ + @@ -190,10 +191,10 @@ - + + + + diff --git a/connector_prestashop/views/product_view.xml b/connector_prestashop/views/product_view.xml index 070e903f2..0f6d3acd6 100644 --- a/connector_prestashop/views/product_view.xml +++ b/connector_prestashop/views/product_view.xml @@ -94,9 +94,9 @@

- + @@ -106,6 +106,7 @@ + @@ -125,6 +126,7 @@ + + + + +
+ -
-

- -

+ +

+ +

- - - - + + + + - - - + + + - - - - - - - - - + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - -

- By clicking on the buttons, - you will initiate the - synchronizations - with PrestaShop. - Note that the import or exports - won't be done directly, - they will create 'Jobs' - executed as soon - as possible. -

-

- Once imported, - some types of records, - like the products - or categories, - need a manual review. - You will find the list - of the - new records to review - in the menu 'Connectors > Checkpoint'. -

- -
-
-