[kforge-user] Error: unicode() argument 2 must be string, not None.

Nick Ascione nick.ascione at gmail.com
Wed Jan 20 13:34:58 UTC 2010


Thanks for getting back to me John. The version of the SQL object is as follows.

[root at localhost bin]# more sqlobject-admin
#!/usr/local/kforge/bin/python
# EASY-INSTALL-SCRIPT: 'SQLObject==0.12.0','sqlobject-admin'
__requires__ = 'SQLObject==0.12.0'
import pkg_resources
pkg_resources.run_script('SQLObject==0.12.0', 'sqlobject-admin')
[root at localhost bin]#



On Wed, Jan 20, 2010 at 6:55 AM, John Bywater
<john.bywater at appropriatesoftware.net> wrote:
> Hi Nick,
>
> Thanks for your message.
>
> Firstly, I should admit, I haven't been testing KForge with MySQL. I will
> start doing that, because there are clearly MySQL-specific issues that can't
> be ignored.
>
> I just tried to setup KForge against MySQL. It fails, but with a different
> error ("BLOB/TEXT column 'name' used in key specification without a key
> length") from the error you reported.
>
> The error you reported "unicode() argument 2 must be string, not None" was
> generated from within SQLObject's createTable() method. That error would pop
> up whenever the optional 'encoding' argument of the unicode() class exists,
> but is a null value. Looking though the SQLObject code, it appears that this
> should always be set. So I'm wondering, which version of SQLObject do you
> have?
>
> I will fix KForge for MySQL, but not today. So if you have a deadline, using
> KForge at first with SQLite or PostgreSQL might be the way to go. It's
> possible later to switch database systems (dump KForge domain data, adjust
> db config, reload domain data) so you could start with SQLite, and then move
> to MySQL when we've fixed the issues you have highlighted.
>
> At any rate, please let me know how you get on.
>
> Best wishes,
>
> John.
>
>
>
>
>
>
> Nick Ascione wrote:
>>
>> Hello,
>> I am trying to install kforge and I get the following error.
>> <<
>> (kforge)[root at localhost ~]# kforge-admin --config
>> /usr/local/kforge/etc/kforge.conf db init
>> kforge [ERROR] Couldn't create table for class 'State': Error:
>> unicode() argument 2 must be string, not None. Attributes are:
>> {'name': <String typeName='String' name='name'>}
>> Error: Couldn't init the domain data: Couldn't create table for class
>> 'State': Error: unicode() argument 2 must be string, not None.
>> Attributes are: {'name': <String typeName='String' name='name'>}
>> (kforge)[root at localhost ~]#
>>
>> The DB connection is working properly and the database default
>> character set is utf8. I am using mysql server version 5.0.77
>>
>> Here is the config file. I removed the passwords.
>>
>> (kforge)[root at localhost ~]# more /usr/local/kforge/etc/kforge.conf
>> [DEFAULT]
>> # Base path (required, but only within some of the values below).
>> master_dir = /usr/local/kforge
>>
>> # Path to folder for KForge project service files (required).
>> project_data_dir = %(master_dir)s/var/project
>>
>> # Name of KForge service (default: KForge).
>> service_name = KForge
>>
>> # Server name of KForge service (defaults to platform hostname).
>> domain_name = kforge.my.domain
>>
>> # Mode of operation (default: production).
>> system_mode = production
>>
>> [virtualenv]
>> # Path to bin folder of virtual environment (required within virtualenv).
>> bin_dir = %(master_dir)s/bin
>>
>> [environment]
>> # Timezone, see platform's zoneinfo database (defaults to environment).
>> timezone = Europe/London
>>
>> [logging]
>> # Path to KForge log file (required).
>> log_file = %(master_dir)s/var/log/kforge.log
>> # Log level ERROR, WARNING, or INFO (default: ERROR).
>> level = INFO
>>
>> [db]
>> # For sqlite type, set file path as db name. Otherwise for
>> # postgres and mysql type, set a normal database name, and
>> # set the user, password and host if necessary. (Required.)
>> type = mysql
>> name = kforge
>> user = kforge
>> pass = ******
>> host = localhost
>>
>> [memos]
>> # Enable memoization of access controller results (not enabled by
>> default).
>> enabled = on
>> # Maximum number of memos to store (default: 3000).
>> limit = 3000
>> # Maximum time (seconds) validity of memos (default: 30).
>> expire = 30
>>
>> [django]
>> # Path to folder of template files (required).
>> templates_dir = %(master_dir)s/templates
>> # Secret to seed session key generation (default: not-a-secret).
>> secret_key = franksinatra
>>
>> [www]
>> # Path to folder with css, images, and scripts (required).
>> media_dir = %(master_dir)s/media
>> # Path to auto-generated Apache configuration file (required).
>> apache_config_file = %(master_dir)s/var/httpd-autogenerated.conf
>> # Shell command to reload Apache when config changes (default: blank).
>> reload_apache = sudo /etc/init.d/httpd restart
>>
>> [email]
>> # Send notifications of changes to administrators (not enabled by
>> default).
>> notify_changes = on
>> # Email address for send of service emails (defaults to good guess).
>> service_address = kforge-noreply at blah.com
>> # Socket for connections with SMTP server (default: localhost).
>> smtp_host = localhost
>>
>> [feed]
>> # Maximum number of items in feed (default: 100).
>> length = 100
>> # Maximum number of items in feed summary (default: 25).
>> length_summary = 25
>>
>> ## ********************************************************************
>> ## Plugins
>> ## ********************************************************************
>> [moin]
>> # Path to MoinMoin folder containing the htdocs folder (required).
>> system_path = /usr/share/moin
>>
>> [trac]
>> # Trac admin script (default: trac-admin).
>> admin_script = trac-admin
>> # Path to Trac templates folder (required < v0.11).
>> templates_path = /usr/share/trac/templates
>> # Path to Trac htdocs folder (optional).
>> #htdocs_path = /usr/share/trac/htdocs
>>
>> [wordpress]
>> # Path to master Wordpress installation to be used as a template
>> (required).
>> master_path = /usr/share/wordpress
>>
>> [joomla]
>> # Path to master Joomla installation to be used as a template (required).
>> master_path = /usr/share/joomla_1.5
>> # Shell command to backup the Joomla database (required).
>> backup_command = mysqldump --user=kforge --password=***** kforge
>>
>> _______________________________________________
>> kforge-user mailing list
>> kforge-user at lists.okfn.org
>> http://lists.okfn.org/mailman/listinfo/kforge-user
>
>




More information about the kforge-user mailing list