triangle-utils 1.4.109 → 1.4.111

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.
@@ -22,7 +22,7 @@ export class UtilsMisc {
22
22
  return undefined;
23
23
  }
24
24
  async iterate(inputs, f, options = {}) {
25
- const num_iterators = options.num_iterators || 0;
25
+ const num_iterators = options.num_iterators || 1;
26
26
  const verbosity = typeof options.verbosity === "boolean" ? (options.verbosity === true ? 1 : 0) : (options.verbosity || 0);
27
27
  let index = 0;
28
28
  let iterators = [];
@@ -45,7 +45,7 @@ export class UtilsMisc {
45
45
  }
46
46
  async batch_iterate(inputs, f, options) {
47
47
  const batch_size = options.batch_size || 1;
48
- const num_iterators = options.num_iterators || 0;
48
+ const num_iterators = options.num_iterators || 1;
49
49
  const verbosity = typeof options.verbosity === "boolean" ? (options.verbosity === true ? 1 : 0) : (options.verbosity || 0);
50
50
  let index = 0;
51
51
  let iterators = [];
@@ -3,6 +3,7 @@ export declare class GlobalConfig {
3
3
  readonly cognito_user_pool_id: string;
4
4
  readonly secret_key: string;
5
5
  readonly auth_url: string;
6
+ readonly s3_triangle: string;
6
7
  readonly s3_elections: string;
7
8
  readonly s3_prism: string;
8
9
  readonly s3_scout: string;
@@ -3,6 +3,7 @@ export class GlobalConfig {
3
3
  cognito_user_pool_id;
4
4
  secret_key;
5
5
  auth_url;
6
+ s3_triangle;
6
7
  s3_elections;
7
8
  s3_prism;
8
9
  s3_scout;
@@ -22,6 +23,7 @@ export class GlobalConfig {
22
23
  this.cognito_user_pool_id = global_config.cognito_user_pool_id;
23
24
  this.secret_key = global_config.secret_key;
24
25
  this.auth_url = global_config.auth_url;
26
+ this.s3_triangle = global_config.s3_triangle;
25
27
  this.s3_elections = global_config.s3_elections;
26
28
  this.s3_prism = global_config.s3_prism;
27
29
  this.s3_scout = global_config.s3_scout;
@@ -40,6 +42,7 @@ export class GlobalConfig {
40
42
  typeof global_config.cognito_user_pool_id === "string" &&
41
43
  typeof global_config.secret_key === "string" &&
42
44
  typeof global_config.auth_url === "string" &&
45
+ typeof global_config.s3_triangle === "string" &&
43
46
  typeof global_config.s3_elections === "string" &&
44
47
  typeof global_config.s3_prism === "string" &&
45
48
  typeof global_config.s3_scout === "string" &&
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-utils",
3
- "version": "1.4.109",
3
+ "version": "1.4.111",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "directories": {
package/src/UtilsMisc.ts CHANGED
@@ -32,7 +32,7 @@ export class UtilsMisc {
32
32
  }
33
33
 
34
34
  async iterate<T, U>(inputs : T[], f : (input : T, iterator_id : number, index : number) => Promise<U>, options : { num_iterators? : number, verbosity? : number | boolean } = {}) {
35
- const num_iterators = options.num_iterators || 0
35
+ const num_iterators = options.num_iterators || 1
36
36
  const verbosity : number = typeof options.verbosity === "boolean" ? (options.verbosity === true ? 1 : 0) : (options.verbosity || 0)
37
37
  let index = 0
38
38
  let iterators = []
@@ -57,7 +57,7 @@ export class UtilsMisc {
57
57
  async batch_iterate<T, U>(inputs : T[], f : (inputs : T[], iterator_id : number, index : number) => Promise<U>,
58
58
  options : { batch_size? : number, num_iterators? : number, verbosity? : number | boolean }) {
59
59
  const batch_size = options.batch_size || 1
60
- const num_iterators = options.num_iterators || 0
60
+ const num_iterators = options.num_iterators || 1
61
61
  const verbosity : number = typeof options.verbosity === "boolean" ? (options.verbosity === true ? 1 : 0) : (options.verbosity || 0)
62
62
  let index = 0
63
63
  let iterators = []
@@ -3,6 +3,7 @@ export class GlobalConfig {
3
3
  readonly cognito_user_pool_id : string
4
4
  readonly secret_key : string
5
5
  readonly auth_url : string
6
+ readonly s3_triangle : string
6
7
  readonly s3_elections : string
7
8
  readonly s3_prism : string
8
9
  readonly s3_scout : string
@@ -24,6 +25,7 @@ export class GlobalConfig {
24
25
  this.cognito_user_pool_id = global_config.cognito_user_pool_id
25
26
  this.secret_key = global_config.secret_key
26
27
  this.auth_url = global_config.auth_url
28
+ this.s3_triangle = global_config.s3_triangle
27
29
  this.s3_elections = global_config.s3_elections
28
30
  this.s3_prism = global_config.s3_prism
29
31
  this.s3_scout = global_config.s3_scout
@@ -44,6 +46,7 @@ export class GlobalConfig {
44
46
  typeof global_config.cognito_user_pool_id === "string" &&
45
47
  typeof global_config.secret_key === "string" &&
46
48
  typeof global_config.auth_url === "string" &&
49
+ typeof global_config.s3_triangle === "string" &&
47
50
  typeof global_config.s3_elections === "string" &&
48
51
  typeof global_config.s3_prism === "string" &&
49
52
  typeof global_config.s3_scout === "string" &&