similar to: Encoding problems with Rails 3 + Ruby 1.9.1 (big surprise)

Displaying 20 results from an estimated 40000 matches similar to: "Encoding problems with Rails 3 + Ruby 1.9.1 (big surprise)"

2009 Oct 15
5
invalid multibyte character error
Hi. When I try to use multibyte characters in my rails controller I get an invalid multibyte characters error (<rails_app>/app/controllers/admin_controller.rb:6: invalid multibyte char (US-ASCII)). Here is my controller: contoller AdminController < ApplicationController def read @title = ''Заголовок страницы'' end end Here is my haml template extraction: ...
2010 Apr 19
10
Overview of Ruby 1.9 encoding problem tickets
SUMMARY: -------- I tried to identify the general and root causes for these problems with 1.9, by taking into account non-utf encoding, current patches, comments and ideas. I used ticket #2188 as base for explanations. This is a long read. I wanted to include all the relevant information in one place. I also included information about related tickets in LH and their status. I decided that adding
2009 Apr 12
9
invalid byte sequence utf-8 OR best option to sanitize content brought in with net::http? single non-utf character causes rails to crash
hi all, platform: debian lenny, ruby1.91.p0, passenger/apache-multithread, rails2.3 in vendor/postres and sql server via odbc. all current gems. i have legacy asp content on win2k servers that i wrap in rails controllers. this all worked great with ruby1.8, but now that we are dealing with encoded strings in ruby1.9, i am having page crashes randomly as users have cut and pasted high ascii code
2011 Jun 17
7
Encoding
What''s a good solution for fixing character encoding problems for compatibility between ascii and utf-8? The database is postgres and is encoded in utf-8. Once in awhile there will be a compatibility error from strings from a webform. Is there a command to fix this besides using a_string.force_encoding(''utf-8'')? Even this doesn''t seem to always work either.
2010 Dec 05
3
Strange problem with CSV and funny chars
I am using CSV in a rake task (db:seed) on Rails 3.0.3, Ruby 1.9.2 to read a file with some funny chars in it. Upon breaking in at a point where the row read using CSV is in variable row, with the string with the char in row[''price''] I get the following strange results which I cannot understand. (rdb:1) row[''price''] "\xA32.00" (rdb:1)
2009 Feb 15
12
Using MacPorts To Install Ruby 1.9.1 and Rails 2.3.0 RC1
Using MacPorts To Install Ruby 1.9.1 and Rails 2.3.0 RC1 WARNING: If you want to live on the edge, please continue with the steps below. Also, please be aware that all gems are not fully compatible with Ruby 1.9.1 stable release (i.e. 1.9.1p0). Furthermore, this installation requires you to remove ALL Ruby related gems and ports because we are performing a clean install.
2012 Feb 07
10
Encoding error
Hello, I have in my db a register what have special characters, and when I try to put on my form to edit this values, this happens: incompatible character encodings: UTF-8 and ASCII-8BIT Extracted source (around line #4): 1: <%= form_for :group, :url => { :action => "update" } do |f| %> 2: <%= utf8_enforcer_tag %> 3: <label>Nome do grupo</label>
2010 Aug 01
3
Problem with non-ascii characters in forms: "incompatible character encodings: UTF-8 and ASCII-8BIT"
Hi First off, I''m using Ruby 1.9.1p378 and Rails 2.3.8. I was creating a minimal application to test handling of Norwegian special characters when I bumped into this strange problem... I have a simple Car model with fields maker:string and model:string. For the controller I planned to just have an index action do all the work: class CarsController < ApplicationController def index
2011 Apr 16
17
Rails 3 Crashing On Windows 7
Hi guys, I have Rails 3 running on Windows 7 with Ruby 1.9.2 Every now and again, my server crashes, and I see the following information in the windows event log: Faulting application name: ruby.exe, version: 1.9.2.180, time stamp: 0x4d5ee5ed Faulting module name: msvcrt-ruby191.dll, version: 1.9.2.180, time stamp: 0x4d5ee5ec Exception code: 0xc0000005 Fault offset: 0x0011a00e Faulting process
2011 Jan 23
1
Force UTF-8 encoding
I''m writing an upload script for contact management, but having encoding issues: #=> Encoding::UndefinedConversionError: "\xFA" from ASCII-8BIT to UTF-8 I will not always know the encoding supplied, and this is the result of `some_string.encode("UTF-8")` I have also tried .force_encoding("UTF-8") to no avail. For now I''m simply trying to
2010 Sep 01
4
NoMethodError: undefined method `force_encoding' for "Conten
Hi everyone! Im trying to install mechanizer from http://github.com/tenderlove/mechanize. I`ve clone the project into /tmp folder. When I do rake inside the folder /tmp/mechanizer it gives me this error: mac159180:mechanize renatosis$ rake (in /private/tmp/mechanize) /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -w -Ilib:bin:test:. -e ''require "rubygems";
2010 May 26
25
Extremely slow start up with ruby 1.9.1 vs 1.8.7
I created a fresh new rails app, no gems, no nothing. Completely unmodified. Doing anything that initializes rails takes 2 - 3 times longer in ruby 1.9.1 than it does in 1.8.7. Obviously with a fresh rails app, this is only 2 - 3 seconds extra. But with a decent sized app, this can take up to 25 seconds for rails to initialize, vs the 12 seconds in 1.8.7. I''ve been racking my brain on
2010 Aug 08
1
Why Rails 3 installation is so pane full
Hi all Why Rails 3 installation is so pane full...? I am using fedora 10, ruby 1.8.6 rails 2.3.5/2.3.8 Now want to upgrade to rails3 i tried so many links... but nothing find essay.. for Rails 3 problem in ruby installation please suggest good links ... Thanks.... Regards Shyam 971-618-9650 shyam.heroku.com -- You received this message because you are subscribed to the Google Groups
2010 Feb 18
4
Error installing some gems (Ruby 1.9.2)
Hi I am testing Ruby 1.9.2 and Rails 3. Has anybody encountered this error: web katz$ gem install rspec-rails ************************************************** Thank you for installing rspec-rails-1.3.2 If you are upgrading, do this in each of your rails apps that you want to upgrade: $ ruby script/generate rspec Please be sure to read History.rdoc and Upgrade.rdoc for useful
2011 May 16
3
Problem with GET args and UTF-8 encoding (output of Rack::Utils.unescape() ?)
Hi folks, Here''s my basic issue, hopefully this is clear. I''m trying to submit some UTF-8 values in my query string, but they are coming out mangled on the other end. It *seems* like the problem is that what Rack::Utils.unescape() pushes out gets converted to UTF-8 somewhere in the chain (using 3.0.7, and Ruby 1.9.2, by the way), and it''s mangling characters which are
2007 Apr 01
7
database.yml: encoding: utf8 does not work
Hi all According to the Agile 2nd Ed book I added the line encoding: utf8 to my database.yml connections. But now when running rake I get plenty of errors: Character set ''utf-8'' is not a compiled character set and is not specified in the ''/usr/local/mysql/share/mysql/charsets/Index'' file What''s wrong here? I checked this Index file, but it seems to
2011 Aug 29
32
Weird assignment problem, very confused :(
Hey, I have the following line in my controller: User.create(:email => "fuuu-+RB1Aph5k6s@public.gmane.org", :password => ''asldfkjadsfadsf'', :ip => request.remote_ip) my IP is 127.0.0.1 - now User.find_by_ip(''127.0.0.1'') returns 0 records although User.first contains ''127.0.0.1'' if I change it to: User.create(:email =>
2010 Jan 19
15
git clone locally
Hi, I follow the instructions below to set up a git repository with gitosis on my home ubuntu server. I can connect to the repository remotely perfectly and set up a new repository named My_Project. I successfully push the content of My_Project to this repository using the remote computer with an SSH key. Now I want to clone My_Project locally onto another directory within the unbuntu server.
2009 Mar 21
15
mysql encoding with rails 2.3.2 and ruby 1.9.1
when I run console with ruby 1.9.1 and rails 2.3.2, and trying to do something like User.first.name.encoding I''m getting #<Encoding:ASCII-8BIT>, though I''ve set "encoding: utf8" in database.yml any suggestions? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails:
2010 Mar 26
6
installing ActionMailer from Rails 3?
Hi I''d like to use the new ActionMailer that comes with Rails 3, for a email reminder program I am writing. I am pretty new to Ruby, and would like to know how I can gem install this pre-release version, so I can start using it. Thanks for the help :) Alex -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups