Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
VaeterchenFrost committed Jun 4, 2020
2 parents 7a59209 + 9a648f4 commit 52d45c8
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 8 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install wheel
pip install flake8 pytest
pip install flake8 pytest coverage
- name: Install project dependencies
run: |
Expand All @@ -55,6 +55,14 @@ jobs:
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
- name: Test with coverage & pytest
run: |
pytest
coverage run --source=tdvisu -m pytest .
coverage xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
flags: unittests
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# TdVisu
![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)
![Tests](https://github.com/VaeterchenFrost/tdvisu/workflows/Tests/badge.svg)
[![PyPI license](https://img.shields.io/pypi/l/tdvisu.svg)](https://pypi.python.org/pypi/tdvisu/)
![Tests](https://github.com/VaeterchenFrost/tdvisu/workflows/Tests/badge.svg)
[![codecov](https://codecov.io/gh/VaeterchenFrost/tdvisu/branch/master/graph/badge.svg)](https://codecov.io/gh/VaeterchenFrost/tdvisu)


![GitHub release (latest SemVer including pre-releases)](https://img.shields.io/github/v/release/vaeterchenfrost/tdvisu?include_prereleases)
[![PyPI version fury.io](https://badge.fury.io/py/tdvisu.svg)](https://pypi.python.org/pypi/tdvisu/)
Expand All @@ -12,7 +14,7 @@
![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/VaeterchenFrost/tdvisu)
![GitHub commits since latest release (by SemVer)](https://img.shields.io/github/commits-since/VaeterchenFrost/tdvisu/latest)


----------

Visualization for [dynamic programming](https://en.wikipedia.org/wiki/Dynamic_programming) on [tree decompositions](https://en.wikipedia.org/wiki/Tree_decomposition).

Expand All @@ -26,6 +28,7 @@ For the portable and light weight '.svg' format, all graphs for a timestep can b

With the '.svg' format the images are highly customizable, and even combining several timesteps together using svg [animate](https://developer.mozilla.org/en-US/docs/Web/SVG/Element/animate) would be an option in the future.

----------

# Using
[Alubbock:Graphviz](https://anaconda.org/alubbock/graphviz) (or [Graphviz (>=2.38)](https://graphviz.gitlab.io/download/))
Expand Down Expand Up @@ -68,6 +71,7 @@ pip install .[test]
pytest .\test\
```

----------

# How to use

Expand Down Expand Up @@ -144,3 +148,6 @@ In case any dependencies changed, or just to update some, check in
- For details see: [Upload Python Package](https://github.com/VaeterchenFrost/tdvisu/blob/master/.github/workflows/python-app.yml )

**Now you are set for the new release :tada:**

----------

9 changes: 6 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,12 @@ def read_files(files, delim: str = "\n") -> str:
The concatenated string.
"""
data = []
for file in files:
with open(file, encoding='utf-8') as handle:
data.append(handle.read())
try:
for file in files:
with open(file, encoding='utf-8') as handle:
data.append(handle.read())
except IOError:
pass
return delim.join(data)


Expand Down

0 comments on commit 52d45c8

Please sign in to comment.