Skip to content

Some improvements to CSV import of manual symbols#598

Open
leppa wants to merge 2 commits intoafadil:mainfrom
leppa:fix-custom-symbol-imports
Open

Some improvements to CSV import of manual symbols#598
leppa wants to merge 2 commits intoafadil:mainfrom
leppa:fix-custom-symbol-imports

Conversation

@leppa
Copy link

@leppa leppa commented Feb 18, 2026

Description

This change includes several improvements:

Include existing manual symbols in activity import validation

Existing manual symbols were not included in the check_activities_import reply and were incorrectly marked as invalid with "Could not find SYMBOL in market data" error, forcing users to manually remap already-existing symbols.

Reorder validation logic to look up existing assets before validating market data requirements. When an existing asset is found, its quote_mode is populated, allowing manual symbols to bypass market data
validation.

Preserve user-provided symbol name on import

When user created a manual symbol during import the user provided name was "lost" and symbol ticker was set as the name instead.

Update both UI and server code to include symbolName into the request and pull symbolName from the response. Don't overwrite symbol name with normalized_symbol in the check_activities_import if it was already set.

Add "Mark Custom" and "Mark All Custom" buttons in the CSV import

Alow to quickly mark unresolved symbols as manual during CSV import, instead of requiring manual search and mapping one-by-one.

Two buttons were added:

  • "Mark Custom" to the right of each unresolved symbol - will mark only corresponding symbol as manual
  • "Mark All Custom" at the top right - will mark all symbols as manual

Manual symbols will be created as an equity with the symbol as both its ticker and its name.

image

Set quoteMode in the symbolMappingMeta

quoteMode was defined in the importMappingSchema but was never set.

Add type safety for quoteMode

Change quoteMode in DraftActivity, importMappingSchema, and importActivitySchema from generic string to quoteModeSchema ("MANUAL" | "MARKET"), ensuring that it can only take valid values.

Checklist

By submitting this PR, I agree to the
CLA.

@leppa leppa force-pushed the fix-custom-symbol-imports branch from 46ca3df to 5251853 Compare February 18, 2026 17:19
@leppa leppa changed the title Fix #597: Fix CSV import with manual symbols and improve the unrecognized symbol mapping UX Some improvements to CSV import of manual symbols Feb 18, 2026
@leppa
Copy link
Author

leppa commented Feb 18, 2026

@afadil, thanks for fixing #597 so quickly. I rebased this PR on top of your latest changes. It fixes few remaining issues that weren't addressed in your fix and also adds buttons that allow to quickly mark unrecognized symbols as custom.

1. Include existing manual symbols in activity import validation

Existing manual symbols were not included in the
`check_activities_import` reply and were incorrectly marked as invalid
with "Could not find SYMBOL in market data" error, forcing users to
manually remap already-existing symbols.

Reorder validation logic to look up existing assets before validating
market data requirements. When an existing asset is found, its
`quote_mode` is populated, allowing manual symbols to bypass market data
validation.

2. Preserve user-provided symbol name on import

When user created a manual symbol during import the user provided name
was "lost" and symbol ticker was set as the name instead.

Update both UI and server code to include `symbolName` into the request
and pull `symbolName` from the response. Don't overwrite symbol name
with `normalized_symbol` in the `check_activities_import` if it was
already set.

3. Set `quoteMode` in the `symbolMappingMeta`

`quoteMode` was defined in the `importMappingSchema` but was never set.

4. Add type safety for `quoteMode`

Change `quoteMode` in `DraftActivity`, `importMappingSchema`, and
`importActivitySchema` from generic string to `quoteModeSchema`
(`"MANUAL" | "MARKET"`), ensuring that it can only take valid values.
Alow to quickly mark unresolved symbols as manual during CSV import,
instead of requiring manual search and mapping one-by-one.

Two buttons were added:
- "Mark Custom" to the right of each unresolved symbol - will mark
  only corresponding symbol as manual
- "Mark All Custom" at the top right - will mark all symbols as manual

Manual symbols will be created as an equity with the symbol as both its
ticker and its name.
@leppa leppa force-pushed the fix-custom-symbol-imports branch from 5251853 to 294a951 Compare February 25, 2026 13:42
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.

1 participant