Affected files:
* Configuration.py
* Database.py
* HandHistoryConverter.py
* fpdb_import.py
and setup.py to a lesser extent.
Logging requires a configuration file when initialising the class. If we
are executing from outside the source tree, this file is not present.
Catch config parser's error and try to provide the logging config file
from debian package path.
Update symlink target to match python-support from latest Debian and the
oncoming Ubuntu versions.
Cleaned up storeHandsPlayers and added storeHudCacheNew
Haven't decided on the data structures to be passed in as yet so the functions only insert the bare minimum and have a list of commented out variables
Conflicts:
pyfpdb/Database.py
Resolve by reverting to sqlcoder's version; it uses the nice insert in
fillDefaultData for each case now and having the DB backends separate
might be good for the foreseeable future.
Database.py : fillDefaultData()
Remove manual 'id' from INSERT command. In database schema,
TourneyTypes.id is a primary key and thus autoincrement. In postgres,
autoincrements are implemented as sequences - inserting a value
"manually" bypasses the sequence generation, which resulted in a
remarkably weird error.
Namely, upon the first hand to import, the insert fails due to primary
key violation. The default value from an unused sequence is 1, but a
row with such an id already exists.
The solution is to create the single row of default data values with
unspecified TourneyTypes.id, hence allowing postgres to generate the
correct id from the sequence. This way the import works again.
Database.py : fillDefaultData()
Sql-coder had fixed the default data insert, and in the process changed
the default type ID. Since his works in general case, I can remove my
modifications.