Skip to content

Commit

Permalink
fix: fix issue with get(name, null, options) call not meeting expecta…
Browse files Browse the repository at this point in the history
…tions
  • Loading branch information
csg01123119 committed Aug 13, 2024
2 parents 3d0a1a5 + 1470e7d commit d654442
Show file tree
Hide file tree
Showing 82 changed files with 39,950 additions and 51,979 deletions.
7 changes: 0 additions & 7 deletions .autod.conf.js

This file was deleted.

7 changes: 7 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,10 @@ task/
browser-build.js
es
cjs
dist/

lib/common/utils/createRequest.js
lib/common/utils/encodeString.js
lib/common/utils/getStandardRegion.js

lib/common/bucket/putBucketInventory.d.ts
8 changes: 6 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/* eslint max-len: [0] */
// Ignore checking the js file generated by ts
const buckets = ['dataIndex.js'];
const ignorePatterns = ['lib/common/utils/*.js'].concat(buckets.map(item => `lib/common/bucket/${item}`));

module.exports = {
ignorePatterns,
extends: ['airbnb', 'eslint-config-ali/typescript', 'prettier'],
parserOptions: {
ecmaFeatures: {
Expand All @@ -16,7 +20,6 @@ module.exports = {
},
rules: {
indent: ['error', 2],
// override default options
'no-underscore-dangle': [0],
'no-plusplus': [0],
'no-return-await': [0],
Expand All @@ -34,6 +37,7 @@ module.exports = {
}
],
'no-buffer-constructor': [2],
'no-void': 'warn',
'comma-dangle': [0],
'import/prefer-default-export': [0]
}
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/codeCov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,9 @@ jobs:
ALI_SDK_STS_REGION: ${{secrets.ALI_SDK_STS_REGION}}
ALI_SDK_STS_ROLE: ${{secrets.ALI_SDK_STS_ROLE}}
ALI_SDK_STS_SECRET: ${{secrets.ALI_SDK_STS_SECRET}}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: test and report upload
run: |
npm install
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
23 changes: 10 additions & 13 deletions .github/workflows/dev_node_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@ jobs:
node-version: [14.x]

steps:
- uses: actions/checkout@v2
with:
ref: develop
- uses: actions/checkout@v4
- name: browser build and test
run: |
curl cip.cc
Expand Down Expand Up @@ -63,13 +61,12 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2
with:
ref: develop
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install
- run: npm run test

Expand All @@ -96,13 +93,12 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2
with:
ref: develop
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install
- run: npm run test

Expand All @@ -129,12 +125,13 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
ref: develop
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install
- run: npm run test
20 changes: 13 additions & 7 deletions .github/workflows/master_node_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
node-version: [14.x]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: browser build and test
run: |
curl cip.cc
Expand Down Expand Up @@ -61,11 +61,13 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install -D npm@6.14.12
- run: npm install
- run: npm run test

Expand All @@ -92,11 +94,13 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install -D npm@6.14.16
- run: npm install
- run: npm run test

Expand All @@ -123,10 +127,12 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install -D npm@6.14.18
- run: npm install
- run: npm run test
36 changes: 36 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Release

on:
push:
branches:
- release
jobs:
release:
name: Release
runs-on: ubuntu-latest
permissions:
# https://docs.github.com/zh/actions/using-jobs/assigning-permissions-to-jobs
contents: write # 为 GITHUB_TOKEN 授予更新tag的权限
env:
GITHUB_TOKEN: ${{ secrets.GIT_TOKEN }} # semantic-release和create-pull-request.js需要
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} # 只有semantic-release需要

steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 18
architecture: x64
- name: Install Dependencies
run: npm install
- name: Snyk Protect
run: npm run snyk-protect
- name: Release to npm
run: npx semantic-release
# - name: Publish to cdn
# run: node publish.js # 因为发cdn 的ak权限比较大,有安全风险,故需要在本地发版到cdn
# 为了创建pr,GIT_TOKEN需要public_repo权限(https://github.com/settings/tokens/new)
- name: Create Pull Request
run: node ./task/create-pull-request.js
11 changes: 6 additions & 5 deletions .github/workflows/schedule.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Regularly clean test buckets at 4:00 every day
# Regularly clean test buckets at GMT 01:00 every day.
name: 'Schdule Delete'

on:
schedule:
- cron: '0 4 1/1 * *'
- cron: '0 1 1/1 * *'

jobs:
cleanAllBucket:
Expand All @@ -25,10 +25,11 @@ jobs:
matrix:
node-version: [14.x]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: clean all bucket
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: x64
- run: npm install
- run: node test/node/cleanAllBucket.js
- run: node test/node/fixtures/cleanAllBucket.js
3 changes: 2 additions & 1 deletion .github/workflows/snyk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ jobs:
security:
environment: ali_oss_AK
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- run: npm install
- name: Run Snyk to check for vulnerabilities
Expand Down
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ build
test/node/.tmp
test/browser/.tmp
test/demo.js
yarn.lock
package-lock.json
.nyc_output/
.env

Expand All @@ -44,3 +42,6 @@ package-lock.json

es
.eslintcache

/test/node/fixtures/nodejs-processed-w200-latest.png
/test/node/fixtures/nodejs-processed-w200.png
8 changes: 8 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
node_modules/
dist/

lib/common/utils/createRequest.js
lib/common/utils/encodeString.js
lib/common/utils/getStandardRegion.js

lib/common/bucket/putBucketInventory.d.ts
31 changes: 31 additions & 0 deletions .releaserc
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"branches": "release",
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/github",
[
"@semantic-release/npm",
{
"npmPublish": true
}
],
[
"@semantic-release/exec",
{
"prepareCmd": "npm run build-dist"
}
],
[
"@semantic-release/git",
{
"assets": [
"package.json",
"lib/browser/version.js",
"dist/*.js"
],
"message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"
}
]
]
}
44 changes: 44 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,50 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## [6.20.0](https://github.com/ali-sdk/ali-oss/compare/v6.19.0...v6.20.0) (2024-01-19)

### Features

* support v4 signature ([#1277](https://github.com/ali-sdk/ali-oss/issues/1277)) ([8bbe9b1](https://github.com/ali-sdk/ali-oss/commit/8bbe9b1ac8aa34c1564a1ad11549b67fc1db7f3a))

## [6.19.0](https://github.com/ali-sdk/ali-oss/compare/v6.18.1...v6.19.0) (2023-12-18)

### Features

* verify object names strictly when signing URLs and enabled by default ([#1265](https://github.com/ali-sdk/ali-oss/issues/1265)) ([830e36e](https://github.com/ali-sdk/ali-oss/commit/830e36ea143b57e09e42d0634bc0c4d07474a2a5))

### [6.18.1](https://github.com/ali-sdk/ali-oss/compare/v6.18.0...v6.18.1) (2023-09-08)

### Features

* add default content-type in DingTalk for ios ([#1244](https://github.com/ali-sdk/ali-oss/issues/1244)) ([13a2691](https://github.com/ali-sdk/ali-oss/commit/13a2691e49ee04667f41070d63478301fbc983e3))

### Bug Fixes

* opt.headers in _uploadPart does not use es6 ([#1248](https://github.com/ali-sdk/ali-oss/issues/1248)) ([e2872a0](https://github.com/ali-sdk/ali-oss/commit/e2872a0046af9c5bf537c6eb67e8c32bd119021e))
* upgrade urllib to 2.41.0 to avoid deps vm2 ([#1239](https://github.com/ali-sdk/ali-oss/issues/1239) [#1232](https://github.com/ali-sdk/ali-oss/issues/1232)) ([7656d6f](https://github.com/ali-sdk/ali-oss/commit/7656d6f49489451a7862015b0893ef1286b2e948))

## [6.18.0](https://github.com/aliyun/oss-nodejs-sdk/compare/v6.17.0...v6.18.0) (2023-07-27)

### Features

- add asyncSignatureUrl method ([#1057](https://github.com/aliyun/oss-nodejs-sdk/issues/1057)) ([1a05e80](https://github.com/aliyun/oss-nodejs-sdk/commit/1a05e8077b9e2ecbef0579253594ee2e67c45af4))
- add getBucketStat method ([#1102](https://github.com/aliyun/oss-nodejs-sdk/issues/1102)) ([a63a5a4](https://github.com/aliyun/oss-nodejs-sdk/commit/a63a5a4c6c853f78dbbb97ca065866dcfe212ab0))
- optimized multipartUpload progress close [#1139](https://github.com/aliyun/oss-nodejs-sdk/issues/1139) ([#1141](https://github.com/aliyun/oss-nodejs-sdk/issues/1141)) ([12fcfd1](https://github.com/aliyun/oss-nodejs-sdk/commit/12fcfd1abd9f6fb7ca0fce9b81c076b2d7518c1f))
- the browser needs to set cross domain and expose the x-oss-next-append-position header ([#1218](https://github.com/aliyun/oss-nodejs-sdk/issues/1218)) ([ab2f4a3](https://github.com/aliyun/oss-nodejs-sdk/commit/ab2f4a3c795d1ab61b54112f3fc081d8afb39b7f))

### Bug Fixes

- uploadPart not pass all headers parameters ([#1215](https://github.com/aliyun/oss-nodejs-sdk/issues/1215)) ([d842a6c](https://github.com/aliyun/oss-nodejs-sdk/commit/d842a6cd1653901ad865f080f37d40ff0a73cbe1))
- **6.x:** lock dependencies ([#1088](https://github.com/aliyun/oss-nodejs-sdk/issues/1088)) ([9b65ef2](https://github.com/aliyun/oss-nodejs-sdk/commit/9b65ef28db5859b13238bd6aaccb3c25547b11e3))
- fix user input header MD5 value being overwritten problem ([#1100](https://github.com/aliyun/oss-nodejs-sdk/issues/1100)) ([3f26b79](https://github.com/aliyun/oss-nodejs-sdk/commit/3f26b79384d733687e9324fa6b03df863a9a43dd))
- remove Invalid Comparison ([#1090](https://github.com/aliyun/oss-nodejs-sdk/issues/1090)) ([bbb55b8](https://github.com/aliyun/oss-nodejs-sdk/commit/bbb55b821b5b0254827e62042bbadd6f96311c8b))
- require module exits ([#1052](https://github.com/aliyun/oss-nodejs-sdk/issues/1052)) ([b176fa8](https://github.com/aliyun/oss-nodejs-sdk/commit/b176fa87d0de8b346f0f792f77acaf3002ca3a4d))
- to fix callback customValue ([#1126](https://github.com/aliyun/oss-nodejs-sdk/issues/1126)) ([e6cdfe5](https://github.com/aliyun/oss-nodejs-sdk/commit/e6cdfe5a778e30de33eebd3f2b95791c38d6a8f6))
- upgrade address from 1.1.2 to 1.2.2 ([#1114](https://github.com/aliyun/oss-nodejs-sdk/issues/1114)) ([a9b4d03](https://github.com/aliyun/oss-nodejs-sdk/commit/a9b4d03d7c53cb91efe790b9716c8bb8ecc2fda9))([#1184](https://github.com/aliyun/oss-nodejs-sdk/issues/1184)) ([b113222](https://github.com/aliyun/oss-nodejs-sdk/commit/b1132220f430d38e9e8738b6fdd8fb7f20b668a6))
- upgrade is-type-of from 1.2.1 to 1.4.0 ([#1204](https://github.com/aliyun/oss-nodejs-sdk/issues/1204)) ([39ef9ac](https://github.com/aliyun/oss-nodejs-sdk/commit/39ef9acd9177b5d6348df7b9c83ca3a87c6b6185))
- upgrade utility from 1.17.0 to 1.18.0 ([#1203](https://github.com/aliyun/oss-nodejs-sdk/issues/1203)) ([bc05406](https://github.com/aliyun/oss-nodejs-sdk/commit/bc05406b1b9326e1e08975e7639259cf04c2bf1e))

## [6.17.0](https://github.com/aliyun/oss-nodejs-sdk/compare/v6.15.0...v6.17.0) (2022-01-27)

### Features
Expand Down
Loading

0 comments on commit d654442

Please sign in to comment.