view docs/api/models.rst @ 7580:927b7934b867

utils: let make_ui return an empty ui.ui() object if the requested hgrc file isn't present 89c30b145bb8 lost an "if repoui" in simplehg, and Kallithea would thus fail on serving repos without a .hg/hgrc : File ".../kallithea/lib/middleware/simplehg.py", line 285, in _augment_hgrc for k, v in repoui.configitems(section): AttributeError: 'bool' object has no attribute 'configitems' It is *only* simplehg that invoke make_ui with read_from 'file'. In this case it could return False if the requested file wasn't present. It was odd and inconsistent that make_ui with read_from 'file' either returned an ui object or the value False. To fix the problem, just let make_ui return the empty ui.ui() if no .hg/hgrc is present. An ui object that just doesn't have any config sections is much better than any alternative.
author Mads Kiilerich <mads@kiilerich.com>
date Tue, 19 Mar 2019 03:05:11 +0100
parents cd6c577ade97
children b6b6955981a5
line wrap: on
line source

.. _models:

========================
The :mod:`models` module
========================

.. automodule:: kallithea.model
   :members:

.. automodule:: kallithea.model.comment
   :members:

.. automodule:: kallithea.model.permission
   :members:

.. automodule:: kallithea.model.repo_permission
   :members:

.. automodule:: kallithea.model.repo
   :members:

.. automodule:: kallithea.model.repo_group
   :members:

.. automodule:: kallithea.model.scm
   :members:

.. automodule:: kallithea.model.user
   :members:

.. automodule:: kallithea.model.user_group
   :members: