Skip to content

fix(lint): fix mypy errors in api/snowplow_context

What does this merge request do and why?

This addressed mypy errors in api/snowplow_context.py.

❯ make check-mypy                                                                                                                                                                               
Installing lint dependencies...                                                                                                                                                                 
Installing dependencies from lock file                                                                                                                                                          
                                                                                                                                                                                                
No dependencies to install or update                                                                                                                                                            
                                                                                                                                                                                                
Installing the current project: ai_gateway (0.1.0)                                                                                                                                              
Running mypy check...                                                                                                                                                                           
ai_gateway/api/snowplow_context.py:54: error: Argument 1 to "len" has incompatible type "str | None"; expected "Sized"  [arg-type]                                                              
ai_gateway/api/snowplow_context.py:55: error: Argument 1 to "len" has incompatible type "str | None"; expected "Sized"  [arg-type]                                                              
Found 2 errors in 1 file (checked 283 source files)                                                                                                                                             
make: *** [Makefile:119: check-mypy] Error 1

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Merge request checklist

  • Tests added for new functionality. If not, please raise an issue to follow up.
  • Documentation added/updated, if needed.

Contributes to &34

Edited by Tan Le

Merge request reports

Loading