Comments (5)
(Sorry, I closed this by clicking the wrong button, reopening it)
Can you share that activity, so I can have a look? Either attach it to this issue, or send it to me directly at [email protected]. I have a large collection of "odd" FIT files for testing, but it seems that there is always a new one, which breaks...
Also, does this activity contain data collected using a "Connect IQ" application? (support for these is new).
from activitylog2.
Yes the activity contains data from a connect iq data field...it is a multi data field in one page using stock data field showed...and the Garmin connect iq power field.
All my activities since years have this kind of data because I use this all in one data field .
In fact I tried to import also other activities and none worked..
( Sorry I closed also by mistake clicking in phone...reopened)
from activitylog2.
The patch below will avoid inserting the multi-value field in the database, and the activity will import correctly (without that field being added). You will still be able to see the running power data.
I will push a fix later today (I want to do some more testing), but meanwhile, you can apply the patch below, by saving it to a file (make sure you use UNIX line endings) and using "git apply". A;ternatively, you can open the "rkt/database.rkt" file in a text editor, find the xdata-store-values
and xdata-store-summary-values
functions and replace the "(when val" lines with "(when (and val (or (number? val) (string? val) (bytes? val)))".
Also, how does Garmin Connect display this field in its GUI? I am not sure there is enough information in the FIT file itself to display it properly...
rkt/database.rkt | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/rkt/database.rkt b/rkt/database.rkt
index 154ceea..157bb46 100644
--- a/rkt/database.rkt
+++ b/rkt/database.rkt
@@ -364,7 +364,7 @@
(define (xdata-store-values db record id xdata-fields)
(for (([field-key field-id] (in-hash xdata-fields)))
(define val (dict-ref record field-key #f))
- (when val
+ (when (and val (or (number? val) (string? val) (bytes? val)))
(query-exec db sql-insert-xdata-value id field-id val))))
(define sql-insert-xdata-summary-value
@@ -379,7 +379,7 @@
(define (xdata-store-summary-values db record id xdata-fields)
(for (([field-key field-id] (in-hash xdata-fields)))
(define val (dict-ref record field-key #f))
- (when val
+ (when (and val (or (number? val) (string? val) (bytes? val)))
(query-exec db sql-insert-xdata-summary-value id field-id val))))
from activitylog2.
Hi @airon111 , I updated the master branch with a fix for this issue. Can you please fetch the latest sources, rebuild the application and try to import again? Thanks, Alex.
from activitylog2.
Pulled latest sources and tried it, working perfectly...
Thank you very much
from activitylog2.
Related Issues (20)
- User defined plot scales HOT 1
- error on activity deletion HOT 9
- In Linux, when creating a new database, an incorrect dialog (open) appears instead of correct one (save). HOT 3
- division by zero HOT 1
- Lap swimming: TRACKPOINTS are linked to wrong LENGTHS HOT 19
- bug: "bsearch: unbound identifier" HOT 2
- Contract violation in edit-lab-swim.rkt HOT 3
- Heart rate data is lost after joining or splitting a swim lap. HOT 3
- HR data is missing in Lap Summary HOT 4
- Linux: ActivityLog2 freezes HOT 6
- Error in Edit Swim lap HOT 2
- Workout files don't appear anymore on the watch after copying to Newfiles HOT 2
- Humindex HOT 2
- Make a linux build HOT 3
- crashing in charts for open water swimming activity HOT 7
- Add Garmin devices HOT 1
- Wishlist: Open water swimming data series HOT 3
- gdi32.dll on win 7 HOT 2
- CombinedPedalSmoothness XDATA Howto HOT 7
- Failed to import: #(struct:exn:fail fit-file: bad file CRC #<continuation-mark-set>) HOT 3
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 activitylog2.