Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update database schema in Rails 7 #390

Merged
merged 3 commits into from
Oct 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"configureZshAsDefaultShell": true,
"nonFreePackages": true
"nonFreePackages": false
},
"ghcr.io/devcontainers/features/github-cli:1": {
"installDirectlyFromGitHubRelease": true,
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ end

group :development do
gem 'web-console', '>= 3.3.0'
gem 'listen', '>= 3.0.5', '< 3.2'
gem 'listen', '~> 3.8'
gem 'spring', '~> 4.1', '>= 4.1.1'
gem 'spring-watcher-listen', '~> 2.1'
gem 'better_errors', '~> 2.5'
Expand Down
10 changes: 5 additions & 5 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ GEM
factory_bot_rails (5.2.0)
factory_bot (~> 5.2.0)
railties (>= 4.2.0)
ffi (1.15.5)
ffi (1.16.3)
gemoji (4.1.0)
globalid (1.1.0)
activesupport (>= 5.0)
Expand All @@ -149,9 +149,9 @@ GEM
jsonapi-renderer (0.2.2)
jwt (2.7.1)
language_server-protocol (3.17.0.3)
listen (3.0.8)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
listen (3.8.0)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
loofah (2.21.3)
crass (~> 1.0.2)
nokogiri (>= 1.12.0)
Expand Down Expand Up @@ -381,7 +381,7 @@ DEPENDENCIES
factory_bot_rails (~> 5.1)
gemoji
jwt (~> 2.7, >= 2.7.1)
listen (>= 3.0.5, < 3.2)
listen (~> 3.8)
memoist (~> 0.16.0)
meta-tags (~> 2.11, >= 2.11.1)
pg (~> 1.5, >= 1.5.3)
Expand Down
31 changes: 15 additions & 16 deletions db/schema.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,16 @@
#
# It's strongly recommended that you check this file into your version control system.

ActiveRecord::Schema[6.1].define(version: 2023_08_26_132242) do

ActiveRecord::Schema[7.0].define(version: 2023_09_12_113739) do
# These are extensions that must be enabled in order to support this database
enable_extension "pgcrypto"
enable_extension "plpgsql"

create_table "backups", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.string "key", null: false
t.jsonb "data", default: {}, null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "created_at", precision: nil, null: false
t.datetime "updated_at", precision: nil, null: false
t.index ["key"], name: "index_backups_on_key", unique: true
end

Expand All @@ -29,8 +28,8 @@
t.string "course_slug", null: false
t.string "lesson_slug", null: false
t.string "reaction_name", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "created_at", precision: nil, null: false
t.datetime "updated_at", precision: nil, null: false
t.index ["user_id", "course_slug", "lesson_slug"], name: "index_lesson_reactions_on_user_id_and_course_and_lesson_slug", unique: true
t.index ["user_id", "course_slug"], name: "index_lesson_reactions_on_user_id_and_course_slug"
t.index ["user_id"], name: "index_lesson_reactions_on_user_id"
Expand All @@ -40,8 +39,8 @@
t.uuid "user_id"
t.string "course_slug", null: false
t.string "lesson_slug", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "created_at", precision: nil, null: false
t.datetime "updated_at", precision: nil, null: false
t.index ["user_id", "course_slug", "lesson_slug"], name: "index_progresses_on_user_id_and_course_slug_and_lesson_slug", unique: true
t.index ["user_id", "course_slug"], name: "index_progresses_on_user_id_and_course_slug"
t.index ["user_id"], name: "index_progresses_on_user_id"
Expand All @@ -57,9 +56,9 @@
t.string "days_utc", default: [], null: false, array: true
t.integer "hours_utc", default: [], null: false, array: true
t.string "lessons_delivered", default: [], array: true
t.datetime "last_delivered_at"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "last_delivered_at", precision: nil
t.datetime "created_at", precision: nil, null: false
t.datetime "updated_at", precision: nil, null: false
t.string "user_timezone", default: "UTC"
t.boolean "disguised", default: false
t.index ["active"], name: "index_subscriptions_on_active"
Expand All @@ -72,9 +71,9 @@
t.string "firebase_id", null: false
t.string "email", null: false
t.boolean "email_verified", default: false
t.datetime "last_seen_at"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "last_seen_at", precision: nil
t.datetime "created_at", precision: nil, null: false
t.datetime "updated_at", precision: nil, null: false
t.boolean "terms_accepted", default: false
t.index ["email"], name: "index_users_on_email", unique: true
t.index ["firebase_id"], name: "index_users_on_firebase_id", unique: true
Expand All @@ -83,8 +82,8 @@
create_table "votes", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.uuid "user_id"
t.string "course_slug", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "created_at", precision: nil, null: false
t.datetime "updated_at", precision: nil, null: false
t.index ["course_slug"], name: "index_votes_on_course_slug"
t.index ["user_id", "course_slug"], name: "index_votes_on_user_id_and_course_slug", unique: true
t.index ["user_id"], name: "index_votes_on_user_id"
Expand Down
Loading