Skip to content

Commit efc41fa

Browse files
committed
python: add pkg_resources in the namespace __init__.py
For the __init__.py in the main package, this change follows the advisory at https://packaging.python.org/guides/packaging-namespace-packages/#pkg-resources-style-namespace-packages to add the the line __import__('pkg_resources').declare_namespace(__name__) to ONLY the main package's directory i.e. in the same directory level as setup.py Fixes #4
1 parent 2abfa79 commit efc41fa

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

python/sqlcommenter-python/google/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,5 @@
1313
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
16+
17+
__import__('pkg_resources').declare_namespace(__name__)

0 commit comments

Comments
 (0)