You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by al...@apache.org on 2020/06/11 16:23:24 UTC
[flink] branch release-1.11 updated: [hotfix] Fix head --lines
usage in test scripts
This is an automated email from the ASF dual-hosted git repository.
aljoscha pushed a commit to branch release-1.11
in repository https://gitbox.apache.org/repos/asf/flink.git
The following commit(s) were added to refs/heads/release-1.11 by this push:
new e2ec853 [hotfix] Fix head --lines usage in test scripts
e2ec853 is described below
commit e2ec853b216728cbf3cbb28f12bc4da0caeb9385
Author: Aljoscha Krettek <al...@apache.org>
AuthorDate: Thu Jun 11 18:17:39 2020 +0200
[hotfix] Fix head --lines usage in test scripts
--lines does not work on macOS but -n works.
---
flink-end-to-end-tests/test-scripts/common.sh | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/flink-end-to-end-tests/test-scripts/common.sh b/flink-end-to-end-tests/test-scripts/common.sh
index 3baae6b..4ca974e 100644
--- a/flink-end-to-end-tests/test-scripts/common.sh
+++ b/flink-end-to-end-tests/test-scripts/common.sh
@@ -366,7 +366,7 @@ function check_logs_for_errors {
| grep -ic "error" || true)
if [[ ${error_count} -gt 0 ]]; then
echo "Found error in log files; printing first 500 lines; see full logs for details:"
- find $FLINK_DIR/log/ -exec head --lines=500 {} \;
+ find $FLINK_DIR/log/ -exec head -n 500 {} \;
EXIT_CODE=1
else
echo "No errors in log files."
@@ -402,7 +402,7 @@ function check_logs_for_exceptions {
| grep -ic "exception" || true)
if [[ ${exception_count} -gt 0 ]]; then
echo "Found exception in log files; printing first 500 lines; see full logs for details:"
- find $FLINK_DIR/log/ -exec head --lines=500 {} \;
+ find $FLINK_DIR/log/ -exec head -n 500 {} \;
EXIT_CODE=1
else
echo "No exceptions in log files."
@@ -424,7 +424,7 @@ function check_logs_for_non_empty_out_files {
| grep "." \
> /dev/null; then
echo "Found non-empty .out files; printing first 500 lines; see full logs for details:"
- find $FLINK_DIR/log/ -name '*.out' -exec head --lines=500 {} \;
+ find $FLINK_DIR/log/ -name '*.out' -exec head -n 500 {} \;
EXIT_CODE=1
else
echo "No non-empty .out files."