[NPMCLI-145] Refactor code with Promises to avoid async issues Created: 16/Nov/17 Updated: 25/Mar/22 |
|
| Status: | Open |
| Project: | Magnolia CLI |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Neutral |
| Reporter: | Federico Grilli | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Template: |
|
||||||||
| Acceptance criteria: |
Empty
|
||||||||
| Task DoR: |
Empty
|
||||||||
| Description |
|
There are some places in the CLI codebase where we should synchronise code execution (due to Node.js single-threaded, async nature), certain operations needing to be run only after others are done. This can be achieved either with callbacks or better with ES6 (latest Javascript) Promises. First evaluate, and estimate how much work it would be to switch to promises. Discuss with PXM, and we'll decide whether to keep in v 3 release or postpone. |