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

Improve error handling by validating inputs and outputs of functions #93

Open
tkilias opened this issue Aug 24, 2023 · 0 comments
Open
Labels
refactoring Code improvement without behavior change

Comments

@tkilias
Copy link
Collaborator

tkilias commented Aug 24, 2023

Background

  • We got at some point the following error message

    [Code: 0, SQL State: 43000] "attempt to index a nil value (field 'integer index')" caught in script "IDA"."SME_DEPLOY_SAGEMAKER_AUTOPILOT_ENDPOINT" at line 402 (Session: 1775016774761775104)

  • This error is caused by something which is nil, but shouldn't be nil, we should check this before we're accessing and throw proper error messages.

  • It is likely, that the following line caused the error

    • and that the metadata_row nil was, because the db_metadata_reader didn't find the metadata row for this particular job.
    • To get better error message, we should have checked in the db_metadata_reader, if the row was nil or not
@tkilias tkilias added the refactoring Code improvement without behavior change label Aug 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactoring Code improvement without behavior change
Projects
None yet
Development

No branches or pull requests

1 participant