Coder Social home page Coder Social logo

Comments (5)

isidentical avatar isidentical commented on May 18, 2024

The problem is that, on get_repo_caches it can't find the cache, and it gives a warning, but the custom handler shows the warnings as an exception since (exc_info set to True). I'm not sure whether that is intentional or not, so maybe @jimmylai can help?

from fixit.

jimmylai avatar jimmylai commented on May 18, 2024

Some rules rely on Pyre to provide inferred type (e.g. AwaitAsyncCallRule) to work.

class AwaitAsyncCallRule(CstLintRule):

Missing Pyre doesn't impact the use of Fixit.
If you don't want to install Pyre, you can simply ignore the exception message. It's a suggestion, not an error.

Flake8 is included in Fixit via Flake8PseudoLintRule.
https://fixit.readthedocs.io/en/latest/rules/Flake8PseudoLintRule.html

So Fixit actually work fine on your example code. There was no other suggestions from Fixit specific rules.
If you run the same command on code has some issues that Fixit currently supports, it should provide you extra suggestions and autofixes.

Closing this since there is real no issue.

from fixit.

isidentical avatar isidentical commented on May 18, 2024

If you don't want to install Pyre, you can simply ignore the exception message. It's a suggestion, not an error.

Wouldn't it be more feasible (especially targeted for new users who have no idea about this, since most linters don't require additional type-checkers to start in that same environment) to ignore this errors, and just give a couple of warnings at the end.

Current:

Encountered exception <class 'Exception'> for the following paths:
./main.py
Running `pyre start` may solve the issue.
main.py:4:1
    E305: expected 2 blank lines after class or function definition, found 1

Found 1 reports in 1 files in 0.33 seconds.

IMHO a better:

main.py:4:1
    E305: expected 2 blank lines after class or function definition, found 1

-> Some rules were disabled since pyre is not found on the current environment
Found 1 reports in 1 files in 0.33 seconds.

from fixit.

jimmylai avatar jimmylai commented on May 18, 2024

That makes sense especially Pyre is not listed as required dependency of Fixit.
Add a better suggestion at the end of the CLI run is a better user experience (instead of the current exception).
Reopen to keep track this action item.

from fixit.

amyreese avatar amyreese commented on May 18, 2024

Hey folks, we just released Fixit 2.0, which includes major changes to the core frameworks, linting engine, API, and CLI. In light of this new release, this issue is likely to be resolved or no longer relevant. Please take a look at the new user guide or the upgrade guide for more information on how to migrate your projects to the new version.

If you believe this issue is still relevant or still occurring in the latest version, please feel free to open a new issue, or reply here with more details.

Thank you!

from fixit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.