rails6にアップデートをしてから、Action Textを試したのですが上手くできません。もしかしたら、Action Textは関係なくモデルの問題かもしれませんがよろしくおねがいしますm(_ _)m。
migrateerror
1rails aborted! 2StandardError: An error has occurred, this and all later migrations canceled: 3 4SQLite3::SQLException: table "active_storage_blobs" already exists 5C:/Users/user/Desktop/UG/db/migrate/20191224082803_create_active_storage_tables.active_storage.rb:4:in `change' 6bin/rails:4:in `require' 7bin/rails:4:in `<main>' 8 9Caused by: 10ActiveRecord::StatementInvalid: SQLite3::SQLException: table "active_storage_blobs" already exists 11C:/Users/user/Desktop/UG/db/migrate/20191224082803_create_active_storage_tables.active_storage.rb:4:in `change' 12bin/rails:4:in `require' 13bin/rails:4:in `<main>' 14 15Caused by: 16SQLite3::SQLException: table "active_storage_blobs" already exists 17C:/Users/user/Desktop/UG/db/migrate/20191224082803_create_active_storage_tables.active_storage.rb:4:in `change' 18bin/rails:4:in `require' 19bin/rails:4:in `<main>' 20Tasks: TOP => db:migrate 21(See full trace by running task with --trace)
マイグレーション実行時のエラーです。
なぜかファイルはもうある、的なことが書かれていますがマイグレーションファイルを見たところactive_storage_blobsというファイルは今回作ったものしかありませんでした。
Terminalerror
1Started GET "/samples/new" for ::1 at 2019-12-24 18:00:34 +0900 2 (1.2ms) SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC 3 4ActiveRecord::PendingMigrationError ( 5 6Migrations are pending. To resolve this issue, run: 7 8 rails db:migrate RAILS_ENV=development 9 10): 11 12(省略)
railsactiontextinstall
1DEPRECATION WARNING: Single arity template handlers are deprecated. Template handlers must 2now accept two parameters, the view object and the source for the view object. 3Change: 4 >> Coffee::Rails::TemplateHandler.call(template) 5To: 6 >> Coffee::Rails::TemplateHandler.call(template, source) 7 (called from <top (required)> at C:/Users/user/Desktop/UG/Rakefile:6) 8DEPRECATION WARNING: Single arity template handlers are deprecated. Template handlers must 9now accept two parameters, the view object and the source for the view object. 10Change: 11 >> Coffee::Rails::TemplateHandler.call(template) 12To: 13 >> Coffee::Rails::TemplateHandler.call(template, source) 14 (called from <top (required)> at C:/Users/user/Desktop/UG/Rakefile:6) 15Copying actiontext.scss to app/assets/stylesheets 16 create app/assets/stylesheets/actiontext.scss 17Copying fixtures to test/fixtures/action_text/rich_texts.yml 18 create test/fixtures/action_text/rich_texts.yml 19Copying blob rendering partial to app/views/active_storage/blobs/_blob.html.erb 20 create app/views/active_storage/blobs/_blob.html.erb 21Installing JavaScript dependencies 22 run yarn add trix@^1.0.0 @rails/actiontext@^6.0.1 from "." 23WARNING: Action Text can't locate your JavaScript bundle to add its package dependencies. 24 25Add these lines to any bundles: 26 27require("trix") 28require("@rails/actiontext") 29 30Alternatively, install and setup the webpacker gem then rerun `bin/rails action_text:install` 31to have these dependencies added automatically. 32 33Copied migration 20191224082803_create_active_storage_tables.active_storage.rb from active_storage 34Copied migration 20191224082804_create_action_text_tables.action_text.rb from action_text
gem
1gem 'image_processing'←これを追加した。
細かい設定は一切していません。インストールをして使おうとしただけです。
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/12/25 03:23
2019/12/25 04:09
2019/12/25 04:22
2019/12/25 04:31
2019/12/25 05:42 編集
2019/12/25 06:59