Skip to content

Commit

Permalink
use overrides instead of resoultions, add missing step to workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
bracesproul committed Jun 10, 2024
1 parent 6771629 commit 9301293
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 14 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/compatibility.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ jobs:
with:
node-version: ${{ env.NODE_VERSION }}
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Build `@langchain/standard-tests`
run: yarn build --filter=@langchain/standard-tests
- name: Test LangChain with lowest deps
run: docker compose -f dependency_range_tests/docker-compose.yml run test-langchain-with-lowest-deps

Expand Down Expand Up @@ -83,6 +87,10 @@ jobs:
with:
node-version: ${{ env.NODE_VERSION }}
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Build `@langchain/standard-tests`
run: yarn build --filter=@langchain/standard-tests
- name: Test `@langchain/community` with lowest deps
run: docker compose -f dependency_range_tests/docker-compose.yml run test-community-with-lowest-deps

Expand Down Expand Up @@ -112,6 +120,10 @@ jobs:
with:
node-version: ${{ env.NODE_VERSION }}
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Build `@langchain/standard-tests`
run: yarn build --filter=@langchain/standard-tests
- name: Test `@langchain/openai` with lowest deps
run: docker compose -f dependency_range_tests/docker-compose.yml run test-openai-with-lowest-deps

Expand Down Expand Up @@ -141,5 +153,9 @@ jobs:
with:
node-version: ${{ env.NODE_VERSION }}
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Build `@langchain/standard-tests`
run: yarn build --filter=@langchain/standard-tests
- name: Test `@langchain/anthropic` with lowest deps
run: docker compose -f dependency_range_tests/docker-compose.yml run test-anthropic-with-lowest-deps
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ if (currentPackageJson.dependencies["@langchain/core"] && !currentPackageJson.de
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/core"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/core": minVersion,
};
currentPackageJson.dependencies = {
Expand All @@ -23,8 +23,8 @@ if (currentPackageJson.dependencies["@langchain/openai"] && !currentPackageJson.
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/openai"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/openai": minVersion,
};
currentPackageJson.dependencies = {
Expand All @@ -37,8 +37,8 @@ if (currentPackageJson.dependencies["@langchain/textsplitters"] && !currentPacka
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/textsplitters"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/textsplitters": minVersion,
};
currentPackageJson.dependencies = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ if (currentPackageJson.dependencies["@langchain/core"] && !currentPackageJson.de
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/core"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/core": minVersion,
};
currentPackageJson.dependencies = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ if (currentPackageJson.dependencies["@langchain/core"] && !currentPackageJson.de
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/core"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/core": minVersion,
};
currentPackageJson.dependencies = {
Expand All @@ -23,8 +23,8 @@ if (currentPackageJson.dependencies["@langchain/openai"] && !currentPackageJson.
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/openai"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/openai": minVersion,
};
currentPackageJson.dependencies = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ if (currentPackageJson.dependencies["@langchain/core"] && !currentPackageJson.de
const minVersion = semver.minVersion(
currentPackageJson.dependencies["@langchain/core"]
).version;
currentPackageJson.resolutions = {
...currentPackageJson.resolutions,
currentPackageJson.overrides = {
...currentPackageJson.overrides,
"@langchain/core": minVersion,
};
currentPackageJson.dependencies = {
Expand Down

0 comments on commit 9301293

Please sign in to comment.