This repository has been archived by the owner on Nov 3, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correctly detect publicity of modules inside directories (#494)
* Fix Module.is_public() when the module is not a the root * Add PR reference * Use pathlib * Use pathlib instead of os for test_module_publicity * Update release notes for #493 * Use forward slash '/' operator instead of .joinpath() * Fix pull-request number in release notes * Fix publicity of module in private package * Update test_module_publicity docstring * Add test for directory starting with double underscore * Make packages containing double-underscore public * Add test to assert __init__ module is public * Make modules in a __private_package private * Fix lint errors from lines being too long * Update publicity.rst with more information * Parameterize module publicity tests and include .py file extension in test path parameters * Make module publicity determination respect $PYTHONPATH * Fix line-length issue * Reword comment * Add tests with the same path over different sys.path cases * Add note about checking sys.path for determining publicity * Apply suggestions from code review Co-authored-by: Thibault Derousseaux <tibdex@gmail.com> Co-authored-by: Thibault Derousseaux <6574550+tibdex@users.noreply.github.com> Co-authored-by: Sambhav Kothari <sambhavs.email@gmail.com>
- Loading branch information
1 parent
b0f7d62
commit 2aa3aa7
Showing
5 changed files
with
110 additions
and
11 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -54,3 +54,6 @@ docs/snippets/error_code_table.rst | |
|
||
# PyCharm files | ||
.idea | ||
|
||
# VS Code | ||
.vscode/ |
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
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