Ticket #1141 (closed defect: fixed)

Opened 10 years ago

Last modified 10 years ago

bcfg2-lint: AttributeError: 'NoneType' object has no attribute 'splitlines'

Reported by: Alexanderyt <[email protected]…> Owned by:
Priority: major Milestone: Bcfg2 1.3.0 Release
Component: bcfg2-server Version: 1.0
Keywords: Cc:


Ubuntu 12.04 Version: 1.3.0-1~testing2~precise1+e276eef

# bcfg2-lint

Django configuration problem: Please fill out the database NAME in the settings module before using the database. Traceback (most recent call last):

File "/usr/sbin/bcfg2-lint", line 207, in <module>


File "/usr/sbin/bcfg2-lint", line 195, in main

setup=setup, files=files)

File "/usr/sbin/bcfg2-lint", line 31, in run_server_plugins

errorhandler=errorhandler, setup=setup, files=files)

File "/usr/sbin/bcfg2-lint", line 55, in run_plugin

return plugin(*args, dict(files=files, errorhandler=errorhandler)).Run()

File "/usr/lib/pymodules/python2.7/Bcfg2/Server/Lint/", line 23, in Run


File "/usr/lib/pymodules/python2.7/Bcfg2/Server/Lint/", line 117, in check_cfg

self.check_plaintext(,, rtype)

File "/usr/lib/pymodules/python2.7/Bcfg2/Server/Lint/", line 134, in check_plaintext

self.check_lines(filename, data.splitlines(), rtype)

AttributeError?: 'NoneType?' object has no attribute 'splitlines'


Change History

comment:1 Changed 10 years ago by

  • Owner changed from desai to
  • Status changed from new to accepted

I can't seem to replicate this; can you provide some details on a minimal replication case? Thanks.

comment:2 Changed 10 years ago by Alexanderyt <[email protected]…>

I can reproduce this issue if rename any file to <filename.genshi>. For example, please run "mv motd motd.genshi" and now "bcfg2-lint".

comment:3 Changed 10 years ago by

My best guess is that the file you've renamed to .genshi is not a valid Genshi template, so the file cannot be parsed. If that's so, you should see "Failed to load template: <filename>" somewhere in the startup messages when you run bcfg2-lint. Can you verify if that's the case? Thanks.

comment:4 Changed 10 years ago by

  • Status changed from accepted to closed
  • Resolution set to fixed

Turns out I was misunderstanding the problem; fixed in


WARNING! You need to establish a session before you can create or edit tickets. Otherwise the ticket will get treated as spam.


Add a comment

Modify Ticket

Change Properties
<Author field>
as closed
The resolution will be deleted. Next status will be 'reopened'

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.