-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Initialize poc solver submission * use https://github.com/yxtay/python-project-template template * cleanup template * initialization with poetry * Test validation command * [submission] validate, show, submission dir tests * only python 3.11 * Add direct link for creating new submission * Execute generation in poetry environement * Add missing fields List existing track, division, logic * Pretty print participations of the solver * Add conversion from csv and json schema dump * Add sub command for downloading benchmarks Not tested since server are unavailable * Add download, fix convertion, benchexec * Exclude archive and web from black linting. * Fix extra html tag. * Fix typo. * Add ignore file for prettier. * Blackify. * Fix formatting in archive. * Fix end of files in archive. * List all the web files. * Fix benchexec * Fix csv conversion and use solver final * Compatibility with starexec - One tool module installed with smtcomp - redefine unpack_archive to keep executable bit - in compa_starexec mode execute locally the script with bash (some script don't have #!) * Add a target for running hugo server * Precise the pip to install for generating the doc * Fxi last commit * Add the configuration cache into the code to avoid internet requirements * Add trivia benchmark generator - static cache of configuration of starexec - instructions for using the commands * Add submission instructions and schema. --------- Co-authored-by: Martin Jonáš <martin.jonas@mail.muni.cz> Co-authored-by: Martin Jonas <mjonas@fbk.eu>
- Loading branch information
1 parent
d664ce3
commit f0f743e
Showing
2,653 changed files
with
44,016 additions
and
42,643 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// For format details, see https://aka.ms/devcontainer.json. For config options, see the | ||
// README at: https://github.com/devcontainers/templates/tree/main/src/python | ||
{ | ||
"name": "smtcomp", | ||
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile | ||
"image": "mcr.microsoft.com/devcontainers/python:1-3.11-bullseye", | ||
"features": { | ||
"ghcr.io/devcontainers-contrib/features/poetry:2": {} | ||
}, | ||
|
||
// Use 'postCreateCommand' to run commands after the container is created. | ||
"postCreateCommand": "./.devcontainer/postCreateCommand.sh", | ||
|
||
// Configure tool-specific properties. | ||
"customizations": { | ||
"vscode": { | ||
"extensions": ["ms-python.python", "editorconfig.editorconfig"], | ||
"settings": { | ||
"python.testing.pytestArgs": ["tests"], | ||
"python.testing.unittestEnabled": false, | ||
"python.testing.pytestEnabled": true, | ||
"python.defaultInterpreterPath": "/workspaces/smtcomp/.venv/bin/python", | ||
"python.testing.pytestPath": "/workspaces/smtcomp/.venv/bin/pytest" | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#! /usr/bin/env bash | ||
|
||
# Install Dependencies | ||
poetry install --with dev | ||
|
||
# Install pre-commit hooks | ||
poetry run pre-commit install --install-hooks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
max_line_length = 120 | ||
|
||
[*.json] | ||
indent_style = space | ||
indent_size = 4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: "setup-poetry-env" | ||
description: "Composite action to setup the Python and poetry environment." | ||
|
||
inputs: | ||
python-version: | ||
required: false | ||
description: "The python version to use" | ||
default: "3.11" | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Set up python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ inputs.python-version }} | ||
|
||
- name: Install Poetry | ||
uses: snok/install-poetry@v1 | ||
with: | ||
virtualenvs-in-project: true | ||
|
||
- name: Load cached venv | ||
id: cached-poetry-dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: .venv | ||
key: venv-${{ runner.os }}-${{ inputs.python-version }}-${{ hashFiles('poetry.lock') }} | ||
|
||
- name: Install dependencies | ||
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true' | ||
run: poetry install --no-interaction | ||
shell: bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
name: Main | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
types: [opened, synchronize, reopened] | ||
|
||
jobs: | ||
quality: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out | ||
uses: actions/checkout@v3 | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: ~/.cache/pre-commit | ||
key: pre-commit-${{ hashFiles('.pre-commit-config.yaml') }} | ||
|
||
- name: Set up the environment | ||
uses: ./.github/actions/setup-poetry-env | ||
|
||
- name: Compute changed files | ||
id: changed-files | ||
uses: tj-actions/changed-files@v40 | ||
with: | ||
files: | | ||
submissions/*.json | ||
- name: Show changed files | ||
run: | | ||
for file in ${{ steps.changed-files.outputs.all_changed_files }}; do | ||
poetry run smtcomp show $file | ||
done | ||
- name: Run checks | ||
run: make check | ||
|
||
tox: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: ["3.11"] | ||
fail-fast: false | ||
steps: | ||
- name: Check out | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install Poetry | ||
uses: snok/install-poetry@v1 | ||
|
||
- name: Load cached venv | ||
uses: actions/cache@v3 | ||
with: | ||
path: .tox | ||
key: venv-${{ runner.os }}-${{ matrix.python-version }}-${{ hashFiles('poetry.lock') }} | ||
|
||
- name: Install tox | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install tox tox-gh-actions | ||
- name: Test with tox | ||
run: tox | ||
|
||
- name: Upload coverage reports to Codecov with GitHub Action on Python 3.11 | ||
uses: codecov/codecov-action@v3 | ||
if: ${{ matrix.python-version == '3.11' }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
name: validate-codecov-config | ||
|
||
on: | ||
pull_request: | ||
paths: [codecov.yaml] | ||
push: | ||
branches: [main] | ||
|
||
jobs: | ||
validate-codecov-config: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Validate codecov configuration | ||
run: curl -sSL --fail-with-body --data-binary @codecov.yaml https://codecov.io/validate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,172 @@ | ||
Makefile | ||
_site | ||
Gemfile | ||
Gemfile.lock | ||
howto-serve | ||
*.swp | ||
bin | ||
docs/source | ||
|
||
# From https://raw.githubusercontent.com/github/gitignore/main/Python.gitignore | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
wheels/ | ||
share/python-wheels/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
MANIFEST | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.nox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*.cover | ||
*.py,cover | ||
.hypothesis/ | ||
.pytest_cache/ | ||
cover/ | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
local_settings.py | ||
db.sqlite3 | ||
db.sqlite3-journal | ||
|
||
# Flask stuff: | ||
instance/ | ||
.webassets-cache | ||
|
||
# Scrapy stuff: | ||
.scrapy | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# PyBuilder | ||
.pybuilder/ | ||
target/ | ||
|
||
# Jupyter Notebook | ||
.ipynb_checkpoints | ||
|
||
# IPython | ||
profile_default/ | ||
ipython_config.py | ||
|
||
# pyenv | ||
# For a library or package, you might want to ignore these files since the code is | ||
# intended to run in multiple environments; otherwise, check them in: | ||
# .python-version | ||
|
||
# pipenv | ||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. | ||
# However, in case of collaboration, if having platform-specific dependencies or dependencies | ||
# having no cross-platform support, pipenv may install dependencies that don't work, or not | ||
# install all needed dependencies. | ||
#Pipfile.lock | ||
|
||
# poetry | ||
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. | ||
# This is especially recommended for binary packages to ensure reproducibility, and is more | ||
# commonly ignored for libraries. | ||
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control | ||
#poetry.lock | ||
|
||
# pdm | ||
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. | ||
#pdm.lock | ||
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it | ||
# in version control. | ||
# https://pdm.fming.dev/#use-with-ide | ||
.pdm.toml | ||
|
||
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm | ||
__pypackages__/ | ||
|
||
# Celery stuff | ||
celerybeat-schedule | ||
celerybeat.pid | ||
|
||
# SageMath parsed files | ||
*.sage.py | ||
|
||
# Environments | ||
.env | ||
.venv | ||
env/ | ||
venv/ | ||
ENV/ | ||
env.bak/ | ||
venv.bak/ | ||
|
||
# Spyder project settings | ||
.spyderproject | ||
.spyproject | ||
|
||
# Rope project settings | ||
.ropeproject | ||
|
||
# mkdocs documentation | ||
/site | ||
|
||
# mypy | ||
.mypy_cache/ | ||
.dmypy.json | ||
dmypy.json | ||
|
||
# Pyre type checker | ||
.pyre/ | ||
|
||
# pytype static type analyzer | ||
.pytype/ | ||
|
||
# Cython debug symbols | ||
cython_debug/ | ||
|
||
# Vscode config files | ||
.vscode/ | ||
|
||
# PyCharm | ||
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can | ||
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore | ||
# and can be added to the global gitignore or merged into this file. For a more nuclear | ||
# option (not recommended) you can uncomment the following to ignore the entire idea folder. | ||
#.idea/ | ||
|
||
/submission-schema.json | ||
/submission-schema.html | ||
schema_doc.css | ||
schema_doc.min.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: "v4.4.0" | ||
hooks: | ||
- id: check-case-conflict | ||
- id: check-merge-conflict | ||
- id: check-toml | ||
- id: check-yaml | ||
- id: end-of-file-fixer | ||
- id: trailing-whitespace | ||
|
||
# - repo: https://github.com/astral-sh/ruff-pre-commit | ||
# # Ruff version. | ||
# rev: v0.2.1 | ||
# hooks: | ||
# # Run the linter. | ||
# - id: ruff | ||
|
||
- repo: https://github.com/psf/black | ||
rev: "24.1.1" | ||
hooks: | ||
- id: black | ||
|
||
- repo: https://github.com/pre-commit/mirrors-prettier | ||
rev: "v3.0.3" | ||
hooks: | ||
- id: prettier |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
archive | ||
_site | ||
web/themes/smtcomp/layouts/ |
Oops, something went wrong.