From 7036e30af155a2f4b3aa95164b93ee1a5813c5d9 Mon Sep 17 00:00:00 2001 From: Barnabas Jovanovics Date: Tue, 18 Jun 2024 11:06:24 +0200 Subject: [PATCH] fix after rebase --- mix.lock | 4 +- ...0240529072637.json => 20240618085942.json} | 46 ++++++++++--------- ...=> 20240618085942_migrate_resources29.exs} | 6 +-- 3 files changed, 29 insertions(+), 27 deletions(-) rename priv/resource_snapshots/test_repo/stateful_post_followers/{20240529072637.json => 20240618085942.json} (86%) rename priv/test_repo/migrations/{20240529072637_migrate_resources27.exs => 20240618085942_migrate_resources29.exs} (85%) diff --git a/mix.lock b/mix.lock index 7011367..21d65d6 100644 --- a/mix.lock +++ b/mix.lock @@ -1,5 +1,5 @@ %{ - "ash": {:hex, :ash, "3.0.12", "c5b8f8884dab1ab140f11ff6e5a5a3889eae6c5083cabc1952d65fb2a6d13b89", [:mix], [{:comparable, "~> 1.0", [hex: :comparable, repo: "hexpm", optional: false]}, {:decimal, "~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:ecto, "~> 3.7", [hex: :ecto, repo: "hexpm", optional: false]}, {:ets, "~> 0.8", [hex: :ets, repo: "hexpm", optional: false]}, {:jason, ">= 1.0.0", [hex: :jason, repo: "hexpm", optional: false]}, {:picosat_elixir, "~> 0.2", [hex: :picosat_elixir, repo: "hexpm", optional: true]}, {:plug, ">= 0.0.0", [hex: :plug, repo: "hexpm", optional: true]}, {:reactor, ">= 0.8.1 and < 1.0.0-0", [hex: :reactor, repo: "hexpm", optional: false]}, {:simple_sat, ">= 0.1.1 and < 1.0.0-0", [hex: :simple_sat, repo: "hexpm", optional: true]}, {:spark, ">= 2.1.18 and < 3.0.0-0", [hex: :spark, repo: "hexpm", optional: false]}, {:splode, "~> 0.2", [hex: :splode, repo: "hexpm", optional: false]}, {:stream_data, "~> 1.0", [hex: :stream_data, repo: "hexpm", optional: false]}, {:telemetry, "~> 1.1", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "b8c9b56784f71debda4fc23960ecb6645b39eaa26376ba0423b94c550632c07b"}, + "ash": {:hex, :ash, "3.0.13", "9111fa58362f82fd6687635c12ea96ce1958d24772e3c773fbc8b0893a7e7d47", [:mix], [{:comparable, "~> 1.0", [hex: :comparable, repo: "hexpm", optional: false]}, {:decimal, "~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:ecto, "~> 3.7", [hex: :ecto, repo: "hexpm", optional: false]}, {:ets, "~> 0.8", [hex: :ets, repo: "hexpm", optional: false]}, {:jason, ">= 1.0.0", [hex: :jason, repo: "hexpm", optional: false]}, {:picosat_elixir, "~> 0.2", [hex: :picosat_elixir, repo: "hexpm", optional: true]}, {:plug, ">= 0.0.0", [hex: :plug, repo: "hexpm", optional: true]}, {:reactor, ">= 0.8.1 and < 1.0.0-0", [hex: :reactor, repo: "hexpm", optional: false]}, {:simple_sat, ">= 0.1.1 and < 1.0.0-0", [hex: :simple_sat, repo: "hexpm", optional: true]}, {:spark, ">= 2.1.18 and < 3.0.0-0", [hex: :spark, repo: "hexpm", optional: false]}, {:splode, "~> 0.2", [hex: :splode, repo: "hexpm", optional: false]}, {:stream_data, "~> 1.0", [hex: :stream_data, repo: "hexpm", optional: false]}, {:telemetry, "~> 1.1", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "b5c1a9c428eac939a313bfea5e4509e8ac39beaa4707bd0deb5f7f310b1022c3"}, "ash_sql": {:hex, :ash_sql, "0.2.5", "8b50c3178776263b912e1b60e161e2bcf08a907a38abf703edf8a8a0a51b3fe2", [:mix], [{:ash, "~> 3.0", [hex: :ash, repo: "hexpm", optional: false]}, {:ecto, "~> 3.9", [hex: :ecto, repo: "hexpm", optional: false]}, {:ecto_sql, "~> 3.9", [hex: :ecto_sql, repo: "hexpm", optional: false]}], "hexpm", "0d5d8606738a17c4e8c0be4244623df721abee5072cee69d31c2711c36d0548f"}, "benchee": {:hex, :benchee, "1.3.1", "c786e6a76321121a44229dde3988fc772bca73ea75170a73fd5f4ddf1af95ccf", [:mix], [{:deep_merge, "~> 1.0", [hex: :deep_merge, repo: "hexpm", optional: false]}, {:statistex, "~> 1.0", [hex: :statistex, repo: "hexpm", optional: false]}, {:table, "~> 0.1.0", [hex: :table, repo: "hexpm", optional: true]}], "hexpm", "76224c58ea1d0391c8309a8ecbfe27d71062878f59bd41a390266bf4ac1cc56d"}, "bunt": {:hex, :bunt, "1.0.0", "081c2c665f086849e6d57900292b3a161727ab40431219529f13c4ddcf3e7a44", [:mix], [], "hexpm", "dc5f86aa08a5f6fa6b8096f0735c4e76d54ae5c9fa2c143e5a1fc7c1cd9bb6b5"}, @@ -42,7 +42,7 @@ "simple_sat": {:hex, :simple_sat, "0.1.3", "f650fc3c184a5fe741868b5ac56dc77fdbb428468f6dbf1978e14d0334497578", [:mix], [], "hexpm", "a54305066a356b7194dc81db2a89232bacdc0b3edaef68ed9aba28dcbc34887b"}, "sobelow": {:hex, :sobelow, "0.13.0", "218afe9075904793f5c64b8837cc356e493d88fddde126a463839351870b8d1e", [:mix], [{:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "cd6e9026b85fc35d7529da14f95e85a078d9dd1907a9097b3ba6ac7ebbe34a0d"}, "sourceror": {:hex, :sourceror, "1.3.0", "70ab9e8bf6df085a1effba4b49ad621b7153b065f69ef6cdb82e6088f2026029", [:mix], [], "hexpm", "1794c3ceeca4eb3f9437261721e4d9cbf846d7c64c7aee4f64062b18d5ce1eac"}, - "spark": {:hex, :spark, "2.2.1", "b4ec56c99b3a750f7db0d2651fc59dc59c4002a5e0d658dde968fc69bd451136", [:mix], [{:igniter, ">= 0.1.7 and < 1.0.0-0", [hex: :igniter, repo: "hexpm", optional: false]}, {:jason, "~> 1.4", [hex: :jason, repo: "hexpm", optional: false]}, {:sourceror, "~> 1.2", [hex: :sourceror, repo: "hexpm", optional: false]}], "hexpm", "a6052f08ebe1ef152f86489151401210755bd81a9f0cbd737dd50819c65a0fc1"}, + "spark": {:hex, :spark, "2.2.3", "d41c45f0d7e8289499bf104173543be41ee1d8d213cb7503e9328b30751f2f13", [:mix], [{:igniter, ">= 0.1.7 and < 1.0.0-0", [hex: :igniter, repo: "hexpm", optional: false]}, {:jason, "~> 1.4", [hex: :jason, repo: "hexpm", optional: false]}, {:sourceror, "~> 1.2", [hex: :sourceror, repo: "hexpm", optional: false]}], "hexpm", "401dec157c8b88634c27f241f4e374476081c577f51d2b08512f2c681c25a852"}, "spitfire": {:hex, :spitfire, "0.1.2", "49b85d59c170d671e7e49649f62f6fe0771743a61bc42bd7a203f98f322d99e2", [:mix], [], "hexpm", "21f04cf02df601d75e1551e393ee5c927e3986fbb7598f3e59f71d4ca544fd9b"}, "splode": {:hex, :splode, "0.2.4", "71046334c39605095ca4bed5d008372e56454060997da14f9868534c17b84b53", [:mix], [], "hexpm", "ca3b95f0d8d4b482b5357954fec857abd0fa3ea509d623334c1328e7382044c2"}, "statistex": {:hex, :statistex, "1.0.0", "f3dc93f3c0c6c92e5f291704cf62b99b553253d7969e9a5fa713e5481cd858a5", [:mix], [], "hexpm", "ff9d8bee7035028ab4742ff52fc80a2aa35cece833cf5319009b52f1b5a86c27"}, diff --git a/priv/resource_snapshots/test_repo/stateful_post_followers/20240529072637.json b/priv/resource_snapshots/test_repo/stateful_post_followers/20240618085942.json similarity index 86% rename from priv/resource_snapshots/test_repo/stateful_post_followers/20240529072637.json rename to priv/resource_snapshots/test_repo/stateful_post_followers/20240618085942.json index 068ff13..3f872e3 100644 --- a/priv/resource_snapshots/test_repo/stateful_post_followers/20240529072637.json +++ b/priv/resource_snapshots/test_repo/stateful_post_followers/20240618085942.json @@ -7,8 +7,8 @@ "source": "id", "references": null, "allow_nil?": false, - "primary_key?": true, - "generated?": false + "generated?": false, + "primary_key?": true }, { "default": "nil", @@ -17,8 +17,8 @@ "source": "order", "references": null, "allow_nil?": true, - "primary_key?": false, - "generated?": false + "generated?": false, + "primary_key?": false }, { "default": "\"active\"", @@ -27,8 +27,8 @@ "source": "state", "references": null, "allow_nil?": true, - "primary_key?": false, - "generated?": false + "generated?": false, + "primary_key?": false }, { "default": "nil", @@ -38,25 +38,26 @@ "references": { "name": "stateful_post_followers_post_id_fkey", "table": "posts", - "primary_key?": true, - "destination_attribute": "id", "schema": "public", + "on_delete": null, "multitenancy": { "global": null, "attribute": null, "strategy": null }, - "on_delete": null, + "primary_key?": true, + "destination_attribute": "id", "on_update": null, "deferrable": false, - "match_with": null, + "index?": false, "match_type": null, + "match_with": null, "destination_attribute_default": null, "destination_attribute_generated": null }, "allow_nil?": false, - "primary_key?": false, - "generated?": false + "generated?": false, + "primary_key?": false }, { "default": "nil", @@ -66,49 +67,50 @@ "references": { "name": "stateful_post_followers_follower_id_fkey", "table": "users", - "primary_key?": true, - "destination_attribute": "id", "schema": "public", + "on_delete": null, "multitenancy": { "global": null, "attribute": null, "strategy": null }, - "on_delete": null, + "primary_key?": true, + "destination_attribute": "id", "on_update": null, "deferrable": false, - "match_with": null, + "index?": false, "match_type": null, + "match_with": null, "destination_attribute_default": null, "destination_attribute_generated": null }, "allow_nil?": false, - "primary_key?": false, - "generated?": false + "generated?": false, + "primary_key?": false } ], "table": "stateful_post_followers", - "hash": "8E28B293E05160B8D10ACF7906DCEDE01EB4E60103922CCB83F8D6B32AAA57B3", + "hash": "AD29C60B91FF00BAC638481D15457BA12C9D2E01B7B3B7F30F8E19DED6534C09", "repo": "Elixir.AshPostgres.TestRepo", "identities": [ { "name": "join_attributes", "keys": [ - "follower_id", "post_id", + "follower_id", "state" ], "where": null, "base_filter": null, - "all_tenants?": false, "nils_distinct?": true, + "all_tenants?": false, "index_name": "stateful_post_followers_join_attributes_index" } ], + "schema": null, "check_constraints": [], "custom_indexes": [], "base_filter": null, - "schema": null, "multitenancy": { "global": null, "attribute": null, diff --git a/priv/test_repo/migrations/20240529072637_migrate_resources27.exs b/priv/test_repo/migrations/20240618085942_migrate_resources29.exs similarity index 85% rename from priv/test_repo/migrations/20240529072637_migrate_resources27.exs rename to priv/test_repo/migrations/20240618085942_migrate_resources29.exs index 4ce1075..f8e6fe2 100644 --- a/priv/test_repo/migrations/20240529072637_migrate_resources27.exs +++ b/priv/test_repo/migrations/20240618085942_migrate_resources29.exs @@ -1,4 +1,4 @@ -defmodule AshPostgres.TestRepo.Migrations.MigrateResources27 do +defmodule AshPostgres.TestRepo.Migrations.MigrateResources29 do @moduledoc """ Updates resources based on their most recent snapshots. @@ -37,7 +37,7 @@ defmodule AshPostgres.TestRepo.Migrations.MigrateResources27 do end create( - unique_index(:stateful_post_followers, ["follower_id", "post_id", "state"], + unique_index(:stateful_post_followers, ["post_id", "follower_id", "state"], name: "stateful_post_followers_join_attributes_index" ) ) @@ -45,7 +45,7 @@ defmodule AshPostgres.TestRepo.Migrations.MigrateResources27 do def down do drop_if_exists( - unique_index(:stateful_post_followers, ["follower_id", "post_id", "state"], + unique_index(:stateful_post_followers, ["post_id", "follower_id", "state"], name: "stateful_post_followers_join_attributes_index" ) )