Hello Chuck-
I'm getting errors. Below is the output from the MKBasic test, as well
as my LocalConfig.py.
All the tests complain about this: ERROR 1062 (23000) at line 25:
Duplicate entry '1' for key 1. I think the problem is actually a bug
in MySQL. If you delete a database, and then recreate the database and
recreate the tables, then the old data that was in that table is
"magically" back there. In other words:
mysql> use MKBasic
mysql> select * from _MKClassIds;
mysql> drop database if exists MKBasic;
mysql> create database MKBasic;
mysql> use MKBasic;
mysql> show tables;
Empty set (0.00 sec)
At this point we have dropped and recreated the database. As soon as
we recreate the table, the old data magically reappears:
mysql> create table _MKClassIds (
-> id int not null primary key,
-> name varchar(100)
-> );
Query OK, 0 rows affected (0.00 sec)
mysql> select * from _MKClassIds;
+----+--------+
| id | name |
+----+--------+
| 1 | Thing |
| 2 | Person |
+----+--------+
2 rows in set (0.00 sec)
----------------------------------------------
output from MKBasic test:
% python Test.py MKBasic
*** MKBasic ***
<cmd> python TestDesign.py MKBasic.mkmodel Settings.config
Removing WorkDir...
../Design/Generate.py --outdir WorkDir --db MySQL --model
MKBasic.mkmodel --config Settings.config
Generating SQL...
Generating Python...
importing classes: Thing, Person
<cmd> mysql -u root < WorkDir/GeneratedSQL/Create.sql
ERROR 1062 (23000) at line 25: Duplicate entry '1' for key 1
RESULTS
-------
*** FAILED *** MKBasic.mkmodel
1 seconds
----------------------------------------------
The contents of my LocalConfig.py:
# LocalConfig.py
import site
site.addsitedir('/Users/winstonw/Projects/svn/python/extern/MySQL-
python-1.0.0/build/lib')
dbName = 'MySQL'
storeArgs = {'user': 'root', 'passwd': ''}
sqlCommand = 'mysql -u root '
# end
-----------------------------
On Feb 5, 2005, at 8:16 PM, Chuck Esterbrook wrote:
> As you'll see on the checkins list, I made some fixes to MiddleKit.
> The test suite now passes in full for MySQL even with more recent
> versions of MySQLdb (which started breaking MiddleKit with MySQLdb
> 0.9.2).
>
> Two notes:
>
> * Someone should run the test suite on the latest code with Postgres.
>
> * One of the bugs I fixed was a new one. If you modify MiddleKit,
> please run the test suite for some db (MySQL, Postgres or MSSQL)
> before checking in changes. There's a ReadMe.text in MiddleKit/Tests
> with all the instructions you need. You should see this at the end of
> a good test run:
>
>
> RESULTS
> -------
> succeeded MKBasic.mkmodel
> succeeded MKNone.mkmodel
> succeeded MKString.mkmodel
> succeeded MKDateTime.mkmodel
> succeeded MKEnums.mkmodel
> succeeded MKDefaultMinMax.mkmodel
> succeeded MKTypeValueChecking.mkmodel
> succeeded MKInheritance.mkmodel
> succeeded MKInheritanceAbstract.mkmodel
> succeeded MKList.mkmodel
> succeeded MKObjRef.mkmodel
> succeeded MKObjRefReuse.mkmodel
> succeeded MKDelete.mkmodel
> succeeded MKDeleteMark.mkmodel
> succeeded MKMultipleStores.mkmodel
> succeeded MKMultipleThreads.mkmodel
> succeeded MKModelInh1.mkmodel
> succeeded MKModelInh2.mkmodel
> succeeded MKModelInh3.mkmodel
> succeeded MKExcel.mkmodel
>
>
> Thanks,
> -Chuck
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
> Tool for open source databases. Create drag-&-drop reports. Save time
> by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
> Download a FREE copy at http://www.intelliview.com/go/osdn_nl
> _______________________________________________
> Webware-devel mailing list
> Webware-devel@...
> https://lists.sourceforge.net/lists/listinfo/webware-devel
>
>
_________________________________________
winston wolff - (646) 827-2242 - http://www.stratolab.com - learning by
creating
|