I’d be grateful for some help on this as this is the only stumbling
block I’ve got before a full switch over to Typo. When I run my
“wordpress2.rb” conversion script I get the following output:
Code:
Creating Blog…
Converting 0 users…
Converting 104 entries…
…/…/config/…/vendor/rails/activerecord/lib/…/…/activesupport/lib/active_support/dependencies.rb:123:in const_missing': uninitialized constant TestRequest (NameError) from ../../config/../app/models/blog.rb:183:inrequest’
from …/…/config/…/app/models/blog.rb:156:in url_for' from ../../config/../app/models/blog.rb:168:inarticle_url’
from …/…/config/…/app/models/article.rb:26:in location' from ../../config/../app/models/article.rb:40:inreally_send_pings’
from
…/…/config/…/app/models/content_state/just_published.rb:44:in send_pings' from ../../config/../app/models/article.rb:67:insend_pings’
from …/…/config/…/app/models/web_notifier.rb:5:in after_save' ... 15 levels... from wordpress2.rb:27:ininitialize’
from wordpress2.rb:285:in execute_without_timestamps' from wordpress2.rb:23:ininitialize’
from wordpress2.rb:291
Google turns up no answers so I’d be very grateful for your input!
Doh! I ran into this when updating the script for WordPress 2 and then
promptly forgot about it after I got the conversion working. FWIW, my
fix is the same as yours except that I had
Thanks Alistair and Phil. Much appreciate your help. Its now working
like a charm so I shall get on with the process of converting
entirely.
Doug,
Good luck. I finally made the switch from Wordpress to Typo a few
days ago. Still coming to grips with it, but mostly very successful.
One other change that I had to make was to fixup some numeric XML
entities (like “ሴ”) in article titles.
Set
$KCODE=“u”
Then for each article:
a.title = CGI::unescapeHTML a.title
It seems that Typo escapes the characters in the article titles, but
Wordpress doesn’t. I am probably the only person in the world to use
these numeric entities so I haven’t bothered submitting a patch.
Quite happy to, if anyone thinks it’s worthwhile.
Other than that the conversion process worked great.
BTW I can also recommend my hosting provider, a2hosting. They support
rails and even have a knowledgebase article for Typo (https:// support.a2hosting.com/index.php?
_m=knowledgebase&_a=viewarticle&kbarticleid=378&nav=0,23,36)
Doug,
This is just a shot in the dark. Are you sure that you are looking in
the right database? Maybe you are looking in the production database
and the data is in the development database. I have been bitten by
this myself a few times. I am pretty sure that the script would squawk
if there was a problem writing the data to the database.
I ran the conversion after making the patch with everything appearing
to work fine. It runs through “converting entries…” and finishes.
However, when I check the typo DB there’s been no import. No articles
showing up in the backend or in the database itself.
Bit awkward as there’s no error message to give a hint about it
I stumbled upon this bug, when i was trying to write my own sidebar
plugin.
Whenever i try to add or remove items to sidebar by dragging the stuff
to
the active region, i get error:
NoMethodError (You have a nil object when you didn’t expect it!
You might have expected an instance of Array.
The error occured while evaluating nil.reject):
/app/controllers/admin/sidebar_controller.rb:48:in remove' /vendor/rails/actionpack/lib/action_controller/base.rb:910:inperform_action_without_filters’
/vendor/rails/actionpack/lib/action_controller/filters.rb:368:in perform_action_without_benchmark' /vendor/rails/actionpack/lib/action_controller/benchmarking.rb:69:inperform_action_without_rescue’
/usr/lib/ruby/1.8/benchmark.rb:293:in measure' /vendor/rails/actionpack/lib/action_controller/benchmarking.rb:69:inperform_action_without_rescue’
/vendor/rails/actionpack/lib/action_controller/rescue.rb:82:in perform_action' /vendor/rails/actionpack/lib/action_controller/base.rb:381:inprocess_without_filters’
/vendor/rails/actionpack/lib/action_controller/filters.rb:377:in
`process_without_session_management_support’
activemap = flash[:sidebars].inject({}) do |h, sb_id|
sb = Sidebar.find(sb_id.to_i)
sb ? h.merge({ sb.html_id => sb_id }) : h
end
while we assign the active plugins to flash[:sidebars] in index action,
but
they are replaced or lost in set_active method and hence the bug.
It may be something to do with the way mongrel handles sessions alos,
but
may be.
It looks a bug to me, right now.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.