From 102f1d7404821ff67f330ca28216be94d98d48d9 Mon Sep 17 00:00:00 2001 From: Will Jones Date: Thu, 25 May 2023 09:20:37 -0700 Subject: [PATCH] add dbg prints --- .github/workflows/release.yml | 2 +- ci/build_linux_artifacts.sh | 15 +++++++++++++-- ci/build_macos_artifacts.sh | 14 ++++++++++++++ ci/release_process.md | 28 +++++++++++++++++----------- 4 files changed, 45 insertions(+), 14 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 758cb8a53..387f9c000 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -38,7 +38,7 @@ jobs: - uses: softprops/action-gh-release@v1 with: draft: true - files: target/vectordb-*.crate + files: target/package/vectordb-*.crate fail_on_unmatched_files: true python: diff --git a/ci/build_linux_artifacts.sh b/ci/build_linux_artifacts.sh index 1f59c0d82..b4975c708 100644 --- a/ci/build_linux_artifacts.sh +++ b/ci/build_linux_artifacts.sh @@ -48,12 +48,23 @@ install_node() { else nvm install 17 # latest that supports glibc 2.17 fi + + printenv + echo "Node version:" + npm --version + which npm + which node } install_rust() { echo "Installing rust..." curl https://sh.rustup.rs -sSf | bash -s -- -y + + printenv + export PATH="$PATH:/root/.cargo/bin" + + printenv } build_node_binary() { @@ -66,8 +77,8 @@ build_node_binary() { fi # We don't pass in target, since the native target here already matches # and openblas-src doesn't do well with cross-compilation. - npm run build-release - npm run pack-build + npm run build-release --script-shell bash + npm run pack-build --script-shell bash popd } diff --git a/ci/build_macos_artifacts.sh b/ci/build_macos_artifacts.sh index f940fd842..5cea8b0c0 100644 --- a/ci/build_macos_artifacts.sh +++ b/ci/build_macos_artifacts.sh @@ -2,6 +2,20 @@ # Usage: ./build_macos_artifacts.sh [target] # Targets supported: x86_64-apple-darwin aarch64-apple-darwin +prebuild_rust() { + # Building here for the sake of easier debugging. + pushd rust/ffi/node + + for target in $1 + do + echo "Building rust library for $target" + export RUST_BACKTRACE=1 + cargo build --release --target $target + done + + popd +} + build_node_binaries() { pushd node diff --git a/ci/release_process.md b/ci/release_process.md index 8beca8311..f2728a5e5 100644 --- a/ci/release_process.md +++ b/ci/release_process.md @@ -35,18 +35,14 @@ git push --tag vX.X.X ``` When the tag is pushed, GitHub actions will start building the libraries and -will upload them to a draft release. Wait for those jobs to complete. +will upload them to a draft release. -### 3. Publish the release +While those jobs are running, edit the release notes as needed. For example, +bring relevant new features and bugfixes to the top of the notes and the testing +and CI changes to the bottom. -Once the jobs are complete, you can edit the - -2. Push a tag, such as vX.X.X. Once the tag is pushrf, GitHub actions will start - building the native libraries and uploading them to a draft release. Wait for - those jobs to complete. -3. If the libraries are successful, edit the changelog and then publish the - release. Once you publish, a new action will start and upload all the - release artifacts to npm. +Once the jobs have finished, the release will be marked as not draft and the +artifacts will be released to crates.io, NPM, and PyPI. ## Manual process @@ -92,7 +88,15 @@ docker run \ ```