Skip to content

Commit 4849eb8

Browse files
authored
Remove rotten_tomatoes dataset from CatBoost 1.2.7 for OSSC compliance (#8160)
1 parent 0c578f7 commit 4849eb8

2 files changed

Lines changed: 11 additions & 0 deletions

File tree

c/catboost/Dockerfiles/v1.2.7_ubi_9.6/Dockerfile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,10 @@ RUN set -ex \
103103
&& grep -n 'yasm/1.3.0' "$CONANFILE" || true \
104104
&& grep -n 'ragel/6.10' "$CONANFILE" || true \
105105
\
106+
&& echo -e "\n[+] Remove rotten_tomatoes dataset function\n" \
107+
&& DATASETS_FILE="$REPO_DIR/catboost/python-package/catboost/datasets.py" \
108+
&& sed -i '/^def rotten_tomatoes():/,/^def /{/^def rotten_tomatoes():/!{/^def /!d}}; /^def rotten_tomatoes():/d' "$DATASETS_FILE" \
109+
\
106110
&& RAGEL_BUILD="$WORKDIR/_ragel_build" \
107111
&& rm -rf "$RAGEL_BUILD" \
108112
&& mkdir -p "$RAGEL_BUILD" \

c/catboost/catboost-1.2.7_ubi_9.6.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,13 @@ sed -i \
145145
grep -n 'yasm/1.3.0' "$CONANFILE" || true
146146
grep -n 'ragel/6.10' "$CONANFILE" || true
147147

148+
# ----------------------------------------------------------------------------
149+
# Remove rotten_tomatoes dataset function
150+
# ----------------------------------------------------------------------------
151+
152+
DATASETS_FILE="$REPO_DIR/catboost/python-package/catboost/datasets.py"
153+
sed -i '/^def rotten_tomatoes():/,/^def /{/^def rotten_tomatoes():/!{/^def /!d}}; /^def rotten_tomatoes():/d' "$DATASETS_FILE"
154+
148155
# ----------------------------------------------------------------------------
149156
# Build ragel from source
150157
# ----------------------------------------------------------------------------

0 commit comments

Comments
 (0)