Skip to content

Commit

Permalink
Fixes integer columns for read_fit()
Browse files Browse the repository at this point in the history
  • Loading branch information
AartGoossens committed Apr 20, 2021
1 parent 9d8432d commit 8668735
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions docs/docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ Types of changes:
- `Security` in case of vulnerabilities.

## [Unreleased] - {ISO8601 date}
### Fixed
- `sweat.read_fit()` now supports integer column names.

## [0.20.2] - 2021-04-16
### Fixed
Expand Down
2 changes: 1 addition & 1 deletion sweat/io/fit.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

def process_location_columns(df, columns=None):
if columns is None:
columns = [c for c in df.columns if c.endswith("_lat") or c.endswith("_long")]
columns = [c for c in df.columns if isinstance(c, str) and (c.endswith("_lat") or c.endswith("_long"))]
else:
columns = [c for c in columns if c in df.columns]

Expand Down

0 comments on commit 8668735

Please sign in to comment.