Rails bug
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "bundler" | |
Bundler.setup | |
require "active_record" | |
ActiveRecord::Base.logger = Logger.new(STDOUT) | |
ActiveRecord::Base.establish_connection(:adapter => "sqlite3", :database => ':memory:') | |
class TestModel < ActiveRecord::Base; end | |
connection = ActiveRecord::Base.connection | |
connection.create_table(:test_models) | |
record = TestModel.create! # => succeeds | |
record.reload # => raises error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source "https://rubygems.org" | |
gem "activerecord", github: "rails" | |
gem "sqlite3" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GIT | |
remote: git://github.com/rails/rails.git | |
revision: 46617f02c6e473b7e695330076d2039de1c9aff2 | |
specs: | |
activemodel (5.0.0.alpha) | |
activesupport (= 5.0.0.alpha) | |
builder (~> 3.1) | |
activerecord (5.0.0.alpha) | |
activemodel (= 5.0.0.alpha) | |
activesupport (= 5.0.0.alpha) | |
arel (~> 6.0) | |
activesupport (5.0.0.alpha) | |
i18n (>= 0.7.0.beta1, < 0.8) | |
json (~> 1.7, >= 1.7.7) | |
minitest (~> 5.1) | |
thread_safe (~> 0.1) | |
tzinfo (~> 1.1) | |
GEM | |
remote: https://rubygems.org/ | |
specs: | |
arel (6.0.0) | |
builder (3.2.2) | |
i18n (0.7.0.beta1) | |
json (1.8.1) | |
minitest (5.4.3) | |
sqlite3 (1.3.10) | |
thread_safe (0.3.4) | |
tzinfo (1.2.2) | |
thread_safe (~> 0.1) | |
PLATFORMS | |
ruby | |
DEPENDENCIES | |
activerecord! | |
sqlite3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D, [2014-12-12T14:31:27.235390 #13773] DEBUG -- : [1m[36m (0.3ms)[0m [1mCREATE TABLE "test_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m | |
D, [2014-12-12T14:31:27.239085 #13773] DEBUG -- : [1m[35m (0.0ms)[0m begin transaction | |
D, [2014-12-12T14:31:27.240748 #13773] DEBUG -- : [1m[36mSQL (0.0ms)[0m [1mINSERT INTO "test_models" DEFAULT VALUES[0m | |
D, [2014-12-12T14:31:27.240928 #13773] DEBUG -- : [1m[35m (0.0ms)[0m commit transaction | |
D, [2014-12-12T14:31:27.243074 #13773] DEBUG -- : [1m[36mTestModel Load (0.1ms)[0m [1mSELECT "test_models".* WHERE "test_models"."id" = ? LIMIT 1[0m [["id", 1]] | |
E, [2014-12-12T14:31:27.243098 #13773] ERROR -- : SQLite3::SQLException: no such table: test_models: SELECT "test_models".* WHERE "test_models"."id" = ? LIMIT 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment