{"issue":{"pull_request":{"diff_url":null,"html_url":null,"patch_url":null},"state":"open","user":{"avatar_url":"https://secure.gravatar.com/avatar/45aefb7d7e9688352b34b574862f17a0?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"45aefb7d7e9688352b34b574862f17a0","url":"https://api.github.com/users/niblh","login":"niblh","id":135003},"milestone":null,"assignee":null,"updated_at":"2011-11-10T23:11:23Z","labels":[],"comments":0,"closed_at":null,"url":"https://api.github.com/repos/tanoku/rinku/issues/15","body":"\r\n\r\nThe default passenger ruby wrapper wraps ruby as\r\n\r\n    exec ruby -E ASCII-8BIT \"$@\"\r\n\r\nwhich causes problem with the multibyte character in the gemspec author field.\r\n\r\nA simple encoding hint at the top of the gemspec (# encoding: UTF-8) seems to solve it.\r\n\r\n\r\nSample trace below:\r\n\r\n---\r\n\r\n```bash\r\n\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/message_channel.rb:287:in `write_scalar'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:330:in `send_error_page'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:297:in `rescue in handle_spawn_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:274:in `handle_spawn_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/helper-scripts/passenger-spawn-server:99:in `<main>'\r\n[ pid=3573 thr=67894760 file=utils.rb:176 time=2011-11-10 23:32:27.986 ]: *** Exception SyntaxError in PhusionPassenger::Rack::ApplicationSpawner (/var/www/myapp/app/shared/bundle/ruby/1.9.1/bundler/gems/rinku-60f821316be1/rinku.gemspec:11: invalid multibyte char (US-ASCII)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t /var/www/myapp/app/shared/bundle/ruby/1.9.1/bundler/gems/rinku-60f821316be1/rinku.gemspec:11: invalid multibyte char (US-ASCII)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t /var/www/myapp/app/shared/bundle/ruby/1.9.1/bundler/gems/rinku-60f821316be1/rinku.gemspec:11: syntax error, unexpected $end, expecting ']'\r\ns.authors = [\"Vicent Martí\"]\r\n^) (process 3573, thread #<Thread:0x817fbd0>):\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler.rb:241:in `eval'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler.rb:241:in `rescue in block in load_gemspec'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler.rb:236:in `block in load_gemspec'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler.rb:234:in `chdir'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler.rb:234:in `load_gemspec'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/source.rb:353:in `block in load_spec_files'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/source.rb:352:in `each'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/source.rb:352:in `load_spec_files'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/source.rb:570:in `load_spec_files'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/source.rb:385:in `local_specs'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/source.rb:555:in `specs'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/lazy_specification.rb:48:in `__materialize__'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/spec_set.rb:84:in `block in materialize'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/spec_set.rb:82:in `map!'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/spec_set.rb:82:in `materialize'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/definition.rb:90:in `specs'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/definition.rb:135:in `specs_for'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/definition.rb:124:in `requested_specs'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/environment.rb:23:in `requested_specs'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler/runtime.rb:11:in `setup'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290@global/gems/bundler-1.0.21.rc/lib/bundler.rb:110:in `setup'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/utils.rb:326:in `prepare_app_process'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/rack/application_spawner.rb:155:in `block in initialize_server'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/utils.rb:572:in `report_app_init_status'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/rack/application_spawner.rb:153:in `initialize_server'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:204:in `start_synchronously'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:180:in `start'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/rack/application_spawner.rb:128:in `start'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:253:in `block (2 levels) in spawn_rack_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server_collection.rb:132:in `lookup_or_add'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:246:in `block in spawn_rack_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server_collection.rb:82:in `block in synchronize'\r\nfrom <internal:prelude>:10:in `synchronize'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server_collection.rb:79:in `synchronize'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:244:in `spawn_rack_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:137:in `spawn_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:275:in `handle_spawn_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/helper-scripts/passenger-spawn-server:99:in `<main>'\r\n*** Exception Encoding::CompatibilityError in spawn manager (incompatible character encodings: ASCII-8BIT and US-ASCII) (process 3573, thread #<Thread:0x817fbd0>):\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/message_channel.rb:287:in `write_scalar'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:330:in `send_error_page'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:297:in `rescue in handle_spawn_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/spawn_manager.rb:274:in `handle_spawn_application'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'\r\nfrom /home/passenger/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.9/helper-scripts/passenger-spawn-server:99:in `<main>'\r\n\r\n´´´\r\n","html_url":"https://github.com/tanoku/rinku/issues/15","title":"Unspecified encoding for gemspec file causes encoding problems with passenger spawner under ruby 1.9.2","number":15,"id":2204140,"created_at":"2011-11-10T23:11:23Z"},"action":"opened"}