[web2py] Re: help testing auth.signature with mysql/pgsql

2013-06-16 Thread Arnon Marcus
That's not a justified reason. If I have a table with a column that has zero nulls in it, it is perfectly reasonable for me to expect to be able to add a not-null constraint after the fact. If web2py is dealing with this migration, it should at least attempt to do it correctly. It should only

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Adi
do you mean: db._common_fields.append(auth.signature) i have it, and can test now On Saturday, December 22, 2012 12:44:06 PM UTC-5, Massimo Di Pierro wrote: If you have fields with auth.signature and mysql/pgsql could you help me test the latest trunk? The reason is that I changed the

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Massimo Di Pierro
Yes. That would be a good test. On Saturday, 22 December 2012 12:30:25 UTC-6, Adi wrote: do you mean: db._common_fields.append(auth.signature) i have it, and can test now On Saturday, December 22, 2012 12:44:06 PM UTC-5, Massimo Di Pierro wrote: If you have fields with auth.signature and

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Massimo Di Pierro
Specifically let me know: - after upgrade, do you see a migration in sql.log? - does everything seem to work or you get a ticket? Masimo On Saturday, 22 December 2012 12:30:25 UTC-6, Adi wrote: do you mean: db._common_fields.append(auth.signature) i have it, and can test now On Saturday,

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Adi
My app was in a fake migration mode, and when I enabled a migration it wanted to re-ecreate two existing tables, one regular (pmt), the other archive (customer_archive)... (sql.log bellow). I renamed existing tables in order to proceed... What I see is that archive table got created with

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Massimo Di Pierro
This is not exactly what I was hoping for but it shows a problem with trunk. It migrates is_active form notnull=False to notnull=True and then tries to copy the old data (which include Null values). This will break the migration. It worked for you because the step was only faked. The creation

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Adi
let me know when you change. i can test again... On Saturday, December 22, 2012 2:40:19 PM UTC-5, Massimo Di Pierro wrote: This is not exactly what I was hoping for but it shows a problem with trunk. It migrates is_active form notnull=False to notnull=True and then tries to copy the old

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Massimo Di Pierro
I reverted it so there should be no problem. This leave the original problem. If people add an auth signature, they must manually change is_active=None to is_active=True. On Saturday, 22 December 2012 13:59:13 UTC-6, Adi wrote: let me know when you change. i can test again... On Saturday,

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Cliff Kachinske
What happens if you add the field, set it to True,then add the notnull constraint? --

[web2py] Re: help testing auth.signature with mysql/pgsql

2012-12-22 Thread Massimo Di Pierro
The problem is that adding notnull constraint causes a migration (except on sqlite). Because the field exists already web2py creates a new tmp field, than tried to move existing data over. But the data contains Null while the new field is notnull=True therefore the migration will fail. On