diff --git a/.github/workflows/static.yml b/.github/workflows/static.yml index 646bab7..1dbe541 100644 --- a/.github/workflows/static.yml +++ b/.github/workflows/static.yml @@ -2,9 +2,10 @@ name: Deploy static content to Pages on: - # Runs on pushes targeting the default branch push: - branches: ["master"] + # Pattern matched against refs/tags + tags: + - '**' # Allows you to run this workflow manually from the Actions tab workflow_dispatch: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index c7186fc..af62146 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,5 +1,5 @@ # Simple workflow for deploying static content to GitHub Pages -name: Deploy static content to Pages +name: Run pytest on: # Runs on pushes targeting the default branch diff --git a/CHANGELOG.md b/CHANGELOG.md index bb65c40..cc9bcda 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,17 +4,20 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## Unreleased +## [0.3.1] +### Added +- documentation with mkdocs + ### Fixed - CLI new-config-file handle error when directory does not exist. ## [0.3.0] - 2024-03-19 -### Adding +### Added - Allow editing configs for a given block - Methods to allow resetting participant state to allow the above work - CLI option to generate new config -### Changing +### Changed - Allow managing multiple participants - Generated output can be written to stdout - Renamed endpoints @@ -23,46 +26,46 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Config displayed as table - Update UI to manage multiple participants - Uses htmx & alpine -- Adding aliases to commands +- Added aliases to commands ## [0.2.6] - 2023-08-28 -### Adding +### Added - Web ui: Adding refresh button and poll every min ## [0.2.5] - 2023-08-28 -### Changing +### Changed - Web UI: - Using htmx - Show status - Returned json from server is formatted -### Adding +### Added - `block-id` and `status-string` to api ## [0.2.4] - 2022-11-15 -### Changing +### Changed - Fix - GET method crashing when getting second parameter meant for POST methods - Fix - `extends` not working with names not in `order` - Fix - (#1) modification watcher failing when reloading config fails - Fix - `group` ordering not used when flat array is used in `order` -### Adding +### Added - Dev tools (debugger and static analyzer) ## [0.2.3] - 2022-10-09 -### Changing +### Changed - Fix call order in cli ## [0.2.2] - 2022-10-09 -### Adding +### Added - Allow setting random seed in toml config - Function calls within configs -### Removing +### Removed - Removed `base_config.expconfig` in static folder and references to it. ## [0.2.1] - 2022-08-31 -### Adding +### Added - Generate json files based on config file from cli - Get complete config (in server, client and experiment) - Watchdog to reload config when it's modified @@ -74,7 +77,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Refactor - moved `GlobalState` to `_api` ## [0.2] - 2022-08-26 -### Adding +### Added - `Experiment` class to allow loading and managing script locally. - toml based configurations. - `-i/--participant-index` as cli option for `run` @@ -85,7 +88,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Fixed same condition being reused causing issues with `resolve_extends` as the reused dicts are references. ## [0.1] - 2022-08-25 -### Adding +### Added - Change log - Adding functions to process `extends`. - `Utils.merge_dicts` diff --git a/README.md b/README.md index 00be502..a0c880f 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,8 @@ This is a Python application that allows you to create/maintain/manage study configurations away from your implementations. `experiment-server` has several different interfaces (see below) to allow using it in a range of different scenarios. I've used it with Python, js and [Unity projects](https://github.com/ahmed-shariff/experiment_server/wiki/Using-with-Unity). See the [wiki](https://github.com/ahmed-shariff/experiment_server/wiki) for examples. +Documentation is available at [https://shariff-faleel.com/experiment_server/](https://shariff-faleel.com/experiment_server/) + # Content - [Overview](#overview) diff --git a/pyproject.toml b/pyproject.toml index 374356c..6b1203e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [tool.poetry] name = "experiment_server" -version = "0.3.0" +version = "0.3.2" description = "Server for experiments to get configuarations from" license = "MIT" @@ -11,6 +11,9 @@ authors = ["Ahmed Shariff "] readme = "README.md" keywords = [ "experiment", "study-design" ] +homepage = "https://shariff-faleel.com/experiment_server/" +documentation = "https://shariff-faleel.com/experiment_server/documentation/" +repository = "https://github.com/ahmed-shariff/experiment_server" classifiers = [ "Development Status :: 1 - Planning", diff --git a/test/test_api.py b/test/test_api.py index ca0dfa1..0d55ccc 100644 --- a/test/test_api.py +++ b/test/test_api.py @@ -69,12 +69,12 @@ def test_block_through_all(self, experiment, exp_config): ret = experiment.get_config() assert ret["name"] == c["name"], c["name"] - def test_reset_config(self, experiment): + def test_reset_participant(self, experiment): _ = experiment.move_to_block(0) experiment.global_state[experiment.default_participant_index].config[0]["config"]["foo"] = "bar" output = experiment.get_config() assert "foo" in output - experiment.reset_config() + experiment.reset_participant() output = experiment.get_config() assert "foo" not in output