AgileBG Planethttp://planet.agilebg.com
Mon, 09 May 2016 15:59:29 +0000en-UShourly1https://wordpress.org/?v=4.8.9How to add an HTML element at the bottom of the last page of a webkit reporthttp://planet.agilebg.com/en/2014/05/how-to-add-html-element-at-the-bottom-of-the-last-page-of-webkit-report/?utm_source=rss&utm_medium=rss&utm_campaign=how-to-add-html-element-at-the-bottom-of-the-last-page-of-webkit-report
http://planet.agilebg.com/en/2014/05/how-to-add-html-element-at-the-bottom-of-the-last-page-of-webkit-report/#commentsTue, 27 May 2014 09:30:29 +0000http://planet.agilebg.com/?p=1941Continue Reading]]>Introduction

It includes multiple headers, footers and logos, javascript support, CSS support and other features.

Sometimes you want to print an element of the report at the bottom of the last page of the report. Take for instance the customer’s signature on a quotation. You need to print the 'Signature:' string once, but if you put it at the end of the mako template, it could be printed in the centre of the page: it depends on the number of lines of the quotation.

The code

Let’s see how to solve this using the standard footer of a webkit report.

The main benefit of using Buildbot instead of runbot is that buildbot allows to test a specific configuration (a specific revision of the code, possibly with patch, a specific set of modules) and does not force to test all available modules (like runbot)

For example in the build 7, composed of OpenERP 7 and Italian modules, we can see several sections.

‘Steps and Logfiles’ contains all the steps made by the build. Starting from the code update to the database creation and the tests execution.

Step 13, the only one red, is the step that checks the tests result. To understand the meaning of the failure, we need to open the output of step 12. Here we can find 3 errors:

ValueError: res_partner_c2c not found when processing /home/buildslave/public/openerp/openerp-italia-postgresql-9_1/build/parts/italian-addons-7.0/l10n_it_fiscalcode/test/fiscalcode.yml. This Yaml file appears to depend on missing data. This often happens for tests that belong to a module's test suite and depend on each other.

File "/home/buildslave/public/openerp/openerp-italia-postgresql-9_1/build/parts/server-7.0/openerp/tools/yaml_import.py", line 501, in _eval_field raise KeyError("Object '%s' does not contain field '%s'" % (model, field_name)) KeyError: "Object '' does not contain field 'address_contact_id'"

Specific Configurations

AgileBG uses buildout + buildbot for every customer’s instance: keeping green tests guarantees the best stability for every system.

Thanks to buildbot’s way to test specific configuration, having a red openerp-italia-7-ocb-postgresql-9.1 instance doesn’t mean that customers that use the Italian branch have red tests: they would have red tests only if their configuration included the modules whose tests are failing.