mirror of
https://github.com/Unstructured-IO/unstructured.git
synced 2025-08-17 21:29:05 +00:00

### Description Currently the CI caches the CI dependencies but uses the hash of all files in `requirements/`. This isn't completely accurate since the ingest dependencies are installed in a later step and don't affect the cached environment. As part of this PR: * ingest dependencies were isolated into their own folder in `requirements/ingest/` * A new cache setup was introduced in the CI to restore the base cache -> install ingest dependencies -> cache it with a new id * new make target created to install all ingest dependencies via `pip install -r ...` * updates to Dockerfile to use `find ...` to install all dependencies, avoiding the need to update this when new deps are added. * update to pip-compile script to run over all `*.in` files in `requirements/`
18 lines
507 B
Bash
Executable File
18 lines
507 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# python version must match lowest supported (3.8)
|
|
major=3
|
|
minor=8
|
|
if ! python -c "import sys; assert sys.version_info.major == $major and sys.version_info.minor == $minor"; then
|
|
echo "python version not equal to expected $major.$minor: $(python --version)"
|
|
exit 1
|
|
fi
|
|
|
|
for file in requirements/**/*.in; do
|
|
if [[ "$file" =~ "constraints" ]]; then
|
|
continue;
|
|
fi;
|
|
echo "running: pip-compile --upgrade $file"
|
|
pip-compile --upgrade "$file" -c requirements/constraints.in
|
|
done
|