Skip to content

Instantly share code, notes, and snippets.

$ source ~/.venvs/chaosinteract/bin/activate
(chaosinteract) $ chaos run yorn-interactive-experiment.json
[2019-03-22 16:09:45 INFO] Validating the experiment's syntax
[2019-03-22 16:09:45 WARNING] Could not find Python module 'chaosyorn.control' in control 'prompt'. Did you install the Python module? The experiment will carry on running nonetheless.
[2019-03-22 16:09:45 INFO] Experiment looks valid
[2019-03-22 16:09:45 INFO] Running experiment: A simple sample experiment that can be executed to show controls
[2019-03-22 16:09:45 INFO] Steady state hypothesis: Assess the Steady State ... (not really in this case)
[2019-03-22 16:09:45 INFO] Probe: hypothesis-activity
[2019-03-22 16:09:45 INFO] Steady state hypothesis is met!
[2019-03-22 16:09:45 INFO] Action: dangerous-method-activity
[2019-03-22 16:09:45 INFO] Steady state hypothesis: Assess the Steady State ... (not really in this case)
(chaosinteract) $ pip uninstall chaostoolkit-chaosyorn
Uninstalling chaostoolkit-chaosyorn-0.1.0:
Would remove:
/.../chaostoolkit-chaosyorn.egg-link
Proceed (y/n)? y
Successfully uninstalled chaostoolkit-chaosyorn-0.1.0
(chaosinteract) $ pip install -e .
# -*- coding: utf-8 -*-
from typing import Any, Dict, List
from chaoslib.types import Activity, Configuration, Experiment, Hypothesis, \
Journal, Run, Secrets
from chaoslib.exceptions import InterruptExecution
import click
from logzero import logger
__all__ = ["before_activity_control"]
(chaosinteract) $ chaos run simple-interactive-experiment.json
[2019-03-21 17:00:54 INFO] Validating the experiment's syntax
[2019-03-21 17:00:54 INFO] Experiment looks valid
[2019-03-21 17:00:54 INFO] Running experiment: A simple sample experiment that can be executed to show controls
[2019-03-21 17:00:54 INFO] Steady state hypothesis: Assess the Steady State ... (not really in this case)
Press any key to continue ...
{
"version": "1.0.0",
"title": "A simple sample experiment that can be executed to show controls",
"description": "Does nothing at all other than be executable by the Chaos Toolkit",
"tags": [],
"steady-state-hypothesis": {
"title": "Assess the Steady State ... (not really in this case)",
"probes": [
{
"type": "probe",
pip freeze
...
-e git+git@github.com:chaosiq/chaosiq.git@92da7697cfb40062abe5002f6fdbf70e53c82a92#egg=chaostoolkit_chaossimpleinteract&subdirectory=interactive-controls/sources/simple
...
pip install -e .
# -*- coding: utf-8 -*-
from typing import Any, Dict, List
from chaoslib.types import Activity, Configuration, Experiment, Hypothesis, \
Journal, Run, Secrets
# from chaoslib.exception import InterruptActivity
import click
from logzero import logger
__all__ = ["before_activity_control"]