From a277bfb44a725f201b728dfc79515a01c0a29f6a Mon Sep 17 00:00:00 2001 From: Adrian Torres Date: Tue, 9 Oct 2018 08:54:42 +0000 Subject: [PATCH] [REM] packaging: drop PyYAML dependency Commit cf853a785ba4b533ddb2e8a717c9ffa6429e7b81 removed all yml tests and the yml import engine from Odoo forever, however PyYAML remains a dependency even though it's not used anymore. This commit removes any reference to this lib that could be found. closes odoo/odoo#27563 --- .../overwrite_before_init/etc/init_posbox_image.sh | 2 +- debian/control | 1 - doc/reference/guidelines.rst | 2 +- doc/webservices/localization.rst | 12 +++++++----- requirements.txt | 2 -- setup.cfg | 1 - setup/package.dfdebian | 1 - setup/package.dffedora | 1 - setup/win32/winpy_requirements.txt | 1 - 9 files changed, 9 insertions(+), 14 deletions(-) diff --git a/addons/point_of_sale/tools/posbox/overwrite_before_init/etc/init_posbox_image.sh b/addons/point_of_sale/tools/posbox/overwrite_before_init/etc/init_posbox_image.sh index c6db04f707e..254c8def2b0 100755 --- a/addons/point_of_sale/tools/posbox/overwrite_before_init/etc/init_posbox_image.sh +++ b/addons/point_of_sale/tools/posbox/overwrite_before_init/etc/init_posbox_image.sh @@ -21,7 +21,7 @@ apt-get update && apt-get -y upgrade # Do not be too fast to upgrade to more recent firmware and kernel than 4.38 # Firmware 4.44 seems to prevent the LED mechanism from working -PKGS_TO_INSTALL="fswebcam python3-urllib3 cups printer-driver-all cups-ipp-utils adduser postgresql python3 python3-dateutil python3-decorator python3-docutils python3-feedparser python3-pil python3-jinja2 python3-ldap3 python3-lxml python3-mako python3-mock python3-openid python3-psutil python3-psycopg2 python3-babel python3-pydot python3-pyparsing python3-pypdf2 python3-reportlab python3-requests python3-simplejson python3-tz python3-vatnumber python3-werkzeug python3-yaml python3-serial python3-pip python3-dev localepurge vim mc mg screen iw hostapd git rsync console-data lightdm xserver-xorg-video-fbdev xserver-xorg-input-evdev iceweasel xdotool unclutter x11-utils openbox python3-netifaces rpi-update python3-passlib python3-libsass python3-qrcode python3-html2text python3-unittest2 python3-simplejson nginx-full dnsmasq" +PKGS_TO_INSTALL="fswebcam python3-urllib3 cups printer-driver-all cups-ipp-utils adduser postgresql python3 python3-dateutil python3-decorator python3-docutils python3-feedparser python3-pil python3-jinja2 python3-ldap3 python3-lxml python3-mako python3-mock python3-openid python3-psutil python3-psycopg2 python3-babel python3-pydot python3-pyparsing python3-pypdf2 python3-reportlab python3-requests python3-simplejson python3-tz python3-vatnumber python3-werkzeug python3-serial python3-pip python3-dev localepurge vim mc mg screen iw hostapd git rsync console-data lightdm xserver-xorg-video-fbdev xserver-xorg-input-evdev iceweasel xdotool unclutter x11-utils openbox python3-netifaces rpi-update python3-passlib python3-libsass python3-qrcode python3-html2text python3-unittest2 python3-simplejson nginx-full dnsmasq" echo "Acquire::Retries "16";" > /etc/apt/apt.conf.d/99acquire-retries # KEEP OWN CONFIG FILES DURING PACKAGE CONFIGURATION # http://serverfault.com/questions/259226/automatically-keep-current-version-of-config-files-when-apt-get-install diff --git a/debian/control b/debian/control index 24bb9130e86..7600e8bf580 100644 --- a/debian/control +++ b/debian/control @@ -42,7 +42,6 @@ Depends: python3-vatnumber, python3-werkzeug, python3-xlsxwriter, - python3-yaml, Conflicts: tinyerp-server, openerp-server, openerp-web, openerp Replaces: tinyerp-server, openerp-server, openerp-web, openerp Recommends: diff --git a/doc/reference/guidelines.rst b/doc/reference/guidelines.rst index cd83f0bd8f5..d7148f3aec2 100644 --- a/doc/reference/guidelines.rst +++ b/doc/reference/guidelines.rst @@ -44,7 +44,7 @@ Other optional directories compose the module. - *wizard/* : regroups the transient models (``models.TransientModel``) and their views - *report/* : contains the printable reports and models based on SQL views. Python objects and XML views are included in this directory -- *tests/* : contains the Python/YML tests +- *tests/* : contains the Python tests File naming diff --git a/doc/webservices/localization.rst b/doc/webservices/localization.rst index a4e68f4bcbc..238e49788e6 100644 --- a/doc/webservices/localization.rst +++ b/doc/webservices/localization.rst @@ -17,19 +17,21 @@ In case of no country code set or no localization module found, the ``l10n_gener For example, ``l10n_be`` will be installed if the company has ``Belgium`` as country. -This behavior is allowed by the presence of a *.yml* file containing the following code: +This behavior is allowed by the presence of a *.xml* file containing the following code: .. code-block:: xml - - - !python {model: account.chart.template, id: pl_chart_template}: | - self[0].try_loading_for_current_company() + + + + +Where ``module.template_xmlid`` is the **fully-qualified** xmlid of the corresponding template. Usually located in the ``data`` folder, it must be loaded at the very last in the ``__manifest__.py`` file. .. danger:: - If the *.yml* file is missing, the right chart of accounts won't be loaded on time! + If the *.xml* file is missing, the right chart of accounts won't be loaded on time! Configuring my own Chart of Accounts? diff --git a/requirements.txt b/requirements.txt index c5c09f800cf..775f6917f93 100644 --- a/requirements.txt +++ b/requirements.txt @@ -31,8 +31,6 @@ pyserial==3.1.1 python-dateutil==2.5.3 pytz==2016.7 pyusb==1.0.0 -PyYAML==3.12 ; python_version < '3.7' -PyYAML==3.13 ; python_version >= '3.7' qrcode==5.3 reportlab==3.3.0 requests==2.11.1 diff --git a/setup.cfg b/setup.cfg index 31fb90461f5..ea31e808da9 100644 --- a/setup.cfg +++ b/setup.cfg @@ -36,7 +36,6 @@ requires = python3-dateutil python3-pytz python3-pyusb - python3-PyYAML python3-qrcode python3-reportlab python3-requests diff --git a/setup/package.dfdebian b/setup/package.dfdebian index 82a70dd8dce..51f97b060ad 100644 --- a/setup/package.dfdebian +++ b/setup/package.dfdebian @@ -50,7 +50,6 @@ RUN apt-get update -qq && \ python3-vobject \ python3-werkzeug \ python3-xlsxwriter \ - python3-yaml -y && \ rm -rf /var/lib/apt/lists/* RUN echo "PS1=\"[\u@nightly-tests] # \"" > ~/.bashrc diff --git a/setup/package.dffedora b/setup/package.dffedora index 1ee83e0767d..f1d000f9244 100644 --- a/setup/package.dffedora +++ b/setup/package.dffedora @@ -34,7 +34,6 @@ RUN dnf update -d 0 -e 0 -y && \ python3-dateutil \ python3-pytz \ python3-pyusb \ - python3-PyYAML \ python3-qrcode \ python3-reportlab \ python3-requests \ diff --git a/setup/win32/winpy_requirements.txt b/setup/win32/winpy_requirements.txt index 4a615ad1818..3d1c5f44b2c 100644 --- a/setup/win32/winpy_requirements.txt +++ b/setup/win32/winpy_requirements.txt @@ -25,7 +25,6 @@ pyserial==3.1.1 python-dateutil==2.5.3 pytz==2016.7 pyusb==1.0.0 -PyYAML==3.12 qrcode==5.3 reportlab>=3.3.0 requests==2.11.1