Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
439e1d8
refactor(core): simplify AppFailure ctor and remove AsyncResult alias
CowboyGH Dec 28, 2025
68df68b
feat(auth): add User entity and AuthRepository interface for authenti…
CowboyGH Dec 28, 2025
76c8068
feat(auth): add typed AuthFailure and Firebase mappers
CowboyGH Dec 28, 2025
65311dc
feat(auth): implement AuthRepository using Firebase Authentication
CowboyGH Dec 28, 2025
0616fac
test(auth): cover AuthRepositoryImpl
CowboyGH Dec 28, 2025
3376f11
test(auth): enhance AuthRepositoryImpl tests with signOut and authSta…
CowboyGH Jan 5, 2026
a09535f
chore: add *.freezed.dart to .gitignore for Build Runner generated files
CowboyGH Jan 5, 2026
6b4efe1
feat(auth): implement AuthBloc with authentication events and states
CowboyGH Jan 5, 2026
a45f267
test(auth): cover AuthBloc
CowboyGH Jan 5, 2026
37eda57
feat(auth): implement SignInPage and update routing for authentication
CowboyGH Jan 7, 2026
03086aa
feat(debug): add Sign Out button to DebugScreen for testing AuthBloc
CowboyGH Jan 7, 2026
314388c
feat(auth): implement redirect logic and auth state listener in router
CowboyGH Jan 7, 2026
f1888e9
feat(auth): add localized error messages for authentication failures
CowboyGH Jan 8, 2026
3ad34a7
docs(core): add descriptive comments for authentication failure classes
CowboyGH Jan 8, 2026
8a659c8
refactor(auth): simplify comments and documentation in authentication…
CowboyGH Jan 8, 2026
2a51a4e
chore: remove empty .gitkeep files from unnecessary directories
CowboyGH Jan 8, 2026
cacc367
chore: update Firebase dependencies to latest versions
CowboyGH Jan 8, 2026
7479be5
fix(ci): add code generation step to CI/CD pipeline and Dockerfile
CowboyGH Jan 9, 2026
5d02663
docs(core): update documentation for authentication failure classes
CowboyGH Jan 9, 2026
ecc6e82
docs: update CHANGELOG.md
CowboyGH Jan 9, 2026
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
3 changes: 3 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,9 @@ jobs:
- name: Get dependencies
run: flutter pub get

- name: Run code generation
run: dart run build_runner build --delete-conflicting-outputs

- name: Install Pods
run: |
cd ios
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ unlinked_spec.ds

# Build Runner generated
*.g.dart
*.freezed.dart
*.mocks.dart

# Firebase related
Expand Down
32 changes: 32 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,38 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- Added `User` entity for representing authenticated user data.
- Added `AuthRepository` interface defining contract for authentication operations.
- Added typed authentication failures (`AuthFailure` hierarchy, including `UnknownAuthFailure`).
- Added `AuthFailureMapper` to convert `FirebaseAuthException` to `AuthFailure`.
- Added `UserMapper` to convert Firebase `User` to domain `User`.
- Added `AuthRepositoryImpl` implementation using Firebase Authentication.
- Added unit tests for `AuthRepositoryImpl` (success, Firebase exceptions, unexpected errors, auth state stream).
- Added `AuthBloc` for authentication events/state handling.
- Added unit tests for `AuthBloc`.
- Added email/password auth UI (`SignInPage`) with sign in / sign up flow.
- Added `DebugScreen` sign out action for quick manual verification.
- Added auth-aware routing with GoRouter redirect (`/auth/*` is public, other routes require authentication).
- Added localized authentication failure messages (ARB + `AuthFailure` β†’ l10n mapper).

### Changed

- Changed `AppFailure` constructor: `message` is now a positional parameter (API change).
- Updated `AppFailure` constructor to match new `AppFailure` signature.
- Removed `AsyncResult<T>` type alias (deleted `async_result.dart`).
- Enhanced `AuthRepositoryImpl` tests: added sign out and `authStateChanges` verifications.
- Updated `.gitignore` to exclude generated `*.freezed.dart` files (Build Runner output).
- Updated auth route paths to use `/auth/*` prefix.
- Improved authentication failure documentation/comments.
- Removed unnecessary empty `.gitkeep` files.
- Updated Firebase dependencies to latest versions.

### Fixed

- Fixed CI failing due to missing generated Freezed files by running `build_runner` code generation in CI/Dockerfile.

## [0.2.0] - 2025-12-20

### Added
Expand Down
4 changes: 4 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,10 @@ RUN flutter pub get
COPY . .


# Run code generation
RUN dart run build_runner build --delete-conflicting-outputs


# Build Android APK in release mode
RUN flutter build apk --release --split-per-abi --no-tree-shake-icons

Expand Down
204 changes: 102 additions & 102 deletions ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1194,97 +1194,97 @@ PODS:
- BoringSSL-GRPC/Implementation (0.0.37):
- BoringSSL-GRPC/Interface (= 0.0.37)
- BoringSSL-GRPC/Interface (0.0.37)
- cloud_firestore (6.1.0):
- Firebase/Firestore (= 12.4.0)
- cloud_firestore (6.1.1):
- Firebase/Firestore (= 12.6.0)
- firebase_core
- Flutter
- connectivity_plus (0.0.1):
- Flutter
- Firebase/Auth (12.4.0):
- Firebase/Auth (12.6.0):
- Firebase/CoreOnly
- FirebaseAuth (~> 12.4.0)
- Firebase/CoreOnly (12.4.0):
- FirebaseCore (~> 12.4.0)
- Firebase/Crashlytics (12.4.0):
- FirebaseAuth (~> 12.6.0)
- Firebase/CoreOnly (12.6.0):
- FirebaseCore (~> 12.6.0)
- Firebase/Crashlytics (12.6.0):
- Firebase/CoreOnly
- FirebaseCrashlytics (~> 12.4.0)
- Firebase/Firestore (12.4.0):
- FirebaseCrashlytics (~> 12.6.0)
- Firebase/Firestore (12.6.0):
- Firebase/CoreOnly
- FirebaseFirestore (~> 12.4.0)
- Firebase/Storage (12.4.0):
- FirebaseFirestore (~> 12.6.0)
- Firebase/Storage (12.6.0):
- Firebase/CoreOnly
- FirebaseStorage (~> 12.4.0)
- firebase_analytics (12.0.4):
- FirebaseStorage (~> 12.6.0)
- firebase_analytics (12.1.0):
- firebase_core
- FirebaseAnalytics (= 12.4.0)
- FirebaseAnalytics (= 12.6.0)
- Flutter
- firebase_auth (6.1.2):
- Firebase/Auth (= 12.4.0)
- firebase_auth (6.1.3):
- Firebase/Auth (= 12.6.0)
- firebase_core
- Flutter
- firebase_core (4.2.1):
- Firebase/CoreOnly (= 12.4.0)
- firebase_core (4.3.0):
- Firebase/CoreOnly (= 12.6.0)
- Flutter
- firebase_crashlytics (5.0.5):
- Firebase/Crashlytics (= 12.4.0)
- firebase_crashlytics (5.0.6):
- Firebase/Crashlytics (= 12.6.0)
- firebase_core
- Flutter
- firebase_storage (13.0.4):
- Firebase/Storage (= 12.4.0)
- firebase_storage (13.0.5):
- Firebase/Storage (= 12.6.0)
- firebase_core
- Flutter
- FirebaseAnalytics (12.4.0):
- FirebaseAnalytics/Default (= 12.4.0)
- FirebaseCore (~> 12.4.0)
- FirebaseInstallations (~> 12.4.0)
- FirebaseAnalytics (12.6.0):
- FirebaseAnalytics/Default (= 12.6.0)
- FirebaseCore (~> 12.6.0)
- FirebaseInstallations (~> 12.6.0)
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/MethodSwizzler (~> 8.1)
- GoogleUtilities/Network (~> 8.1)
- "GoogleUtilities/NSData+zlib (~> 8.1)"
- nanopb (~> 3.30910.0)
- FirebaseAnalytics/Default (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseInstallations (~> 12.4.0)
- GoogleAppMeasurement/Default (= 12.4.0)
- FirebaseAnalytics/Default (12.6.0):
- FirebaseCore (~> 12.6.0)
- FirebaseInstallations (~> 12.6.0)
- GoogleAppMeasurement/Default (= 12.6.0)
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/MethodSwizzler (~> 8.1)
- GoogleUtilities/Network (~> 8.1)
- "GoogleUtilities/NSData+zlib (~> 8.1)"
- nanopb (~> 3.30910.0)
- FirebaseAppCheckInterop (12.4.0)
- FirebaseAuth (12.4.0):
- FirebaseAppCheckInterop (~> 12.4.0)
- FirebaseAuthInterop (~> 12.4.0)
- FirebaseCore (~> 12.4.0)
- FirebaseCoreExtension (~> 12.4.0)
- FirebaseAppCheckInterop (12.6.0)
- FirebaseAuth (12.6.0):
- FirebaseAppCheckInterop (~> 12.6.0)
- FirebaseAuthInterop (~> 12.6.0)
- FirebaseCore (~> 12.6.0)
- FirebaseCoreExtension (~> 12.6.0)
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/Environment (~> 8.1)
- GTMSessionFetcher/Core (< 6.0, >= 3.4)
- RecaptchaInterop (~> 101.0)
- FirebaseAuthInterop (12.4.0)
- FirebaseCore (12.4.0):
- FirebaseCoreInternal (~> 12.4.0)
- FirebaseAuthInterop (12.6.0)
- FirebaseCore (12.6.0):
- FirebaseCoreInternal (~> 12.6.0)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/Logger (~> 8.1)
- FirebaseCoreExtension (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseCoreInternal (12.4.0):
- FirebaseCoreExtension (12.6.0):
- FirebaseCore (~> 12.6.0)
- FirebaseCoreInternal (12.6.0):
- "GoogleUtilities/NSData+zlib (~> 8.1)"
- FirebaseCrashlytics (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseInstallations (~> 12.4.0)
- FirebaseRemoteConfigInterop (~> 12.4.0)
- FirebaseSessions (~> 12.4.0)
- FirebaseCrashlytics (12.6.0):
- FirebaseCore (~> 12.6.0)
- FirebaseInstallations (~> 12.6.0)
- FirebaseRemoteConfigInterop (~> 12.6.0)
- FirebaseSessions (~> 12.6.0)
- GoogleDataTransport (~> 10.1)
- GoogleUtilities/Environment (~> 8.1)
- nanopb (~> 3.30910.0)
- PromisesObjC (~> 2.4)
- FirebaseFirestore (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseCoreExtension (~> 12.4.0)
- FirebaseFirestoreInternal (~> 12.4.0)
- FirebaseSharedSwift (~> 12.4.0)
- FirebaseFirestoreInternal (12.4.0):
- FirebaseFirestore (12.6.0):
- FirebaseCore (~> 12.6.0)
- FirebaseCoreExtension (~> 12.6.0)
- FirebaseFirestoreInternal (~> 12.6.0)
- FirebaseSharedSwift (~> 12.6.0)
- FirebaseFirestoreInternal (12.6.0):
- abseil/algorithm (~> 1.20240722.0)
- abseil/base (~> 1.20240722.0)
- abseil/container/flat_hash_map (~> 1.20240722.0)
Expand All @@ -1293,58 +1293,58 @@ PODS:
- abseil/strings/strings (~> 1.20240722.0)
- abseil/time (~> 1.20240722.0)
- abseil/types (~> 1.20240722.0)
- FirebaseAppCheckInterop (~> 12.4.0)
- FirebaseCore (~> 12.4.0)
- FirebaseAppCheckInterop (~> 12.6.0)
- FirebaseCore (~> 12.6.0)
- "gRPC-C++ (~> 1.69.0)"
- gRPC-Core (~> 1.69.0)
- leveldb-library (~> 1.22)
- nanopb (~> 3.30910.0)
- FirebaseInstallations (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseInstallations (12.6.0):
- FirebaseCore (~> 12.6.0)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/UserDefaults (~> 8.1)
- PromisesObjC (~> 2.4)
- FirebaseRemoteConfigInterop (12.4.0)
- FirebaseSessions (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseCoreExtension (~> 12.4.0)
- FirebaseInstallations (~> 12.4.0)
- FirebaseRemoteConfigInterop (12.6.0)
- FirebaseSessions (12.6.0):
- FirebaseCore (~> 12.6.0)
- FirebaseCoreExtension (~> 12.6.0)
- FirebaseInstallations (~> 12.6.0)
- GoogleDataTransport (~> 10.1)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/UserDefaults (~> 8.1)
- nanopb (~> 3.30910.0)
- PromisesSwift (~> 2.1)
- FirebaseSharedSwift (12.4.0)
- FirebaseStorage (12.4.0):
- FirebaseAppCheckInterop (~> 12.4.0)
- FirebaseAuthInterop (~> 12.4.0)
- FirebaseCore (~> 12.4.0)
- FirebaseCoreExtension (~> 12.4.0)
- FirebaseSharedSwift (12.6.0)
- FirebaseStorage (12.6.0):
- FirebaseAppCheckInterop (~> 12.6.0)
- FirebaseAuthInterop (~> 12.6.0)
- FirebaseCore (~> 12.6.0)
- FirebaseCoreExtension (~> 12.6.0)
- GoogleUtilities/Environment (~> 8.1)
- GTMSessionFetcher/Core (< 6.0, >= 3.4)
- Flutter (1.0.0)
- GoogleAdsOnDeviceConversion (3.1.0):
- GoogleAdsOnDeviceConversion (3.2.0):
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/Logger (~> 8.1)
- GoogleUtilities/Network (~> 8.1)
- nanopb (~> 3.30910.0)
- GoogleAppMeasurement/Core (12.4.0):
- GoogleAppMeasurement/Core (12.6.0):
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/MethodSwizzler (~> 8.1)
- GoogleUtilities/Network (~> 8.1)
- "GoogleUtilities/NSData+zlib (~> 8.1)"
- nanopb (~> 3.30910.0)
- GoogleAppMeasurement/Default (12.4.0):
- GoogleAdsOnDeviceConversion (~> 3.1.0)
- GoogleAppMeasurement/Core (= 12.4.0)
- GoogleAppMeasurement/IdentitySupport (= 12.4.0)
- GoogleAppMeasurement/Default (12.6.0):
- GoogleAdsOnDeviceConversion (~> 3.2.0)
- GoogleAppMeasurement/Core (= 12.6.0)
- GoogleAppMeasurement/IdentitySupport (= 12.6.0)
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/MethodSwizzler (~> 8.1)
- GoogleUtilities/Network (~> 8.1)
- "GoogleUtilities/NSData+zlib (~> 8.1)"
- nanopb (~> 3.30910.0)
- GoogleAppMeasurement/IdentitySupport (12.4.0):
- GoogleAppMeasurement/Core (= 12.4.0)
- GoogleAppMeasurement/IdentitySupport (12.6.0):
- GoogleAppMeasurement/Core (= 12.6.0)
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/MethodSwizzler (~> 8.1)
- GoogleUtilities/Network (~> 8.1)
Expand Down Expand Up @@ -1472,7 +1472,7 @@ PODS:
- gRPC-Core/Privacy (= 1.69.0)
- gRPC-Core/Interface (1.69.0)
- gRPC-Core/Privacy (1.69.0)
- GTMSessionFetcher/Core (5.0.0)
- GTMSessionFetcher/Core (3.5.0)
- leveldb-library (1.22.6)
- nanopb (3.30910.0):
- nanopb/decode (= 3.30910.0)
Expand Down Expand Up @@ -1566,37 +1566,37 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
abseil: a05cc83bf02079535e17169a73c5be5ba47f714b
BoringSSL-GRPC: dded2a44897e45f28f08ae87a55ee4bcd19bc508
cloud_firestore: 7a6d8a533ec7418a7fe46b3a5dabf55661a5b298
cloud_firestore: 45532e0c1fd1f6a5720af8aa0312470c366b73d2
connectivity_plus: cb623214f4e1f6ef8fe7403d580fdad517d2f7dd
Firebase: f07b15ae5a6ec0f93713e30b923d9970d144af3e
firebase_analytics: 67fbdd9f3c04e55048024f3da21cfc36f05e56cf
firebase_auth: 9225db04db5d8e3b46dc8940e04bc6aec6833e27
firebase_core: f1aafb21c14f497e5498f7ffc4dc63cbb52b2594
firebase_crashlytics: c039028126cb45e32f4c217aa392408b0963d081
firebase_storage: d558bbfa99449fff39352db83c466c8515fa1afa
FirebaseAnalytics: 0fc2b20091f0ddd21bf73397cf8f0eb5346dc24f
FirebaseAppCheckInterop: f734c802f21fe1da0837708f0f9a27218c8a4ed0
FirebaseAuth: 4a2aed737c84114a9d9b33d11ae1b147d6b94889
FirebaseAuthInterop: 858e6b754966e70740a4370dd1503dfffe6dbb49
FirebaseCore: bb595f3114953664e3c1dc032f008a244147cfd3
FirebaseCoreExtension: 7e1f7118ee970e001a8013719fb90950ee5e0018
FirebaseCoreInternal: d7f5a043c2cd01a08103ab586587c1468047bca6
FirebaseCrashlytics: a6ece278a837c7e88de2d9b5da0a3542f2342395
FirebaseFirestore: 2a6183381cf7679b1bb000eb76a8e3178e25dee2
FirebaseFirestoreInternal: 6577a27cd5dc3722b900042527f86d4ea1626134
FirebaseInstallations: ae9f4902cb5bf1d0c5eaa31ec1f4e5495a0714e2
FirebaseRemoteConfigInterop: 1e31ec72b89c9924367c59bfb5ec9ab60d1d6766
FirebaseSessions: ba7c7a7ca8696a8d540eb3fe3800fbe98c79786d
FirebaseSharedSwift: 93426a1de92f19e1199fac5295a4f8df16458daa
FirebaseStorage: 20d6b56fb8a40ebaa03d6a2889fe33dac64adb73
Firebase: a451a7b61536298fd5cbfe3a746fd40443a50679
firebase_analytics: 4f9cca09e65f6c2944a862c6dc86f6bed9fb769c
firebase_auth: f547a06ed4933a1da2b9ac8d8c64ae09d113c8e1
firebase_core: ba00a168e719694f38960502ceb560285603d073
firebase_crashlytics: 13f4b77e9ce2a84b1f8ea07f293db5b6213ce1cf
firebase_storage: 90cdab308fdc9e9aedcbe90d62b949cb66d91ce1
FirebaseAnalytics: d0a97a0db6425e5a5d966340b87f92ca7b13a557
FirebaseAppCheckInterop: e2178171b4145013c7c1a3cc464d1d446d3a1896
FirebaseAuth: 613c463cb43545a7fd2cd99ade09b78ac472c544
FirebaseAuthInterop: db06756ef028006d034b6004dc0c37c24f7828d4
FirebaseCore: 0e38ad5d62d980a47a64b8e9301ffa311457be04
FirebaseCoreExtension: 032fd6f8509e591fda8cb76f6651f20d926b121f
FirebaseCoreInternal: 69bf1306a05b8ac43004f6cc1f804bb7b05b229e
FirebaseCrashlytics: 3d6248c50726ee7832aef0e53cb84c9e64d9fa7e
FirebaseFirestore: 51ce079b9ddcaa481644164eda649d362c2a6396
FirebaseFirestoreInternal: 8b1d2b0a1b859b2ddbd63f448c416c5be7367405
FirebaseInstallations: 631b38da2e11a83daa4bfb482f79d286a5dfa7ad
FirebaseRemoteConfigInterop: 3443b8cb8fffd76bb3e03b2a84bfd3db952fcda4
FirebaseSessions: 2e8f808347e665dff3e5843f275715f07045297d
FirebaseSharedSwift: 79f27fff0addd15c3de19b87fba426f3cc2c964f
FirebaseStorage: 550349b1e8f7315834ea08308696e9469d77135d
Flutter: cabc95a1d2626b1b06e7179b784ebcf0c0cde467
GoogleAdsOnDeviceConversion: e03a386840803ea7eef3fd22a061930142c039c1
GoogleAppMeasurement: 1e718274b7e015cefd846ac1fcf7820c70dc017d
GoogleAdsOnDeviceConversion: d68c69dd9581a0f5da02617b6f377e5be483970f
GoogleAppMeasurement: 3bf40aff49a601af5da1c3345702fcb4991d35ee
GoogleDataTransport: aae35b7ea0c09004c3797d53c8c41f66f219d6a7
GoogleUtilities: 00c88b9a86066ef77f0da2fab05f65d7768ed8e1
"gRPC-C++": cc207623316fb041a7a3e774c252cf68a058b9e8
gRPC-Core: 860978b7db482de8b4f5e10677216309b5ff6330
GTMSessionFetcher: 02d6e866e90bc236f48a703a041dfe43e6221a29
GTMSessionFetcher: 5aea5ba6bd522a239e236100971f10cb71b96ab6
leveldb-library: cc8b8f8e013647a295ad3f8cd2ddf49a6f19be19
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
path_provider_foundation: bb55f6dbba17d0dccd6737fe6f7f34fbd0376880
Expand Down
Loading