Skip to content

Releases: muktihari/fit

v0.23.4

19 Sep 18:23
5488953
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.23.3...v0.23.4

v0.23.3

19 Sep 17:45
7eb269b
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.23.2...v0.23.3

v0.23.2

19 Sep 03:19
2b79f14
Compare
Choose a tag to compare

What's Changed

Feat: add ability for Fitconv CLI to convert unknown data from CSV to FIT as an alternative approach to help solving this issue https://forums.garmin.com/developer/fit-sdk/f/discussion/385131/unable-to-convert-csv-to-fit-file

  • perf: early validate all messages before encoding by @muktihari in #454
  • cli-fix: fitconv remove quote char and unprintable chars in csv by @muktihari in #455
  • cli-feat: fitconv ability to convert unknown data from CSV to FIT by @muktihari in #456
  • feat: filedef listener add ability to reset by @muktihari in #457
  • chore: encoder clean up unused variable by @muktihari in #458

Full Changelog: v0.23.1...v0.23.2

v0.23.1

17 Sep 12:16
e3d3e16
Compare
Choose a tag to compare

What's Changed

Changes related to FIT Activity CLI only

  • fix: typo on fitactivity conceal docs by @muktihari in #450
  • cli: fitactivity feat support combine multi-sessions by @muktihari in #451
  • chore: fix typo on fitactivity conceal docs by @muktihari in #452
  • fix: fitactivity combine should accumulate all the accumulable values by @muktihari in #453

Full Changelog: v0.23.0...v0.23.1

v0.23.0

17 Sep 03:30
6d72369
Compare
Choose a tag to compare

Breaking Changes

  • primitive bool value is now replaced with typedef.Bool to allow invalid/unset value, affected package: proto, profile/mesgdef
  • Encoder option: WithNormalHeader and WithCompressedTimestampHeader is removed, replaced by WithHeaderOption.
  • Decoder will no longer returns ErrFieldValueTypeMismatch when value of field num 253 is not uint32 and ErrFieldValueTypeMismatch is now removed. ErrInvalidBaseType is now private, ErrNotAFitFile is renamed to ErrNotFITFile, ErrDataSizeZero is deleted and an ErrNotFITFile will be returned instead when FileHeader's DataSize is zero.
  • proto.Validator's SetProtocolVersion() and ProtocolVersion() are removed, export the protocol version field directly.

New Features

  • Now we can encode compressed timestamp header with multiple local message type 0-3.

Fixes

  • Bug related to Decoder and Encoder on handling compressed timestamp header is now fixed.
  • PeekFileId now only check the first decoded message, if it's not an file_id, it returns error.
  • UTF-8 string handling: now we discard utf8.RuneError and it stops when the bytes are successfully decoded or it reaches a null-terminated string '0'.
  • Encoder's validator now prints the value when the size exceed max allowed for easier debugging.

CLIs

  • fitactivity is updated to support compressed timestamp header with multiple local message type and more improvement.

What's Changed

Full Changelog: v0.22.0...v0.23.0

v0.22.0

12 Sep 10:12
7d1dc9d
Compare
Choose a tag to compare

What's Changed (with Breaking Changes)

1. Behavior

The decoder methods Decode() and DecodeWithContext() no longer need to be wrapped inside a Next() loop. These methods can be directly invoked multiple times to decode chained FIT file. Method Next() is now just a convenience tool to do iteration.

2. Modified

Functions

  • proto.CreateMessageDefinition -> proto.NewMessageDefinition
  • proto.CreateMessageDefinitionTo -> (*Encoder) newMessageDefinition

Methods

  • (FileHeader) MarshalAppend -> (*FileHeader) MarshalAppend
  • (MessageDefinition) MarshalAppend -> (*MessageDefinition) MarshalAppend
  • (Message) MarshalAppend(n []byte) -> (*Message) MarshalAppend(b []byte, arch byte)

Structs or Fields

  • proto: FileHeader.ProtocolVersion type is changed from byte to proto.Version for consistency.
  • decoder: AccumulatedValue is now private with the new name value
  • decoder: Accumulator's Field: AccumulatedValues is now private with new name values

Errors

  • encoder: ErrNotAFitFile -> ErrNotFITFile

3. Removed

Package

  • internal/kit

Functions

  • factory.CreateMesgOnly

Methods

  • (*Factory) CreateMesgOnly
  • (proto.FIT) WithMessages
  • (proto.Message) WithFields
  • (proto.Message) WithDeveloperFields
  • (proto.Message) WithFieldValues
  • (proto.Message) Clone
  • (proto.Field) Clone
  • (proto.SubField) Clone
  • (proto.DeveloperField) Clone
  • (FileHeader) MarshalBinary
  • (MessageDefinition) MarshalBinary
  • (Message) MarshalBinary

Constants

  • proto: MaxBytesPerMessage and MaxBytesPerMessageDefinition are removed

4. Performance Improvements

  • Encoder now uses less memory

5. Bug Fixes

  • Encoder: fix on validating dynamic protocol version.
  • CLI: fitactivity's opener concurrency is now limited to the lesser value between the number of files and the number of CPU.
  • CLI: fitactivity's opener now updates the corresponding Laps GPS positions instead of removing them.
  • CLI: fitactivity now listens to interrupt signal and gracefully shutdown.

6. Additional Features

  • Fieldef: Activity File now has new messages: GpsMetadata, TimeInZone, Split and Split Summary.

References

Full Changelog: v0.21.5...v0.22.0

v0.21.5

09 Sep 04:39
20cc308
Compare
Choose a tag to compare

What's Changed

  • chore: pin misspell hash in ci workflow for security reason by @muktihari in #406
  • chore: update dependabot interval from daily to weekly by @muktihari in #407
  • fix: decoder should expand component only from a valid value by @muktihari in #408
  • chore: clean up decoder code by @muktihari in #409

Full Changelog: v0.21.4...v0.21.5

v0.21.4

08 Sep 12:16
87c075a
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.21.3...v0.21.4

v0.21.3

08 Sep 09:42
4516ba4
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.21.2...v0.21.3

v0.21.2

30 Aug 07:35
36e3cc9
Compare
Choose a tag to compare

What's Changed

  • chore: update release workflow by @muktihari in #376
  • fix: proto.Value's Valid method when handling slice of uint_z by @muktihari in #377
  • cli: fitactivity remove aggregate limitation by @muktihari in #378
  • cli: fitactivity auto determine protocol version by @muktihari in #380
  • chore(deps): bump github/codeql-action from 3.26.5 to 3.26.6 by @dependabot in #379

Full Changelog: v0.21.1...v0.21.2