Skip to content

Fix bug in batteryBDC#1495

Merged
stark4n6 merged 2 commits into
abrignoni:mainfrom
JamesHabben:bug/battery-module
May 27, 2026
Merged

Fix bug in batteryBDC#1495
stark4n6 merged 2 commits into
abrignoni:mainfrom
JamesHabben:bug/battery-module

Conversation

@JamesHabben
Copy link
Copy Markdown
Collaborator

  • the watts column was causing an index error on csv files where there were not enough columns
  • check for 9 columns in source file; write error and skip file if less
  • safely get watts value or '' if column isn't there
  • lint error cleanup

- the watts column was causing an index error on csv files where there were not enough columns
- check for 9 columns in source file; write error and skip file if less
- safely get watts value or '' if column isn't there
- lint error cleanup
- update last_update_date
@JamesHabben JamesHabben added the Artifact Module Update related to an artifact module label May 27, 2026
@stark4n6 stark4n6 merged commit b1ffa39 into abrignoni:main May 27, 2026
1 check passed
@JamesHabben
Copy link
Copy Markdown
Collaborator Author

here is the error i got when running against josh's ios15 image. for reference

[21/439] batteryBDC [batteryBDC] artifact started
Reading batteryBDC artifact had errors!
Error was list index out of range
Exception Traceback: Traceback (most recent call last):
  File "ileapp.py", line 506, in crunch_artifacts
  File "scripts\ilapfuncs.py", line 477, in wrapper
    data_headers, data_list, source_path = func(Context)
                                           ^^^^^^^^^^^^^
  File "C:\Users\James Habben\AppData\Local\Temp\_MEI247162\scripts\artifacts\batteryBDC.py", line 47, in batteryBDC
    watts = item[18]
            ~~~~^^^^
IndexError: list index out of range

@JamesHabben JamesHabben deleted the bug/battery-module branch May 27, 2026 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Artifact Module Update related to an artifact module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants