[COMPASS-7314] [Remove Platform Specific] Replace usage of global Node.js methods Created: 09/Oct/23  Updated: 07/Nov/23  Resolved: 11/Oct/23

Status: Closed
Project: Compass
Component/s: None
Affects Version/s: None
Fix Version/s: 1.40.4

Type: Task Priority: Major - P3
Reporter: Anna Henningsen Assignee: Anna Henningsen
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: COMPASS-7020
Story Points: 2
Documentation Changes: Not Needed
Sprint: Iteration Lambeosaurus, Iteration Minmi

 Comments   
Comment by Githook User [ 23/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna.henningsen@mongodb.com', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314 (#4974)

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: COMPASS-7308
https://github.com/mongodb-js/compass/commit/6f2aed093ac068de248315f28c6d2c5aaa86e479

Comment by Githook User [ 17/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna.henningsen@mongodb.com', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314 (#4974)

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: ga-releases
https://github.com/mongodb-js/compass/commit/6f2aed093ac068de248315f28c6d2c5aaa86e479

Comment by Githook User [ 17/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna.henningsen@mongodb.com', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314 (#4974)

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: investigate-update-preview
https://github.com/mongodb-js/compass/commit/6f2aed093ac068de248315f28c6d2c5aaa86e479

Comment by Githook User [ 16/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna.henningsen@mongodb.com', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314 (#4974)

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: beta-releases
https://github.com/mongodb-js/compass/commit/6f2aed093ac068de248315f28c6d2c5aaa86e479

Comment by Githook User [ 12/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna.henningsen@mongodb.com', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314 (#4974)

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: COMPASS-7292-run-ai-accuracy-tests
https://github.com/mongodb-js/compass/commit/6f2aed093ac068de248315f28c6d2c5aaa86e479

Comment by Githook User [ 11/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna.henningsen@mongodb.com', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314 (#4974)

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: main
https://github.com/mongodb-js/compass/commit/6f2aed093ac068de248315f28c6d2c5aaa86e479

Comment by Githook User [ 10/Oct/23 ]

Author:

{'name': 'Anna Henningsen', 'email': 'anna@addaleax.net', 'username': 'addaleax'}

Message: chore: avoid process.nextTick() and setImmediate() COMPASS-7314

Replace, or where unused remove, usage of `process.nextTick()`
and `setImmediate()`, both of which are Node.js-specific APIs
for async deferral for which browser-compatible replacements with
near-identical behavior exist.

Add linting rules to prevent usage of these methods. There might be
a way to scope these linting rules to only the packages that we
intend to use in browser environments, or exclude them from applying
to test files. However, that seems unnecessary, given that the
replacements are no harder to use, so a consistent style across
the entire Compass codebase seems preferable.
Branch: 7314-dev
https://github.com/mongodb-js/compass/commit/502e8b389d2fb12c975e4f53cc9bb70f46480309

Generated at Wed Feb 07 22:46:08 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.