Skip to content

Commit 0d247c3

Browse files
committed
Debug GitHub low disk space error
1 parent f0b486d commit 0d247c3

File tree

2 files changed

+39
-8
lines changed

2 files changed

+39
-8
lines changed

check-disk-space

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/bash
2+
3+
set -euo pipefail
4+
5+
df -h || true
6+
du -sh || true
7+
du -sh /* || true

test-all

+32-8
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,15 @@ function run {
99
echo
1010
}
1111

12+
function clean {
13+
if [ "$CI" = "true" ]; then
14+
rm -rf target/debug/examples
15+
rm -rf target/debug/incremental
16+
fi
17+
df -h
18+
du -sh target/debug/build/*
19+
}
20+
1221
# Make sure the Tensorflow version in the -sys build script matches the one in
1322
# the run-valgrind script.
1423
version_build_script=`grep "const VERSION" tensorflow-sys/build.rs | sed 's|.*"\([^"]*\)";|\1|g'`
@@ -51,28 +60,40 @@ export RUSTFLAGS="-Awarnings"
5160
# Keras format, which the C API can't read:
5261
# https://github.com/tensorflow/tensorflow/issues/70514
5362
TF_USE_LEGACY_KERAS=1 run python3 examples/mobilenetv3/create_model.py
63+
run df -h
5464
# TODO(#391): Re-enable: (cd test_resources/library && ./build-test-op)
5565
run cargo fmt --all -- --check
66+
clean
5667
run cargo test -vv -j 2
68+
clean
5769
run cargo test -vv -j 2 --features eager
70+
clean
5871
run cargo test -vv -j 2 --features tensorflow_unstable
72+
clean
5973
run cargo test -vv -j 2 --features ndarray
74+
clean
6075
run cargo run --example regression
76+
clean
6177
run cargo run --example xor
78+
clean
6279
run cargo run --features tensorflow_unstable --example expressions
80+
clean
6381
run cargo run --features eager --example mobilenetv3
82+
clean
6483
run cargo doc --features experimental,tensorflow_unstable,ndarray,eager
84+
clean
6585
run cargo doc --features experimental,tensorflow_unstable,ndarray,eager,private-docs-rs
86+
clean
6687
# TODO(#66): Re-enable: (cd tensorflow-sys && cargo test -vv -j 1)
67-
(cd tensorflow-sys && run cargo run --example multiplication)
68-
(cd tensorflow-sys && run cargo run --example tf_version)
69-
(cd tensorflow-sys && run cargo doc -vv)
88+
(cd tensorflow-sys && run cargo run --example multiplication && clean)
89+
(cd tensorflow-sys && run cargo run --example tf_version && clean)
90+
(cd tensorflow-sys && run cargo doc -vv && clean)
7091

71-
run cargo clippy
72-
(cd tensorflow-sys && run cargo clippy)
73-
(cd tensorflow-op-codegen && run cargo clippy)
74-
(cd tensorflow-proto-codegen && run cargo clippy)
75-
(cd tensorflow-internal-macros && run cargo clippy)
92+
# run cargo clippy
93+
# (cd tensorflow-sys && run cargo clippy)
94+
# (cd tensorflow-op-codegen && run cargo clippy)
95+
# (cd tensorflow-proto-codegen && run cargo clippy)
96+
# (cd tensorflow-internal-macros && run cargo clippy)
7697

7798
for file in $(find . -name target -prune -o -name '*.rs' -print); do
7899
bad_deprecations="$(rustfmt --emit stdout --config max_width=1000 "$file" | grep '#\[deprecated' | grep -E -v '([^"\\]|\\.|"([^"\\]|\\.)*")*since' || true)"
@@ -88,3 +109,6 @@ for file in $(find . -name target -prune -o -name '*.rs' -print); do
88109
exit 1
89110
fi
90111
done
112+
113+
df -h
114+
du -sh target/debug/build/*

0 commit comments

Comments
 (0)