Last Site Update: September 28th, 2024 | Latest Version: 12.2.0 |
|
|
|
|
|
|
|
|
PyDev Code AnalysisCode analysis provides error finding in python programs. It finds common errors such as undefined tokens, duplicated signatures and warns about things such as unused variables or unused imports. PyDev can currently find:
Advantages of the PyDev Code Analysis
NOTE 1: You may still configure PyDev to analyze your code only when you save a file if you want. NOTE 2: You have to disable PyLint manually if you don't want to use it anymore. NOTE 3: If you want information on how to configure PyLint, you can check: PyDev PyLint Configuring itPyDev allows you to tweak-around the code analysis settings to suit your coding-style. To do that, go to: window > preferences > PyDev > Code Analysis. The image below shows it...
Its options should be self-explanatory, so, if you have some doubt, please drop a note in the PyDev forum. Seeing the outputThe output is shown as error markers in the editor itself (you may hover over it to see the description).
You may also view the output in the 'problems view':
Important notes to effectively use code-analysisIMPORTANT 1: The undefined variable errors produced are used as an input for a content assistant that allows you to fix it. Check the PyDev Content Assistants page for more information on that (it also explains how you can give 'notes' to the code analysis so that it ignores some error or warning). IMPORTANT 2: You are advised to leave the 'auto-build' turned on (in the menu: project > build automatically). If you however want to leave it off, you have to remember to make a build when you want your changes analyzed. IMPORTANT 3: When you change the interpreter or change your pythonpath, your files are not automatically analyzed. If you want them analyzed after that, you have to manually do a 'clear' on the projects you want analyzed (in the menu: project > clean...). Passing info to code-analysisCurrently code-analysis does lots of analysis so that invalid signs are not raised, but some signs are nearly impossible to detect when doing static analysis, so, in some cases some flags may be added to the code to give more info to the code-analysis and make it behave better. Currently, the supported flags are: Flag: @DynamicAttrs Example: class Struct:
'''Attributes passed in constructor.
*@DynamicAttrs*
'''
def __init__(self, *entries):
self.__dict__.update(entries)
|
PyDev developmentPyDev is open source and depends on your contributions! This may be in the form of bug fixes, answers on stackoverflow, new features...Another option is financially supporting it at: Patreon (which provides a way to support it monthly and get rewards starting with $1). Or through 1-time contributions at: Paypal Search PyDev-related content |
|
|
Copyright: Brainwy Software Ltda, 2014-2021 |