Forum: Typo Converter for TypePad

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
87f3caa6600d95f06fdc00b822ed108d?d=identicon&s=25 Justin Johnson (Guest)
on 2006-05-25 19:40
(Received via mailing list)
I've been working on a converter that takes a TypePad export file and
converts it to Typo.  I had this working for the latest stable
version, but then decided I wanted the latest SVN version.  I'm having
a hard time finding what I need to include in my hash when calling
Content.create.  The current version of my script is attached.  Below
are the errors I'm getting.

Any help you can provide is appreciated.

[typo/db/converters]$ ./typepad.rb --help
Usage: typepad.rb [options]
    -f, --file FILE                  Path to TypePad export file.
    -b, --blogname BLOGNAME          Name of blog defined in Typo.
    -h, --help                       Show this message.
[typo/db/converters]$ ./typepad.rb -f ~/export.txt -b justinj.org
Converting 112 entries...
Converting 'Disciples of Jesus in the Talmud'
../../config/../app/models/content_observer.rb:3:in
`populate_html_fields': wrong number of arguments (0 for 1)
(ArgumentError)
        from ../../config/../app/models/content_observer.rb:3:in
`before_save'
        from
../../config/../vendor/rails/activerecord/lib/active_record/observer.rb:123:in
`update'
        from /usr/local/lib/ruby/1.8/observer.rb:185:in
`notify_observers'
        from /usr/local/lib/ruby/1.8/observer.rb:184:in
`notify_observers'
        from
../../config/../vendor/rails/activerecord/lib/active_record/callbacks.rb:364:in
`notify'
        from
../../config/../vendor/rails/activerecord/lib/active_record/callbacks.rb:328:in
`callback'
        from
../../config/../vendor/rails/activerecord/lib/active_record/callbacks.rb:248:in
`create_or_update'
        from
../../config/../vendor/rails/activerecord/lib/active_record/base.rb:1392:in
`save_without_validation'
         ... 7 levels...
        from ./typepad.rb:100:in `convert_entries'
        from ./typepad.rb:28:in `convert_entries'
        from ./typepad.rb:19:in `initialize'
        from ./typepad.rb:144
[typo/db/converters]$
This topic is locked and can not be replied to.