Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: Custom patterns for parsing logged metadata in ASC files #767

Merged
merged 16 commits into from
Sep 29, 2024

Conversation

saeub
Copy link
Collaborator

@saeub saeub commented Jul 23, 2024

Description

Fixes #758

Implemented changes

  • BREAKING: Return metadata dictionary from from_asc()
  • Add argument matadata_patterns to from_asc() and parse_eyelink()
  • Default value of None for metadata keys specified in metadata_patterns that are not present in the ASC file

TODO

  • Make pylint happy
  • Fix test coverage

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change is or requires a documentation update

How Has This Been Tested?

  • Metadata returned
  • Test default None values

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules
  • I have checked my code and corrected any misspellings

@github-actions github-actions bot added breaking enhancement New feature or request labels Jul 23, 2024
Copy link

codecov bot commented Jul 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (84f1416) to head (b2ce27f).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #767   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           71        71           
  Lines         3230      3225    -5     
  Branches       925       925           
=========================================
- Hits          3230      3225    -5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@saeub
Copy link
Collaborator Author

saeub commented Jul 23, 2024

NOTE: #510 says:

Don't care about integrating this into the 'gaze.from_asc()` function yet.

So not sure if this breaking interface change in from_asc() is acceptable, but I think it would be useful...

@saeub saeub force-pushed the feat/asc-metadata branch from 536158e to 5890edf Compare August 8, 2024 19:04
@saeub saeub marked this pull request as ready for review August 8, 2024 19:23
@SiQube
Copy link
Member

SiQube commented Aug 19, 2024

I think this is a great addition and the benefits outweigh the breaking change.

Copy link
Member

@SiQube SiQube left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks very good -- some minor comments

@SiQube
Copy link
Member

SiQube commented Aug 21, 2024

@prassepaul @dkrako I'd liked to have a second pair of eyes on this breaking change

@SiQube SiQube enabled auto-merge (squash) September 2, 2024 06:47
Copy link
Member

@SiQube SiQube left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SiQube SiQube disabled auto-merge September 27, 2024 06:56
@saeub saeub merged commit 7093e95 into aeye-lab:main Sep 29, 2024
21 checks passed
@saeub saeub deleted the feat/asc-metadata branch September 29, 2024 19:37
SiQube added a commit that referenced this pull request Sep 30, 2024
* Return metadata from from_asc()

* Parse metadata from ASC files based on custom patterns

* Refactor

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Refactor

* Fix test coverage

* Fix docstrings

* Fix docstring

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: David R. Reich <[email protected]>
@saeub saeub mentioned this pull request Mar 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow custom patterns for extracting logged metadata from ASC files
2 participants