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

Add :analysis :all option #1897

Closed
sheluchin opened this issue Dec 4, 2022 · 8 comments
Closed

Add :analysis :all option #1897

sheluchin opened this issue Dec 4, 2022 · 8 comments
Labels
expired expired - might be closed due to too little activity

Comments

@sheluchin
Copy link
Contributor

To upvote this issue, give it a thumbs up. See this list for the most upvoted issues.

Is your feature request related to a problem? Please describe.
Some tools which depend on clj-kondo analysis data aim to get as much analysis information as possible, but understanding which Extra analysis options are available requires some effort and if the options list grows, the downstream tools need to be updated to use the new options.

Examples of tools that could benefit from an :analysis :all option:

Describe the solution you'd like
It would be helpful to have an analysis config option like :analysis :all to return all possible analysis data. The list of available data can grow and consumers of the data could receive the expanded map without needing to update any code on their end.

Describe alternatives you've considered
The alternative is to read through the docs and construct the comprehensive analysis config yourself, and then watch for newly added options and incorporate them as they come.

I can submit a PR for this feature, but I can't promise exactly when I'll get around to it.

@borkdude
Copy link
Member

borkdude commented Dec 4, 2022

PR welcome

@phronmophobic
Copy link

I just commented on the mentioned issue in dewey, but the tldr is that I'm less interested in having an :analysis :all option, but would be happy to have some way to programmatically inspect what kinds of analysis are available. That would allow me to check if new analyses are available and independently decide when/if to pull them in.

@sheluchin
Copy link
Contributor Author

It's a valid point about reproducibility.

What about having something that can return the available analysis options as an EQL query or something like that?

@borkdude
Copy link
Member

borkdude commented Dec 4, 2022

If I retrieve analysis I'm usually doing this with a specific case in mind. But when just exploring the data when experimenting :all may be convenient. You can programmatically then discover the available data by analyzing a sample maybe, although this wouldn't tell you about all available keys if nothing in the analysis hits a relevant piece of code.

@sheluchin
Copy link
Contributor Author

How about putting the config map that :all corresponds to in a map that can be inspected to get its explicit meaning? It could fulfill the desire for a convenient :all option, would allow for inspection, and would serve as a bit of documentation. Maybe Dewey could publish the complete analysis config along with the dump artifacts to support reproducibility?

@borkdude
Copy link
Member

borkdude commented Dec 4, 2022

@sheluchin That's an interesting idea. We could just expose a var that is the config to get all the analysis, so you can also inspect that map in the REPL locally.

@phronmophobic
Copy link

phronmophobic commented Dec 4, 2022

Maybe Dewey could publish the complete analysis config along with the dump artifacts to support reproducibility?

I like that idea!

Copy link

stale bot commented Dec 4, 2023

This issue has been automatically marked as expired because it has not had recent activity. To prevent it from being closed, please leave a message. Additionally, consider giving the original message a thumbs up if this issue is important to you, so it will appear higher in this list. Thank you for your contributions!

@stale stale bot added the expired expired - might be closed due to too little activity label Dec 4, 2023
@stale stale bot closed this as completed Jan 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
expired expired - might be closed due to too little activity
Projects
None yet
Development

No branches or pull requests

3 participants