judge-server icon indicating copy to clipboard operation
judge-server copied to clipboard

executors: fix typing on `compiler_fs`

Open Riolku opened this issue 2 years ago • 4 comments

We rely on the fs being a list in order to add it to other lists, so we should type it accordingly. MyPy complains about typing in some executors unless they are explicitly typed, see https://mypy.readthedocs.io/en/stable/common_issues.html#variance.

Riolku avatar Mar 01 '22 16:03 Riolku

Converting to draft. MyPy needs to be fixed so this PR can pass CI.

Riolku avatar Mar 02 '22 04:03 Riolku

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (1806ba4) 82.71% compared to head (12a4fa1) 82.71%.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1009   +/-   ##
=======================================
  Coverage   82.71%   82.71%           
=======================================
  Files         141      141           
  Lines        5310     5311    +1     
=======================================
+ Hits         4392     4393    +1     
  Misses        918      918           

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov-commenter avatar Mar 02 '22 04:03 codecov-commenter

Converting to draft. MyPy needs to be fixed so this PR can pass CI. See this issue.

Riolku avatar Mar 02 '22 04:03 Riolku

We don't actually rely on these being lists right now... since we don't add them to anything (which is why it typechecks of course), but it's worth adding this for potential future use.

Riolku avatar Mar 06 '22 06:03 Riolku

Should we also change https://github.com/DMOJ/judge-server/blob/master/dmoj/cptbox/isolate.py#L45 to List?

kiritofeng avatar Dec 27 '23 01:12 kiritofeng

Should we also change https://github.com/DMOJ/judge-server/blob/master/dmoj/cptbox/isolate.py#L45 to List?

Updated.

Riolku avatar Dec 27 '23 02:12 Riolku