Skip to content

Commit

Permalink
Revert D27967517: [pytorch][PR] Use JIT Plug-in for coverage to cover…
Browse files Browse the repository at this point in the history
… JIT'd functions and methods

Test Plan: revert-hammer

Differential Revision:
D27967517 (pytorch@88bd051)

Original commit changeset: 53fd8431d772

fbshipit-source-id: 491841dcde629f1e9f8ee38be7366955c03b6e27
  • Loading branch information
Rong Rong (AI Infra) authored and facebook-github-bot committed Apr 24, 2021
1 parent c416167 commit 3fbc154
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 10 deletions.
3 changes: 1 addition & 2 deletions .circleci/docker/common/install_conda.sh
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,6 @@ if [ -n "$ANACONDA_PYTHON_VERSION" ]; then
# TODO: Why is scipy pinned
# Pin MyPy version because new errors are likely to appear with each release
# Pin hypothesis to avoid flakiness: https://github.com/pytorch/pytorch/issues/31136
# Pin coverage so we can use COVERAGE_RCFILE
as_jenkins pip install --progress-bar off pytest \
scipy==1.1.0 \
scikit-image \
Expand All @@ -112,7 +111,7 @@ if [ -n "$ANACONDA_PYTHON_VERSION" ]; then
llvmlite \
unittest-xml-reporting \
boto3==1.16.34 \
coverage==5.5 \
coverage \
hypothesis==4.53.2 \
mypy==0.812 \
tb-nightly
Expand Down
2 changes: 0 additions & 2 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
[run]
plugins =
coverage_plugins.jit_plugin
omit =
*/tmp*
*/Temp/*
Expand Down
1 change: 0 additions & 1 deletion .jenkins/pytorch/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ fi
if [[ "$BUILD_ENVIRONMENT" == *coverage* ]]; then
export PYTORCH_COLLECT_COVERAGE=1
export COVERAGE_RCFILE="$PWD/.coveragerc" # coverage config file needed for plug-ins and settings to work
pip install -e tools/coverage_plugins_package # allows coverage to run with JitPlugin for JIT coverage
fi

if [[ "$BUILD_ENVIRONMENT" == *cuda* ]]; then
Expand Down
3 changes: 1 addition & 2 deletions .jenkins/pytorch/win-test-helpers/setup_pytorch_env.bat
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ pip install "ninja==1.10.0.post1" future "hypothesis==4.53.2" "librosa>=0.6.2" p

:: TODO: All sharded configs run coverage. We should change that to be only one config, but right now we will just
:: install coverage everywhere. Tracked: https://github.com/pytorch/pytorch/issues/56264
python -mpip install coverage==5.5
python -mpip install -e tools/coverage_plugins_package
python -mpip install coverage

if %errorlevel% neq 0 ( exit /b %errorlevel% )

Expand Down
3 changes: 1 addition & 2 deletions .jenkins/pytorch/win-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,7 @@ echo "TEST PASSED"

if [[ "${BUILD_ENVIRONMENT}" == "pytorch-win-vs2019-cuda10-cudnn7-py3" ]]; then
pushd "$TEST_DIR"
python -mpip install coverage==5.5
python -mpip install -e "$PROJECT_DIR/tools/coverage_plugins_package"
python -mpip install coverage
echo "Generating XML coverage report"
time python -mcoverage xml
popd
Expand Down
1 change: 0 additions & 1 deletion scripts/onnx/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ fi

pip install pytest scipy hypothesis # these may not be necessary
pip install pytest-cov # installing since `coverage run -m pytest ..` doesn't work
pip install -e tools/coverage_plugins_package # allows coverage to run w/o failing due to a missing plug-in

# realpath might not be available on MacOS
script_path=$(python -c "import os; import sys; print(os.path.realpath(sys.argv[1]))" "${BASH_SOURCE[0]}")
Expand Down

0 comments on commit 3fbc154

Please sign in to comment.