Skip to content

Commit

Permalink
fix dynamic import with binary distribution (#2583)
Browse files Browse the repository at this point in the history
  • Loading branch information
niclim authored Dec 6, 2023
1 parent bd350fe commit 83fd861
Show file tree
Hide file tree
Showing 10 changed files with 11 additions and 12 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "openapi-workspaces",
"license": "MIT",
"private": true,
"version": "0.53.7",
"version": "0.53.8",
"workspaces": [
"projects/json-pointer-helpers",
"projects/openapi-io",
Expand Down
2 changes: 1 addition & 1 deletion projects/fastify-capture/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/fastify-capture",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion projects/json-pointer-helpers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/json-pointer-helpers",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion projects/openapi-io/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/openapi-io",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion projects/openapi-utilities/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/openapi-utilities",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion projects/optic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/optic",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion projects/rulesets-base/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/rulesets-base",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand Down
3 changes: 2 additions & 1 deletion projects/standard-rulesets/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@useoptic/standard-rulesets",
"license": "MIT",
"packageManager": "[email protected]",
"version": "0.53.7",
"version": "0.53.8",
"main": "build/index.js",
"types": "build/index.d.ts",
"files": [
Expand All @@ -23,6 +23,7 @@
"json-stable-stringify": "^1.1.0",
"object-hash": "^3.0.0",
"openai": "^4.7.1",
"ora": "5.4.1",
"whatwg-mimetype": "^4.0.0"
},
"devDependencies": {
Expand Down
5 changes: 1 addition & 4 deletions projects/standard-rulesets/src/lintgpt/rules-helper.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import crypto from 'crypto';
import chunk from 'lodash.chunk';
import ora from 'ora';

type OpenAPIRuleType =
| 'OPERATION'
Expand Down Expand Up @@ -80,8 +81,6 @@ export class LintgptRulesHelper {
{ rule: string; rule_checksum: string; prep?: CachedRulePrep }
>();

const ora = (await import('ora')).default;

let spinner = ora({
text: this.getPrepSpinnerText({
total: rules.length,
Expand Down Expand Up @@ -177,8 +176,6 @@ export class LintgptRulesHelper {
}
>();

const ora = (await import('ora')).default;

let spinner = ora({
text: this.getEvalSpinnerText({
total: eval_requests.length,
Expand Down
1 change: 1 addition & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3905,6 +3905,7 @@ __metadata:
json-stable-stringify: "npm:^1.1.0"
object-hash: "npm:^3.0.0"
openai: "npm:^4.7.1"
ora: "npm:5.4.1"
prettier: "npm:^3.0.0"
ts-jest: "npm:^29.0.3"
ts-node: "npm:^10.9.1"
Expand Down

0 comments on commit 83fd861

Please sign in to comment.