This affects the "Cursor not closed explicitly..." message.
The message is at a "warning" level, but the frame inspection added
some expensive overhead to each cursor open. So, avoid that unless we
are at debug mode.
bzr revid: p_christ@hol.gr-20101124094853-0ljr6nebkyya0eui
The reference to the "ganeti" project has always been totally arbitrary
and false. It is true that some parts of "websrv_lib" have been based
on Python's BaseHTTPServer and SimpleHTTPServer classes, but not more
than that. Overriding and perhaps resembling to parent classes is the
most common thing in OO programming. But never copied or knew about
any "ganeti" project whatsoever. (actually, the code mentioned at the
url admits itself that it copies the BaseHTTPServer, a common
denominator)
Git history to your help, all the code evolution is clearly recorded.
bzr revid: p_christ@hol.gr-20101123183357-fjroqywizql2qdkk
They will report "HTTP/1.0" to us, while they support (and need) the
authorisation features of HTTP/1.1 .
This makes WebDAV work for some Mac OSX versions.
bzr revid: p_christ@hol.gr-20101123154448-0z7s5o77256cj1tu
There was a fundamental problem when a user, through the 'document' module
would try to write into his personal folder; the res.users model won't be
writable by normal users. So, have all this code in a _single_ function,
which will be redefined by document.
Also follow the v6 API for access control, don't just lookup at ir.model.access.
Conflicts:
bin/addons/base/ir/ir_attachment.py
bzr revid: p_christ@hol.gr-20101123154212-pphsnyp2rsmbjf72
At some cases, ir.model.data is left with orphan entries, so ensure that
the message below is used (rather than "bool has no get()" exception).
Conflicts:
bin/tools/yaml_import.py
bzr revid: p_christ@hol.gr-20101123153936-0cc4t4e2xwat70q1
While searching for the KTHML bug, noticed that partial http requests
would falsely be honoured. Instead, we must check if the full headers
(including the blank line) have been parsed before we dispatch the
request to the virtual handler class.
Conflicts:
bin/service/websrv_lib.py
bzr revid: p_christ@hol.gr-20101123153558-oh44mjkhwjaebwow
Since 91422704d965268f, specifying a font that is not registered with
pdfmetrics will raise an exception. Now, improve that exception to
help the user understand what has gone wrong.
Note: rather than hiding the fact that some font is missing, the admin
should see this error and try to either fix the report (to use a known
font), or register more fonts with the customfonts.py mechanism.
bzr revid: p_christ@hol.gr-20101123153235-c1yri33ptaydb5eo
The os.popen2 is deprecated since Python 2.6. It also failed to properly
escape the command line arguments.
Conflicts:
bin/tools/misc.py
bzr revid: p_christ@hol.gr-20101123152224-d52414w2tscw6bvo
That snippet of code practically meant "don't use anything but the
standard fonts (by name) in the report". It obviously wanted to prevent the
rml2pdf engine from crashing at a non-existent font.
Well, if the report specifies a font that cannot be mapped by the system,
it should preferably raise an exception (and ask us to fix the report), not
silently ignore the font.
Case 1: the internationalized reports, where font name is used to select a
Unicode-capable font.
Case 2: l10n_ch, where the OCR-B font had to be used (perhaps legal req.)
bzr revid: p_christ@hol.gr-20101123152002-es404ul29rsohzqd
When strings are 8-bit utf8-encoded, unicode will break with the usual:
UnicodeDecodeError: 'ascii' codec can't decode byte 0xce in position ..
message. ustr() will have better luck in those cases.
Conflicts:
bin/report/render/rml2pdf/utils.py
bzr revid: p_christ@hol.gr-20101123151930-8r9q9gg7r902i2nv
This should log the rendering exceptions for reports. Also fix am error at
custom fonts, suppress a message.
Conflicts:
bin/report/render/rml2pdf/utils.py
bzr revid: p_christ@hol.gr-20101123151110-bckon1ji7hul20mp
exception() cannot be called without a string, yet it is even better to
demote those logs to warnings.
Conflicts:
bin/report/render/rml2pdf/utils.py
bzr revid: p_christ@hol.gr-20101123150903-zgiyob943ivcftkq
The meaning of any SSL certificate (even self-signed) is that it uniquely
identifies the server. So, if we have a generic cert distributed with our
packaging, we break that. We could not even generate a cert at the "build"
stage of our server, because that would be included in the packages.
If anybody needs to run OpenERP with SSL, they will need to generate the
certificate at the target server, possibly using ssl-cert.cfg as a sample.
Also, the "ssl" directory under bin/ would confuse some pythonic code that
had tried to "import ssl" (eg. urllib.py).
bzr revid: p_christ@hol.gr-20101123135844-nr8k78qrmlyn19xb
A closed cursor should behave the same as a closed connection, ie.
OperationalError. Also instrument a function we don't expect to be called.
bzr revid: p_christ@hol.gr-20101123135837-vkn3ph0e4bz9urf0
When a column changes type in module upgrades, we have code to rename
the column. The new name shall be based on the old column name, not the
name of the table.
bzr revid: p_christ@hol.gr-20101123135748-z8rtmy36c8u972xb
Inspecting the full stack just to learn the file:line info for debugging
purposes is both expensive and error-prone. Write an alternative function
in tools/func.py that will just go N frames back and try to get the info.
bzr revid: p_christ@hol.gr-20101123135742-2jp75f3uxyg3a6b6
If a res.user belongs to a company_id that the current user has no access
to, perm_read() wouldn't be able to return results (but exception). Now,
just skip the uid->login resolution and return the numeric value instead.
bzr revid: p_christ@hol.gr-20101123135654-bslxfv93p10216d3
Since we have moved all code into the websrv_lib, we must also support
this non-standard extension in our do_OPTIONS(). It has been noted that
some Win XP machines wouldn't connect to our WebDAV unless we set that
header.
bzr revid: p_christ@hol.gr-20101123134932-65wmh8bntuwt4jvc
This fixes the support for callable sql_constraint messages, which have
always been wrong. It respects the (cr, uid, ids, context) arguments and
will fallback to Postgres's error if it cannot call.
Note that sql constraints are not properly explained when base_module_record
or audittrail are installed.
bzr revid: p_christ@hol.gr-20101118184643-8tnmj83b09kuvf1j