jywarren/mapknitter

WarperController#create Runtime error on Lightroom jpegs

Closed this issue · 2 comments

Photo jpegs which have been output by Adobe Lightroom v3 cause the following error on upload to MapKnitter for this map: http://mapknitter.org/maps/harvey-cove--lake-warner. These jpegs had GPS coordinates written to the exif header by RoboGeo, then were added to Adobe Lightroom where various data (tags, captions, etc) were added, then were output by Lightroom with new filenames. The original jpegs after RoboGeo added the GPS coordinates do not throw this error and load fine. It seems that the subsequent pass through Lightroom is making MapKnitter complain.

RuntimeError in WarperController#create

FreeImage exception for type JPEG: Exif: Suspicious offset of first IFD value
RAILS_ROOT: /home/warren/sites/mapknitter.org

Application Trace | Framework Trace | Full Trace
/home/warren/sites/mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu/processors/image_science_processor.rb:14:in with_image' /home/warren/sites/mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu/processors/image_science_processor.rb:14:inwith_image'
/home/warren/sites/mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu.rb:357:in with_image' /home/warren/sites/mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu/processors/image_science_processor.rb:21:inprocess_attachment'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:178:in send' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:178:inevaluate_method'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:166:in call' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:93:inrun'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:92:in each' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:92:insend'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:92:in run' /home/warren/sites/mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu.rb:443:inrun_callbacks'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/callbacks.rb:344:in callback' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/callbacks.rb:317:invalid?'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/validations.rb:1088:in save_without_dirty' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/dirty.rb:79:insave_without_transactions'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:229:in send' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:229:inwith_transaction_returning_status'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstract/database_statements.rb:136:in transaction' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:182:intransaction'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:228:in with_transaction_returning_status' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:196:insave'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:208:in rollback_active_record_state!' /home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:196:insave'
/home/warren/sites/mapknitter.org/app/controllers/warper_controller.rb:21:in `create'
Request

Parameters:

{"commit"=>"Upload",
"authenticity_token"=>"FhwKT1okz60IZgKgH/OqCNr75KYMigxc+pHnK94/AIk=",
"warpable"=>{"uploaded_data"=>#File:/tmp/RackMultipart7648-0},
"map_id"=>"2283"}
Show session dump

Response

Headers:

{"Content-Type"=>"",
"Cache-Control"=>"no-cache"}

It thinks you're hacking the server :-P

Hmm... need to search around for this error to see if there's a workaround.
Thanks for reporting!

On Thu, Jul 25, 2013 at 10:59 AM, Fastie notifications@github.com wrote:

Photo jpegs which have been output by Adobe Lightroom v3 cause the
following error on upload to MapKnitter. These jpegs had GPS coordinates
written to the exif header by RoboGeo, then were added to Adobe Lightroom
where various data (tags, captions, etc) were added, then were output by
Lightroom with new filenames. The original jpegs after RoboGeo added the
GPS coordinates do not throw this error and load fine. It seems that the
subsequent pass through Lightroom is making MapKnitter complain.

RuntimeError in WarperController#create

FreeImage exception for type JPEG: Exif: Suspicious offset of first IFD
value
RAILS_ROOT: /home/warren/sites/mapknitter.org

Application Trace | Framework Trace | Full Trace
/home/warren/sites/
mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu/processors/image_science_processor.rb:14:in
with_image'
/home/warren/sites/
mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu/processors/image_science_processor.rb:14:in
with_image'
/home/warren/sites/
mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu.rb:357:in
with_image'
/home/warren/sites/
mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu/processors/image_science_processor.rb:21:in
process_attachment'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:178:in
send'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:178:in
evaluate_method'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:166:in
call'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:93:inrun'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:92:in
each'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:92:insend'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activesupport-2.3.15/lib/active_support/callbacks.rb:92:in
run'
/home/warren/sites/
mapknitter.org/vendor/plugins/attachment_fu/lib/technoweenie/attachment_fu.rb:443:in
run_callbacks'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/callbacks.rb:344:in
callback'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activerecord-2.3.15/lib/active_record/callbacks.rb:317:invalid?'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/validations.rb:1088:in
save_without_dirty'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activerecord-2.3.15/lib/active_record/dirty.rb:79:in
save_without_transactions'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:229:in
send'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activerecord-2.3.15/lib/active_record/transactions.rb:229:in
with_transaction_returning_status'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstract/database_statements.rb:136:in
transaction'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activerecord-2.3.15/lib/active_record/transactions.rb:182:in
transaction'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:228:in
with_transaction_returning_status'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activerecord-2.3.15/lib/active_record/transactions.rb:196:insave'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default/gems/activerecord-2.3.15/lib/active_record/transactions.rb:208:in
rollback_active_record_state!'
/home/warren/.rvm/gems/ruby-1.8.7-p330@default
/gems/activerecord-2.3.15/lib/active_record/transactions.rb:196:insave'
/home/warren/sites/
mapknitter.org/app/controllers/warper_controller.rb:21:in `create'
Request

Parameters:

{"commit"=>"Upload",
"authenticity_token"=>"FhwKT1okz60IZgKgH/OqCNr75KYMigxc+pHnK94/AIk=",
"warpable"=>{"uploaded_data"=>#File:/tmp/RackMultipart7648-0},
"map_id"=>"2283"}
Show session dump

Response

Headers:

{"Content-Type"=>"",
"Cache-Control"=>"no-cache"}


Reply to this email directly or view it on GitHubhttps://github.com//issues/144
.

Hi Chris, can you check if this happens on mapknitter.org now? We use a different image processor. Not the Mapknitter 2 beta, just the current production server. If it does, could you copy the error you see and relevant info to https://github.com/publiclab/mapknitter/issues please? Thanks.