Commit Graph

91 Commits

Author SHA1 Message Date
Vo Minh Thu c99c4091ce [REM] Deleted .apidoc lines.
They were probably used by some tools. How sad.

bzr revid: vmt@openerp.com-20130212142410-zqdjd8jw3gtvxab0
2013-02-12 15:24:10 +01:00
Cecile Tonglet 8d1b7ce632 [FIX] Removed too much in openerp.tools.misc: html2text
bzr revid: cto@openerp.com-20121217150241-smbswmdmumva29ft
2012-12-17 16:02:41 +01:00
Cecile Tonglet ad8b76de53 [MERGE] From trunk (second time)
bzr revid: cto@openerp.com-20121217144753-1rboqdw01h8yrehj
2012-12-17 15:47:53 +01:00
Cecile Tonglet 5f0070dcb6 [FIX] Remove unused imports and fix some imports that doesn't use the new namespace
bzr revid: cto@openerp.com-20121217143029-e9ki4ftwihq7pdme
2012-12-17 15:30:29 +01:00
Xavier Morel d02fc09bb9 [IMP] more augmented assignments
bzr revid: xmo@openerp.com-20121214134455-c1o7ehlot6vdwioe
2012-12-14 14:44:55 +01:00
Xavier Morel c6079dd6bb [REM] unnecessary parens
bzr revid: xmo@openerp.com-20121214123803-6xu2s1ndnoyj4i3e
2012-12-14 13:38:03 +01:00
Xavier Morel d65709f68b [IMP] simplify @profile implementation
bzr revid: xmo@openerp.com-20121205160847-8zc8of4grueusbl2
2012-12-05 17:08:47 +01:00
Thibault Delavallée c596792bc2 [FIX] tools: re-added html2text import, because of its use in ir_mail_server. Not sure it belongs here.
bzr revid: tde@openerp.com-20121106123407-2s4ya7ln7detui6y
2012-11-06 13:34:07 +01:00
Thibault Delavallée 5f53f5253b [FIX] tools: some import cleaning and fixing.
bzr revid: tde@openerp.com-20121106115851-5f5sfhtp2g3qrm1o
2012-11-06 12:58:51 +01:00
Thibault Delavallée da6ad1e27c [REF] tools: moved email and mail related functions from misc to mail.
bzr revid: tde@openerp.com-20121106115744-pcxgyqv3lf8zfedw
2012-11-06 12:57:44 +01:00
Olivier Dony 9582a8bc82 [FIX] res.lang: ar_AR does not exist (Arabic in Argentina?!) -> replaced with ar_SY
ar_SY is the default locale alias for the `ar`
code in babel, so we can use that until a
translation team asks for a regional
variation of Arabic.

This should also fix an issue in the web
client, where ar_AR was not working, because
silently replaced with ar_SY.

This will only work for new databases,
old ones should be manually fixed.

bzr revid: odo@openerp.com-20121024161527-vec2r46a4o5lk47x
2012-10-24 18:15:27 +02:00
Olivier Dony b5b19a7a01 [FIX] generate_tracking_message_id: use more randomness to avoid duplicates
When several message IDs had to be generated for the same
record at the same time, there was a high chance to
get non-unique results. This possibly lead to data loss because
some mail implementations might ignore multiple mails with the
same ID (including OpenERP itself). On most operating systems
the available time resolution precision is better than what
we used (due to the float rounding of `%s`).
Adding a bit of randomness doesn't hurt, as OpenERP will
be used in increasingly distributed environments, so
we now add an extra random part as well.

bzr revid: odo@openerp.com-20121022162421-qr7nq8idihp5781u
2012-10-22 18:24:21 +02:00
Olivier Dony e06e3aad4a [IMP] tools.html2plaintext: consistent use of lxml.etree.HTMLParser to convert HTML to plaintext
We used to switch to using BeautifulSoup when available, but that
lead to inconsistent behavior depending on the installed Python
packages, and sometimes lead to bad surprises. There is no advantage
in using BeautifulSoup rather than HTMLParser, and the latter is
always available.

bzr revid: odo@openerp.com-20121015120934-njaylf99dc5zekfw
2012-10-15 14:09:34 +02:00
Xavier Morel 1e4a677f05 [MERGE] from trunk
bzr revid: xmo@openerp.com-20121010154436-wz29sdkbs9vvhjba
2012-10-10 17:44:36 +02:00
Xavier Morel 9805c665c8 [ADD] big bit on new import: pretty much everything but o2m
bzr revid: xmo@openerp.com-20120919114047-w4paoim95oxr91zb
2012-09-19 13:40:47 +02:00
Stephane Wirtel 3d2355df04 [MERGE] improve the tools.misc.scan_languages function
bzr revid: stw@openerp.com-20120912104713-jhvkxp9egpchs2ti
2012-09-12 12:47:13 +02:00
Stephane Wirtel ff438c8eb7 [FIX] openerp.tools.misc.file_open: Very little fix to display coherent error message when file not found occurs.
bzr revid: stw@openerp.com-20120912095946-chjiq2y4bltisfw9
2012-09-12 11:59:46 +02:00
Stephane Wirtel 5bd3b4f0a2 [MERGE] base: fix typo of some languages
bzr revid: stw@openerp.com-20120911152531-h5naowr08c3lqva0
2012-09-11 17:25:31 +02:00
Thibault Delavallée 1f84036086 [MERGE] Merged with server/trunk.
bzr revid: tde@openerp.com-20120904075105-ljg3lgn6tf958kvd
2012-09-04 09:51:05 +02:00
Olivier Dony 869564ce28 [MERGE] file_open: give precedence to directory before zip, courtesy of Florent Xicluna
lp bug: https://launchpad.net/bugs/928376 fixed
lp bug: https://launchpad.net/bugs/928507 fixed

bzr revid: odo@openerp.com-20120903130536-5sqwp9tnhk1ntee3
2012-09-03 15:05:36 +02:00
Olivier Dony 6803862711 [IMP] res.partner: simplified+corrected parsing of partner name and email in name_create, added tests, made this internal method private
bzr revid: odo@openerp.com-20120831225205-04l4udn95cz3n72o
2012-09-01 00:52:05 +02:00
Olivier Dony d37745559e [ADD] tools.misc: new function append_to_html, can be used to inject blocks (html or plaintext) to existing HTML snippets
bzr revid: odo@openerp.com-20120831132337-of2p1wlh5l4lpvez
2012-08-31 15:23:37 +02:00
Thibault Delavallée ec85db8e83 [REVIEW] tools: removed duplicate email_split in tools.
bzr revid: tde@openerp.com-20120828080939-5bt3klbep49gjw47
2012-08-28 10:09:39 +02:00
Thibault Delavallée bc5da1a02b [REVIEW] tools: moved email_split function in emails section, instead of 'somwhere in the file'.
bzr revid: tde@openerp.com-20120828073414-lt4bpubxtv3235b6
2012-08-28 09:34:14 +02:00
Turkesh Patel (Open ERP) 7b36f6a7bd [MRG] merge with lp:openobject-server.
bzr revid: tpa@tinyerp.com-20120823050804-nrpewpzqtcqgl6fq
2012-08-23 10:38:04 +05:30
Fabien Pinckaers 3c8c168f85 merge_trunk
bzr revid: fp@tinyerp.com-20120822133509-v4irlqdjjba0wxxn
2012-08-22 15:35:09 +02:00
Christophe Simonis 4eafc023b3 [IMP] tools.misc.mute_logger can now be used as decorator
bzr revid: chs@openerp.com-20120822122013-9uxjwr9oqohseton
2012-08-22 14:20:13 +02:00
Turkesh Patel (Open ERP) 568288c3e1 [MRG] merge with main branch.
bzr revid: tpa@tinyerp.com-20120822115641-3l3yla4kji6xaxm6
2012-08-22 17:26:41 +05:30
Christophe Simonis 89f1693653 [IMP] remove unwanted log in test
bzr revid: chs@openerp.com-20120822110604-il0sxlvf592wasur
2012-08-22 13:06:04 +02:00
Thibault Delavallée b772da168f [FIX] tools: emails_split -> email-split.
bzr revid: tde@openerp.com-20120821151413-9hxmsyp51q3ny32f
2012-08-21 17:14:13 +02:00
Fabien Pinckaers b9bdf2c29a [IMP] tools.email_split
bzr revid: fp@tinyerp.com-20120816164239-yl1vzp83w6z5xi5i
2012-08-16 18:42:39 +02:00
Olivier Dony f5e7d53bce [IMP] tools.reference_re: support matching model name as well
bzr revid: odo@openerp.com-20120807161202-jav73f2kj86pzil4
2012-08-07 18:12:02 +02:00
Turkesh Patel (Open ERP) c49f2418c2 [FIX] Typo in Portuguese official language names.
bzr revid: tpa@tinyerp.com-20120704051748-y41la206dwk67klv
2012-07-04 10:47:48 +05:30
Divyesh Makwana (Open ERP) 9fbdc7c526 [IMP] Improved the typos.
bzr revid: mdi@tinyerp.com-20120423102313-0mboqhctzoje5ize
2012-04-23 15:53:13 +05:30
Christophe Simonis 91b8829050 [FIX] tools.email_send: use correct kwarg
bzr revid: chs@openerp.com-20120306173319-6tmhco83w0we5hl6
2012-03-06 18:33:19 +01:00
Xavier Morel 18d38fb5ee [IMP] document tools.misc.scan_languages, make its implementation less retarded
bzr revid: xmo@openerp.com-20120223103207-ra1a0dzcyoe745cx
2012-02-23 11:32:07 +01:00
Xavier Morel 2332c23c30 [IMP] replaces tools.misc.get_languages by the static dictionary it returns, rename that dict to ALL_LANGUAGES for clarity
bzr revid: xmo@openerp.com-20120223103045-a44cl5kdkrnehc66
2012-02-23 11:30:45 +01:00
Florent Xicluna 9769884ca5 [MERGE] file_open: give precedence to directory before zip.
bzr revid: florent.xicluna@gmail.com-20120208222801-p2gfhmsnptujdfru
2012-02-08 23:28:01 +01:00
Olivier Dony 69a5eca5b4 [IMP] Give precedence to module directories instead of zips while locating resources
The previous behavior gave the precedence to zipped
modules, without any apparent reason, and this is
sub-optimal for several reasons:

1. The default is to have regular modules, not
zipped modules, so looking first for a regular
module is more efficient.
2. Keeping a zipped module next to a regular
module with the same name is not a documented
or supported feature.
3. Even if you were relying on this behavior
having the extracted module take precedence
is more practical: you could simply extract
the zipped module to test a quick fix.

We have another issue related to this feature
because the code looking for zipped modules
escapes the addons paths chroot and goes
up to the filesystem root looking for a zip
module at each step. This is described in
bug 928376 and a fix for it should follow.

lp bug: https://launchpad.net/bugs/928376 fixed

bzr revid: odo@openerp.com-20120208173932-pwhz53vxxdzbo8ja
2012-02-08 18:39:32 +01:00
Florent Xicluna 44e02f756b [FIX] file_open should not search zip files outside its root directory. Fix the returned value with pathinfo=True.
lp bug: https://launchpad.net/bugs/928507 fixed
lp bug: https://launchpad.net/bugs/928376 fixed

bzr revid: florent.xicluna@gmail.com-20120208153304-9443zx2z09bws10x
2012-02-08 16:33:04 +01:00
Vo Minh Thu 283304f9a2 [IMP] warnings: turn warnings.warn into logging.warning:
Warnings are handled with the other logs (and not always sent to stderr),
they also appear under a module __name__ channel instead of py.warn.
The disadvantage is that there is no longer specific warnings,
such as pending deprecation warning or deprecation warning.

bzr revid: vmt@openerp.com-20120125132407-u33idc0qh7ecs1i5
2012-01-25 14:24:07 +01:00
Vo Minh Thu a142292f91 [IMP] openerp.tools: _logger with fully qualified module name.
bzr revid: vmt@openerp.com-20120124140056-hqoy49bh7wyr1xce
2012-01-24 15:00:56 +01:00
Vo Minh Thu a236a3ac75 [IMP] tools: removed deprecated debug() function.
bzr revid: vmt@openerp.com-20120118114910-xrynwguzu0e5zsng
2012-01-18 12:49:10 +01:00
Vo Minh Thu 8c3daeea12 [IMP] tools: removed __builtin__.{all,any} (they were there for previous python versions).
bzr revid: vmt@openerp.com-20120118114640-sm71f9fi48n4qn3q
2012-01-18 12:46:40 +01:00
Vo Minh Thu b5caa70b83 [IMP] tools: removed some functools functions (they were there for previous python versions).
bzr revid: vmt@openerp.com-20120118114109-txh1cjv503xautty
2012-01-18 12:41:09 +01:00
Olivier Dony 9ddd05fb3a [REF] float_utils: moved in its own python module
bzr revid: odo@openerp.com-20111216160426-gya8d1d1zymcz8os
2011-12-16 17:04:26 +01:00
Olivier Dony ba2b2bdae1 [IMP] tools.float_*: more tests with negative values, some cleanup
bzr revid: odo@openerp.com-20111115113605-l5e6gg675qbrvjz6
2011-11-15 12:36:05 +01:00
Olivier Dony ffe640cece [IMP] tools.float_*: added tests and docstrings
bzr revid: odo@openerp.com-20111114182310-kkzh78uej0uuwhaz
2011-11-14 19:23:10 +01:00
Olivier Dony dcb5ff6eac [IMP] res.currency,base: factor out float rounding methods in tools to allow use without currency
Pending: addition of tests

bzr revid: odo@openerp.com-20111114163617-kw7u8rxcie7m2hj5
2011-11-14 17:36:17 +01:00
niv-openerp e42256c478 [imp] switched the dates to UTC. I'm so happy.
bzr revid: nicolas.vanhoren@openerp.com-20110922095443-3pzaup9ryb2vb25m
2011-09-22 11:54:43 +02:00