Commit Graph

1963 Commits

Author SHA1 Message Date
AdamWHY2K
3f5fff27ea feat: process pending transactions from lunchflow (#731)
* feat(config): add Lunchflow runtime configuration flags

* feat(api): add include_pending parameter to Lunchflow API

* feat(processor): add pending metadata support to Lunchflow processor

* feat(processor): generate temporary IDs for pending transactions

* feat(importer): integrate pending transaction support in sync

* fix(importer): improve deduplication for transactions without IDs

* feat(model): add Lunchflow pending support to Transaction scopes

* test: add Lunchflow processor pending metadata tests

* docs: update AGENTS.md for Lunchflow pending support

* chore: remove unused variable

* fix: simplify key check

* fix: dotenv-linter key order

* fix: avoid collapsing distinct pending transactions

* fix: prevent unbounded raw payload growth for blank IDs
2026-01-23 00:53:24 +01:00
LPW
2c827fbc88 Fix locale mismatch and add option activity type mappings (#743)
* Expand option activity type support in `activities_processor` and update i18n hint for SnapTrade account loading.

* Add `SELL_SIDE_TYPES` constant to streamline sell-side activity handling in `activities_processor`.

---------

Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
2026-01-23 00:28:17 +01:00
LPW
6279bfc497 Add comprehensive tests for SnaptradeAccount processors and data helpers. (#742)
Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
2026-01-23 00:27:00 +01:00
Alessio Cappa
262de20602 fix: Use right arrow position when collapsing sections (#746) 2026-01-23 00:24:29 +01:00
LPW
7bd1058b6e Exclude tax-advantaged account activity from budget & add provider data quality warnings (#724)
* Add tax-advantaged account exclusions and investment data warnings

* Address PR review feedback: translations + cache key stability

- Add proper translations for provider warnings in 8 locales (de, es, nb, pt-BR, ro, tr, zh-CN, zh-TW)
- Fix cache key stability: use SHA256.hexdigest instead of Array#hash (randomized per process)

---------

Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
2026-01-22 22:23:09 +01:00
LPW
9858b36dc7 Centralize sdk_object_to_hash logic in DataHelpers module and update all references for improved reusability and consistency. Add error handling for partial and failed SnapTrade account linking. (#741)
Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
2026-01-22 22:19:44 +01:00
Juan José Mata
bf76d6b88d Let /settings/providers work in demo site 2026-01-22 20:01:18 +00:00
Juan José Mata
8b38d97b8e Add "beta" tag to Mercury for now 2026-01-22 20:00:18 +00:00
LPW
a83f70425f Add SnapTrade brokerage integration with full trade history support (#737)
* Introduce SnapTrade integration with models, migrations, views, and activity processing logic.

* Refactor SnapTrade activities processing: improve activity fetching flow, handle pending states, and update UI elements for enhanced user feedback.

* Update Brakeman ignore file to include intentional redirect for SnapTrade OAuth portal.

* Refactor SnapTrade models, views, and processing logic: add currency extraction helper, improve pending state handling, optimize migration checks, and enhance user feedback in UI.

* Remove encryption for SnapTrade `snaptrade_user_id`, as it is an identifier, not a secret.

* Introduce `SnaptradeConnectionCleanupJob` to asynchronously handle SnapTrade connection cleanup and improve i18n for SnapTrade item status messages.

* Update SnapTrade encryption: make `snaptrade_user_secret` non-deterministic to enhance security.

---------

Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
Co-authored-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-22 20:52:49 +01:00
soky srm
179552657c Mercury integration (#723)
* Initial mercury impl

* FIX both mercury and generator class

* Finish mercury integration and provider generator

* Fix schema

* Fix linter and tags

* Update routes.rb

* Avoid schema drift

---------

Signed-off-by: soky srm <sokysrm@gmail.com>
Co-authored-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-22 20:37:07 +01:00
Juan José Mata
7842b4a044 Fixes to contributions payment copy 2026-01-22 19:22:55 +00:00
Juan José Mata
667300398f Add Skylight performance badge to README
Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-22 15:53:07 +01:00
Copilot
558bf7eeda feat: Support optional balance date column in account CSV imports (#736)
* Initial plan

* Add ability to specify balance date in AccountImport CSV

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Restore original Ruby version

* Fix linting issues - remove trailing whitespace

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Add error handling for date parsing in AccountImport

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Revert unintended Gemfile.lock changes

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>
2026-01-22 15:25:43 +01:00
Juan José Mata
051197137c Fix Polish translation template error (and increase testing/fix other locales as well) (#734)
* Add Polish locale support for money formatting

The Money::Formatting module handles locale-specific currency formatting
for French, German, Spanish, Italian, and Portuguese (Brazil), but was
missing support for Polish locale. This caused formatting issues when
users with Polish locale viewed account valuations.

- Add Polish locale handling to locale_options method
- Polish formatting uses: space as thousands delimiter, comma as
  decimal separator, symbol after number ("%n %u" format)
- Add test coverage for Polish locale formatting

* Add locale support for all supported locales in Money::Formatting

Extend the Money::Formatting module to handle all locales from
SUPPORTED_LOCALES to prevent template errors when users select
different languages.

Added locale-specific formatting for:
- Turkish (tr): dot delimiter, comma separator, symbol after number
- Norwegian Bokmål (nb): space delimiter, comma separator, symbol after
- Catalan (ca): dot delimiter, comma separator, symbol after number
- Romanian (ro): dot delimiter, comma separator, symbol after number
- Dutch (nl): dot delimiter, comma separator, symbol before number

Also improved Dutch handling to work with all currencies (not just EUR).

Added comprehensive tests for:
- All newly supported locales
- Chinese (zh-CN, zh-TW) which use default English-style formatting
- A test that verifies all SUPPORTED_LOCALES can format without errors

* Fix broken money formatting tests

- Fix Chinese Traditional locale test: TWD currency uses "TW$" symbol
  (prefixed with first 2 chars of ISO code to distinguish from USD)
- Fix all supported locales test: replace assert_nothing_raised (which
  doesn't accept message argument in Minitest) with explicit assertions

* Refactor Money::Formatting to consolidate locale patterns

Group locales by their formatting patterns into constants to reduce
repetition and make it easier to add new locales:

- EUROPEAN_SYMBOL_AFTER: de, es, it, tr, ca, ro
  (dot delimiter, comma separator, symbol after)
- SPACE_DELIMITER_SYMBOL_AFTER: pl, nb
  (space delimiter, comma separator, symbol after)
- EUROPEAN_SYMBOL_BEFORE: nl, pt-BR
  (dot delimiter, comma separator, symbol before)

French locale remains separate due to its unique non-breaking space usage.

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-22 14:27:12 +01:00
Juan José Mata
9855c67bc4 Coinbase CDP link for API 2026-01-22 11:26:01 +00:00
Juan José Mata
da269cdbc9 Update README with clarification of when demo data is available
Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-22 08:19:39 +01:00
Juan José Mata
16e4c4ede4 Small QOL fix in shell samples
Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-22 08:14:43 +01:00
github-actions[bot]
6c2120e4ce Bump version to next alpha after v0.6.7-alpha.14 release 2026-01-21 22:53:06 +00:00
LPW
dd991fa339 Add Coinbase exchange integration with CDP API support (#704)
* **Add Coinbase integration with item and account management**
- Creates migrations for `coinbase_items` and `coinbase_accounts`.
- Adds models, controllers, views, and background tasks to support account linking, syncing, and transaction handling.
- Implements Coinbase API client and adapter for seamless integration.
- Supports ActiveRecord encryption for secure credential storage.
- Adds UI components for provider setup, account management, and synchronization.

* Localize Coinbase-related UI strings, refine account linking for security, and add timeouts to Coinbase API requests.

* Localize Coinbase account handling to support native currencies (USD, EUR, GBP, etc.) across balances, trades, holdings, and transactions.

* Improve Coinbase processing with timezone-safe parsing, native currency support, and immediate holdings updates.

* Improve trend percentage formatting and enhance race condition handling for Coinbase account linking.

* Fix log message wording for orphan cleanup

* Ensure `selected_accounts` parameter is sanitized by rejecting blank entries.

* Add tests for Coinbase integration: account, item, and controller coverage

- Adds unit tests for `CoinbaseAccount` and `CoinbaseItem` models.
- Adds integration tests for `CoinbaseItemsController`.
- Introduces Stimulus `select-all` controller for UI checkbox handling.
- Localizes UI strings and logging for Coinbase integration.

* Update test fixtures to use consistent placeholder API keys and secrets

* Refine `coinbase_item` tests to ensure deterministic ordering and improve scope assertions.

* Integrate `SyncStats::Collector` into Coinbase syncer to streamline statistics collection and enhance consistency.

* Localize Coinbase sync status messages and improve sync summary test coverage.

* Update `CoinbaseItem` encryption: use deterministic encryption for `api_key` and standard for `api_secret`.

* fix schema drift

* Beta labels to lower expectations

---------

Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
Co-authored-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-21 22:56:39 +01:00
Copilot
0357cd7d44 Allow subcategories to inherit parent budget without individual limits (#579)
* Initial plan

* Implement subcategory budget inheritance feature

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Fix available_to_spend calculation for parent categories with mixed subcategories

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Optimize budget category calculations to avoid redundant filtering

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Add documentation for subcategory budget inheritance feature

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Add edge case tests for budget inheritance feature

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Fix linting issues - remove trailing whitespace

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Replace hardcoded '(shared)' label with i18n translation

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Fix test failures due to duplicate category names

Use unique names with timestamps to avoid validation errors when creating test categories. The Category model has a uniqueness validation on name scoped to family_id, and the test fixtures already contain categories like "Restaurants" which were causing conflicts.

Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>

* Remove LLM `.md` spec file

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jjmata <187772+jjmata@users.noreply.github.com>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Juan José Mata <jjmata@jjmata.com>
2026-01-21 22:10:15 +01:00
Juan José Mata
8eb9d9cf28 Add GitHub Actions workflow to update documentation
Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-21 21:56:46 +01:00
Daniel Anomfueme
278b2d0008 Add backup service to Docker Compose configuration (#637)
* Add backup service to Docker Compose configuration

* Add backup_data volume to Docker Compose examples

* Add backup profiles and update backup volume path in Docker Compose examples

* Linter likes those spaces in brackets

* Switch to `stable` tags for sure

---------

Co-authored-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-21 21:12:33 +01:00
Juan José Mata
4e425ce4e5 Add option for FOSS contribution payments (#730)
* First commit

* Use subscription flow for monetary contributions

* Removed only part of the SPAN

* Localize Stripe payments message

* More localization of contribution strings

* Missed two billing to payment changes

* Fix tests

* Localization of "Open Demo" strings

* Fix grammar error

* Update for consistency

* Localize CTA

* More localilzation strings
2026-01-21 20:45:04 +01:00
Juan José Mata
8e36c8e736 Rename billing to payment throughout the codebase (#726)
* Rename billing to payment throughout the codebase

This change updates terminology from "billing" to "payment" to better
reflect that these are contributions/payments rather than bills.

Changes include:
- Rename BillingsController to PaymentsController
- Rename billing_email to payment_email
- Rename next_billing_date to next_payment_date
- Rename create_billing_portal_session_url to create_payment_portal_session_url
- Update routes from billing to payment
- Update all 12 locale files with new terminology
- Update views, helpers, and tests

* Update app/views/subscriptions/upgrade.html.erb

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Juan José Mata <jjmata@jjmata.com>

---------

Signed-off-by: Juan José Mata <jjmata@jjmata.com>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-21 19:06:00 +01:00
soky srm
abab66675c Implement a setting to retrieve high res logos (#725)
* Implement a setting to retrieve high res logos

* Update _brand_fetch_settings.html.erb

* Add fallback for stock tickers also to use Brandfetch

* Update security.rb

* Update toggle logic for high-res logos setting

Signed-off-by: Juan José Mata <jjmata@jjmata.com>

* Update security.rb

* Update security.rb

---------

Signed-off-by: Juan José Mata <jjmata@jjmata.com>
Co-authored-by: Juan José Mata <jjmata@jjmata.com>
2026-01-21 17:16:51 +01:00
soky srm
ae61df4978 FIX OpenAPI auth specs (#722)
* FIX auth specs

* FIX header params are not required with auth spec

* Add missing endpoints
2026-01-21 11:10:03 +01:00
soky srm
d8cdced662 Merge pull request #718 from luckyPipewrench/plug-black-hole
Fix "black hole" - Make investment contributions visible in cashflow with auto-categorization
2026-01-21 09:21:45 +01:00
soky srm
ae82197530 Merge pull request #719 from nuno-am/refactor-import-export-sections
refactor: Import and Export sections
2026-01-21 09:15:57 +01:00
Nuno Marques
412e21f810 fix: aria label for action buttons on Export table 2026-01-21 00:42:29 +00:00
Nuno Marques
c229c357ae fix: aria label for action buttons on Import table 2026-01-21 00:31:51 +00:00
Nuno Marques
7d19024e24 fix: alignment for failed stated 2026-01-21 00:09:54 +00:00
Nuno Marques
03e59c8b3c fix: translations suggestions 2026-01-20 23:59:39 +00:00
Nuno Marques
0a5e815732 fix: export counter 2026-01-20 23:49:48 +00:00
Nuno Marques
80290fc0c7 fix: delete unused partial file to render export entries 2026-01-20 23:49:09 +00:00
Nuno Marques
571d09a869 fix: date formats 2026-01-20 23:48:22 +00:00
Nuno Marques
7f69063a95 refactor: Imports section and updated translation files 2026-01-20 23:21:42 +00:00
Nuno Marques
6ba0189e07 refactor: Exports section and updated translation files 2026-01-20 23:21:27 +00:00
Nuno Marques
f8860c091f feat: created Badge component 2026-01-20 23:20:10 +00:00
Nuno Marques
388e1759a9 fix: pagination background 2026-01-20 23:19:34 +00:00
luckyPipewrench
a75cb816c7 Centralize investment_contributions_category logic and update references for streamlined handling. 2026-01-20 17:51:36 -05:00
luckyPipewrench
480e53710a Centralize investment_contributions category handling using i18n key and streamline related references. 2026-01-20 17:36:56 -05:00
luckyPipewrench
4727a391a7 Refactor Investment Contributions category handling to use a centralized constant and streamline related logic. 2026-01-20 17:18:49 -05:00
luckyPipewrench
196d12466f Handle investment_contribution classification and update related logic. 2026-01-20 16:50:45 -05:00
Alessio Cappa
95a2d115a0 fix: Adjust chat input position (#717) 2026-01-20 22:39:16 +01:00
Juan José Mata
45c4bc595b Enable sending logs to Sentry
Enabled logging to Sentry and patched Ruby logger.

Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-20 17:19:17 +01:00
Dario G. Mori
7d2cecdd15 fix: installing cloudnative-pg as namespace bound and bumped cnpg operator to 0.27 (#714)
* feat: updated cloudnative-pg to 0.27

* fix: default config is clusterWide false
2026-01-20 13:08:04 +01:00
LPW
da9148c8be Move money market tickers and patterns to configuration (#712)
Co-authored-by: luckyPipewrench <luckypipewrench@proton.me>
2026-01-20 07:44:12 +01:00
github-actions[bot]
650f02ee2d Bump version to next alpha after v0.6.7-alpha.13 release 2026-01-19 23:21:58 +00:00
Julien Orain
777fbdc4ca feat(settings): add pagination to imports and exports pages (#598)
* feat(settings): split imports and exports

* feat(security): sanitize pagination params to prevent abuse

* fix(settings): fix syntax in settings nav

* feat(settings): internationalize family_exports and imports UI strings

* fix(settings): fix coderabbit review

* fix(settings): fix coderabbit review

* fix(settings): fix coderabbit review

* Change default per_page value from 20 to 10

Signed-off-by: Juan José Mata <jjmata@jjmata.com>

* Add `/family_export` to navigation

* Consistency with old defaults

* Align `safe_per_page` even if not DRY

---------

Signed-off-by: Julien Orain <julien.orain@gmail.com>
Signed-off-by: Juan José Mata <jjmata@jjmata.com>
Signed-off-by: Juan José Mata <juanjo.mata@gmail.com>
Co-authored-by: JulienOrain <your-github-email@example.com>
Co-authored-by: Juan José Mata <jjmata@jjmata.com>
Co-authored-by: Juan José Mata <juanjo.mata@gmail.com>
2026-01-20 00:11:22 +01:00
David Gil
3d91e60a8a feat: Add subcategory breakdown to Cash Flow Sankey and Reports (#639)
* feat: Add subcategory breakdown to Cash Flow and Reports

Implements Discussion #546 - adds hierarchical category/subcategory
visualization to both the Sankey chart and Reports breakdown tables.

Sankey chart changes:
- Income: subcategory → parent category → Cash Flow
- Expense: Cash Flow → parent category → subcategory
- Extracted process_category_totals helper to DRY up income/expense logic

Reports breakdown changes:
- Subcategories display nested under parent categories
- Smaller dots and indented rows for visual hierarchy
- Extracted _breakdown_table partial to eliminate duplication

* fix: Dynamic node padding for Sankey chart with many nodes

- Add dynamic nodePadding calculation to prevent padding from dominating
  chart height when there are many subcategory nodes
- Extract magic numbers to static constants for configuration
- Decompose monolithic #draw() into focused methods
- Consolidate duplicate tooltip/currency formatting code
- Modernize syntax with spread operators and optional chaining

* fix: Hide overlapping Sankey labels, show on hover

- Add label overlap detection by grouping nodes by column depth
- Hide labels that would overlap with adjacent nodes
- Show hidden labels on hover (node rectangle or connected links)
- Add hover events to node rectangles (not just text)

* fix: Use deterministic fallback colors for categories

- Replace Category::COLORS.sample with Category::UNCATEGORIZED_COLOR
  for income categories in Sankey chart (was producing different colors
  on each page load)
- Add nil color fallback in reports_controller for parent and root
  categories

Addresses CodeRabbit review feedback.

* fix: Expand CSS variable map for d3 color manipulation

Add hex mappings for commonly used CSS variables so d3 can manipulate
opacity for gradients and hover effects:
- var(--color-destructive) -> #EC2222
- var(--color-gray-400) -> #9E9E9E
- var(--color-gray-500) -> #737373

* test: Add tests for subcategory breakdown in dashboard and reports

- Test dashboard renders Sankey chart with parent/subcategory transactions
- Test reports groups transactions by parent and subcategories
- Test reports handles categories with nil colors
- Use EntriesTestHelper#create_transaction for cleaner test setup

* Fix lint: use Number.NEGATIVE_INFINITY

* Remove obsolete nil color test

Category model now validates color presence, so nil color categories
cannot exist. The fallback handling in reports_controller is still in
place but the scenario is unreachable.

* Update reports_controller.rb

* FIX trade category

---------

Co-authored-by: sokie <sokysrm@gmail.com>
2026-01-20 00:01:55 +01:00