how do I fix this?

144 views
Skip to first unread message

Angel Robert Marquez

unread,
Jul 9, 2010, 11:43:36 PM7/9/10
to rubyonra...@googlegroups.com

ruby 1.9.3dev (2010-07-06 trunk 28554) [i686-linux]

Rails 3.0.0.beta4

Fedora Release 13 

Kernel Linux 2.6.33.5-124.fc13.i686.PAE
GNOME 2.30.0

After I scaffold, migrate, link_to posts_path,  and check click on new post I'm presented with this error. Please help...what does it mean and how do I fix it? I downloaded the Getting Started code and replaced the partial file and received a different error..any ideas?

http://localhost:3000/posts/new

I18n::UnknownFileType in Posts#new

Showing /home/user/Desktop/blog/app/views/posts/_form.html.erb where line #15 raised:

Extracted source (around line #15):

12:   <% end %>

13: 

14:   <div class="field">

15:     <%= f.label :name %><br />

16:     <%= f.text_field :name %>

17:   </div>

18:   <div class="field">

Frederick Cheung

unread,
Jul 10, 2010, 7:05:44 AM7/10/10
to Ruby on Rails: Talk


On Jul 10, 4:43 am, Angel Robert Marquez <angel.marq...@gmail.com>
wrote:
> ruby 1.9.3dev (2010-07-06 trunk 28554) [i686-linux]Rails 3.0.0.beta4
> Fedora Release 13
>
> Kernel Linux 2.6.33.5-124.fc13.i686.PAE
> GNOME 2.30.0
> After I scaffold, migrate, link_to posts_path,  and check click on new post
> I'm presented with this error. Please help...what does it mean and how do I
> fix it? I downloaded the Getting Started code and replaced the partial file
> and received a different error..any
> ideas?http://localhost:3000/posts/newI18n::UnknownFileType

Sounds like you've got a weird file somewhere where rails expected to
find I18n data (config/locales unless you've changed it)

Fred
> in Posts#newShowing /home/user/Desktop/blog/app/views/posts/_form.html.erb

Angel Robert Marquez

unread,
Jul 10, 2010, 2:22:27 PM7/10/10
to rubyonra...@googlegroups.com
Appreciate the help FC.

The only file that is in config/locales is en.yml. I haven't changed or moved anything that I am aware of. How do I make yml a known file type?

can not load translations from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.0.0.beta4/lib/active_support/locale/en.yml, the file type yml is not known

/config/locales/en.yml
# Sample localization file for English. Add more files in this directory for other locales.

en:
  hello: "Hello world"



I settled on using sqlite. When attempting to 'rails new blog -d mysql' and  'rake db:migrate'

undefined method `init' for Mysql:Class
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/mysql_adapter.rb:30:in `mysql_connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:226:in `new_connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:248:in `checkout_new_connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:190:in `block (2 levels) in checkout'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:186:in `loop'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:186:in `block in checkout'
/usr/local/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:185:in `checkout'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:99:in `connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_pool.rb:330:in `retrieve_connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_specification.rb:103:in `retrieve_connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/connection_adapters/abstract/connection_specification.rb:95:in `connection'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/migration.rb:459:in `initialize'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/migration.rb:406:in `new'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/migration.rb:406:in `up'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/migration.rb:388:in `migrate'
/usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_record/railties/databases.rake:140:in `block (2 levels) in <top (required)>'
/usr/local/lib/ruby/1.9.1/rake.rb:634:in `call'
/usr/local/lib/ruby/1.9.1/rake.rb:634:in `block in execute'
/usr/local/lib/ruby/1.9.1/rake.rb:629:in `each'
/usr/local/lib/ruby/1.9.1/rake.rb:629:in `execute'
/usr/local/lib/ruby/1.9.1/rake.rb:595:in `block in invoke_with_call_chain'
/usr/local/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/usr/local/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
/usr/local/lib/ruby/1.9.1/rake.rb:581:in `invoke'
/usr/local/lib/ruby/1.9.1/rake.rb:2041:in `invoke_task'
/usr/local/lib/ruby/1.9.1/rake.rb:2019:in `block (2 levels) in top_level'
/usr/local/lib/ruby/1.9.1/rake.rb:2019:in `each'
/usr/local/lib/ruby/1.9.1/rake.rb:2019:in `block in top_level'
/usr/local/lib/ruby/1.9.1/rake.rb:2058:in `standard_exception_handling'
/usr/local/lib/ruby/1.9.1/rake.rb:2013:in `top_level'
/usr/local/lib/ruby/1.9.1/rake.rb:1992:in `run'
/usr/local/bin/rake:31:in `<main>'


--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonra...@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.


LiTE

unread,
Jul 18, 2010, 7:16:39 PM7/18/10
to Ruby on Rails: Talk
I have the same problem. I report problem to lighthouse
https://rails.lighthouseapp.com/projects/8994/tickets/5129-enyml-the-file-type-yml-is-not-known-problem-with-dbmigrate#ticket-5129-1

On 10 Lip, 20:22, Angel Robert Marquez <angel.marq...@gmail.com>
wrote:
> Appreciate the help FC.
>
> The only file that is in config/locales is en.yml. I haven't changed or
> moved anything that I am aware of. How do I make yml a known file type?
>
> can not load translations from
> /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.0.0.beta4/lib/active_su pport/locale/en.yml,
> the file type yml is not known
>
> /config/locales/en.yml
> # Sample localization file for English. Add more files in this directory for
> other locales.
> # Seehttp://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocalefor
> starting points.
>
> en:
>   hello: "Hello world"
>
> I settled on using sqlite. When attempting to 'rails new blog -d mysql'
> and  'rake db:migrate'
>
> undefined method `init' for Mysql:Class
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/mysql_adapter.rb:30:in
> `mysql_connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:226:in
> `new_connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:248:in
> `checkout_new_connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:190:in
> `block (2 levels) in checkout'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:186:in
> `loop'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:186:in
> `block in checkout'
> /usr/local/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:185:in
> `checkout'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:99:in
> `connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_pool.rb:330:in
> `retrieve_connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_specification.rb:103:in
> `retrieve_connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/connection_adapters/abstract/connection_specification.rb:95:in
> `connection'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/migration.rb:459:in
> `initialize'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/migration.rb:406:in
> `new'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/migration.rb:406:in
> `up'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/migration.rb:388:in
> `migrate'
> /usr/local/lib/ruby/gems/1.9.1/gems/activerecord-3.0.0.beta4/lib/active_rec ord/railties/databases.rake:140:in
> > rubyonrails-ta...@googlegroups.com<rubyonrails-talk%2Bunsubscrib e...@googlegroups.com>
> > .

Angel Robert Marquez

unread,
Jul 19, 2010, 3:33:36 AM7/19/10
to rubyonra...@googlegroups.com
Yea, I gave up, kinda. Thanks for confirming and inputing the bug. Did you put me in the notes as a co-conspirator? I would totally test the newness if that was available to the public...or is it..

The deal was I would run ruby -v, gem -v and rails -v and get the latest install info; but, the errors would reference the previous version. I ended up reinstalling the OS and starting from scratch. Different set of issues. I even tried a shot at ubuntu..

I'm not discouraged though. Everything was running lean before I got all excited and upgraded and reality kicked me in the face. I'm reading all the manuals thoroughly and didn't want to hound the group with every error I came up with.

I do have some new inquiries regarding project rails.

Why does it seem like sqlite is preferred over mysql? It seems like it may be due to transaction support; but, isn't that just an innodb engine option when creating your mysql db 
Is there native JSON support? The active record stuff is rather amazing. What's the easiest way to make a json object request and retain the pattern to a json response. make sense? I want to send the message down a tube or clothes line and get the same thing back but better...
Thor? Should I dig deeper into this?

I've been reading all the ruby shtuff I can get my hands on too. i think i like it but i'm not sure why. Is it fair that I'm learning as I go and the most recent is always going to seem easier because I'm more aware and understand more. 

This is f*cking great BTW



To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.

Angel Robert Marquez

unread,
Jul 19, 2010, 3:37:29 AM7/19/10
to rubyonra...@googlegroups.com
Here's the last email about that I decided not to send:
ruby -v
ruby 1.9.3dev (2010-07-06 trunk 28554) [i686-linux]
gem -v
1.3.7
rails -v
Rails 3.0.0.beta4

I'm confused. Why are the files in lib all 1.9.1 and the -v command shows me 1.9.3?  
Reply all
Reply to author
Forward
0 new messages