Skip to content

Commit 8c00a98

Browse files
committed
Setup-fix: ModuleNotFoundError: No module named 'Shared.DC.ZRDB'
1 parent 6d9ee0c commit 8c00a98

File tree

5 files changed

+52
-1
lines changed

5 files changed

+52
-1
lines changed

pyproject.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,3 +73,10 @@ directory = "parts/htmlcov"
7373
[tool.setuptools.dynamic]
7474
readme = {file = ["README.rst", "CHANGES.rst"]}
7575

76+
[tool.setuptools.packages.find]
77+
where = ["src"]
78+
79+
[tool.setuptools.package-data]
80+
"*" = ["*.txt", "*.xml", "*.zcml", "*.conf", "*.dtml"]
81+
82+

setup.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,13 @@
1212
#
1313
##############################################################################
1414

15+
from setuptools import find_packages
1516
from setuptools import setup
1617

1718

1819
# See pyproject.toml for package metadata
19-
setup()
20+
setup(
21+
packages=find_packages('src'),
22+
package_dir={'': 'src'},
23+
namespace_packages=['Shared', 'Shared.DC'],
24+
)

src/Products/__init__.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
##############################################################################
2+
#
3+
# Copyright (c) 2002 Zope Foundation and Contributors.
4+
#
5+
# This software is subject to the provisions of the Zope Public License,
6+
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
7+
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
8+
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
9+
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
10+
# FOR A PARTICULAR PURPOSE
11+
#
12+
##############################################################################
13+
__import__('pkg_resources').declare_namespace(__name__)

src/Shared/DC/__init__.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
##############################################################################
2+
#
3+
# Copyright (c) 2002 Zope Foundation and Contributors.
4+
#
5+
# This software is subject to the provisions of the Zope Public License,
6+
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
7+
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
8+
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
9+
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
10+
# FOR A PARTICULAR PURPOSE
11+
#
12+
##############################################################################
13+
__import__('pkg_resources').declare_namespace(__name__)

src/Shared/__init__.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
##############################################################################
2+
#
3+
# Copyright (c) 2002 Zope Foundation and Contributors.
4+
#
5+
# This software is subject to the provisions of the Zope Public License,
6+
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
7+
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
8+
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
9+
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
10+
# FOR A PARTICULAR PURPOSE
11+
#
12+
##############################################################################
13+
__import__('pkg_resources').declare_namespace(__name__)

0 commit comments

Comments
 (0)