fossasia / visdom

A flexible tool for creating, organizing, and sharing visualizations of live, rich data. Supports Torch and Numpy.
Apache License 2.0
9.93k stars 1.13k forks source link

Fix unintentional Rolling-Release Python Linting & Update Black (black ver `22.10` -> black ver `23.1`) #905

Closed da-h closed 1 year ago

da-h commented 1 year ago

Description

This PR updates the python code-guidelines for this project from black 22.10 to black 23.1.

Motivation and Context

The recent black update did result in a failing test on our side (see #904, where no python files were changed, but the python linter check failed). While we actually did fix the black-version in the github-workflow, the action defined under the tag black@22.10.0 did actually use the most recent black version (ver 23), due to a missing argument describing which version to use. :facepalm: Thus, this PR updates the github-action to black@23.1.0 (major update), now additionally with the correct argument (version: 23.1.0), saves the reformatted code black 23 applied and adds a small note to CONTRIBUTING.md regarding the black version.

Types of changes

Checklist: