OpenInterpreter / 01

The open-source language model computer
http://openinterpreter.com/01
GNU Affero General Public License v3.0
4.76k stars 470 forks source link

Fix pre-commit linter #223

Closed dheavy closed 3 months ago

dheavy commented 3 months ago

Closes #208.

Problem

The linter currently set for the project, is not linting what should be linted (software directory).

Furthermore, as discussed in this PR, the linter isn't black as advertised, but ruff, leading to confusion.

Solution

Add actual software directory to the list in the pre-commit black (instead of ruff) config.

Tested on

Discussion

Re-opened after it was accidentally closed by Git after a rebase.

@tyfiero again, the fate of this PR is tied to however you choose to proceed with #213 and the ruff vs black @tyfiero this is updated and ready for another review.

This PR, albeit necessary for smoother collaboration, generates a lot of diff in many files—the actual linting. Therefore, it has been broken into two distinct commits. This will facilitate review (only the first commit is actually proceeding with fixing the pre-commit issue) and should help any regression investigation via git bisect, if ever needed.

Tests from the Tested on section also include actually running the CLI simulator to ensure there were no regression.

tyfiero commented 3 months ago

Fantastic work @dheavy. Thanks for your continuous contributions to the repo :)