Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nosetest fails while running tests directly works #1101

Open
Bihaqo opened this issue Dec 17, 2019 · 1 comment
Open

Nosetest fails while running tests directly works #1101

Bihaqo opened this issue Dec 17, 2019 · 1 comment

Comments

@Bihaqo
Copy link

Bihaqo commented Dec 17, 2019

I'm trying to run nosetests and it reports a lot of failed tests while running the same tests directly works fine (and takes a lot of time, i.e. it seems that nosetest is not actually running as much code as when running directly). The same code used to work fine with nosetests before the latest changes.

Reproducing the problem: https://colab.research.google.com/drive/1rhyXYbqS_od6yJfNXyZhDL6NL0tkGygx

The codebase: https://github.com/Bihaqo/t3f/tree/full_tf2_support

Latest changes diff: https://github.com/Bihaqo/t3f/pull/201/files

@Bihaqo
Copy link
Author

Bihaqo commented Jan 9, 2020

It seems that the problem is that Nose runs all the test files in the same process, polluting Tensorflow state (in some of the test files eager execution is turned off and in others it turned on, and this choice has to be made in the very beginning of the program).

So what I actually need, is to run each test file in a separate process. I tried following this advice: https://stackoverflow.com/questions/31274926/python-nose-unit-testing-using-separate-sequential-python-processes , but it didn't help. Is there any other way of doing it?

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

No branches or pull requests

1 participant