You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#86 [linux/arm64 38/39] RUN python -c "import site; print(site.getsitepackages()[0])" > site_packages_path.txt && PYTHON_SITE_PACKAGES_PATH=$(cat site_packages_path.txt) && sed -i "s/localhost:27020,/127.0.0.1:27020,/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/encryption_options.py" && sed -i 's/HOST = "localhost"/HOST = "127.0.0.1"/g' "${PYTHON_SITE_PACKAGES_PATH}/pymongo/mongo_client.py" && sed -i "s/'localhost'/'127.0.0.1'/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/settings.py" && sed -i "s/'localhost'/'127.0.0.1'/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/pool.py" && rm site_packages_path.txt
#86 0.507 sed: can't read /opt/conda/lib/python3.10/site-packages/pymongo/settings.py: No such file or directory
#86 ERROR: process "/bin/bash -c python -c \"import site; print(site.getsitepackages()[0])\" > site_packages_path.txt && \tPYTHON_SITE_PACKAGES_PATH=$(cat site_packages_path.txt) && \tsed -i \"s/localhost:27020,/127.0.0.1:27020,/g\" \"${PYTHON_SITE_PACKAGES_PATH}/pymongo/encryption_options.py\" && \tsed -i 's/HOST = \"localhost\"/HOST = \"127.0.0.1\"/g' \"${PYTHON_SITE_PACKAGES_PATH}/pymongo/mongo_client.py\" && \tsed -i \"s/'localhost'/'127.0.0.1'/g\" \"${PYTHON_SITE_PACKAGES_PATH}/pymongo/settings.py\" && \tsed -i \"s/'localhost'/'127.0.0.1'/g\" \"${PYTHON_SITE_PACKAGES_PATH}/pymongo/pool.py\" && \trm site_packages_path.txt" did not complete successfully: exit code: 2
------
> [linux/arm64 38/39] RUN python -c "import site; print(site.getsitepackages()[0])" > site_packages_path.txt && PYTHON_SITE_PACKAGES_PATH=$(cat site_packages_path.txt) && sed -i "s/localhost:27020,/127.0.0.1:27020,/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/encryption_options.py" && sed -i 's/HOST = "localhost"/HOST = "127.0.0.1"/g' "${PYTHON_SITE_PACKAGES_PATH}/pymongo/mongo_client.py" && sed -i "s/'localhost'/'127.0.0.1'/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/settings.py" && sed -i "s/'localhost'/'127.0.0.1'/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/pool.py" && rm site_packages_path.txt:
0.507 sed: can't read /opt/conda/lib/python3.10/site-packages/pymongo/settings.py: No such file or directory
------
Dockerfile:212
--------------------
211 | # replace localhost to 127.0.0.1 in pymongo to run on HPC
212 | >>> RUN python -c "import site; print(site.getsitepackages()[0])" > site_packages_path.txt && \
213 | >>> PYTHON_SITE_PACKAGES_PATH=$(cat site_packages_path.txt) && \
214 | >>> sed -i "s/localhost:27020,/127.0.0.1:27020,/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/encryption_options.py" && \
215 | >>> sed -i 's/HOST = "localhost"/HOST = "127.0.0.1"/g' "${PYTHON_SITE_PACKAGES_PATH}/pymongo/mongo_client.py" && \
216 | >>> sed -i "s/'localhost'/'127.0.0.1'/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/settings.py" && \
217 | >>> sed -i "s/'localhost'/'127.0.0.1'/g" "${PYTHON_SITE_PACKAGES_PATH}/pymongo/pool.py" && \
218 | >>> rm site_packages_path.txt
219 |
--------------------
I think this is because the settings.py file got moved or removed. We will need to further investigate.
Also, @Cloud1e ran into another issue due to the reorganization of the modules:
I can see that the use of "pymongo.database.Collection" was problematic, but in this version, we need to change it to pymongo.synchronous.collection.Collection.
For now, I just limited the pymongo version to 4.8 with 8ef0ae3. We will need to revisit this later.
The text was updated successfully, but these errors were encountered:
Turns out there are several major changes in the 4.9.0 version of pymongo, which break our build. One example is in https://github.com/mspass-team/mspass/actions/runs/10966517360/job/30454557775. The error looks like:
I think this is because the
settings.py
file got moved or removed. We will need to further investigate.Also, @Cloud1e ran into another issue due to the reorganization of the modules:
I can see that the use of "pymongo.database.Collection" was problematic, but in this version, we need to change it to
pymongo.synchronous.collection.Collection
.For now, I just limited the pymongo version to 4.8 with 8ef0ae3. We will need to revisit this later.
The text was updated successfully, but these errors were encountered: