Fix bug in batteryBDC#1495
Merged
Merged
Conversation
Collaborator
JamesHabben
commented
May 27, 2026
- 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
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 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.