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

pytest crashes when I import "from decord import VideoReader" #274

Open
lovettchris opened this issue Aug 15, 2023 · 1 comment
Open

pytest crashes when I import "from decord import VideoReader" #274

lovettchris opened this issue Aug 15, 2023 · 1 comment

Comments

@lovettchris
Copy link

lovettchris commented Aug 15, 2023

strace.zip

I tried for hours to create simple repro, but my python project is too complex and could not figure out the magic ingredients that would make it do this, so I included an strace instead. But my project uses the following dependencies.

The interesting thing is I would get an abort with just "pytest --help", so it didn't even need to run any of my tests. I hope this helps narrow it down. The other interesting thing is that if I moved the from decord import VideoReader so it is not at the top of the python file but instead it is inside the function that needs to use the VideoReader, then pytest no longer crashes, even the test that uses this code passes. Very weird.

Also this crash only happens on Ubuntu, but not on Windows. On Windows everything works fine.

dependencies = [
    "azure-data-tables",
    "azure-identity",
    "azure-storage-blob",
    "decord",
    "torch",
    "ray===2.6.2",
    "ray[rllib]===2.6.2",
    "ray[tune]===2.6.2",
    "pygame",
    "psutil",
    "schema",
    "keyboard",
    "numba",  # for jitting the dtw algorithm
    "opencv-python",
    "winput",
    "pywin32; sys_platform == 'win32'",
    "protobuf==3.20.3"  # if we install BE externally, make sure we keep this version of protobuf
]

[project.optional-dependencies]
dev = [
    "black",
    "isort",
    "flake8",
    "Flake8-pyproject",
    "mypy",
    "mypy-extensions",
    "types-PyYAML",
    "toml",
    "pre-commit",
    "tqdm",
    "matplotlib"
]
test = [
    "fastdtw",
    "pytest==7.3.1",
    "Mock",
]
@WhiteDOU
Copy link

same issue

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

2 participants