From 8f6b8a7e848fbb51c672df9b08f47c5898edcc0f Mon Sep 17 00:00:00 2001 From: Jason Date: Wed, 15 Jul 2020 14:21:09 -0400 Subject: [PATCH 1/8] Add initial contribution guidelines --- CONTRIBUTING.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..7a94ac7e --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,18 @@ +# Contribution Guidelines + +When contributing to this repository, please first discuss the change you +wish to make via issue, email, or any other method with the owners of this +repository before making a change. + +## Pull Requests + +1. Fork this repository to your repository +1. Clone the repository to your local machine +1. Checkout the `dev` branch +1. Make any changes to the code on the `dev` branch +1. Push your changes to your fork +1. Create new pull request + +## Documentation Strings + +Documentation strings are to follow the Google Style ([examples](https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html)). From bdc405a4439fa27975d3f0b1dc81eed1259edf27 Mon Sep 17 00:00:00 2001 From: Daniel Rojas Date: Sat, 20 Mar 2021 11:16:04 +0100 Subject: [PATCH 2/8] Remove duplicate contribution guidelines --- CONTRIBUTING.md | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 7a94ac7e..00000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,18 +0,0 @@ -# Contribution Guidelines - -When contributing to this repository, please first discuss the change you -wish to make via issue, email, or any other method with the owners of this -repository before making a change. - -## Pull Requests - -1. Fork this repository to your repository -1. Clone the repository to your local machine -1. Checkout the `dev` branch -1. Make any changes to the code on the `dev` branch -1. Push your changes to your fork -1. Create new pull request - -## Documentation Strings - -Documentation strings are to follow the Google Style ([examples](https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html)). From 80b7a5407bf2774ac899625367df78d8dc5b3e4a Mon Sep 17 00:00:00 2001 From: Andreas Motl Date: Fri, 22 Oct 2021 22:17:23 +0200 Subject: [PATCH 3/8] Improve gracefulness when invoking `wireviz.parse()` without `file_out` This happened to be a regression for WireViz-Web [1], which aims to do as much in memory as possible. [1] https://github.com/daq-tools/wireviz-web. --- src/wireviz/wireviz.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/wireviz/wireviz.py b/src/wireviz/wireviz.py index 95674945..a9b37498 100755 --- a/src/wireviz/wireviz.py +++ b/src/wireviz/wireviz.py @@ -40,8 +40,13 @@ def parse(yaml_input: str, file_out: (str, Path) = None, return_types: (None, st options = Options(**yaml_data.get('options', {})), tweak = Tweak(**yaml_data.get('tweak', {})), ) + + # When title is not given, either deduce it from filename, or use default text. if 'title' not in harness.metadata: - harness.metadata['title'] = Path(file_out).stem + if file_out is None: + harness.metadata['title'] = "WireViz diagram and BOM" + else: + harness.metadata['title'] = Path(file_out).stem # add items sections = ['connectors', 'cables', 'connections'] From 7f33517a79b3c577f52107b12a3217dd22c4183c Mon Sep 17 00:00:00 2001 From: Daniel Rojas Date: Mon, 25 Oct 2021 20:13:24 +0200 Subject: [PATCH 4/8] Bump version to 0.3.1 --- docs/CHANGELOG.md | 6 ++++++ src/wireviz/__init__.py | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 14183a63..0b665be5 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## [0.3.1](https://github.com/formatc1702/WireViz/tree/v0.3.1) (2021-10-25) + +### Hotfix + +- Assign generic harness title when using WireViz as a module and not specifying an output file name ([#253](https://github.com/formatc1702/WireViz/issues/253), [#254](https://github.com/formatc1702/WireViz/pull/254)) + ## [0.3](https://github.com/formatc1702/WireViz/tree/v0.3) (2021-10-11) ### New features diff --git a/src/wireviz/__init__.py b/src/wireviz/__init__.py index fcc7f3bd..70f88e02 100644 --- a/src/wireviz/__init__.py +++ b/src/wireviz/__init__.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # Please don't import anything in this file to avoid issues when it is imported in setup.py -__version__ = '0.3' +__version__ = '0.3.1' CMD_NAME = 'wireviz' # Lower case command and module name APP_NAME = 'WireViz' # Application name in texts meant to be human readable From 9af0cb8ab0314bc6754b153769f7562b5b38ec10 Mon Sep 17 00:00:00 2001 From: Julien Lecoeur Date: Fri, 26 Nov 2021 16:05:04 +0100 Subject: [PATCH 5/8] Fix graphviz file header The two header comments were missing an endline. Closes #258 --- src/wireviz/Harness.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wireviz/Harness.py b/src/wireviz/Harness.py index 2f9eb641..95419a42 100644 --- a/src/wireviz/Harness.py +++ b/src/wireviz/Harness.py @@ -93,8 +93,8 @@ def connect(self, from_name: str, from_pin: (int, str), via_name: str, via_wire: def create_graph(self) -> Graph: dot = Graph() - dot.body.append(f'// Graph generated by {APP_NAME} {__version__}') - dot.body.append(f'// {APP_URL}') + dot.body.append(f'// Graph generated by {APP_NAME} {__version__}\n') + dot.body.append(f'// {APP_URL}\n') dot.attr('graph', rankdir='LR', ranksep='2', bgcolor=wv_colors.translate_color(self.options.bgcolor, "HEX"), From b0d0070f08247e132b11bf45e617da9e8e1881f1 Mon Sep 17 00:00:00 2001 From: Daniel Rojas Date: Sat, 27 Nov 2021 13:32:40 +0100 Subject: [PATCH 6/8] Bump version to 0.3.2 --- docs/CHANGELOG.md | 6 ++++++ src/wireviz/__init__.py | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 0b665be5..84ab1452 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## [0.3.2](https://github.com/formatc1702/WireViz/tree/v0.3.2) (2021-11-27) + +### Hotfix + +- Adjust GraphViz generation code for compatibility with v0.18 of the `graphviz` Python package ([#258](https://github.com/formatc1702/WireViz/issues/258), [#262](https://github.com/formatc1702/WireViz/pull/261)) + ## [0.3.1](https://github.com/formatc1702/WireViz/tree/v0.3.1) (2021-10-25) ### Hotfix diff --git a/src/wireviz/__init__.py b/src/wireviz/__init__.py index 70f88e02..d658231f 100644 --- a/src/wireviz/__init__.py +++ b/src/wireviz/__init__.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # Please don't import anything in this file to avoid issues when it is imported in setup.py -__version__ = '0.3.1' +__version__ = '0.3.2' CMD_NAME = 'wireviz' # Lower case command and module name APP_NAME = 'WireViz' # Application name in texts meant to be human readable From 3b57f02f595e57fff42f90ec31a3ccc05a72fb40 Mon Sep 17 00:00:00 2001 From: Mark Niedzielski Date: Tue, 7 Mar 2023 23:45:58 -0500 Subject: [PATCH 7/8] Enable tests for current Python versions. --- .github/workflows/main.yml | 4 ++-- setup.py | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 301ac18a..171ee487 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,7 +8,7 @@ jobs: strategy: max-parallel: 4 matrix: - python-version: [3.7, 3.8] + python-version: [3.7, 3.8, 3.9, 3.10, 3.11] steps: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }} @@ -29,4 +29,4 @@ jobs: name: examples-and-tutorials path: | examples/ - tutorial/ \ No newline at end of file + tutorial/ diff --git a/setup.py b/setup.py index 4992bc56..861cee1f 100644 --- a/setup.py +++ b/setup.py @@ -40,6 +40,9 @@ def read(fname): 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', + 'Programming Language :: Python :: 3.11', 'Topic :: Utilities', 'License :: OSI Approved :: GNU General Public License v3 (GPLv3)', ], From a7ab1f959aec0651564118815ccd4633ff7b6587 Mon Sep 17 00:00:00 2001 From: Mark Niedzielski Date: Wed, 8 Mar 2023 00:47:11 -0500 Subject: [PATCH 8/8] Syntax fix for pytest bug. --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 171ee487..3e017743 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,7 +8,7 @@ jobs: strategy: max-parallel: 4 matrix: - python-version: [3.7, 3.8, 3.9, 3.10, 3.11] + python-version: [3.7, 3.8, 3.9, "3.10", "3.11"] steps: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }}