odesli.js 1.3.7 → 1.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10,7 +10,7 @@ jobs:
10
10
  runs-on: ubuntu-latest
11
11
  permissions:
12
12
  contents: read
13
- packages: write
13
+ id-token: write
14
14
 
15
15
  steps:
16
16
  - name: Checkout code
@@ -24,7 +24,43 @@ jobs:
24
24
  node-version: '20.x'
25
25
  cache: 'npm'
26
26
  registry-url: 'https://registry.npmjs.org'
27
+ # OIDC is automatically used when id-token: write permission is set
27
28
 
29
+ # #region agent log
30
+ - name: Debug - Check npm version (Trusted Publishing requires npm 11.5.1+)
31
+ run: |
32
+ echo "HYPOTHESIS_G: Checking npm version for Trusted Publishing compatibility"
33
+ npm --version
34
+ echo "Required: npm >= 11.5.1 for Trusted Publishing"
35
+ NPM_VERSION=$(npm --version)
36
+ if [ "$(printf '%s\n' "11.5.1" "$NPM_VERSION" | sort -V | head -n1)" != "11.5.1" ]; then
37
+ echo "npm version is too old, upgrading to latest..."
38
+ npm install -g npm@latest
39
+ npm --version
40
+ else
41
+ echo "npm version is compatible"
42
+ fi
43
+ # #endregion
44
+ # #region agent log
45
+ - name: Debug - Check OIDC token availability and workflow context
46
+ run: |
47
+ echo "HYPOTHESIS_A_B_C: Checking OIDC and workflow context"
48
+ echo "Repository: ${{ github.repository }}"
49
+ echo "Expected: MattrAus/odesli.js"
50
+ echo "Workflow ref: ${{ github.workflow_ref }}"
51
+ echo "Workflow file path: .github/workflows/publish-npm.yml"
52
+ echo "Workflow name: ${{ github.workflow }}"
53
+ if [ -n "$ACTIONS_ID_TOKEN_REQUEST_TOKEN" ]; then
54
+ echo "OIDC token request token: SET (length: ${#ACTIONS_ID_TOKEN_REQUEST_TOKEN})"
55
+ else
56
+ echo "OIDC token request token: NOT SET"
57
+ fi
58
+ if [ -n "$ACTIONS_ID_TOKEN_REQUEST_URL" ]; then
59
+ echo "OIDC token request URL: SET"
60
+ else
61
+ echo "OIDC token request URL: NOT SET"
62
+ fi
63
+ # #endregion
28
64
  - name: Install dependencies
29
65
  run: npm ci
30
66
 
@@ -43,7 +79,55 @@ jobs:
43
79
  - name: Update package name for npm
44
80
  run: npm pkg set name="odesli.js"
45
81
 
82
+ # #region agent log
83
+ - name: Debug - Check npm configuration before publish
84
+ run: |
85
+ echo "HYPOTHESIS_D_F: Checking npm configuration and authentication"
86
+ echo "NPM_CONFIG_REGISTRY: ${NPM_CONFIG_REGISTRY:-not set}"
87
+ echo "NPM_CONFIG_USERCONFIG: ${NPM_CONFIG_USERCONFIG:-not set}"
88
+ if [ -f .npmrc ]; then
89
+ echo ".npmrc file exists in repo:"
90
+ cat .npmrc | sed 's/\(.*auth.*\)/REDACTED/'
91
+ else
92
+ echo ".npmrc file does NOT exist in repo"
93
+ fi
94
+ if [ -f "${NPM_CONFIG_USERCONFIG:-/home/runner/work/_temp/.npmrc}" ]; then
95
+ echo ".npmrc file from setup-node exists:"
96
+ cat "${NPM_CONFIG_USERCONFIG:-/home/runner/work/_temp/.npmrc}" | sed 's/\(.*auth.*\)/REDACTED/'
97
+ else
98
+ echo ".npmrc file from setup-node does NOT exist"
99
+ fi
100
+ echo "NODE_AUTH_TOKEN length: ${#NODE_AUTH_TOKEN}"
101
+ echo "Package name: $(node -p "require('./package.json').name")"
102
+ echo "Package version: $(node -p "require('./package.json').version")"
103
+ echo "Checking npm config:"
104
+ npm config list 2>&1 | grep -E "(registry|auth|token)" || echo "No auth config found"
105
+ npm whoami 2>&1 || echo "npm whoami failed (expected if not authenticated)"
106
+ # #endregion
107
+ # #region agent log
108
+ - name: Debug - Verify Trusted Publisher match
109
+ run: |
110
+ echo "HYPOTHESIS_A: Verifying Trusted Publisher configuration match"
111
+ echo "GitHub Repository: ${{ github.repository }}"
112
+ echo "GitHub Workflow: ${{ github.workflow }}"
113
+ echo "GitHub Workflow Ref: ${{ github.workflow_ref }}"
114
+ echo "Expected npm config:"
115
+ echo " Repository: MattrAus/odesli.js"
116
+ echo " Workflow file: publish-npm.yml (or .github/workflows/publish-npm.yml)"
117
+ echo "Actual GitHub values:"
118
+ echo " Repository: ${{ github.repository }}"
119
+ echo " Workflow file path: .github/workflows/publish-npm.yml"
120
+ echo " Workflow name: ${{ github.workflow }}"
121
+ # #endregion
46
122
  - name: Publish to NPM
47
- run: npm publish --access public
48
- env:
49
- NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
123
+ run: |
124
+ echo "HYPOTHESIS_E_FIX: Attempting npm publish with --provenance flag"
125
+ echo "Final npm config check:"
126
+ npm config get registry
127
+ npm config get //registry.npmjs.org/:_authToken 2>&1 | head -c 20 || echo "No auth token in config"
128
+ npm publish --provenance --access public 2>&1 || {
129
+ EXIT_CODE=$?
130
+ echo "npm publish failed with exit code: $EXIT_CODE"
131
+ echo "Error details above"
132
+ exit $EXIT_CODE
133
+ }
package/CHANGELOG.md CHANGED
@@ -7,7 +7,41 @@ All notable changes to this project will be documented in this file.
7
7
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
8
8
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
9
9
 
10
- ## [1.3.7] - 2025-01-27
10
+ ## [1.3.9] - 2025-12-20
11
+
12
+ ### Security
13
+
14
+ - **Dependency Security**: Added npm overrides for js-yaml to fix CVE-2025-64718 (prototype pollution vulnerability)
15
+
16
+ ### Changed
17
+
18
+ - Updated dependencies via npm update
19
+
20
+ ## [1.3.8] - 2025-10-04
21
+
22
+ ### Changed
23
+
24
+ - **Dependency Updates**: Updated multiple development dependencies to their latest compatible versions for improved security and performance
25
+ - Updated `@types/node` from 24.0.13 to 24.6.2
26
+ - Updated `@types/jest` from 30.0.0 (already on latest)
27
+ - Updated `eslint-config-prettier` from 10.1.5 to 10.1.8
28
+ - Updated `eslint-plugin-import` from 2.28.0 to 2.32.0
29
+ - Updated `eslint-plugin-prettier` from 5.5.1 to 5.5.4
30
+ - Updated `jest` from 29.5.0 to 30.2.0 (major version update)
31
+ - Updated `jsdoc` from 4.0.2 to 4.0.4
32
+ - Updated `snyk` from 1.1297.3 to 1.1299.1
33
+ - Updated `ts-jest` from 29.1.0 to 29.4.4
34
+ - Updated `typescript` from 5.0.0 to 5.9.3
35
+
36
+ ### Notes
37
+
38
+ - Kept `eslint` at 8.57.1 (ESLint 9 requires configuration migration)
39
+ - Kept `node-fetch` at 2.7.0 (v3 is ESM-only, incompatible with current CommonJS setup)
40
+ - Kept `eslint-plugin-promise` at 6.6.0 (v7 has peer dependency conflicts with eslint-config-standard)
41
+ - All tests passing with 100% test suite coverage
42
+ - No security vulnerabilities detected
43
+
44
+ ## [1.3.7] - 2025-07-13
11
45
 
12
46
  ### Fixed
13
47
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "odesli.js",
3
- "version": "1.3.7",
3
+ "version": "1.3.9",
4
4
  "description": "Node.js Client to query odesli.co (song.link/album.link) API",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib/index.js",
@@ -66,7 +66,7 @@
66
66
  "url": "https://github.com/MattrAus/odesli.js/issues"
67
67
  },
68
68
  "dependencies": {
69
- "@types/node": "^24.0.13",
69
+ "@types/node": "^24.6.2",
70
70
  "node-fetch": "^2.7.0"
71
71
  },
72
72
  "devDependencies": {
@@ -75,20 +75,23 @@
75
75
  "@types/jest": "^30.0.0",
76
76
  "@types/prettier": "^2.7.3",
77
77
  "eslint": "^8.57.1",
78
- "eslint-config-prettier": "^10.1.5",
78
+ "eslint-config-prettier": "^10.1.8",
79
79
  "eslint-config-standard": "^17.1.0",
80
- "eslint-plugin-import": "^2.28.0",
80
+ "eslint-plugin-import": "^2.32.0",
81
81
  "eslint-plugin-jest": "^29.0.1",
82
82
  "eslint-plugin-node": "^11.1.0",
83
- "eslint-plugin-prettier": "^5.5.1",
83
+ "eslint-plugin-prettier": "^5.5.4",
84
84
  "eslint-plugin-promise": "^6.6.0",
85
- "jest": "^29.5.0",
85
+ "jest": "^30.2.0",
86
86
  "jest-fetch-mock": "^3.0.3",
87
- "jsdoc": "^4.0.2",
87
+ "jsdoc": "^4.0.4",
88
88
  "prettier": "^3.6.2",
89
- "snyk": "^1.1297.3",
90
- "ts-jest": "^29.1.0",
91
- "typescript": "^5.0.0"
89
+ "snyk": "^1.1299.1",
90
+ "ts-jest": "^29.4.4",
91
+ "typescript": "^5.9.3"
92
+ },
93
+ "overrides": {
94
+ "js-yaml": "^4.1.1"
92
95
  },
93
96
  "homepage": "https://github.com/MattrAus/odesli.js#readme"
94
97
  }
@@ -381,7 +381,7 @@ describe('Advanced Features', () => {
381
381
 
382
382
  const summary = metrics.getSummary();
383
383
  expect(summary.counters.totalRequests).toBe(5);
384
- });
384
+ }, 10000);
385
385
 
386
386
  test('should work together - plugins with metrics', async () => {
387
387
  const pluginSystem = new PluginSystem();