Supabase Client Implementation#8
Open
thisisamna wants to merge 8 commits into
Open
Conversation
…ing oneSHot field in question
Namely: - Command execution fixes - One shot questions addition - Environment setup (sample files, root vs regular user, etc) - Removed interview-specific features (difficulty, etc)
- Go back and forth between questions - Submission confirmation popup - Color-coded feedback for grading - Grading flow fixes and refactoring
This commit moves the database functionality to the database pkg, and defines a Client interface that defines its core functions. This allows the previously hard-coded SQLITE "backend" to be swapped out. The original implementation is now defined as LocalClient in sqlite.go.
This behavior adds the score of the same level multiple times when it is resubmitted. Now, the score is simply summed at the end, with individual submissions being saved as they come.
- Implement Client interface for connecting to a Supabase backend - Provide anonymous (credential-less) user authentication - Update TUI to use the new Supabase client for session initialization. - Backend URL and public token hard-coded for now; can be passed as CLI arguments in the future
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Feature: Add SupabaseClient with anonymous auth
Refactor: Created Client interface and refactored database functionality
Moved the database functionality to the
databasepkg, and define aClientinterface that outlines its core functions. This allows the previously hard-coded SQLITE "backend" to be swapped out. The original implementation is now defined asLocalClientinsqlite.go.Fix: Removed incremental score additions
There was a bug due to incrementing the score upon each submission, which led to the same points being awarded multiple times upon re-submission. Now, the score is simply summed at the end, with individual submissions being saved as they come.