diff --git a/.copier-answers.yml b/.copier-answers.yml
new file mode 100644
index 000000000000..e5e5d5d38724
--- /dev/null
+++ b/.copier-answers.yml
@@ -0,0 +1,24 @@
+# Do NOT update manually; changes here will be overwritten by Copier
+_commit: v1.14.2
+_src_path: gh:oca/oca-addons-repo-template
+ci: GitHub
+dependency_installation_mode: PIP
+generate_requirements_txt: true
+github_check_license: true
+github_ci_extra_env: {}
+github_enable_codecov: true
+github_enable_makepot: false
+github_enable_stale_action: false
+github_enforce_dev_status_compatibility: true
+include_wkhtmltopdf: false
+odoo_version: 16.0
+org_name: Odoo Community Association (OCA)
+org_slug: OCA
+rebel_module_groups: []
+repo_description: null
+repo_name: 'Open Source upgrade path for Odoo/OpenERP '
+repo_slug: openupgrade
+repo_website: https://github.com/OCA/OpenUpgrade
+travis_apt_packages: []
+travis_apt_sources: []
+
diff --git a/.eslintrc.yml b/.eslintrc.yml
index 88f2881b4c12..9429bc688aab 100644
--- a/.eslintrc.yml
+++ b/.eslintrc.yml
@@ -1,9 +1,16 @@
env:
browser: true
+ es6: true
# See https://github.com/OCA/odoo-community.org/issues/37#issuecomment-470686449
parserOptions:
- ecmaVersion: 2017
+ ecmaVersion: 2019
+
+overrides:
+ - files:
+ - "**/*.esm.js"
+ parserOptions:
+ sourceType: module
# Globals available in Odoo that shouldn't produce errorings
globals:
@@ -14,7 +21,7 @@ globals:
moment: readonly
odoo: readonly
openerp: readonly
- Promise: readonly
+ owl: readonly
# Styling is handled by Prettier, so we only need to enable AST rules;
# see https://github.com/OCA/maintainer-quality-tools/pull/618#issuecomment-558576890
diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml
index 2eb68c8293fa..23e6e58d6bc5 100644
--- a/.github/workflows/pre-commit.yml
+++ b/.github/workflows/pre-commit.yml
@@ -2,16 +2,34 @@ name: pre-commit
on:
pull_request:
+ branches:
+ - "16.0*"
push:
+ branches:
+ - "16.0"
+ - "16.0-ocabot-*"
jobs:
pre-commit:
- runs-on: ubuntu-latest
+ runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- - uses: actions/setup-python@v4
+ - uses: actions/setup-python@v2
+ - name: Get python version
+ run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
+ - uses: actions/cache@v1
with:
- # The pylint-odoo version we use here does not support python 3.10
- # https://github.com/OCA/oca-addons-repo-template/issues/80
- python-version: "3.9"
- - uses: pre-commit/action@v2.0.0
+ path: ~/.cache/pre-commit
+ key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }}
+ - name: Install pre-commit
+ run: pip install pre-commit
+ - name: Run pre-commit
+ run: pre-commit run --all-files --show-diff-on-failure --color=always
+ - name: Check that all files generated by pre-commit are in git
+ run: |
+ newfiles="$(git ls-files --others --exclude-from=.gitignore)"
+ if [ "$newfiles" != "" ] ; then
+ echo "Please check-in the following files:"
+ echo "$newfiles"
+ exit 1
+ fi
diff --git a/.gitignore b/.gitignore
index 90a43136cee1..9c283fd41f6c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -15,7 +15,6 @@ build/
develop-eggs/
dist/
eggs/
-lib/
lib64/
parts/
sdist/
@@ -64,6 +63,9 @@ coverage.xml
# Rope
.ropeproject
+# Sphinx documentation
+docs/_build/
+
# Backup files
*~
*.swp
diff --git a/.isort.cfg b/.isort.cfg
index 7683badfa449..0ec187efd1bf 100644
--- a/.isort.cfg
+++ b/.isort.cfg
@@ -10,3 +10,4 @@ known_odoo=odoo
known_odoo_addons=odoo.addons
sections=FUTURE,STDLIB,THIRDPARTY,ODOO,ODOO_ADDONS,FIRSTPARTY,LOCALFOLDER
default_section=THIRDPARTY
+ensure_newline_before_comments = True
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index de1430197cfe..2396d0ff9bf9 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -10,6 +10,8 @@ exclude: |
^README\.md$|
# Library files can have extraneous formatting (even minimized)
/static/(src/)?lib/|
+ # Repos using Sphinx to generate docs don't need prettying
+ ^docs/_templates/.*\.html$|
# You don't usually want a bot to modify your legal texts
(LICENSE.*|COPYING.*)
default_language_version:
@@ -36,7 +38,7 @@ repos:
# update the NOT INSTALLABLE ADDONS section above
- id: oca-update-pre-commit-excluded-addons
- id: oca-fix-manifest-website
- args: ["https://github.com/OCA/OpenUpgrade"]
+ args: ["https://github.com/OCA/openupgrade"]
- repo: https://github.com/myint/autoflake
rev: v1.6.1
hooks:
@@ -76,10 +78,10 @@ repos:
hooks:
- id: trailing-whitespace
# exclude autogenerated files
- exclude: /README\.rst$|\.pot?$|openupgrade_scripts/scripts.*noupdate_changes.xml
+ exclude: /README\.rst$|\.pot?$
- id: end-of-file-fixer
# exclude autogenerated files
- exclude: /README\.rst$|\.pot?$|^openupgrade_scripts/script.*.txt
+ exclude: /README\.rst$|\.pot?$
- id: debug-statements
- id: fix-encoding-pragma
args: ["--remove"]
@@ -88,7 +90,7 @@ repos:
- id: check-executables-have-shebangs
- id: check-merge-conflict
# exclude files where underlines are not distinguishable from merge conflicts
- exclude: /README\.rst$|^docsource/.*\.rst
+ exclude: /README\.rst$|^docs/.*\.rst$
- id: check-symlinks
- id: check-xml
- id: mixed-line-ending
diff --git a/.pylintrc b/.pylintrc
index f3e6517ed0f9..c233f8732205 100644
--- a/.pylintrc
+++ b/.pylintrc
@@ -1,3 +1,5 @@
+
+
[MASTER]
load-plugins=pylint_odoo
score=n
@@ -64,6 +66,38 @@ enable=anomalous-backslash-in-string,
use-vim-comment,
wrong-tabs-instead-of-spaces,
xml-syntax-error,
+ attribute-string-redundant,
+ character-not-valid-in-resource-link,
+ consider-merging-classes-inherited,
+ context-overridden,
+ create-user-wo-reset-password,
+ dangerous-filter-wo-user,
+ dangerous-qweb-replace-wo-priority,
+ deprecated-data-xml-node,
+ deprecated-openerp-xml-node,
+ duplicate-po-message-definition,
+ except-pass,
+ invalid-commit,
+ manifest-maintainers-list,
+ missing-newline-extrafiles,
+ missing-readme,
+ missing-return,
+ odoo-addons-relative-import,
+ old-api7-method-defined,
+ po-msgstr-variables,
+ po-syntax-error,
+ renamed-field-parameter,
+ resource-not-exist,
+ str-format-used,
+ test-folder-imported,
+ translation-contains-variable,
+ translation-positional-used,
+ unnecessary-utf8-coding-comment,
+ website-manifest-key-not-valid-uri,
+ xml-attribute-translatable,
+ xml-deprecated-qweb-directive,
+ xml-deprecated-tree-attribute,
+ external-request-timeout,
# messages that do not cause the lint step to fail
consider-merging-classes-inherited,
create-user-wo-reset-password,
diff --git a/.pylintrc-mandatory b/.pylintrc-mandatory
index 60c572966a8c..fa4b81c41e6f 100644
--- a/.pylintrc-mandatory
+++ b/.pylintrc-mandatory
@@ -1,3 +1,4 @@
+
[MASTER]
load-plugins=pylint_odoo
score=n
@@ -56,7 +57,40 @@ enable=anomalous-backslash-in-string,
unreachable,
use-vim-comment,
wrong-tabs-instead-of-spaces,
- xml-syntax-error
+ xml-syntax-error,
+ attribute-string-redundant,
+ character-not-valid-in-resource-link,
+ consider-merging-classes-inherited,
+ context-overridden,
+ create-user-wo-reset-password,
+ dangerous-filter-wo-user,
+ dangerous-qweb-replace-wo-priority,
+ deprecated-data-xml-node,
+ deprecated-openerp-xml-node,
+ duplicate-po-message-definition,
+ except-pass,
+ file-not-used,
+ invalid-commit,
+ manifest-maintainers-list,
+ missing-newline-extrafiles,
+ missing-readme,
+ missing-return,
+ odoo-addons-relative-import,
+ old-api7-method-defined,
+ po-msgstr-variables,
+ po-syntax-error,
+ renamed-field-parameter,
+ resource-not-exist,
+ str-format-used,
+ test-folder-imported,
+ translation-contains-variable,
+ translation-positional-used,
+ unnecessary-utf8-coding-comment,
+ website-manifest-key-not-valid-uri,
+ xml-attribute-translatable,
+ xml-deprecated-qweb-directive,
+ xml-deprecated-tree-attribute,
+ external-request-timeout
[REPORTS]
msg-template={path}:{line}: [{msg_id}({symbol}), {obj}] {msg}
diff --git a/README.md b/README.md
index b47dfb565fac..8150a67dc31c 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,12 @@
-
-
+[](https://github.com/OCA/openupgrade/actions/workflows/pre-commit.yml?query=branch%3A16.0)
+[](https://github.com/OCA/openupgrade/actions/workflows/test.yml?query=branch%3A16.0)
+[](https://codecov.io/gh/OCA/openupgrade)
+

+
# Tools to upgrade Odoo instances from a major version to another
This OCA project aims to provide an
@@ -22,12 +25,25 @@ For documentation, see here incl
+
+
+[//]: # (addons)
+
+This part will be replaced when running the oca-gen-addons-table script from OCA/maintainer-tools.
+
+[//]: # (end addons)
+
+
+
## Licenses
This repository is licensed under [AGPL-3.0](LICENSE).
-----
+However, each module can have a totally different license, as long as they adhere to Odoo Community Association (OCA)
+policy. Consult each module's `__manifest__.py` file, which contains a `license` key
+that explains its license.
+----
OCA, or the [Odoo Community Association](http://odoo-community.org/), is a nonprofit
organization whose mission is to support the collaborative development of Odoo features
and promote its widespread use.