diff --git a/.travis.yml b/.travis.yml index 12862c09a..7ecbf577e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,6 +10,7 @@ addons: apt: packages: - expect-dev # provides unbuffer utility + - cloc # module_analysis env: global: diff --git a/module_analysis/README.rst b/module_analysis/README.rst index 364d3d393..0ef3d66c8 100644 --- a/module_analysis/README.rst +++ b/module_analysis/README.rst @@ -96,7 +96,10 @@ Usage Open the stats to analyze the detail of the code installed - .. image:: https://raw.githubusercontent.com/legalsylvain/server-tools/12.0-ADD-module_analysis/module_analysis/static/description/analysis.png + .. image:: https://raw.githubusercontent.com/legalsylvain/server-tools/12.0-ADD-module_analysis/module_analysis/static/description/analysis_pivot.png + + + .. image:: https://raw.githubusercontent.com/legalsylvain/server-tools/12.0-ADD-module_analysis/module_analysis/static/description/analysis_pie.png Bug Tracker =========== diff --git a/module_analysis/models/ir_module_module.py b/module_analysis/models/ir_module_module.py index 784aa3ffb..e16b07797 100644 --- a/module_analysis/models/ir_module_module.py +++ b/module_analysis/models/ir_module_module.py @@ -104,10 +104,10 @@ class IrModuleModule(models.Model): values = self._prepare_values_from_json(json_res) module.write(values) - except Exception as e: + except Exception: _logger.warning( - 'Failed to execute the cloc command on module %s', - module.name, e.message()) + 'Failed to execute the cloc command on module %s' % ( + module.name)) @api.model def _get_analyzed_languages(self): diff --git a/module_analysis/readme/USAGE.rst b/module_analysis/readme/USAGE.rst index 691931dc1..96a3fda70 100644 --- a/module_analysis/readme/USAGE.rst +++ b/module_analysis/readme/USAGE.rst @@ -2,4 +2,7 @@ Open the stats to analyze the detail of the code installed - .. image:: ../static/description/analysis.png + .. image:: ../static/description/analysis_pivot.png + + + .. image:: ../static/description/analysis_pie.png diff --git a/module_analysis/static/description/analysis_pie.png b/module_analysis/static/description/analysis_pie.png new file mode 100644 index 000000000..1ed7f867d Binary files /dev/null and b/module_analysis/static/description/analysis_pie.png differ diff --git a/module_analysis/static/description/analysis.png b/module_analysis/static/description/analysis_pivot.png similarity index 100% rename from module_analysis/static/description/analysis.png rename to module_analysis/static/description/analysis_pivot.png diff --git a/module_analysis/views/view_ir_module_module.xml b/module_analysis/views/view_ir_module_module.xml index da27f887e..bf72a5151 100644 --- a/module_analysis/views/view_ir_module_module.xml +++ b/module_analysis/views/view_ir_module_module.xml @@ -41,13 +41,22 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + + ir.module.module + + + + + + + Installed Modules by Types ir.actions.act_window ir.module.module [('state', '=', 'installed')] form - pivot + pivot,graph