Loading
Commits on Source 20
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Use actual private members in InternetTest, and unify the test and testAsync methods.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. The purpose of this commit is just to make the review easier. It moves the various state callbacks in another part of the file (and gives them names, to refer to them). They are not linted/formatted on purpose, to allow checking that the changes are minimal with the `--color-moved` option.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. The purpose of this commit is just to make the review easier. It lints the previous commit to make it closer to the next form it will take. To review this commit, you can lint TorConnect.sys.mjs and check you obtain the same result.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Add a specialized class for every state. Removed TorConnectStateTransitions and store the valid transitions inside the new classes.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Removes the context from StateCallback. Instead, we will always initialize new objects.
-
Pier Angelo Vendrame authored
Bug 41114: Fix no-async-promise-executor on TorConnect. Move the responsibility of starting the next state callback and broadcat the state change from the begin function to the transition function. This is what will actually empower us to remove the async promise executor, because they will not have to block the state change anymore.
-
Pier Angelo Vendrame authored
Bug 41114: Fix no-async-promise-executor on TorConnect. Now that callbacks have been lifted from the responsibility of blocking the transition, they do not have to explicitly resolve anymore. So, get rid of the various promises, and make the old callbacks regular methods of the corresponding classes. Also, updated the documentation.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Add the changeState method to StateCallback, other minor changes.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Move some parts of BootstrappingState.run to methods on their own, to make it easier to understand this function.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Various refactors to AutoBootstrappingState.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. TorConnect does not need to be defined in a function.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. First batch of changes requested in the review.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. More changes on the InternetTest class.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Additional refactor to the AutoBootstrappingState: split the run in more methods, removed some layers of try-catch.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Additional refactor to the AutoBootstrappingState: be consistent in initializing private members and document that in case of race some variables might be set to undefined. Also, do not store the bootstrap as a member, to avoid possible race conditions.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. When simulating censorship, do not trigger an additional change of state if one is already happening.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Check if the current state is already transitioning, and refusing any additional transition request.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Do not await TorSettings.applySettings after a successfull bootstrap. Instead, we use .catch and log any unexpected results.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Ignore cancel requests when in non-bootstrapping states.
-
Pier Angelo Vendrame authored
Bug 41114: Refactor TorConnect. Pass only the new state's name to StateCallback.end.