-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit b028a0b
Showing
55 changed files
with
5,774 additions
and
0 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,22 @@ | ||
# Changes here will be overwritten by Copier | ||
_commit: 1.2.6 | ||
_src_path: gh:pawamoy/copier-pdm | ||
author_email: bernardo@impulsogov.org | ||
author_fullname: Bernardo Chrispim Baron | ||
author_username: bcbernardo | ||
copyright_date: '2024' | ||
copyright_holder: ImpulsoGov | ||
copyright_holder_email: contato@impulsogov.org | ||
copyright_license: MIT License | ||
insiders: false | ||
project_description: A stochastic model of the natural history and effects of vaccination | ||
and screening in the progression of Human Papillomavirus infections and cervical | ||
precancer lesions and invasive cancers. | ||
project_name: HPV Progression Model | ||
python_package_command_line_name: hpv-model | ||
python_package_distribution_name: hpv_progression_model | ||
python_package_import_name: hpv_progression_model | ||
repository_name: hpv-progression-model | ||
repository_namespace: ImpulsoGov | ||
repository_provider: github.com | ||
|
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,4 @@ | ||
github: bcbernardo | ||
ko_fi: bcbernardo | ||
custom: | ||
- https://www.paypal.me/bcbernardo |
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,61 @@ | ||
--- | ||
name: Bug report | ||
about: Create a bug report to help us improve. | ||
title: "bug: " | ||
labels: unconfirmed | ||
assignees: [pawamoy] | ||
--- | ||
|
||
### Description of the bug | ||
<!-- Please provide a clear and concise description of what the bug is. --> | ||
|
||
### To Reproduce | ||
<!-- Please provide a Minimal Reproducible Example (MRE) if possible. | ||
Try to boil down the problem to a few lines of code. | ||
Your code should run by simply copying and pasting it. | ||
Example: | ||
``` | ||
git clone https://github.com/username/repro | ||
cd repro | ||
python -m venv .venv | ||
. .venv/bin/activate | ||
pip install -r requirements.txt | ||
... # command or code showing the issue | ||
``` | ||
--> | ||
|
||
``` | ||
WRITE MRE / INSTRUCTIONS HERE | ||
``` | ||
|
||
### Full traceback | ||
<!-- Please provide the full error message / traceback if any, by pasting it in the code block below. | ||
No snapshots! --> | ||
|
||
<details><summary>Full traceback</summary> | ||
|
||
```python | ||
PASTE TRACEBACK HERE | ||
``` | ||
|
||
</details> | ||
|
||
### Expected behavior | ||
<!-- Please provide a clear and concise description of what you expected to happen. --> | ||
|
||
### Environment information | ||
<!-- Please run the following command in your repository and paste its output below it, | ||
redacting sensitive information. --> | ||
|
||
```bash | ||
hpv-model --debug-info # | xclip -selection clipboard | ||
``` | ||
|
||
PASTE OUTPUT HERE | ||
|
||
### Additional context | ||
<!-- Add any other relevant context about the problem here, | ||
like links to other issues or pull requests, snapshots, etc. | ||
--> |
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 @@ | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: I have a question / I need help | ||
url: https://github.com/ImpulsoGov/hpv-progression-model/discussions/new?category=q-a | ||
about: Ask and answer questions in the Discussions tab. |
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,19 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project. | ||
title: "feature: " | ||
labels: feature | ||
assignees: pawamoy | ||
--- | ||
|
||
### Is your feature request related to a problem? Please describe. | ||
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]. --> | ||
|
||
### Describe the solution you'd like | ||
<!-- A clear and concise description of what you want to happen. --> | ||
|
||
### Describe alternatives you've considered | ||
<!-- A clear and concise description of any alternative solutions or features you've considered. --> | ||
|
||
### Additional context | ||
<!-- Add any other context or snapshots about the feature request here. --> |
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,92 @@ | ||
name: ci | ||
|
||
on: | ||
push: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
|
||
env: | ||
LANG: en_US.utf-8 | ||
LC_ALL: en_US.utf-8 | ||
PYTHONIOENCODING: UTF-8 | ||
|
||
jobs: | ||
|
||
quality: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Fetch all tags | ||
run: git fetch --depth=1 --tags | ||
|
||
- name: Set up PDM | ||
uses: pdm-project/setup-pdm@v4 | ||
with: | ||
python-version: "3.8" | ||
|
||
- name: Resolving dependencies | ||
run: pdm lock -v --no-cross-platform -G ci-quality | ||
|
||
- name: Install dependencies | ||
run: pdm install -G ci-quality | ||
|
||
- name: Check if the documentation builds correctly | ||
run: pdm run duty check-docs | ||
|
||
- name: Check the code quality | ||
run: pdm run duty check-quality | ||
|
||
- name: Check if the code is correctly typed | ||
run: pdm run duty check-types | ||
|
||
- name: Check for vulnerabilities in dependencies | ||
run: pdm run duty check-dependencies | ||
|
||
- name: Check for breaking changes in the API | ||
run: pdm run duty check-api | ||
|
||
tests: | ||
|
||
strategy: | ||
max-parallel: 4 | ||
matrix: | ||
os: | ||
- ubuntu-latest | ||
- macos-latest | ||
- windows-latest | ||
python-version: | ||
- "3.8" | ||
- "3.9" | ||
- "3.10" | ||
- "3.11" | ||
- "3.12" | ||
runs-on: ${{ matrix.os }} | ||
continue-on-error: ${{ matrix.python-version == '3.12' }} | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up PDM | ||
uses: pdm-project/setup-pdm@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
allow-python-prereleases: true | ||
|
||
- name: Resolving dependencies | ||
run: pdm lock -v --no-cross-platform -G ci-tests | ||
|
||
- name: Install dependencies | ||
run: pdm install --no-editable -G ci-tests | ||
|
||
- name: Run the test suite | ||
run: pdm run duty test |
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,25 @@ | ||
name: release | ||
|
||
on: push | ||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
if: startsWith(github.ref, 'refs/tags/') | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Fetch all tags | ||
run: git fetch --depth=1 --tags | ||
- name: Setup Python | ||
uses: actions/setup-python@v4 | ||
- name: Install git-changelog | ||
run: pip install git-changelog | ||
- name: Prepare release notes | ||
run: git-changelog --release-notes > release-notes.md | ||
- name: Create release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
body_path: release-notes.md |
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,20 @@ | ||
.idea/ | ||
.vscode/ | ||
__pycache__/ | ||
*.py[cod] | ||
dist/ | ||
*.egg-info/ | ||
build/ | ||
htmlcov/ | ||
.coverage* | ||
pip-wheel-metadata/ | ||
.pytest_cache/ | ||
.mypy_cache/ | ||
site/ | ||
pdm.lock | ||
pdm.toml | ||
.pdm-plugins/ | ||
.pdm-python | ||
__pypackages__/ | ||
.venv/ | ||
.cache/ |
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,6 @@ | ||
FROM gitpod/workspace-full | ||
USER gitpod | ||
ENV PIP_USER=no | ||
RUN pip3 install pipx; \ | ||
pipx install pdm; \ | ||
pipx ensurepath |
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,13 @@ | ||
vscode: | ||
extensions: | ||
- ms-python.python | ||
|
||
image: | ||
file: .gitpod.dockerfile | ||
|
||
ports: | ||
- port: 8000 | ||
onOpen: notify | ||
|
||
tasks: | ||
- init: make setup |
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,8 @@ | ||
# Changelog | ||
|
||
All notable changes to this project will be documented in this file. | ||
|
||
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) | ||
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). | ||
|
||
<!-- insertion marker --> |
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,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2024 ImpulsoGov | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
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,54 @@ | ||
.DEFAULT_GOAL := help | ||
SHELL := bash | ||
DUTY := $(if $(VIRTUAL_ENV),,pdm run) duty | ||
export PDM_MULTIRUN_VERSIONS ?= 3.8 3.9 3.10 3.11 3.12 | ||
export PDM_MULTIRUN_USE_VENVS ?= $(if $(shell pdm config python.use_venv | grep True),1,0) | ||
|
||
args = $(foreach a,$($(subst -,_,$1)_args),$(if $(value $a),$a="$($a)")) | ||
check_quality_args = files | ||
docs_args = host port | ||
release_args = version | ||
test_args = match | ||
|
||
BASIC_DUTIES = \ | ||
changelog \ | ||
check-api \ | ||
check-dependencies \ | ||
clean \ | ||
coverage \ | ||
docs \ | ||
docs-deploy \ | ||
format \ | ||
release \ | ||
vscode | ||
|
||
QUALITY_DUTIES = \ | ||
check-quality \ | ||
check-docs \ | ||
check-types \ | ||
test | ||
|
||
.PHONY: help | ||
help: | ||
@$(DUTY) --list | ||
|
||
.PHONY: lock | ||
lock: | ||
@pdm lock -G:all | ||
|
||
.PHONY: setup | ||
setup: | ||
@bash scripts/setup.sh | ||
|
||
.PHONY: check | ||
check: | ||
@pdm multirun duty check-quality check-types check-docs | ||
@$(DUTY) check-dependencies check-api | ||
|
||
.PHONY: $(BASIC_DUTIES) | ||
$(BASIC_DUTIES): | ||
@$(DUTY) $@ $(call args,$@) | ||
|
||
.PHONY: $(QUALITY_DUTIES) | ||
$(QUALITY_DUTIES): | ||
@pdm multirun duty $@ $(call args,$@) |
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,29 @@ | ||
# HPV Progression Model | ||
|
||
[![ci](https://github.com/ImpulsoGov/hpv-progression-model/workflows/ci/badge.svg)](https://github.com/ImpulsoGov/hpv-progression-model/actions?query=workflow%3Aci) | ||
[![documentation](https://img.shields.io/badge/docs-mkdocs%20material-blue.svg?style=flat)](https://ImpulsoGov.github.io/hpv-progression-model/) | ||
[![pypi version](https://img.shields.io/pypi/v/hpv_progression_model.svg)](https://pypi.org/project/hpv_progression_model/) | ||
|
||
A stochastic model of the natural history and effects of vaccination and screening in the progression of Human Papillomavirus infections and cervical precancer lesions and invasive cancers. | ||
|
||
## Requirements | ||
|
||
- Python 3.11+ | ||
|
||
## Installation | ||
|
||
With `pip`: | ||
|
||
```bash | ||
pip install git+https://github.com/ImpulsoGov/hpv-progression-model.git | ||
``` | ||
|
||
With [`pipx`](https://github.com/pipxproject/pipx): | ||
|
||
```bash | ||
python3 -m pip install --user pipx | ||
pipx install git+https://github.com/ImpulsoGov/hpv-progression-model.git | ||
``` | ||
|
||
## Getting started | ||
|
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 @@ | ||
[tool.black] | ||
line-length = 120 | ||
exclude = "tests/fixtures" |
Oops, something went wrong.