[ckan-dev] CKAN "No section: 'formatters'" error

Stefan Oderbolz stefan.oderbolz at liip.ch
Thu Jun 9 09:04:48 UTC 2016


Hi Derek,

the file looks fine. So I guess it must be the path to the file and/or
missing permissions to read the file. Can you successfully run paster
commands? Does the page work if you use "paster serve"? Are you using
Apache with WSGI, if so check the apache.wsgi file, if it uses to correct
path to the config file.

- Stefan

On Wed, Jun 8, 2016 at 4:52 PM, Derek Hohls <dhohls at csir.co.za> wrote:

> Hi Stefan
>
> I am not sure its going to help to make *no* changes as the links to, for
> example, solr and postgres are not going to work (also in Dockers) if these
> settings are not provided.  By minimal, I meant just the ones appearing in
> the installation guide. AFAIK, I did not change anything about formatters.
>
> I will send a copy of the file to your email.
>
> >>> Stefan Oderbolz <stefan.oderbolz at liip.ch> 06/06/16 8:59 AM >>>
> Can you get it to work if you make *no* changes at all? Or what exactly
> are your "minimum" changes?
> Somehow there is a problem with the file and it's hard to tell without
> access to the whole file.
>
> On Fri, Jun 3, 2016 at 4:11 PM, Derek Hohls <dhohls at csir.co.za> wrote:
>
>> Thanks Stefan
>>
>> I am using the default production.ini file supplied with the software and
>> attempting to make the "minimum"  changes to it, in order for CKAN to work.
>>
>> The sections you asked about are:
>>
>> [app:main]
>> use = egg:ckan
>> full_stack = true
>> cache_dir = /tmp/%(ckan.site_id)s/
>> beaker.session.key = ckan
>>
>> [formatters]
>> keys = generic
>>
>> I cannot see any reference to "formatters" in the
>> http://docs.ckan.org/en/latest/maintaining/configuration.html#ckan-configuration-file
>> document?
>>
>> Thanks
>> Derek
>>
>> >>> Stefan Oderbolz <stefan.oderbolz at liip.ch> 02/06/16 9:38 PM >>>
>> Check the sections in your config file (/etc/ckan/default/production.ini).
>> Is there a [app:main] section? Is there a [formatters] section?
>> Did you generate the config file? If so how? Or what is your template?
>>
>> You can read more about the config file and its structure here:
>> http://docs.ckan.org/en/latest/maintaining/configuration.html#ckan-configuration-file
>>
>> If nothing helps, you can try to re-generate the configuration using the
>> following paster command:
>>
>> paster make-config ckan /etc/ckan/default/new-production.ini
>>
>>
>>
>> On Tue, May 31, 2016 at 5:02 PM, Derek Hohls <dhohls at csir.co.za> wrote:
>>
>>> I have CKAN installed in a container.
>>>
>>> When trying to reach the CKAN webpage, I am getting this error in the
>>> ckan_default.error.log::
>>>
>>>  Traceback (most recent call last):
>>>    File "/etc/ckan/default/apache.wsgi", line 9, in <module>
>>>      fileConfig(config_filepath)
>>>    File
>>> "/usr/lib/ckan/default/lib/python2.7/site-packages/paste/script/util/logging_config.py",
>>> line 93, in fileConfig
>>>      formatters = _create_formatters(cp)
>>>    File
>>> "/usr/lib/ckan/default/lib/python2.7/site-packages/paste/script/util/logging_config.py",
>>> line 125, in _create_formatters
>>>      flist = cp.get("formatters", "keys")
>>>    File "/usr/lib/python2.7/ConfigParser.py", line 330, in get
>>>      raise NoSectionError(section)
>>>  NoSectionError: No section: 'formatters'
>>>
>>>
>>> The ckan.docs website says this is a common error::
>>>
>>>     *NoSectionError: No section: 'formatters'*
>>>
>>>     This suggests that the config file specified with the paster
>>> --config
>>>     parameter (e.g. myconfig.ini) is incorrectly formatted. This may be
>>> true,
>>>     but this error is also printed if you specify an incorrect filename
>>> for
>>>     the config file!
>>>
>>> I checked in the section of code where the error is raised.  It seems as
>>> if the file it is looking for is stored in the 'fname' variable.  Echoing
>>> the contents of this variable shows its value to be
>>> `/etc/ckan/default/production.ini` (which is what I would expect).  This
>>> implies the file itself is incorrectly formatted.  How do I go about
>>> finding what is incorrect about the formatting & then fixing it?
>>>
>>> Thanks
>>> Derek
>>>
>>>
>>> --
>>> This message is subject to the CSIR's copyright terms and conditions,
>>> e-mail legal notice, and implemented Open Document Format (ODF) standard.
>>> The full disclaimer details can be found at
>>> http://www.csir.co.za/disclaimer.html.
>>>
>>>
>>> This message has been scanned for viruses and dangerous content by
>>> *MailScanner* <http://www.mailscanner.info/>,
>>> and is believed to be clean.
>>>
>>>
>>> Please consider the environment before printing this email.
>>>
>>>
>>> _______________________________________________
>>> ckan-dev mailing list
>>> ckan-dev at lists.okfn.org
>>> https://lists.okfn.org/mailman/listinfo/ckan-dev
>>> Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
>>>
>>>
>>
>>
>> --
>> Liip AG  // Limmatstrasse 183 //  CH-8005 Zürich
>> Tel +41 43 500 39 80 // GnuPG 0x7B588C67 // www.liip.ch
>>
>> --
>> This message is subject to the CSIR's copyright terms and conditions,
>> e-mail legal notice, and implemented Open Document Format (ODF) standard.
>> The full disclaimer details can be found at
>> http://www.csir.co.za/disclaimer.html.
>>
>>
>> This message has been scanned for viruses and dangerous content by
>> *MailScanner* <http://www.mailscanner.info/>,
>> and is believed to be clean.
>>
>>
>> Please consider the environment before printing this email.
>>
>> --
>> This message is subject to the CSIR's copyright terms and conditions,
>> e-mail legal notice, and implemented Open Document Format (ODF) standard.
>> The full disclaimer details can be found at
>> http://www.csir.co.za/disclaimer.html.
>>
>>
>> This message has been scanned for viruses and dangerous content by
>> *MailScanner* <http://www.mailscanner.info/>,
>> and is believed to be clean.
>>
>>
>> Please consider the environment before printing this email.
>>
>>
>
>
> --
> Liip AG  // Limmatstrasse 183 //  CH-8005 Zürich
> Tel +41 43 500 39 80 // GnuPG 0x7B588C67 // www.liip.ch
>
> --
> This message is subject to the CSIR's copyright terms and conditions,
> e-mail legal notice, and implemented Open Document Format (ODF) standard.
> The full disclaimer details can be found at
> http://www.csir.co.za/disclaimer.html.
>
>
> This message has been scanned for viruses and dangerous content by
> *MailScanner* <http://www.mailscanner.info/>,
> and is believed to be clean.
>
>
> Please consider the environment before printing this email.
>
> --
> This message is subject to the CSIR's copyright terms and conditions,
> e-mail legal notice, and implemented Open Document Format (ODF) standard.
> The full disclaimer details can be found at
> http://www.csir.co.za/disclaimer.html.
>
>
> This message has been scanned for viruses and dangerous content by
> *MailScanner* <http://www.mailscanner.info/>,
> and is believed to be clean.
>
>
> Please consider the environment before printing this email.
>
>


-- 
Liip AG  // Limmatstrasse 183 //  CH-8005 Zürich
Tel +41 43 500 39 80 // GnuPG 0x7B588C67 // www.liip.ch
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20160609/c64201aa/attachment-0003.html>


More information about the ckan-dev mailing list