Skip to content

added current directory to sys.path during try_import to avoid any relative import failures in test files#118

Merged
swryan merged 1 commit intoOpenMDAO:masterfrom
naylor-b:sys_path_timing
Jul 24, 2024
Merged

added current directory to sys.path during try_import to avoid any relative import failures in test files#118
swryan merged 1 commit intoOpenMDAO:masterfrom
naylor-b:sys_path_timing

Conversation

@naylor-b
Copy link
Member

Summary

Aviary team ran into an issue where all tests in a file were being skipped because they were attempting to do a relative import of a builder file at file scope and the import was failing because the local directory was not part of sys.path at the time when the test module was first imported (during test discovery).

Backwards incompatibilities

None

New Dependencies

None

@swryan swryan merged commit 49fa75f into OpenMDAO:master Jul 24, 2024
@naylor-b naylor-b deleted the sys_path_timing branch July 24, 2024 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants