.. _conf: ================ Configurazione ================ urls.py ======= in urls.py devono essere avviati i vari autodiscover:: autocomplete_light.autodiscover() admin.autodiscover() # Not needed for dj > 1.7 admin_tools.dashboard.autodiscover() in aggiunta devono essere aggiunti i pattern per la localizzazione. :ref:`jmb-start` dovrebbe fare questo in automatico. .. _settings: ============= Settings ============= ``jmb.core`` only looks for 3 variables, no one is required: :WARNING_RULES: determine visibility of Warnings based on module and mesage text :JMB_MONKEY_PATCH_INCLUDE: patches that will be applied :JMB_MONKEY_PATCH_EXCLUDE: patches that won't be applied .. automodule:: jmb.core.apps WARNING_RULES ============= ``WARNING_RULES`` It's based on 2 criteria: * the module where the warning is issued * the regexp of the text of the error It uses ``warning.filterwarnings`` and is fired from within :ref:`app-config` in the ``JmbCoreConfig.__init__`` so as to come *after* django's ``configure_logging`` but before any module import ``WARNING_RULES`` is a list of tuples, each tuple is composed of a ``module_name`` and a regexp. The goal of this settings is to silence warning coming from packages that you don't want/may change so that you don't miss important warning that you shoud take care of. The main necessity comes from the fact that in the transition from on django rel to the other some packages may raise warning that flood the console. If I concentrate on porting one package I don't want other packages to hide these messages in the mess of other ones. An example of the use can be:: WARNING_RULES = [ ('cms', None), ('djangocms_googlemap', None), ('', '.*(PagePermission|PageUserAdmin|ViewRestriction).*'), ] the last tupe is needed becouse in some situation. filterwarning doesn't understand where the messages was originated (I guess when a metaclass generates the classes) .. _monkey: .. automodule:: jmb.core.monkey .. .. _jmbcollect .. automodule:: jmb.core.storage