Skip to main content

Identify long functions to refactor with this function analyser

Project description

function-analyser

TL;DR;

pip install function-analyser

There is much debate about the ideal length of a function or method.

E.g.

The first rule of functions is that they should be small.
The second rule of functions is that they should be smaller than that.
Functions should not be 100 lines long.
Functions should hardly ever be 20 lines long.

Robert (Bob) Martin, Clean Code: A Handbook of Agile Software Craftsmanship (2008) as cited in https://softwareengineering.stackexchange.com/questions/133404/what-is-the-ideal-length-of-a-method-for-you

Common sense, therefore, offers one solution.

However, I have taken a different approach in running analysis on many codebases and using this to calibrate a functional analysis tool to run on your own codebase.

The results are encapsulated in this useful function analysis tool.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

function-analyser-0.0.11.tar.gz (10.0 kB view details)

Uploaded Source

Built Distribution

function_analyser-0.0.11-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file function-analyser-0.0.11.tar.gz.

File metadata

  • Download URL: function-analyser-0.0.11.tar.gz
  • Upload date:
  • Size: 10.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.1 CPython/3.11.4

File hashes

Hashes for function-analyser-0.0.11.tar.gz
Algorithm Hash digest
SHA256 87365334376fdc09b9ddf5fa67de51f2d81d5dc1acdb4aa8bd568e9c5e85bd79
MD5 f2dc4d0880bf06e5c919cc2cbae1e83b
BLAKE2b-256 7e4ea5408b8c0414878ab849e6a7312c7cd49a1dc851ae001541b758f8359441

See more details on using hashes here.

File details

Details for the file function_analyser-0.0.11-py3-none-any.whl.

File metadata

File hashes

Hashes for function_analyser-0.0.11-py3-none-any.whl
Algorithm Hash digest
SHA256 631538d9901fe88253f3cfa4492b1d1b416fe3c6ec03dac4d35a14c296139a67
MD5 cdd279d4f3e488c8dd5a366df7b3419a
BLAKE2b-256 8fb38804b86c048ebbc95bbe8eec59e68bb0a92582f1a21fc136b322b295be45

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page