From 99ff4d84a872aebfcb8ce23c9079799c7447aad5 Mon Sep 17 00:00:00 2001 From: Harry Chen Date: Thu, 28 Dec 2023 17:30:00 +0800 Subject: [PATCH] chore: upgrade v3 logger (#65) * chore: upgrade v3 logger * chore: update * fix: c8 coverage * chore: update * chore: update --- package.json | 2 +- v3/midway-component/boilerplate/_package.json | 2 +- v3/midway-framework-express/boilerplate/_package.json | 2 +- v3/midway-framework-koa-esm/boilerplate/_package.json | 2 +- v3/midway-framework-koa/boilerplate/_package.json | 2 +- v3/midway-framework-web/boilerplate/_package.json | 2 +- v3/midway-quick-start/boilerplate/_package.json | 2 +- .../boilerplate/_package.json | 4 ++-- v3/midway-serverless-http-new/boilerplate/_.mocharc.json | 1 - v3/midway-serverless-http-new/boilerplate/_package.json | 7 ++++--- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/package.json b/package.json index 570d9e9..60021eb 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "scripts": { "release": "lerna publish", "test": "cross-env ./scripts/prepare.sh", - "test_once": "cross-env ./scripts/prepare.sh v3/midway-serverless-http-new-esm", + "test_once": "cross-env ./scripts/prepare.sh v3/midway-serverless-http-new", "build": "lerna run build" }, "engines": { diff --git a/v3/midway-component/boilerplate/_package.json b/v3/midway-component/boilerplate/_package.json index 3bbbe03..3a3aa8a 100644 --- a/v3/midway-component/boilerplate/_package.json +++ b/v3/midway-component/boilerplate/_package.json @@ -22,7 +22,7 @@ "devDependencies": { "@midwayjs/cli": "^2.0.0", "@midwayjs/core": "^3.12.0", - "@midwayjs/decorator": "^3.12.0", + "@midwayjs/logger": "^3.1.0", "@midwayjs/mock": "^3.12.0", "@types/jest": "^29.2.0", "@types/node": "^16.11.22", diff --git a/v3/midway-framework-express/boilerplate/_package.json b/v3/midway-framework-express/boilerplate/_package.json index fa4fc9e..9636133 100644 --- a/v3/midway-framework-express/boilerplate/_package.json +++ b/v3/midway-framework-express/boilerplate/_package.json @@ -8,7 +8,7 @@ "@midwayjs/core": "^3.12.0", "@midwayjs/decorator": "^3.12.0", "@midwayjs/express": "^3.12.0", - "@midwayjs/logger": "^2.14.0" + "@midwayjs/logger": "^3.1.0" }, "devDependencies": { "@midwayjs/cli": "^2.0.0", diff --git a/v3/midway-framework-koa-esm/boilerplate/_package.json b/v3/midway-framework-koa-esm/boilerplate/_package.json index ca523d0..d97c175 100644 --- a/v3/midway-framework-koa-esm/boilerplate/_package.json +++ b/v3/midway-framework-koa-esm/boilerplate/_package.json @@ -10,7 +10,7 @@ "@midwayjs/decorator": "^3.12.0", "@midwayjs/info": "^3.12.0", "@midwayjs/koa": "^3.12.0", - "@midwayjs/logger": "^2.14.0", + "@midwayjs/logger": "^3.1.0", "@midwayjs/validate": "^3.12.0" }, "devDependencies": { diff --git a/v3/midway-framework-koa/boilerplate/_package.json b/v3/midway-framework-koa/boilerplate/_package.json index 12aed2e..6a67405 100644 --- a/v3/midway-framework-koa/boilerplate/_package.json +++ b/v3/midway-framework-koa/boilerplate/_package.json @@ -9,7 +9,7 @@ "@midwayjs/decorator": "^3.12.0", "@midwayjs/info": "^3.12.0", "@midwayjs/koa": "^3.12.0", - "@midwayjs/logger": "^2.14.0", + "@midwayjs/logger": "^3.1.0", "@midwayjs/validate": "^3.12.0" }, "devDependencies": { diff --git a/v3/midway-framework-web/boilerplate/_package.json b/v3/midway-framework-web/boilerplate/_package.json index fc308e2..7382640 100644 --- a/v3/midway-framework-web/boilerplate/_package.json +++ b/v3/midway-framework-web/boilerplate/_package.json @@ -8,7 +8,7 @@ "@midwayjs/core": "^3.12.0", "@midwayjs/web": "^3.12.0", "@midwayjs/decorator": "^3.12.0", - "@midwayjs/logger": "^2.14.0", + "@midwayjs/logger": "^3.1.0", "egg": "^2.0.0" }, "devDependencies": { diff --git a/v3/midway-quick-start/boilerplate/_package.json b/v3/midway-quick-start/boilerplate/_package.json index 0487eaa..1009fa6 100644 --- a/v3/midway-quick-start/boilerplate/_package.json +++ b/v3/midway-quick-start/boilerplate/_package.json @@ -9,7 +9,7 @@ "@midwayjs/decorator": "^3.12.0", "@midwayjs/info": "^3.12.0", "@midwayjs/koa": "^3.12.0", - "@midwayjs/logger": "^2.14.0", + "@midwayjs/logger": "^3.1.0", "@midwayjs/static-file": "^3.4.12", "@midwayjs/validate": "^3.12.0", "@midwayjs/view-nunjucks": "^3.4.12" diff --git a/v3/midway-serverless-http-new-esm/boilerplate/_package.json b/v3/midway-serverless-http-new-esm/boilerplate/_package.json index cfc8a76..31dbaa4 100644 --- a/v3/midway-serverless-http-new-esm/boilerplate/_package.json +++ b/v3/midway-serverless-http-new-esm/boilerplate/_package.json @@ -12,7 +12,7 @@ "scripts": { "dev": "cross-env NODE_ENV=local mwtsc --watch --run @midwayjs/mock/function", "test": "cross-env NODE_ENV=unittest mocha", - "cov": "cross-env c8 --all --reporter=text --reporter=lcovonly npm run test", + "cov": "cross-env c8 --include src --all --reporter=text --reporter=lcovonly npm run test", "deploy": "", "lint": "mwts check", "lint:fix": "mwts fix", @@ -23,7 +23,7 @@ "@midwayjs/core": "^3.12.0", "@midwayjs/faas": "^3.12.0", "@midwayjs/fc-starter": "^3.12.0", - "@midwayjs/logger": "^2.0.0" + "@midwayjs/logger": "^3.1.0" }, "devDependencies": { "@midwayjs/mock": "^3.12.0", diff --git a/v3/midway-serverless-http-new/boilerplate/_.mocharc.json b/v3/midway-serverless-http-new/boilerplate/_.mocharc.json index f63797e..b944748 100644 --- a/v3/midway-serverless-http-new/boilerplate/_.mocharc.json +++ b/v3/midway-serverless-http-new/boilerplate/_.mocharc.json @@ -1,6 +1,5 @@ { "extension": ["ts"], - "node-option": ["no-warnings", "loader=ts-node/register"], "spec": ["test/**/*.test.ts"], "require": ["test/setup.ts"] } \ No newline at end of file diff --git a/v3/midway-serverless-http-new/boilerplate/_package.json b/v3/midway-serverless-http-new/boilerplate/_package.json index 7dbc4d9..fa890e1 100644 --- a/v3/midway-serverless-http-new/boilerplate/_package.json +++ b/v3/midway-serverless-http-new/boilerplate/_package.json @@ -3,6 +3,7 @@ "private": true, "version": "1.0.0", "description": "Midway Serverless for the Serverless environment", + "type": "commonjs", "main": "index.js", "license": "MIT", "keywords": [ @@ -11,8 +12,8 @@ ], "scripts": { "dev": "cross-env NODE_ENV=local mwtsc --watch --run @midwayjs/mock/function --port 7001", - "test": "cross-env NODE_ENV=unittest mocha", - "cov": "cross-env c8 --all --reporter=text --reporter=lcovonly npm run test", + "test": "cross-env NODE_ENV=unittest mocha --require ts-node/register", + "cov": "cross-env c8 --include src --all --reporter=text --reporter=lcovonly npm run test", "deploy": "", "lint": "mwts check", "lint:fix": "mwts fix", @@ -23,7 +24,7 @@ "@midwayjs/core": "^3.12.0", "@midwayjs/faas": "^3.12.0", "@midwayjs/fc-starter": "^3.12.0", - "@midwayjs/logger": "^2.0.0" + "@midwayjs/logger": "^3.1.0" }, "devDependencies": { "@midwayjs/mock": "^3.12.0",