tiramisu.git
6 years ago* config herite from BaseInformation class
Emmanuel Garette [Wed, 8 May 2013 16:14:42 +0000 (18:14 +0200)]
* config herite from BaseInformation class
* _cfgimpl_ => _impl_
* optimpl_ => impl_
* properties/permissives are now set/frozenset
* validation raise ValueError if not valid, didn't return anything otherwise
* consistencies are now validate in setting and when deleting value
* ip/network with netmask consistency now works
* DomainnameOption now works
* if no validation, don't set cache for value
* symlinkoption: remove path (not used)

6 years agocompare option
Emmanuel Garette [Sun, 5 May 2013 19:43:19 +0000 (21:43 +0200)]
compare option

6 years agowork on MetaConfig
Emmanuel Garette [Thu, 2 May 2013 09:34:57 +0000 (11:34 +0200)]
work on MetaConfig

6 years agotiramisu/i18n.py: pep8 compliants
Emmanuel Garette [Thu, 2 May 2013 09:23:47 +0000 (11:23 +0200)]
tiramisu/i18n.py: pep8 compliants

6 years agotiramisu/setting.py: _get_properties and validate_properties are now more easier...
Emmanuel Garette [Thu, 2 May 2013 09:23:04 +0000 (11:23 +0200)]
tiramisu/setting.py: _get_properties and validate_properties are now more easier to read and has best performance

6 years agoRequires need option, not path
Emmanuel Garette [Fri, 26 Apr 2013 12:40:44 +0000 (14:40 +0200)]
Requires need option, not path
Valid requires

6 years agomissing properties in PropertiesOptionError
Emmanuel Garette [Wed, 24 Apr 2013 15:40:16 +0000 (17:40 +0200)]
missing properties in PropertiesOptionError

6 years agoIn make_dict check PropertyConfigError for OptionDescription
Emmanuel Garette [Wed, 24 Apr 2013 09:47:01 +0000 (11:47 +0200)]
In make_dict check PropertyConfigError for OptionDescription

Begin work's on MetaConfig

6 years agoadd a test for force_store_value in read_only mode
Emmanuel Garette [Tue, 23 Apr 2013 17:01:03 +0000 (19:01 +0200)]
add a test for force_store_value in read_only mode

6 years agoforce_store_value store value but not in write mode
Emmanuel Garette [Tue, 23 Apr 2013 14:43:31 +0000 (16:43 +0200)]
force_store_value store value but not in write mode

6 years agoMerge branch 'master' of git://git.labs.libre-entreprise.org/tiramisu
Philippe Caseiro [Tue, 23 Apr 2013 14:30:45 +0000 (16:30 +0200)]
Merge branch 'master' of git://git.labs.libre-entreprise.org/tiramisu

6 years ago * Makefile : Installation des fichiers de langue
Philippe Caseiro [Tue, 23 Apr 2013 14:20:02 +0000 (16:20 +0200)]
 * Makefile : Installation des fichiers de langue

Compilation et Installation des fichiers de traductions pour
Tiramisu

6 years ago Ajout des fichiers de traduction et mise à jour de i18n.py
Philippe Caseiro [Tue, 23 Apr 2013 12:08:17 +0000 (14:08 +0200)]
 Ajout des fichiers de traduction et mise à jour de i18n.py

 Support du chargement des locales

6 years ago'make test' deleted
gwen [Tue, 23 Apr 2013 12:14:19 +0000 (14:14 +0200)]
'make test' deleted

6 years agoremove an unused callback in test
Emmanuel Garette [Tue, 23 Apr 2013 09:41:16 +0000 (11:41 +0200)]
remove an unused callback in test

6 years agotiramisu/values: _empty should not validate with defaultvalue, defaultvalue is alread...
Emmanuel Garette [Tue, 23 Apr 2013 08:41:47 +0000 (10:41 +0200)]
tiramisu/values: _empty should not validate with defaultvalue, defaultvalue is already in value

6 years agodon't raise if check_disabled is True
Emmanuel Garette [Mon, 22 Apr 2013 18:42:54 +0000 (20:42 +0200)]
don't raise if check_disabled is True

6 years agomissing import
Emmanuel Garette [Mon, 22 Apr 2013 14:48:56 +0000 (16:48 +0200)]
missing import

6 years agocallback must be a function and validator support same paramaters has callback
Emmanuel Garette [Mon, 22 Apr 2013 14:48:13 +0000 (16:48 +0200)]
callback must be a function and validator support same paramaters has callback

6 years agoremove _setoption in SymLinkOption
Emmanuel Garette [Mon, 22 Apr 2013 07:19:05 +0000 (09:19 +0200)]
remove _setoption in SymLinkOption
objimpl_ => optimpl_
ConflictConfigError => ConflictError
add read_write/read_only/getowner in Config

6 years agoadd option name's validation and rename Option method with objimpl_
Emmanuel Garette [Sat, 20 Apr 2013 19:58:52 +0000 (21:58 +0200)]
add option name's validation and rename Option method with objimpl_

6 years agoManipulate properties is now more convenient:
Emmanuel Garette [Sat, 20 Apr 2013 15:30:05 +0000 (17:30 +0200)]
Manipulate properties is now more convenient:

c.cfgimpl_get_settings().has_property('hidden') => 'hidden' in c.cfgimpl_get_settings()
c.cfgimpl_get_settings().has_property('hidden', option1) => 'frozen' in c.cfgimpl_get_settings()[opt]

c.cfgimpl_get_settings().get_properties(option1) => c.cfgimpl_get_settings()[option1]
c.cfgimpl_get_settings().get_properties(option1) => c.cfgimpl_get_settings()[option1]

c.cfgimpl_get_settings().add_property('hidden', option1) => c.cfgimpl_get_settings()[optiont1].append('hidden')
c.cfgimpl_get_settings().del_property('hidden', option1) => c.cfgimpl_get_settings()[optiont1].remove('hidden')

c.cfgimpl_get_settings().enable_property('hidden') => c.cfgimpl_get_settings().append('hidden')
c.cfgimpl_get_settings().disable_property('hidden') => c.cfgimpl_get_settings().remove('hidden')

6 years agocache for properties is now in get_properties and not for validate_properties
Emmanuel Garette [Sat, 20 Apr 2013 09:25:14 +0000 (11:25 +0200)]
cache for properties is now in get_properties and not for validate_properties

6 years agoremove expired cache with config.cfgimpl_reset_cache(True)
Emmanuel Garette [Fri, 19 Apr 2013 20:42:33 +0000 (22:42 +0200)]
remove expired cache with config.cfgimpl_reset_cache(True)

6 years agoadd SlaveError for slave's length
Emmanuel Garette [Fri, 19 Apr 2013 18:23:34 +0000 (20:23 +0200)]
add SlaveError for slave's length

6 years agoadd SlaveError for slave's length
Emmanuel Garette [Fri, 19 Apr 2013 18:10:55 +0000 (20:10 +0200)]
add SlaveError for slave's length

6 years agoall multi gestion is now in Multi
Emmanuel Garette [Thu, 18 Apr 2013 21:06:14 +0000 (23:06 +0200)]
all multi gestion is now in Multi

6 years ago* to "reset" a value, now you just have to delete it
Emmanuel Garette [Thu, 18 Apr 2013 18:26:40 +0000 (20:26 +0200)]
* to "reset" a value, now you just have to delete it
config.unwrap_from_path("string").reset(config) => del(config.string)
* add cache for value/setting to 5 secds
to "reset" cache just do: config.cfgimpl_clean_cache()
* can desactivate cache by removing "expire" property

6 years agopass force_properties to value's _setitem and remove config's setoption
Emmanuel Garette [Wed, 17 Apr 2013 21:19:53 +0000 (23:19 +0200)]
pass force_properties to value's _setitem and remove config's setoption

6 years ago_empty is u'' for UnicodeOption
Emmanuel Garette [Wed, 17 Apr 2013 20:06:10 +0000 (22:06 +0200)]
_empty is u'' for UnicodeOption

6 years agoMultiTypeError => ValueError
Emmanuel Garette [Wed, 17 Apr 2013 19:57:06 +0000 (21:57 +0200)]
MultiTypeError => ValueError

6 years agoRename AmbigousOptionError as ConflictOptionError
Emmanuel Garette [Wed, 17 Apr 2013 19:50:31 +0000 (21:50 +0200)]
Rename AmbigousOptionError as ConflictOptionError

6 years agoproperties validation not in setting and now launch when modify multi
Emmanuel Garette [Wed, 17 Apr 2013 19:33:34 +0000 (21:33 +0200)]
properties validation not in setting and now launch when modify multi

6 years agomandatory is a true property (no more MandatoryError) + tests
Emmanuel Garette [Tue, 16 Apr 2013 20:44:16 +0000 (22:44 +0200)]
mandatory is a true property (no more MandatoryError) + tests

6 years agoonly catch PropertiesOptionError
Emmanuel Garette [Tue, 16 Apr 2013 10:04:20 +0000 (12:04 +0200)]
only catch PropertiesOptionError

6 years agoSubConfig: first argument must be a OD
Emmanuel Garette [Tue, 16 Apr 2013 09:51:48 +0000 (11:51 +0200)]
SubConfig: first argument must be a OD

6 years agoauto_store_value => force_store_value
Emmanuel Garette [Tue, 16 Apr 2013 09:30:02 +0000 (11:30 +0200)]
auto_store_value => force_store_value

6 years agoAdd "force_store_value" property. If set, store, for example, calculated value as...
Emmanuel Garette [Tue, 16 Apr 2013 07:45:42 +0000 (09:45 +0200)]
Add "force_store_value" property. If set, store, for example, calculated value as owner values.
So calculated value are calculate only one time.

6 years agoadd cons_lower + DomainnameOption
Emmanuel Garette [Tue, 16 Apr 2013 07:34:00 +0000 (09:34 +0200)]
add cons_lower + DomainnameOption

6 years agoreview exception
Emmanuel Garette [Sun, 14 Apr 2013 10:01:32 +0000 (12:01 +0200)]
review exception

6 years agoconsistencies now a list
Emmanuel Garette [Sun, 14 Apr 2013 08:14:06 +0000 (10:14 +0200)]
consistencies now a list

6 years agoadd gettext support
Emmanuel Garette [Sat, 13 Apr 2013 21:09:05 +0000 (23:09 +0200)]
add gettext support

6 years agoattribute in Option now starts with '_'
Emmanuel Garette [Sat, 13 Apr 2013 20:50:55 +0000 (22:50 +0200)]
attribute in Option now starts with '_'
add ValidateError
add consistancies in Option
remove byattr in find

6 years agoValues validate now value
Emmanuel Garette [Thu, 11 Apr 2013 09:30:58 +0000 (11:30 +0200)]
Values validate now value

6 years agodon't launch apply_requires more than needed
Emmanuel Garette [Mon, 8 Apr 2013 14:12:23 +0000 (16:12 +0200)]
don't launch apply_requires more than needed

6 years agoNoValueReturn is not needed now + apply_requires is now in settings
Emmanuel Garette [Mon, 8 Apr 2013 14:05:56 +0000 (16:05 +0200)]
NoValueReturn is not needed now + apply_requires is now in settings

6 years agosuppress _cfgimpl_parent and _cfgimpl_get_path() from SubConfig
Emmanuel Garette [Fri, 5 Apr 2013 14:59:48 +0000 (16:59 +0200)]
suppress _cfgimpl_parent and _cfgimpl_get_path() from SubConfig

6 years agotiramisu/config.py: _cfgimpl_subconfigs is not used
Emmanuel Garette [Fri, 5 Apr 2013 10:31:50 +0000 (12:31 +0200)]
tiramisu/config.py: _cfgimpl_subconfigs is not used

6 years agotiramisu/config.py can specify return type for find ('option', 'value', 'path') and...
Emmanuel Garette [Fri, 5 Apr 2013 10:20:33 +0000 (12:20 +0200)]
tiramisu/config.py can specify return type for find ('option', 'value', 'path') and remove get

user need replace config.get(value) by config.find(byname="value", type_='value')

6 years agopermissives are for a specified option not config
Emmanuel Garette [Thu, 4 Apr 2013 13:14:16 +0000 (15:14 +0200)]
permissives are for a specified option not config

6 years agoset permissive to cfgimpl_get_home_by_path
Emmanuel Garette [Thu, 4 Apr 2013 10:16:18 +0000 (12:16 +0200)]
set permissive to cfgimpl_get_home_by_path

6 years agorewrite make_dict
Emmanuel Garette [Thu, 4 Apr 2013 09:24:00 +0000 (11:24 +0200)]
rewrite make_dict

6 years agoMerge branch 'master' of ssh://git.labs.libre-entreprise.org/gitroot/tiramisu
Emmanuel Garette [Wed, 3 Apr 2013 15:05:46 +0000 (17:05 +0200)]
Merge branch 'master' of ssh://git.labs.libre-entreprise.org/gitroot/tiramisu

6 years agotiramisu/value.py : self.opt => opt + disable permissive in read_write mode
Emmanuel Garette [Wed, 3 Apr 2013 15:05:41 +0000 (17:05 +0200)]
tiramisu/value.py : self.opt => opt + disable permissive in read_write mode

6 years agotest_option_has_an_api_name temporarily disabled
gwen [Wed, 3 Apr 2013 14:01:53 +0000 (16:01 +0200)]
test_option_has_an_api_name temporarily disabled

6 years agooptimisations and all is properties
Emmanuel Garette [Wed, 3 Apr 2013 10:20:26 +0000 (12:20 +0200)]
optimisations and all is properties

6 years agobuild cache builds correctly now
gwen [Wed, 27 Mar 2013 16:01:20 +0000 (17:01 +0100)]
build cache builds correctly now

6 years agoremise en fonction des self._cfgimpl_slots
Garette Emmanuel [Wed, 27 Mar 2013 15:41:22 +0000 (16:41 +0100)]
remise en fonction des self._cfgimpl_slots

6 years agoLe cache des paths est dans l'OptionDescription
Garette Emmanuel [Wed, 27 Mar 2013 15:16:15 +0000 (16:16 +0100)]
Le cache des paths est dans l'OptionDescription
Utilisation des slots pour la Config

Il faut 566Mo de mémoire pour charger 50 variantes de 100 serveurs chacuns (5000 serveurs en tout).

ref #5111

6 years agoworks on performante
Garette Emmanuel [Tue, 26 Mar 2013 09:29:49 +0000 (10:29 +0100)]
works on performante

6 years agosupport break in iterator
Garette Emmanuel [Mon, 25 Mar 2013 13:21:30 +0000 (14:21 +0100)]
support break in iterator

6 years agoadd import and name => opt._name
Garette Emmanuel [Mon, 25 Mar 2013 10:45:21 +0000 (11:45 +0100)]
add import and name => opt._name

6 years agoadd UnicodeOption
Garette Emmanuel [Wed, 20 Mar 2013 11:37:27 +0000 (12:37 +0100)]
add UnicodeOption

6 years agotests for get_home_by_paths
gwen [Fri, 15 Mar 2013 08:24:43 +0000 (09:24 +0100)]
tests for get_home_by_paths

6 years agocfgimpl_permissive is not the permissive param
Garette Emmanuel [Thu, 14 Mar 2013 16:51:51 +0000 (17:51 +0100)]
cfgimpl_permissive is not the permissive param

6 years agoget_home_by_path is a public method
Garette Emmanuel [Thu, 14 Mar 2013 15:07:26 +0000 (16:07 +0100)]
get_home_by_path is a public method

6 years agoadd permissive in config
Garette Emmanuel [Thu, 14 Mar 2013 10:31:44 +0000 (11:31 +0100)]
add permissive in config

6 years agoinformations attribute finally works
Garette Emmanuel [Wed, 13 Mar 2013 10:29:29 +0000 (11:29 +0100)]
informations attribute finally works

6 years agoadds information attribute to an option
Garette Emmanuel [Tue, 12 Mar 2013 16:45:28 +0000 (17:45 +0100)]
adds information attribute to an option

6 years agoadds information attribute to an option
Garette Emmanuel [Tue, 12 Mar 2013 15:54:39 +0000 (16:54 +0100)]
adds information attribute to an option

6 years agoiter on all objects
gwen [Thu, 7 Mar 2013 10:02:18 +0000 (11:02 +0100)]
iter on all objects

6 years agogenerate correct len for slave if no value
Garette Emmanuel [Wed, 6 Mar 2013 16:17:33 +0000 (17:17 +0100)]
generate correct len for slave if no value

6 years agoMerge branch 'master' of ssh://git.labs.libre-entreprise.org/gitroot/tiramisu
gwen [Wed, 6 Mar 2013 08:34:07 +0000 (09:34 +0100)]
Merge branch 'master' of ssh://git.labs.libre-entreprise.org/gitroot/tiramisu

6 years agovalid name accepts only str type
gwen [Wed, 6 Mar 2013 08:22:56 +0000 (09:22 +0100)]
valid name accepts only str type

6 years agoBaseType refactoring
gwen [Fri, 1 Mar 2013 12:10:52 +0000 (13:10 +0100)]
BaseType refactoring

6 years agofinally a getvalue without a getattr
gwen [Wed, 27 Feb 2013 10:09:13 +0000 (11:09 +0100)]
finally a getvalue without a getattr

6 years agotype shall not be a list
gwen [Wed, 27 Feb 2013 07:50:41 +0000 (08:50 +0100)]
type shall not be a list

6 years agotype shall not be a list
gwen [Tue, 26 Feb 2013 16:04:41 +0000 (17:04 +0100)]
type shall not be a list

6 years agotype shall not be a list
gwen [Tue, 26 Feb 2013 15:58:44 +0000 (16:58 +0100)]
type shall not be a list

6 years agoprevious value api
gwen [Tue, 26 Feb 2013 13:56:15 +0000 (14:56 +0100)]
previous value api

6 years agois_empty
gwen [Tue, 26 Feb 2013 13:31:45 +0000 (14:31 +0100)]
is_empty

6 years agopep8
gwen [Mon, 25 Feb 2013 15:24:30 +0000 (16:24 +0100)]
pep8

6 years agooption names shall be valid names
gwen [Mon, 25 Feb 2013 15:06:10 +0000 (16:06 +0100)]
option names shall be valid names

6 years agomasterlen > instead of !=
gwen [Mon, 25 Feb 2013 14:52:10 +0000 (15:52 +0100)]
masterlen > instead of !=

6 years agoprivate method _get_multitype()
gwen [Mon, 25 Feb 2013 14:12:09 +0000 (15:12 +0100)]
private method _get_multitype()

6 years agoprivate method _get_multitype()
gwen [Mon, 25 Feb 2013 13:27:12 +0000 (14:27 +0100)]
private method _get_multitype()

6 years agooption's name shall not have an api's method name
gwen [Mon, 25 Feb 2013 10:33:20 +0000 (11:33 +0100)]
option's name shall not have an api's method name

6 years agoadd masters/slaves in the Values()
gwen [Fri, 22 Feb 2013 10:09:17 +0000 (11:09 +0100)]
add masters/slaves in the Values()

6 years agorefactoring values
gwen [Thu, 21 Feb 2013 16:07:00 +0000 (17:07 +0100)]
refactoring values

6 years agodoc theme
gwen [Tue, 19 Feb 2013 15:32:31 +0000 (16:32 +0100)]
doc theme

6 years agodoc theme
gwen [Tue, 19 Feb 2013 15:24:13 +0000 (16:24 +0100)]
doc theme

6 years agoupdate of the doc
gwen [Tue, 19 Feb 2013 10:24:17 +0000 (11:24 +0100)]
update of the doc

6 years agorefactoring, the values are in an OptionValues object
gwen [Fri, 8 Feb 2013 10:50:22 +0000 (11:50 +0100)]
refactoring, the values are in an OptionValues object

6 years agovalues are in value objects now
gwen [Thu, 7 Feb 2013 15:20:21 +0000 (16:20 +0100)]
values are in value objects now

6 years agomaster groups that have multis
gwen [Wed, 6 Feb 2013 16:19:56 +0000 (17:19 +0100)]
master groups that have multis

6 years agomasters shall have the same names as groups
gwen [Wed, 6 Feb 2013 15:21:30 +0000 (16:21 +0100)]
masters shall have the same names as groups

6 years agoadds a freeze_everything possibility
gwen [Wed, 6 Feb 2013 13:59:24 +0000 (14:59 +0100)]
adds a freeze_everything possibility

6 years agovalidator set to false for read_write in setting
gwen [Wed, 6 Feb 2013 13:34:12 +0000 (14:34 +0100)]
validator set to false for read_write in setting

6 years agoFix line wrapping and some raise messages spacing
Daniel Dehennin [Thu, 31 Jan 2013 16:01:10 +0000 (17:01 +0100)]
Fix line wrapping and some raise messages spacing

* tiramisu/option.py (Multi.append): do not wrapp short line.
  (validate_requires_arg): Add missing space for multi line strings.

6 years agoFix appending to a non-grouped multi
Daniel Dehennin [Thu, 31 Jan 2013 15:57:15 +0000 (16:57 +0100)]
Fix appending to a non-grouped multi

When the multi is not grouped, just set the value and do not try to
update len of inexistant slaves.

The code path try to update the len of all other variables under the
OptionDescription of the multi.

* tiramisu/option.py (Multi.append): return after setting the value.

Fixes: #4811 @10m