Comments (11)
OFX format is:
<?xml version="1.0" encoding="utf-8" ?><?OFX OFXHEADER="200" VERSION="202" SECURITY="NONE" OLDFILEUID="NONE" NEWFILEUID="NONE"?>
and the amounts look like this:
<TRNAMT>-8.95000</TRNAMT>
I tried to check the unit tests from parseOFX(), however as those are snapshot tests I am not really sure what output I should expect...
from actual.
Okay, so I found this here:
@youngcw could this be the reason that the OFX import is right now broken?
from actual.
@keriati Hmm. That change was to fix an issue someone else had where their bank only sometimes included decimal places in a csv. Im actually a little surprised that the ofx parser uses that same amount parsing.
from actual.
@youngcw maybe it is not, I am trying to make sense of packages/desktop-client/src/components/modals/ImportTransactions.jsx however the number of responsibilities and logic mixed together is crazy 🥲
from actual.
@youngcw Okay I managed to track it down, there are a lot of indirections, but it is hitting looselyParseAmount at some point. As the OFX export I have from the bank is giving me all numbers with such format: -8.95000
it is breaking the imports sadly.
Can be reproduced with this data.ofx file from the test mocks (I adjusted the amounts with 3 extra zeros):
OFXHEADER:100
DATA:OFXSGML
VERSION:102
SECURITY:NONE
ENCODING:USASCII
CHARSET:1252
COMPRESSION:NONE
OLDFILEUID:NONE
NEWFILEUID:NONE
<OFX>
<SIGNONMSGSRSV1>
<SONRS>
<STATUS>
<CODE>0
<SEVERITY>INFO
</STATUS>
<DTSERVER>20190124212851.000[0:UTC]
<LANGUAGE>ENG
<DTACCTUP>20190124212851.000[0:UTC]
<FI>
<ORG>Bank of America
<FID>5959
</FI>
<INTU.BID>6526
<INTU.USERID>jlongster03
</SONRS>
</SIGNONMSGSRSV1>
<BANKMSGSRSV1>
<STMTTRNRS>
<TRNUID>0
<STATUS>
<CODE>0
<SEVERITY>INFO
</STATUS>
<STMTRS>
<CURDEF>USD
<BANKACCTFROM>
<BANKID>012345678
<ACCTID>123456789123
<ACCTTYPE>CHECKING
</BANKACCTFROM>
<BANKTRANLIST>
<DTSTART>20190119120000
<DTEND>20190124120000
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190123120000
<TRNAMT>-30.00000
<FITID>00092990122-30.00019012312798.01
<NAME>PATIENT FIRST TOKEN 01/22 PURCHA
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190123120000
<TRNAMT>-3.77000
<FITID>00092990121-3.77019012312828.01
<NAME>STARBUCKS STORE 07604 01/21 PURC
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190123120000
<TRNAMT>-9.62
<FITID>00092990121-9.62019012312831.78
<NAME>STARBUCKS STORE 07604 01/21 PURC
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-115.99
<FITID>00090231800-115.99019012212841.40
<NAME>VERIZON DES:PAYMENTREC ID:XXXXX3
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-10.34
<FITID>00092990120-10.34019012212957.39
<NAME>URBAN FARMHOUSE NO 2 01/19 PURCH
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-22.53
<FITID>00092990120-22.53019012212967.73
<NAME>URBAN FARMHOUSE NO 2 01/19 PURCH
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-108.71
<FITID>00092990119-108.71019012212990.26
<NAME>TMOBILE*AUTO PAY 01/19 PURCHASE
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-25.00
<FITID>00092990118-25.00019012213098.97
<NAME>COUNTY WASTE 01/18 PURCHASE 804-
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-32.38
<FITID>00092990118-32.38019012213123.97
<NAME>REGENCY MART CITGO 01/18 PURCHAS
</STMTTRN>
<STMTTRN>
<TRNTYPE>DEBIT
<DTPOSTED>20190122120000
<TRNAMT>-6.07
<FITID>00092990117-6.07019012213156.35
<NAME>CHICK-FIL-A #01342 01/17 PURCHAS
</STMTTRN>
</BANKTRANLIST>
<LEDGERBAL>
<BALAMT>12798.01
<DTASOF>20190124212851
</LEDGERBAL>
</STMTRS>
</STMTTRNRS>
</BANKMSGSRSV1>
</OFX>
from actual.
Well looking at the code, I would suggest to revert this: #2399 as it is breaking now OFX import.
from actual.
Is OFX NA only? If so it could have its own parser that only allows decimal period where the loose parser is matching both decimal period and comma, that was part of the issue before
from actual.
OFX is not NA only. Here's my bank in Austria doing the same:
<STMTTRN>
<TRNTYPE>XFER</TRNTYPE>
<DTPOSTED>...</DTPOSTED>
<DTUSER>...</DTUSER>
<DTAVAIL>...</DTAVAIL>
<TRNAMT>-12.38000</TRNAMT>
<FITID>...</FITID>
<REFNUM>...</REFNUM>
<BANKACCTTO>
<BANKID>...</BANKID>
<ACCTID>...</ACCTID>
<ACCTTYPE>CHECKING</ACCTTYPE>
</BANKACCTTO>
<MEMO>...</MEMO>
</STMTTRN>
from actual.
Fix is provided in #2421
from actual.
@gschmidl Can you try out #2421 and see if it fixes your issue?
from actual.
Just tested it in 24.4.0 and it works now correctly
from actual.
Related Issues (20)
- [Bug]: Unable to use the date input on repeating schedules
- [Feature] Read out what's entered as remittanceInformationStructured when syncing your bank transactions with GoCardless so that it can be imported into the "Notes" section in Actual HOT 2
- [Bug]: Hidden categories cannot be selected in category dropdown, even when searching. HOT 1
- [Feature] Payee page: a button to view all transactions of selected payee(s) HOT 1
- [Bug]: Bank-sync operations are not e2e encrypted
- [Bug]: Menus blend in with other elements HOT 9
- [Bug]: Category dropdown selection gets messed up by hidden categories HOT 3
- [Bug]: Reverse proxy header auth still prompts for password HOT 4
- [Feature] import or sync transactions from MoneyMoney app on MacOS HOT 1
- [Bug]: Hidden Category Lost HOT 5
- [Bug]: column titles incorrect when selecting transactions and resizing window
- [Feature] Option to create a new category when adding a transaction if a category doesn't exist HOT 1
- [Feature] Allow option to exclude off budget accounts from "All Accounts" total. HOT 3
- [Feature] Add support for Trading 212 ISA Account sync HOT 1
- [Bug]: Service Worker preventing correct execution of bootstrap when using NGINX reverse proxy HOT 2
- [Bug]: SimpleFIN sync only executes if MX provides org domain HOT 1
- [Bug]: error message while syncing HOT 2
- [Bug]: ofx amount parsing does not work for foreign number formats HOT 3
- [Feature] Autofill "last used value" in Notes, Category and Amount HOT 1
- [Bug]: GoCardLess not working anymore ?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from actual.