Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fta report webui #189

Open
1000i100 opened this issue Dec 4, 2024 · 1 comment
Open

fta report webui #189

1000i100 opened this issue Dec 4, 2024 · 1 comment

Comments

@1000i100
Copy link

1000i100 commented Dec 4, 2024

here is an exemple for javascript with es6 plato :
https://g1.frama.io/g1lib.js/maintainability/ (from this project https://framagit.org/g1/g1lib.js )

My goal :
now, fta give a score and fail thresold but if i have a bad score i have no easy clues to improve it.
perhapse a good linter can do the job, but plato report look perfect (but not for typescript and not fast)

@sgb-io
Copy link
Owner

sgb-io commented Dec 5, 2024

Hi @1000i100 I think what you are describing is outside the scope of FTA currently. But it's an interesting topic.

Quote from the website:

For the vast majority of projects, it is very likely that FTA will tell you that you have at least some files that Could be better or Needs improvement. The bar for achieving OK is fairly high (max FTA score of 50, see above), meaning you can only store a limited amount of operators, operands and logical paths within a single file before FTA will start telling you that improvement is needed.

FTA encourages breaking down large, complex files into smaller, more maintainable parts. Simplifying and breaking apart code is the only effective way to improve FTA scores.

It's entirely reasonable that you might consider something maintainable that has a high FTA score. FTA aims to provide guidance, but not dictate what is OK and what is not. In reality, there are many other factors you should take into account when evaluating the maintainability of code. FTA simply provides you with some baseline information to work with, particularly for files that have very high FTA scores - that usually indicates a smell.

All that said, I think providing dataviz for the fta output could be interesting to look at.

Related; I generally find that the top 5-10 files with the highest scores is what need improving / breaking down. Once every file is below ~70-80 in score, it becomes very subjective.

I would also add that these days, it's probably where an LLM comes into it, in terms of solving "how do I improve this file" and I think that is compatible with fta's current scope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants