NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Python Adapter errors when using files from src dir

When I restructure my Python code so that I could build wheels and source distributions using a nested dir structure
pyhydraulics

src

pyhydraulics.py

pyhydraulics.yml

__init__.py

tests

pytests.py

setup.py

pyproject.toml

README.md

requirements.tx

 

Before all files resided in the top level dir and TS 2023 Q4 worked correctly.

 

When going to this structure, it creates a namespace with src. prepending the filename and errors on every import.

 

Is there an issue with using a src dir that I am not aware of?

 

The Python community goes back and forth between saying to use src of module name such as MyPackage. Since I am using setuptools where it is recommended to use the src dir.

 

Thanks

Randy

 

 

0 Kudos
Message 1 of 1
(191 Views)