Skip to content

Conversation

@xsahil03x
Copy link
Member

@xsahil03x xsahil03x commented Dec 9, 2025

IOS PR: GetStream/stream-feeds-swift#53
Core PR: GetStream/stream-core-flutter#22

Important

Switch to pub dependency before merging the PR

Summary by CodeRabbit

  • Breaking Changes

    • Filter field type renamed to activityType in activity queries
    • Activity location field now uses geographic coordinates
  • New Features

    • Location-based activity filtering with nearby and bounding box search capabilities
    • Added feed and interest tags as new filter criteria
    • Expanded operator support for activity filtering (equality, comparison, full-text search, path checking)

✏️ Tip: You can customize this high-level summary in your review settings.

@xsahil03x xsahil03x requested a review from a team as a code owner December 9, 2025 16:51
@coderabbitai
Copy link

coderabbitai bot commented Dec 9, 2025

Walkthrough

The pull request refactors the activity filtering API by renaming ActivitiesFilterField.type to ActivitiesFilterField.activityType, changes ActivityData.location from ActivityLocation? to LocationCoordinate?, adds new location-based filter fields (near, withinBounds, feed, interestTags), expands operator support for existing filter fields, and updates the stream_core dependency to a git-based reference for location filtering features.

Changes

Cohort / File(s) Change Summary
Configuration
melos.yaml, packages/stream_feeds/pubspec.yaml
Updated stream_core dependency from version constraint (^0.3.1) to git-based dependency pointing to GetStream/stream-core-flutter feat/location-filtering branch
Changelog
packages/stream_feeds/CHANGELOG.md
Added breaking changes: rename type → activityType, change location field type from ActivityLocation? to LocationCoordinate?, add location filtering fields (near, withinBounds, feed, interestTags)
Models & Exports
packages/stream_feeds/lib/src/models.dart
Re-exported BoundingBox, CircularRegion, LocationCoordinate from stream_core
Activity Data Model
packages/stream_feeds/lib/src/models/activity_data.dart, packages/stream_feeds/lib/src/models/activity_data.freezed.dart
Changed location field type from ActivityLocation? to LocationCoordinate?; updated ActivityResponseMapper to transform location data; regenerated freezed copyWith interfaces and implementations
Query Filters
packages/stream_feeds/lib/src/state/query/activities_query.dart
Removed ActivitiesFilterField.type; added activityType, feed, interestTags, near, withinBounds filter fields; expanded operator support for expiresAt, filterTags, searchData, and text fields
Documentation & Examples
docs/code_snippets/03_02_querying_activities.dart, packages/stream_feeds/lib/src/feeds_client.dart, packages/stream_feeds/lib/src/state/query/feed_query.dart
Updated code examples to use ActivitiesFilterField.activityType instead of type
Tests
packages/stream_feeds/test/state/activity_list_test.dart, packages/stream_feeds/test/state/feed_test.dart
Updated all test cases to use ActivitiesFilterField.activityType instead of type across single and composite filters

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

  • Key areas requiring attention:
    • Breaking API changes: Verify all consumers of ActivitiesFilterField.type are updated and that the rename to activityType reflects the intended semantics
    • Location field refactoring: Confirm the mapping transformation from location to LocationCoordinate(latitude: lat, longitude: lng) is correct and doesn't lose data
    • New filter fields: Review operator support for new fields (near, withinBounds, feed, interestTags) to ensure completeness
    • Generated code: Validate freezed regeneration captures all location field type changes in copyWith implementations
    • Dependency change: Ensure git-based stream_core dependency resolves correctly and the feat/location-filtering branch is stable

Possibly related PRs

Poem

🐰 With whiskers twitched and filters refined,
We hopped through types and left them behind!
Location fields now bloom with coordinates bright,
And queries dance through boundaries with delight.
The type's renamed, the feeds take flight—
A refactored warren, oh what a sight! 🌍✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description check ⚠️ Warning The description is incomplete and lacks critical information required by the template, including CLA checkbox, description of changes, testing instructions, and screenshots. Complete the description template by checking the CLA checkbox, explaining the location-based filtering feature and how to test it, and filling in the ticket/issue references.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main feature being added: location-based filtering support for activities, which aligns with the comprehensive changes across the codebase including new filter fields (near, withinBounds), location type changes, and documentation updates.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/location-based-filtering

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (2)
melos.yaml (1)

50-57: Git-based stream_core dep is fine for feature work; plan for stabilization.

Pointing stream_core at feat/location-filtering makes sense while iterating, but for long‑term CI/release stability you’ll likely want to switch back to a tagged version or a commit SHA before publishing. Also double‑check that all packages using stream_core are aligned on the same source to avoid resolution surprises.

packages/stream_feeds/test/state/activity_list_test.dart (1)

23-29: Tests correctly updated to filter on activityType; consider adding coverage for new location filters.

All the updated filters now use ActivitiesFilterField.activityType, which matches the API rename while preserving the original test intent around type‑based local filtering. As a follow‑up (not blocking), it could be useful to add a couple of tests exercising ActivitiesFilterField.near/withinBounds once those behaviors are stable, to guard the new location‑based logic.

Also applies to: 53-59, 90-96, 127-133, 156-162, 185-191, 218-226, 252-258

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 4bbd1dc and 1bd7098.

📒 Files selected for processing (12)
  • docs/code_snippets/03_02_querying_activities.dart (1 hunks)
  • melos.yaml (1 hunks)
  • packages/stream_feeds/CHANGELOG.md (1 hunks)
  • packages/stream_feeds/lib/src/feeds_client.dart (1 hunks)
  • packages/stream_feeds/lib/src/models.dart (1 hunks)
  • packages/stream_feeds/lib/src/models/activity_data.dart (2 hunks)
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart (3 hunks)
  • packages/stream_feeds/lib/src/state/query/activities_query.dart (5 hunks)
  • packages/stream_feeds/lib/src/state/query/feed_query.dart (1 hunks)
  • packages/stream_feeds/pubspec.yaml (1 hunks)
  • packages/stream_feeds/test/state/activity_list_test.dart (8 hunks)
  • packages/stream_feeds/test/state/feed_test.dart (8 hunks)
🧰 Additional context used
📓 Path-based instructions (7)
**/*.dart

📄 CodeRabbit inference engine (.cursor/rules/cursor-rules-location.mdc)

**/*.dart: Use the barrel_files package with @includeInBarrelFile annotations for public API management in Dart projects; keep implementation details in lib/src/ without annotations
Mark only classes, functions, and enums intended for external package usage with @includeInBarrelFile; keep repository classes, mappers, and internal state objects in lib/src/ without annotations

**/*.dart: Use @freezed mixed mode for data classes in Dart
Return Result<T> from all repository methods in Dart
Apply early return patterns consistently in Dart code
Use pattern matching with switch expressions in Dart
Mark public APIs with @includeInBarrelFile annotation in Dart
Follow enhanced enum vs sealed class guidelines in Dart
Use const constructors where possible in Dart
Implement proper disposal patterns in Dart StateNotifiers and providers
Ensure pure Dart compatibility across VM, Flutter, and Web environments
Plan for StateNotifier reactive patterns when implementing state management in Dart

**/*.dart: Use @freezed for all data classes with required id fields and const constructors
Implement StateNotifier-based reactive state management with automatic change notifications
Apply Result pattern for all async operations with explicit error handling
Use early return patterns for clean control flow in Dart code
Create extension functions for data mapping using .toModel() pattern instead of mapper classes
Mark public APIs with @includeInBarrelFile annotation for barrel file export management
Implement proper resource management with disposal and cleanup patterns in Dart code
Use constructor injection for all dependencies in Dart classes

**/*.dart: All data models should use @freezed with Dart's mixed mode syntax and include @OverRide annotations on fields
Mark classes for public export using @includeInBarrelFile annotation
Use extension functions with .toModel() convention for data mapping instead of dedicated mapper classes
All repository methods must return Result...

Files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • docs/code_snippets/03_02_querying_activities.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
  • packages/stream_feeds/lib/src/models/activity_data.dart
packages/stream_feeds/lib/src/**/*.dart

📄 CodeRabbit inference engine (AGENTS.md)

Use // for internal/private code documentation

Files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/lib/src/models/activity_data.dart
packages/stream_feeds/lib/**/*.dart

📄 CodeRabbit inference engine (AGENTS.md)

Apply Dart analyzer configuration from analysis_options.yaml for code quality

Files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/lib/src/models/activity_data.dart
packages/stream_feeds/lib/src/models/**/*.dart

📄 CodeRabbit inference engine (AGENTS.md)

packages/stream_feeds/lib/src/models/**/*.dart: Use @freezed for all data classes in the Stream Feeds SDK
Follow Freezed 3.0 mixed mode syntax with @override annotations for fields
All models should have an id field when representing entities
Place custom data fields last in constructors and class definitions
Model naming convention: Use *Data suffix for model classes (e.g., ActivityData, FeedData)
Query naming convention: Use *Query suffix for query classes (e.g., ActivitiesQuery, FeedsQuery)
Request naming convention: Use *Request suffix for request classes (e.g., FeedAddActivityRequest)

Files:

  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/lib/src/models/activity_data.dart
packages/stream_feeds/pubspec.yaml

📄 CodeRabbit inference engine (AGENTS.md)

packages/stream_feeds/pubspec.yaml: Pure Dart SDK: The stream_feeds package must have no platform-specific dependencies and work outside of Flutter
Use semantic versioning for SDK releases

Files:

  • packages/stream_feeds/pubspec.yaml
packages/stream_feeds/lib/src/state/**/*.dart

📄 CodeRabbit inference engine (AGENTS.md)

packages/stream_feeds/lib/src/state/**/*.dart: State classes must use @freezed with const constructors
State class naming convention: Use *State suffix for state classes (e.g., FeedState, ActivityListState)

Files:

  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
packages/stream_feeds/test/**/*.dart

📄 CodeRabbit inference engine (AGENTS.md)

packages/stream_feeds/test/**/*.dart: Test through public APIs only, not internal StateNotifier implementations
Use HTTP interceptors instead of mocking repositories in tests
Mirror the lib/ structure in test/ directory organization

Files:

  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
🧠 Learnings (35)
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/stream_feeds.dart : Export public API classes from main library entry point `lib/stream_feeds.dart`

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/pubspec.yaml
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/stream_feeds.dart : Keep public API minimal - most code should be in `lib/src/` internal directory

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/pubspec.yaml
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/stream_feeds.dart : Use `///` for public API documentation in exported classes and methods

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/pubspec.yaml
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/stream_feeds.dart : Follow Effective Dart documentation guidelines for all public APIs

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/pubspec.yaml
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : Follow Freezed 3.0 mixed mode syntax with `override` annotations for fields

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/test/state/feed_test.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : Use `freezed` for all data classes in the Stream Feeds SDK

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/pubspec.yaml
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/generated/**/*.dart : Never manually edit generated files (`*.freezed.dart`, `*.g.dart`, `src/generated/`)

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/pubspec.yaml
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : All models should have an `id` field when representing entities

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/repository/**/*.dart : Use extension functions for API-to-domain model mapping in repositories

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : Model naming convention: Use `*Data` suffix for model classes (e.g., `ActivityData`, `FeedData`)

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
  • packages/stream_feeds/lib/src/models/activity_data.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/**/*.dart : Use `//` for internal/private code documentation

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/pubspec.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/stream_feeds.dart : Include examples for complex APIs in documentation

Applied to files:

  • packages/stream_feeds/lib/src/models.dart
  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
📚 Learning: 2025-12-05T14:37:37.953Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-sdk.mdc:0-0
Timestamp: 2025-12-05T14:37:37.953Z
Learning: Applies to **/*.dart : Use immutable freezed models for all data classes with required id fields

Applied to files:

  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
📚 Learning: 2025-12-05T14:37:37.953Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-sdk.mdc:0-0
Timestamp: 2025-12-05T14:37:37.953Z
Learning: Applies to **/*.dart : All data models should use freezed with Dart's mixed mode syntax and include override annotations on fields

Applied to files:

  • packages/stream_feeds/lib/src/models/activity_data.freezed.dart
📚 Learning: 2025-12-05T14:37:17.519Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-api.mdc:0-0
Timestamp: 2025-12-05T14:37:17.519Z
Learning: Applies to {**/api/**/*.dart,**/*_api.dart,**/client/*.dart} : Stream Feeds API integration should be implemented according to the Activity Streams specification with structured actor, verb, object, and target fields

Applied to files:

  • packages/stream_feeds/lib/src/feeds_client.dart
  • docs/code_snippets/03_02_querying_activities.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
  • packages/stream_feeds/lib/src/models/activity_data.dart
  • packages/stream_feeds/CHANGELOG.md
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : Query naming convention: Use `*Query` suffix for query classes (e.g., `ActivitiesQuery`, `FeedsQuery`)

Applied to files:

  • packages/stream_feeds/lib/src/feeds_client.dart
  • docs/code_snippets/03_02_querying_activities.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : Request naming convention: Use `*Request` suffix for request classes (e.g., `FeedAddActivityRequest`)

Applied to files:

  • packages/stream_feeds/lib/src/feeds_client.dart
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
📚 Learning: 2025-12-05T14:37:17.519Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-api.mdc:0-0
Timestamp: 2025-12-05T14:37:17.519Z
Learning: Applies to {**/api/**/*.dart,**/*_api.dart,**/client/*.dart} : Use batch operations for bulk activity creation and updates to optimize API performance

Applied to files:

  • packages/stream_feeds/lib/src/feeds_client.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/pubspec.yaml : Pure Dart SDK: The stream_feeds package must have no platform-specific dependencies and work outside of Flutter

Applied to files:

  • packages/stream_feeds/pubspec.yaml
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/pubspec.yaml : Use semantic versioning for SDK releases

Applied to files:

  • packages/stream_feeds/pubspec.yaml
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/generated/**/*.dart : Never manually edit OpenAPI-generated API code files in `src/generated/`

Applied to files:

  • packages/stream_feeds/pubspec.yaml
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/test/**/*.dart : Use HTTP interceptors instead of mocking repositories in tests

Applied to files:

  • packages/stream_feeds/pubspec.yaml
  • packages/stream_feeds/test/state/activity_list_test.dart
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/state/**/*StateNotifier.dart : Use StateNotifier for reactive state management

Applied to files:

  • packages/stream_feeds/pubspec.yaml
  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/test/**/*.dart : Test through public APIs only, not internal StateNotifier implementations

Applied to files:

  • packages/stream_feeds/pubspec.yaml
  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
  • melos.yaml
📚 Learning: 2025-12-05T14:37:05.876Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/project-overview.mdc:0-0
Timestamp: 2025-12-05T14:37:05.876Z
Learning: Applies to **/*.dart : Implement StateNotifier-based reactive state management with automatic change notifications

Applied to files:

  • packages/stream_feeds/pubspec.yaml
📚 Learning: 2025-12-05T14:37:37.953Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-sdk.mdc:0-0
Timestamp: 2025-12-05T14:37:37.953Z
Learning: Applies to **/*.dart : Use StateNotifier for reactive state management with automatic change notifications

Applied to files:

  • packages/stream_feeds/pubspec.yaml
📚 Learning: 2025-12-05T14:37:37.953Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-sdk.mdc:0-0
Timestamp: 2025-12-05T14:37:37.953Z
Learning: Applies to **/*.dart : Use Dart's type-safe queries for API operations with freezed query specifications

Applied to files:

  • docs/code_snippets/03_02_querying_activities.dart
  • packages/stream_feeds/lib/src/state/query/activities_query.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/state/**/*.dart : State class naming convention: Use `*State` suffix for state classes (e.g., `FeedState`, `ActivityListState`)

Applied to files:

  • packages/stream_feeds/lib/src/state/query/feed_query.dart
  • packages/stream_feeds/test/state/feed_test.dart
  • packages/stream_feeds/test/state/activity_list_test.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/state/**/*StateNotifier.dart : StateNotifier naming convention: Use `*StateNotifier` suffix for StateNotifier implementations (e.g., `FeedStateNotifier`)

Applied to files:

  • packages/stream_feeds/test/state/feed_test.dart
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/src/models/**/*.dart : Place custom data fields last in constructors and class definitions

Applied to files:

  • packages/stream_feeds/lib/src/models/activity_data.dart
📚 Learning: 2025-12-05T14:36:55.335Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/planit-mode.mdc:0-0
Timestamp: 2025-12-05T14:36:55.335Z
Learning: Consider melos mono repo dependencies when implementing features

Applied to files:

  • melos.yaml
📚 Learning: 2025-12-05T14:37:05.876Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/project-overview.mdc:0-0
Timestamp: 2025-12-05T14:37:05.876Z
Learning: All shared dependencies must be defined in melos.yaml for mono repo management

Applied to files:

  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Sync dependencies via `melos bootstrap` after changes to melos.yaml or pubspec.yaml

Applied to files:

  • melos.yaml
📚 Learning: 2025-12-05T14:38:02.662Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-05T14:38:02.662Z
Learning: Applies to packages/stream_feeds/lib/**/*.dart : Apply Dart analyzer configuration from `analysis_options.yaml` for code quality

Applied to files:

  • melos.yaml
📚 Learning: 2025-12-05T14:37:17.519Z
Learnt from: CR
Repo: GetStream/stream-feeds-flutter PR: 0
File: .cursor/rules/stream-feeds-api.mdc:0-0
Timestamp: 2025-12-05T14:37:17.519Z
Learning: Applies to {**/api/**/*.dart,**/*_api.dart,**/client/*.dart} : Implement proper authentication using API keys and user tokens via the StreamFeedsClient with tokenProvider parameter

Applied to files:

  • melos.yaml
🪛 LanguageTool
packages/stream_feeds/CHANGELOG.md

[style] ~7-~7: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...terField.withinBoundsfilter fields. - Add new activity filter fields:Activities...

(ENGLISH_WORD_REPEAT_BEGINNING_RULE)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: build
  • GitHub Check: stream_feeds
🔇 Additional comments (15)
docs/code_snippets/03_02_querying_activities.dart (1)

7-11: Doc snippet correctly updated to activityType.

Using ActivitiesFilterField.activityType here keeps the example aligned with the renamed query field and will compile with the new API.

packages/stream_feeds/lib/src/feeds_client.dart (1)

320-328: ActivityList example updated consistently to activityType.

The example now matches the renamed ActivitiesFilterField.activityType field, so users can copy-paste it with the new API without errors.

packages/stream_feeds/CHANGELOG.md (1)

1-8: Changelog entries clearly describe the breaking and new filtering features.

The notes for activityType, LocationCoordinate, and new filter fields read clearly and match the implemented changes, so consumers will understand the impact.

packages/stream_feeds/lib/src/state/query/feed_query.dart (1)

18-26: FeedQuery example now uses activityType correctly.

The example filter matches the new ActivitiesFilterField.activityType field, so documentation stays consistent with the query API.

packages/stream_feeds/lib/src/models.dart (1)

1-3: Re‑exporting location types from models.dart aligns the public API with new features.

Exposing BoundingBox, CircularRegion, and LocationCoordinate through the models barrel matches how other domain types are surfaced and supports the new location‑based filters and activity data.

packages/stream_feeds/lib/src/models/activity_data.dart (1)

128-131: Location field migration to LocationCoordinate looks consistent and safe.

Changing location to LocationCoordinate? and mapping ActivityResponse.location via location?.let((it) => LocationCoordinate(latitude: it.lat, longitude: it.lng)) preserves null‑handling and cleanly encapsulates the lat/lng pair in the new type. This keeps the domain model aligned with the new location‑filtering capabilities.

Also applies to: 280-285

packages/stream_feeds/test/state/feed_test.dart (2)

419-419: Consistent rename from type to activityType.

The field rename is correctly applied and aligns with the broader API refactor in ActivitiesFilterField.


451-451: All activityType filter usages are consistent.

The remaining filter field renames are correctly applied across all local filtering test scenarios.

Also applies to: 483-483, 561-561, 600-600, 637-637, 675-675, 714-714

packages/stream_feeds/lib/src/models/activity_data.freezed.dart (1)

1-10: Generated file - changes are consistent with source model.

This is auto-generated code reflecting the location field type change from ActivityLocation? to LocationCoordinate? in the source activity_data.dart. No manual edits should be made here.

packages/stream_feeds/lib/src/state/query/activities_query.dart (5)

69-75: Field rename from type to activityType is appropriate.

The rename to activityType improves clarity by distinguishing it from generic type properties. The remote key activity_type follows snake_case convention for API fields.


102-108: New feed filter field follows existing patterns.

The field correctly maps to data.feeds for local filtering and uses the feed remote key for API queries.


118-124: New interestTags field mirrors filterTags pattern.

Consistent implementation for interest-based activity filtering.


85-92: Documentation updates reflect expanded operator support.

The updated operator lists for expiresAt, filterTags, searchData, and text fields align with the enhanced filtering capabilities.

Also applies to: 110-116, 134-148


158-178: Cannot verify location filter implementation—file not found in repository.

The specified file packages/stream_feeds/lib/src/state/query/activities_query.dart does not exist in the accessible repository structure. Without access to:

  • The ActivitiesFilterField class implementation
  • The Filter class and its .equal() method behavior
  • The CircularRegion and BoundingBox type definitions
  • How the location accessor function is used in filtering logic

I cannot confirm whether Filter.equal correctly handles proximity/bounds checking between LocationCoordinate and the expected region types. This concern requires manual code review against the actual implementation.

packages/stream_feeds/pubspec.yaml (1)

33-37: Replace git-based dependency with semantic versioning before release.

Using a git branch reference (feat/location-filtering) for coordinating cross-repository feature development is acceptable temporarily, but this must be replaced with a published version (e.g., ^0.4.0) before merging to main or releasing to pub.dev to comply with semantic versioning requirements for SDK releases.

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.

2 participants