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

fix: Ecto.Enum type wrapped in tuple #58

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Ziinc
Copy link

@Ziinc Ziinc commented Aug 28, 2024

This fixes a bug with the Ecto.Enum, which seems to be wrapped in tuples.

[error] [] Task #PID<0.2169.0> started from Logflare.Vault terminating
** (FunctionClauseError) no function clause matching in Code.ensure_loaded?/1
    (elixir 1.16.0) lib/code.ex:1814: Code.ensure_loaded?({:parameterized, {Ecto.Enum, %{on_load: %{"bigquery" => :bigquery, "datadog" => :datadog, "elastic" => :elastic, "postgres" => :postgres, "webhook" => :webhook}, type: :string, embed_as: :self, on_cast: %{"bigquery" => :bigquery, "datadog" => :datadog, "elastic" => :elastic, "postgres" => :postgres, "webhook" => :webhook}, mappings: [webhook: "webhook", postgres: "postgres", bigquery: "bigquery", datadog: "datadog", elastic: "elastic"], on_dump: %{webhook: "webhook", postgres: "postgres", bigquery: "bigquery", datadog: "datadog", elastic: "elastic"}}}})
    (cloak_ecto 1.3.0) lib/cloak_ecto/migrator.ex:85: Cloak.Ecto.Migrator.cloak_field?/1
    (elixir 1.16.0) lib/enum.ex:4277: Enum.filter_list/2
    (cloak_ecto 1.3.0) lib/cloak_ecto/migrator.ex:62: Cloak.Ecto.Migrator.cloak_fields/1
    (cloak_ecto 1.3.0) lib/cloak_ecto/migrator.ex:21: Cloak.Ecto.Migrator.migrate_schema_with_data/2
    (elixir 1.16.0) lib/enum.ex:1700: Enum."-map/2-lists^map/1-1-"/2
    (logflare 1.8.4) lib/logflare/vault.ex:66: anonymous fn/3 in Logflare.Vault.init/1
    (elixir 1.16.0) lib/task/supervised.ex:101: Task.Supervised.invoke_mfa/2
Function: #Function<2.133720658/0 in Logflare.Vault.init/1>
    Args: []

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant