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: add missing overrides to the supabase generator #422

Closed
wants to merge 2 commits into from

Conversation

devj3ns
Copy link
Contributor

@devj3ns devj3ns commented Aug 27, 2024

This PR sits on top of #420, which fixed some generator issues as described in #416.

It specifically resolves the following errors:

The Customer model has no onConflict specified in the SupabaseSerializable, which results in the following runtime error because of the missing override:

lib/brick/adapters/customer_adapter.g.dart:102:7: Error: The non-abstract class 'CustomerAdapter' is missing implementations for these members:
 - SupabaseAdapter.onConflict

The WindowType model has no SupabaseSerializable specified (because there is no corresponding Supabase table, it is used inside a JSONB field), and therefore the tableName is null, which results in the following runtime error because of the missing override:

lib/brick/adapters/window_type_adapter.g.dart:98:7: Error: The non-abstract class 'WindowTypeAdapter' is missing implementations for these members:
 - SupabaseAdapter.supabaseTableName

I just noticed that the supabaseTableName is a non-nullable field on the SupabaseAdapter, which means this PR is not ready as it is. @tshedor how should we handle this?

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

Successfully merging this pull request may close these issues.

2 participants