Loading
fixup! Bug 40597: Implement TorSettings module
Bug 41710: Move bootstrapping attempts into a new class. We copy the logic from "BootstrappingState" and "AutoBootstrappingState" into "BootstrappingAttempt" and "AutoBootstrappingAttempt". The main difference is that we can do the following: ``` bootstrapAttempt = new BootstrapAttempt(); bootstrapResult = await bootstrapAttempt.run(); // ... bootstrapAttempt.cancel(); ``` rather than using the "StateCallback" class, which requires some complicated state management. Moreover, "AutoBootstrappingAttempt" will use "BootstrappingAttempt" for each of its attempts. So the logic for bootstrapping can be kept in one place. Some other changes: 1. Censorship simulation will no longer necessarily avoid the Moat calls, so these can be tested. 2. It would be possible to perform the internet test when auto-bootstrapping as well. 3. When auto-bootstrapping, if "Bootstrapping" produces an error other than a "BootstrapError", we can end it early. 4. No longer set TorConnect internals. 5. More fine-grained control over censorship simulation and offline simulation.