-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add MYPY_CONFIG_FILE_DIR to environment when config file is read (#9403)
Fixes #7968
- Loading branch information
Showing
3 changed files
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,6 +25,7 @@ | |
cmdline_files = [ | ||
'cmdline.test', | ||
'reports.test', | ||
'envvars.test', | ||
] | ||
|
||
|
||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Test cases related to environment variables | ||
[case testEnvvar_MYPY_CONFIG_FILE_DIR] | ||
# cmd: mypy --config-file=subdir/mypy.ini | ||
[file bogus.py] | ||
FOO = 'x'. # type: int | ||
[file subdir/good.py] | ||
BAR = 0. # type: int | ||
[file subdir/mypy.ini] | ||
\[mypy] | ||
files=$MYPY_CONFIG_FILE_DIR/good.py | ||
|
652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like dots after
'x'
and0
, should be spaces.652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ouch. I hate that. My browser has started doing this (apparently copying cell phones).
652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Do you want to resubmit this yourself, so you get full GitHub credit?)
652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(And sorry for the screw-up.)
652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's coming. Gotta get those internet points!
Also, can I get a "GvR broke my code!" tee shirt?
652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Didn’t see your PR yet?
652aca9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eh, I just merged. You still get credit for the first commit anyway. :-)