On 8/1/2010 12:40 PM, Tay Ray Chuan wrote:
Hi,

On Sat, Jul 31, 2010 at 6:06 AM, Chris Laux<[email protected]>  wrote:
Either way, attached is a patch that fixes the following problems I had when
migrating my 0.9.0 Satchmo install to 0.9.1:
- minor typo (Inavlid ->  Invalid)
The presence of this typo is not a bug with either south or satchmo.
If you examine the source code at the revision on which this migration
was built on (6363f97d659f), this is "correct".

A separate migration,
0005_fix_attributeoption_error_default_spelling.py, was generated to
fix this.


Yeah, I understand - I just happened to spot the typo as I was working on the code.

- made the new AttributeOption's description field have the same data as its
name (admin showed blanks for all options)
- changed the migration to only create one AttributeOption per name
(otherwise you'd end up with lots of identical ones)
Many thanks for this.


Glad to help.

- fixed the bug causing the AttributeError below (added ".objects" before
".get" - how could this have worked at all?)
Hmm, south probably updated their API/ORM access. I spent quite some
time writing and testing this portion to migrate data over - in fact,
I ran it on the sample project installations - so you can be pretty
sure it worked before.


Odd. I haven't used south before, so I just assumed that orm['Product.AttributeOption'] returned a Django model since the line above where I added ".objects" has the standard-looking ".objects.all()".
Seems we need an app to migrate the migration code... ;)


--
Chris Laux

--
You received this message because you are subscribed to the Google Groups "Satchmo 
users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/satchmo-users?hl=en.

Reply via email to