jnicklas/carrierwave — Issue #549: ArgumentError: string contains null byte
Author: omarvelous
Created: 2011-12-03 13:49:25+00:00
State: open

Saw an issue was created and closed prior with the same issue. Closed because additional information wasn't provided.

App Specs:

* rails (3.1.1)
* carrierwave (0.5.7)
* fog (1.0.0)

Here are my params:

{"commit"=>"Create Ride",
"action"=>"create",
"utf8"=>"✓",
"authenticity_token"=>"Sb5jeGbL1viey4xFNYyewhpaMH/A/ruafUnZS1p+DY4=",
"ride"=>
{"picture_attributes"=>
{"file"=>"#"},
"year"=>"2011",
"model_id"=>"3"},
"controller"=>"rides"}

Here is my full backtrace.

[GEM_ROOT]/gems/fog-1.0.0/lib/fog/storage.rb:67:in `basename'

[GEM_ROOT]/gems/fog-1.0.0/lib/fog/storage.rb:67:in `parse_data'

[GEM_ROOT]/gems/fog-1.0.0/lib/fog/aws/requests/storage/put_object.rb:33:in `put_object'

[GEM_ROOT]/gems/fog-1.0.0/lib/fog/aws/models/storage/file.rb:119:in `save'

[GEM_ROOT]/gems/fog-1.0.0/lib/fog/core/collection.rb:50:in `create'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/storage/fog.rb:229:in `store'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/storage/fog.rb:79:in `store!'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/uploader/store.rb:59:in `block in store!'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/uploader/callbacks.rb:17:in `with_callbacks'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/uploader/store.rb:58:in `store!'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/mount.rb:347:in `store!'

[GEM_ROOT]/gems/carrierwave-0.5.7/lib/carrierwave/mount.rb:217:in `store_file!'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:410:in `_run_save_callbacks'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:81:in `run_callbacks'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/callbacks.rb:264:in `create_or_update'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/persistence.rb:37:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/validations.rb:50:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/attribute_methods/dirty.rb:22:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:241:in `block (2 levels) in save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:295:in `block in with_transaction_returning_status'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/connection_adapters/abstract/database_statements.rb:192:in `transaction'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:208:in `transaction'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:491:in `block in transaction_with_trace_ActiveRecord_self_name_transaction'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:242:in `trace_execution_scoped'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:486:in `transaction_with_trace_ActiveRecord_self_name_transaction'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:293:in `with_transaction_returning_status'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:241:in `block in save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:252:in `rollback_active_record_state!'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:240:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/autosave_association.rb:394:in `save_belongs_to_association'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/autosave_association.rb:197:in `block in add_autosave_association_callbacks'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/autosave_association.rb:149:in `instance_eval'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/autosave_association.rb:149:in `block in define_non_cyclic_method'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:422:in `_run_save_callbacks'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:81:in `run_callbacks'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/callbacks.rb:264:in `create_or_update'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/persistence.rb:37:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/validations.rb:50:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/attribute_methods/dirty.rb:22:in `save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:241:in `block (2 levels) in save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:295:in `block in with_transaction_returning_status'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/connection_adapters/abstract/database_statements.rb:192:in `transaction'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:208:in `transaction'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:491:in `block in transaction_with_trace_ActiveRecord_self_name_transaction'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:242:in `trace_execution_scoped'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:486:in `transaction_with_trace_ActiveRecord_self_name_transaction'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:293:in `with_transaction_returning_status'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:241:in `block in save'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:252:in `rollback_active_record_state!'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/transactions.rb:240:in `save'

app/controllers/rides_controller.rb:44:in `create'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/implicit_render.rb:4:in `send_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/abstract_controller/base.rb:167:in `process_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/rendering.rb:10:in `process_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/abstract_controller/callbacks.rb:18:in `block in process_action'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:434:in `_run__603890219__process_action__19225737__callbacks'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:386:in `_run_process_action_callbacks'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:81:in `run_callbacks'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/abstract_controller/callbacks.rb:17:in `process_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/rescue.rb:17:in `process_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/notifications.rb:53:in `block in instrument'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/notifications/instrumenter.rb:21:in `instrument'

[GEM_ROOT]/gems/activesupport-3.1.1/lib/active_support/notifications.rb:53:in `instrument'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/instrumentation.rb:29:in `process_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/params_wrapper.rb:201:in `process_action'

[GEM_ROOT]/gems/activerecord-3.1.1/lib/active_record/railties/controller_runtime.rb:18:in `process_action'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/instrumentation/rails3/action_controller.rb:34:in `block in process_action'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/instrumentation/controller_instrumentation.rb:253:in `block in perform_action_with_newrelic_trace'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/method_tracer.rb:242:in `trace_execution_scoped'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/instrumentation/controller_instrumentation.rb:248:in `perform_action_with_newrelic_trace'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/agent/instrumentation/rails3/action_controller.rb:33:in `process_action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/abstract_controller/base.rb:121:in `process'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/abstract_controller/rendering.rb:45:in `process'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal.rb:193:in `dispatch'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_controller/metal.rb:236:in `block in action'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:65:in `call'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:65:in `dispatch'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:29:in `call'

[GEM_ROOT]/gems/rack-mount-0.8.3/lib/rack/mount/route_set.rb:152:in `block in call'

[GEM_ROOT]/gems/rack-mount-0.8.3/lib/rack/mount/code_generation.rb:96:in `block in recognize'

[GEM_ROOT]/gems/rack-mount-0.8.3/lib/rack/mount/code_generation.rb:103:in `optimized_each'

[GEM_ROOT]/gems/rack-mount-0.8.3/lib/rack/mount/code_generation.rb:95:in `recognize'

[GEM_ROOT]/gems/rack-mount-0.8.3/lib/rack/mount/route_set.rb:141:in `call'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:532:in `call'

[GEM_ROOT]/gems/omniauth-1.0.0/lib/omniauth/strategy.rb:168:in `call!'

[GEM_ROOT]/gems/omniauth-1.0.0/lib/omniauth/strategy.rb:148:in `call'

[GEM_ROOT]/gems/omniauth-1.0.0/lib/omniauth/strategy.rb:168:in `call!'

[GEM_ROOT]/gems/omniauth-1.0.0/lib/omniauth/strategy.rb:148:in `call'

[GEM_ROOT]/gems/omniauth-1.0.0/lib/omniauth/builder.rb:30:in `call'

[GEM_ROOT]/gems/newrelic_rpm-3.3.0/lib/new_relic/rack/browser_monitoring.rb:40:in `call'

[GEM_ROOT]/gems/sass-3.1.10/lib/sass/plugin/rack.rb:54:in `call'

[GEM_ROOT]/gems/warden-1.0.6/lib/warden/manager.rb:35:in `block in call'

[GEM_ROOT]/gems/warden-1.0.6/lib/warden/manager.rb:34:in `catch'

[GEM_ROOT]/gems/warden-1.0.6/lib/warden/manager.rb:34:in `call'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'

[GEM_ROOT]/gems/rack-1.3.5/lib/rack/etag.rb:23:in `call'

[GEM_ROOT]/gems/rack-1.3.5/lib/rack/conditionalget.rb:35:in `call'

[GEM_ROOT]/gems/actionpack-3.1.1/lib/action_dispatch/middleware/head.rb:14:in `call'