Skip to content

Commit ef06eec

Browse files
astachowiczhabanaAdam Stachowicz
andauthored
Fix mxeval installation in mbxp_evaluation setup (#2367)
The mxeval package was failing to install due to two issues with newer pip/setuptools versions: 1. pkg_resources has been removed from setuptools>=82. When pip uses build isolation (default), it installs latest setuptools which no longer includes pkg_resources, causing mxeval setup.py to fail. 2. The entry_point in mxeval setup.py is missing the required callable suffix (:main), which newer pip versions enforce. Fix by: - Pinning mxeval to a known-good commit (e09974f) - Patching the broken entry_point after cloning - Using --no-build-isolation to use existing setuptools Co-authored-by: Adam Stachowicz <astachow@habana.ai>
1 parent 80ee567 commit ef06eec

File tree

1 file changed

+5
-1
lines changed
  • examples/text-generation/mbxp_evaluation

1 file changed

+5
-1
lines changed

examples/text-generation/mbxp_evaluation/setup.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,13 @@
55

66
set -xe
77

8+
MXEVAL_COMMIT="e09974f"
9+
810
apt-get update
911
git clone https://github.com/amazon-science/mxeval.git
10-
pip install -e mxeval
12+
cd mxeval && git checkout ${MXEVAL_COMMIT} && cd ..
13+
sed -i 's/evaluate_functional_correctness = mxeval.evaluate_functional_correctness"/evaluate_functional_correctness = mxeval.evaluate_functional_correctness:main"/' mxeval/setup.py
14+
pip install -e mxeval --no-build-isolation
1115
sed -i 's/npx tsc/tsc/g' mxeval/mxeval/execution.py
1216
cp evaluation_setup/ubuntu.sh mxeval/language_setup/ubuntu.sh
1317
PATH="$HOME/.rbenv/bin:$PATH" bash mxeval/language_setup/ubuntu.sh

0 commit comments

Comments
 (0)