Skip to content

Conversation

@Catrya
Copy link
Member

@Catrya Catrya commented Jan 16, 2026

  • Add infoEventKind constant for new Mostro info event kind
  • Update subscription filter to include kind 38385
  • Change info event detection from z-tag to kind-based filtering

Dispute (kind 38386) and rating (kind 38384) events were not actively used in the app, so no changes were needed for them. The app only subscribed to and processed info events (now migrated to kind 38385).

Summary by CodeRabbit

  • New Features

    • Extended open orders to recognize and process information events (kind 38385), enabling the system to handle additional event types and provide more comprehensive order information to users.
  • Bug Fixes

    • Improved event detection mechanism by using standardized event kind identifiers instead of type strings, ensuring more reliable and accurate event identification across the system.

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

  - Add infoEventKind constant for new Mostro info event kind
  - Update subscription filter to include kind 38385
  - Change info event detection from z-tag to kind-based filtering
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jan 16, 2026

Walkthrough

This change introduces support for the Mostro "info" event kind (38385) in the open orders repository. The Nostr filter is extended to request both order and info events, and event detection logic is updated to use event kind comparison instead of type checking.

Changes

Cohort / File(s) Summary
Nostr Info Event Support
lib/data/repositories/open_orders_repository.dart
Added infoEventKind constant (38385); extended Nostr filter to request both order and info events; updated event detection to compare event.kind instead of checking event.type == 'info'

Possibly related issues

Poem

🐰 A constant hops in, kind 38385,
Info events now dance, the filters come alive,
No more type checking—just kind comparison's way,
Mostro protocol blooms in a fresh, cleaner day! ✨

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'feat: update info event kind from 38383 to 38385' clearly and accurately summarizes the main change: updating the info event kind constant from the old value to the new value 38385.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


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
Member

@grunch grunch left a comment

Choose a reason for hiding this comment

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

LGTM

@grunch grunch merged commit e97744d into main Jan 16, 2026
2 checks passed
@grunch grunch deleted the support-new-mostro-even-kinds branch January 16, 2026 21:32
AndreaDiazCorreia pushed a commit that referenced this pull request Jan 20, 2026
- Add infoEventKind constant for new Mostro info event kind
  - Update subscription filter to include kind 38385
  - Change info event detection from z-tag to kind-based filtering
grunch added a commit that referenced this pull request Jan 21, 2026
…nce (phase 4) (#408)

* feat: add notification settings screen with push notification preferences

Add NotificationSettingsScreen with support for push notification configuration:
- Add route for /notification_settings in app router
- Implement UI for push notifications toggle with platform detection
- Add notification preferences for sound and vibration settings
- Display privacy information card explaining encrypted token approach
- Add Settings model fields for pushNotificationsEnabled, notificationSoundEnabled, not

* refactor: simplify Switch styling and update MockSettings with notification fields

- Replace activeTrackColor and activeThumbColor with single activeColor property in Switch widgets
- Add missing notification-related getters to MockSettings (isLoggingEnabled, pushNotificationsEnabled, notificationSoundEnabled, notificationVibrationEnabled)
- Update MockSettings copyWith method to include new notification preference parameters

* feat: integrate push notification service with session and settings management

- Add setPushServices method to SettingsNotifier to connect with PushNotificationService and FCMService
- Implement automatic token unregistration when user disables push notifications in settings
- Add setPushNotificationService method to SessionNotifier for automatic token registration
- Register push tokens automatically when new sessions are saved
- Initialize push notification integration in main.dart with settings

* Unify brand colors and consolidate color variants, phase 1 (#407)

* standardize brand green color across application

* replace hardcoded background and utility colors with AppTheme constants

* replace remaining harcoded colors

* add doc with phases

* feat: update info event kind from 38383 to 38385 (#410)

- Add infoEventKind constant for new Mostro info event kind
  - Update subscription filter to include kind 38385
  - Change info event detection from z-tag to kind-based filtering

* Bump to version 1.0.7

* Update changelog file

* docs: update FCM implementation roadmap to reflect current progress and future encryption plans

- Update phase descriptions to clarify current unencrypted implementation (Phase 3) vs future encrypted approach (Phase 5)
- Mark Phase 4 (user settings and opt-out) as complete
- Move encryption implementation details from Phase 3 to new Phase 5 (future work)
- Add privacy note explaining current plaintext token registration over HTTPS
- Update PushNotificationService to remove encryption code and use

---------

Co-authored-by: Catrya <140891948+Catrya@users.noreply.github.com>
Co-authored-by: grunch <fjcalderon@gmail.com>
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.

3 participants