Discussion:
[Agilo for Trac] Activiating Agilo in legacy database
Mattias Vannergård
2015-03-06 11:34:29 UTC
Permalink
Hi!

I have run Agilo for Trac locally on a fresh database, and it runs fine. We
are in the progress to activate it for the huge legacy database, and it
seems that no matter what I do, I run into upgrade-problems.

First I get the

TypeError: int() argument must be a string or a number, not 'NoneType'

Then I get the

OperationalError: table agilo_link already exists

How do I get Agilo for Trac working on an exisiting Trac-database?

I have currently no more ideas of what to try, or how to trace down the
first TypeError?

Any tips?

BR
/Mattias
--
--
Follow Agilo on Twitter: http://twitter.com/agilofortrac
Please support us by reviewing and voting on:
http://userstories.com/products/8-agilo-for-scrum
http://ohloh.net/p/agilo-trac
http://freshmeat.net/projects/agiloforscrum

You have received this message because you are subscribed to
the "Agilo for Trac" Google Group. This group is focused on
supporting Agilo for Trac users and is moderated by
Agilo Software GmbH <http://www.agilosoftware.com>.

To post to this group, send email to ***@googlegroups.com
To unsubscribe from this group, send an email to
agilo+***@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/agilo

---
You received this message because you are subscribed to the Google Groups "Agilo for Trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email to agilo+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Mattias Vannergård
2015-03-06 15:17:47 UTC
Permalink
Here is the current log, when it happens:
2015-03-06 12:24:28,249 Trac[log] DEBUG: [Environment]: [DB]: Successfully
Created Table agilo_burndown_data_change
2015-03-06 12:24:28,251 Trac[console] ERROR: Exception in trac-admin
command:
Traceback (most recent call last):
File "build/bdist.linux-x86_64/egg/trac/admin/console.py", line 110, in
onecmd
rv = cmd.Cmd.onecmd(self, line) or 0
File "/usr/lib64/python2.7/cmd.py", line 220, in onecmd
return self.default(line)
File "build/bdist.linux-x86_64/egg/trac/admin/console.py", line 286, in
default
return self.cmd_mgr.execute_command(*args)
File "build/bdist.linux-x86_64/egg/trac/admin/api.py", line 127, in
execute_command
return f(*fargs)
File "build/bdist.linux-x86_64/egg/trac/env.py", line 1011, in _do_upgrade
self.env.upgrade(backup=no_backup is None)
File "build/bdist.linux-x86_64/egg/trac/env.py", line 745, in upgrade
participant.upgrade_environment(db)
File
"/usr/lib/python2.7/site-packages/binary_agilo-1.3.14_PRO-py2.7.egg/agilo/db/plugin_env_setup.py",
line 77, in upgrade_environment
return self.environment_created()
File
"/usr/lib/python2.7/site-packages/binary_agilo-1.3.14_PRO-py2.7.egg/agilo/init.py",
line 141, in environment_created
db_default.create_default_types(self.env)
File
"/usr/lib/python2.7/site-packages/binary_agilo-1.3.14_PRO-py2.7.egg/agilo/db/db_default.py",
line 80, in create_default_types
create_types(env, default_types)
File
"/usr/lib/python2.7/site-packages/binary_agilo-1.3.14_PRO-py2.7.egg/agilo/utils/db.py",
line 165, in create_types
ticket_type_max_value = int(cursor.fetchone()[0])
TypeError: int() argument must be a string or a number, not 'NoneType'

BR
/Mattias
--
--
Follow Agilo on Twitter: http://twitter.com/agilofortrac
Please support us by reviewing and voting on:
http://userstories.com/products/8-agilo-for-scrum
http://ohloh.net/p/agilo-trac
http://freshmeat.net/projects/agiloforscrum

You have received this message because you are subscribed to
the "Agilo for Trac" Google Group. This group is focused on
supporting Agilo for Trac users and is moderated by
Agilo Software GmbH <http://www.agilosoftware.com>.

To post to this group, send email to ***@googlegroups.com
To unsubscribe from this group, send an email to
agilo+***@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/agilo

---
You received this message because you are subscribed to the Google Groups "Agilo for Trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email to agilo+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Mattias Vannergård
2015-03-20 17:42:26 UTC
Permalink
After understanding the message fully, and activating the ipdb debugger,
the solution was quite clear.

The case, when the old legacy database didn't contain any 'ticket_type'
enums, was not covered.

I have sent my updated db.py to the Agilo support, and hopefully they can
update to cover the case in some way close to what I did find.

My upgrade has finally succeeded! :)
--
--
Follow Agilo on Twitter: http://twitter.com/agilofortrac
Please support us by reviewing and voting on:
http://userstories.com/products/8-agilo-for-scrum
http://ohloh.net/p/agilo-trac
http://freshmeat.net/projects/agiloforscrum

You have received this message because you are subscribed to
the "Agilo for Trac" Google Group. This group is focused on
supporting Agilo for Trac users and is moderated by
Agilo Software GmbH <http://www.agilosoftware.com>.

To post to this group, send email to ***@googlegroups.com
To unsubscribe from this group, send an email to
agilo+***@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/agilo

---
You received this message because you are subscribed to the Google Groups "Agilo for Trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email to agilo+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...