Skip to content

Collections v3 client #553

Collections v3 client

Collections v3 client #553

Workflow file for this run

on:
push:
branches:
- main
tags:
- '**'
pull_request:
env:
WEAVIATE_124: preview-fix-extracting-near-object-vector-for-named-vector-classes-99cc1a9
WEAVIATE_125: 1.25.1
jobs:
checks:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node: [
"18.x",
"20.x",
"22.x"
]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- name: "Run checks"
run: |
npm install
npm run lint
npm run format:check
tests:
needs: checks
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
versions: [
{ node: "18.x", weaviate: $WEAVIATE_124},
{ node: "20.x", weaviate: $WEAVIATE_124},
{ node: "22.x", weaviate: $WEAVIATE_124},
{ node: "18.x", weaviate: $WEAVIATE_125},
{ node: "20.x", weaviate: $WEAVIATE_125},
{ node: "22.x", weaviate: $WEAVIATE_125}
]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.versions.node }}
- name: "Install dependencies"
run: |
npm install
ci/run_dependencies.sh ${{ matrix.versions.weaviate }}
- name: "Run tests with authentication tests"
if: ${{ !github.event.pull_request.head.repo.fork }}
env:
OKTA_DUMMY_CI_PW: ${{ secrets.OKTA_DUMMY_CI_PW }}
WCS_DUMMY_CI_PW: ${{ secrets.WCS_DUMMY_CI_PW }}
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
OKTA_CLIENT_SECRET: ${{ secrets.OKTA_CLIENT_SECRET }}
run: |
npm test
npm run build
- name: "Run tests without authentication tests (for forks)"
if: ${{ github.event.pull_request.head.repo.fork }}
run: |
npm test
npm run build
- name: "Stop Weaviate"
run: ci/stop_dependencies.sh ${{ matrix.versions.weaviate }}
publish:
needs: tests
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v3
with:
node-version: '18.x'
registry-url: 'https://registry.npmjs.org'
- run: npm ci && npm run build
- run: npm publish --tag next
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTOMATION_TOKEN }}
- name: "Create a GitHub release"
uses: softprops/action-gh-release@v1
with:
generate_release_notes: true
draft: true