mediasoup 3.12.2 → 3.12.3

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.
@@ -90,7 +90,7 @@ class Worker extends EnhancedEventEmitter_1.EnhancedEventEmitter {
90
90
  // options
91
91
  {
92
92
  env: {
93
- MEDIASOUP_VERSION: '3.12.2',
93
+ MEDIASOUP_VERSION: '3.12.3',
94
94
  // Let the worker process inherit all environment variables, useful
95
95
  // if a custom and not in the path GCC is used so the user can set
96
96
  // LD_LIBRARY_PATH environment variable for runtime.
@@ -10,7 +10,7 @@ export { types };
10
10
  /**
11
11
  * Expose mediasoup version.
12
12
  */
13
- export declare const version = "3.12.2";
13
+ export declare const version = "3.12.3";
14
14
  /**
15
15
  * Expose parseScalabilityMode() function.
16
16
  */
package/node/lib/index.js CHANGED
@@ -11,7 +11,7 @@ exports.types = types;
11
11
  /**
12
12
  * Expose mediasoup version.
13
13
  */
14
- exports.version = '3.12.2';
14
+ exports.version = '3.12.3';
15
15
  /**
16
16
  * Expose parseScalabilityMode() function.
17
17
  */
@@ -1,9 +1,9 @@
1
- const process = require('process');
2
- const os = require('os');
3
- const fs = require('fs');
4
- const { execSync, spawnSync } = require('child_process');
5
- const fetch = require('node-fetch');
6
- const tar = require('tar');
1
+ import process from 'process';
2
+ import os from 'os';
3
+ import fs from 'fs';
4
+ import { execSync, spawnSync } from 'child_process';
5
+ import fetch from 'node-fetch';
6
+ import tar from 'tar';
7
7
 
8
8
  const PKG = JSON.parse(fs.readFileSync('./package.json').toString());
9
9
  const IS_FREEBSD = os.platform() === 'freebsd';
@@ -98,8 +98,8 @@ async function run()
98
98
 
99
99
  case 'typescript:watch':
100
100
  {
101
- // NOTE: Load dep here since it's a devDependency.
102
- const { TscWatchClient } = require('tsc-watch/client');
101
+ // NOTE: Load dep on demand since it's a devDependency.
102
+ const { TscWatchClient } = await import('tsc-watch/client.js');
103
103
 
104
104
  const watch = new TscWatchClient();
105
105
 
@@ -200,8 +200,8 @@ async function run()
200
200
 
201
201
  try
202
202
  {
203
- octokit = getOctokit();
204
- versionChanges = getVersionChanges();
203
+ octokit = await getOctokit();
204
+ versionChanges = await getVersionChanges();
205
205
  }
206
206
  catch (error)
207
207
  {
@@ -357,7 +357,7 @@ function lintNode()
357
357
  {
358
358
  logInfo('lintNode()');
359
359
 
360
- executeCmd('eslint -c node/.eslintrc.js --max-warnings 0 node/src node/.eslintrc.js npm-scripts.js worker/scripts/gulpfile.js');
360
+ executeCmd('eslint -c node/.eslintrc.js --max-warnings 0 node/src node/.eslintrc.js npm-scripts.mjs worker/scripts/gulpfile.js');
361
361
  }
362
362
 
363
363
  function lintWorker()
@@ -599,7 +599,7 @@ async function uploadMacArmPrebuiltWorker()
599
599
  return;
600
600
  }
601
601
 
602
- const octokit = getOctokit();
602
+ const octokit = await getOctokit();
603
603
 
604
604
  logInfo('uploadMacArmPrebuiltWorker() | getting release info');
605
605
 
@@ -623,15 +623,15 @@ async function uploadMacArmPrebuiltWorker()
623
623
  });
624
624
  }
625
625
 
626
- function getOctokit()
626
+ async function getOctokit()
627
627
  {
628
628
  if (!process.env.GITHUB_TOKEN)
629
629
  {
630
630
  throw new Error('missing GITHUB_TOKEN environment variable');
631
631
  }
632
632
 
633
- // NOTE: Load dep here since it's a devDependency.
634
- const { Octokit } = require('@octokit/rest');
633
+ // NOTE: Load dep on demand since it's a devDependency.
634
+ const { Octokit } = await import('@octokit/rest');
635
635
 
636
636
  const octokit = new Octokit(
637
637
  {
@@ -641,12 +641,12 @@ function getOctokit()
641
641
  return octokit;
642
642
  }
643
643
 
644
- function getVersionChanges()
644
+ async function getVersionChanges()
645
645
  {
646
646
  logInfo('getVersionChanges()');
647
647
 
648
- // NOTE: Load dep here since it's a devDependency.
649
- const marked = require('marked');
648
+ // NOTE: Load dep on demand since it's a devDependency.
649
+ const marked = await import('marked');
650
650
 
651
651
  const changelog = fs.readFileSync('./CHANGELOG.md').toString();
652
652
  const entries = marked.lexer(changelog);
@@ -692,19 +692,19 @@ function executeCmd(command, exitOnError = true)
692
692
  function logInfo(message)
693
693
  {
694
694
  // eslint-disable-next-line no-console
695
- console.log(`npm-scripts.js \x1b[36m[INFO] [${task}]\x1b\[0m`, message);
695
+ console.log(`npm-scripts \x1b[36m[INFO] [${task}]\x1b\[0m`, message);
696
696
  }
697
697
 
698
698
  function logWarn(message)
699
699
  {
700
700
  // eslint-disable-next-line no-console
701
- console.warn(`npm-scripts.js \x1b[33m[WARN] [${task}]\x1b\[0m`, message);
701
+ console.warn(`npm-scripts \x1b[33m[WARN] [${task}]\x1b\[0m`, message);
702
702
  }
703
703
 
704
704
  function logError(message)
705
705
  {
706
706
  // eslint-disable-next-line no-console
707
- console.error(`npm-scripts.js \x1b[31m[ERROR] [${task}]\x1b\[0m`, message);
707
+ console.error(`npm-scripts \x1b[31m[ERROR] [${task}]\x1b\[0m`, message);
708
708
  }
709
709
 
710
710
  function exitWithError()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mediasoup",
3
- "version": "3.12.2",
3
+ "version": "3.12.3",
4
4
  "description": "Cutting Edge WebRTC Video Conferencing",
5
5
  "contributors": [
6
6
  "Iñaki Baz Castillo <ibc@aliax.net> (https://inakibaz.me)",
@@ -36,7 +36,7 @@
36
36
  "worker/Makefile",
37
37
  "worker/meson.build",
38
38
  "worker/meson_options.txt",
39
- "npm-scripts.js"
39
+ "npm-scripts.mjs"
40
40
  ],
41
41
  "keywords": [
42
42
  "webrtc",
@@ -48,25 +48,25 @@
48
48
  "node": ">=16"
49
49
  },
50
50
  "scripts": {
51
- "prepare": "node npm-scripts.js prepare",
52
- "postinstall": "node npm-scripts.js postinstall",
53
- "typescript:build": "node npm-scripts.js typescript:build",
54
- "typescript:watch": "node npm-scripts.js typescript:watch",
55
- "worker:build": "node npm-scripts.js worker:build",
56
- "worker:prebuild": "node npm-scripts.js worker:prebuild",
51
+ "prepare": "node npm-scripts.mjs prepare",
52
+ "postinstall": "node npm-scripts.mjs postinstall",
53
+ "typescript:build": "node npm-scripts.mjs typescript:build",
54
+ "typescript:watch": "node npm-scripts.mjs typescript:watch",
55
+ "worker:build": "node npm-scripts.mjs worker:build",
56
+ "worker:prebuild": "node npm-scripts.mjs worker:prebuild",
57
57
  "lint": "npm run lint:node && npm run lint:worker",
58
- "lint:node": "node npm-scripts.js lint:node",
59
- "lint:worker": "node npm-scripts.js lint:worker",
60
- "format:worker": "node npm-scripts.js format:worker",
58
+ "lint:node": "node npm-scripts.mjs lint:node",
59
+ "lint:worker": "node npm-scripts.mjs lint:worker",
60
+ "format:worker": "node npm-scripts.mjs format:worker",
61
61
  "test": "npm run test:node && npm run test:worker",
62
- "test:node": "node npm-scripts.js test:node",
63
- "test:worker": "node npm-scripts.js test:worker",
64
- "coverage:node": "node npm-scripts.js coverage:node",
65
- "install-deps:node": "node npm-scripts.js install-deps:node",
66
- "install-clang-tools": "node npm-scripts.js install-clang-tools",
67
- "release:check": "node npm-scripts.js release:check",
68
- "release": "node npm-scripts.js release",
69
- "release:upload-mac-arm-prebuilt-worker": "node npm-scripts.js release:upload-mac-arm-prebuilt-worker"
62
+ "test:node": "node npm-scripts.mjs test:node",
63
+ "test:worker": "node npm-scripts.mjs test:worker",
64
+ "coverage:node": "node npm-scripts.mjs coverage:node",
65
+ "install-deps:node": "node npm-scripts.mjs install-deps:node",
66
+ "install-clang-tools": "node npm-scripts.mjs install-clang-tools",
67
+ "release:check": "node npm-scripts.mjs release:check",
68
+ "release": "node npm-scripts.mjs release",
69
+ "release:upload-mac-arm-prebuilt-worker": "node npm-scripts.mjs release:upload-mac-arm-prebuilt-worker"
70
70
  },
71
71
  "jest": {
72
72
  "verbose": true,
@@ -89,7 +89,7 @@
89
89
  "dependencies": {
90
90
  "debug": "^4.3.4",
91
91
  "h264-profile-level-id": "^1.0.1",
92
- "node-fetch": "^2.6.11",
92
+ "node-fetch": "^3.3.1",
93
93
  "supports-color": "^9.3.1",
94
94
  "tar": "^6.1.15",
95
95
  "uuid": "^9.0.0"
@@ -98,7 +98,7 @@
98
98
  "@octokit/rest": "^19.0.11",
99
99
  "@types/debug": "^4.1.8",
100
100
  "@types/jest": "^29.5.1",
101
- "@types/node": "^18.15.11",
101
+ "@types/node": "^20.2.5",
102
102
  "@types/uuid": "^9.0.1",
103
103
  "@typescript-eslint/eslint-plugin": "^5.59.7",
104
104
  "@typescript-eslint/parser": "^5.59.7",