Metals: Why is `javax` excluded from indexing?

Created on 22 Sep 2020  路  2Comments  路  Source: scalameta/metals

For a long time, I assumed that I didn't get completions for javax.imageio because of some bug in my setup.

Only after reading the release notes for 0.9.4 I realized that this was a feature-not-a-bug!

The javax package space contains many mainstream features like ImageIO, Swing and SQL.

Isn't excluding it by default going to be a poor experience for new Metals users who aren't aware of the exclusion list and the way to configure it?

Search terms

javax, imageio, swing, sql, exclusion

improvement

Most helpful comment

I think - since until not long ago the package exclusions were not configurable - javax was excluded since it was deemed to be rarely used. This is rather arbitrary and now that we have a mechanism to customize the excluded packages I think it would make sense to be more conservative in the packages excluded by default and limit those to fairly uncontroversial stuff.

Bottom line, I agree with @tgodzik and I think javax is a good candidate to be removed from the default exclusion list.

All 2 comments

Thanks for reporting! I am not a 100 % sure why they were excluded, probably due to the fact that those packages we not used that often and caused some clutter when it comes to auto imports, but that was judgement call and we didn't communicate it clearly. The completions would still work if you imported the classes by hand, but they would not get suggested in the first place.

We can update the default list if it was a wrong call, but in the meantime you can use the new setting to improve the situation.

@olafurpg What was the reason for removing javax.* ? I think it might make sense now to make the default list smaller as we are able now to adjust the exclusions to our personal requirements.

I think - since until not long ago the package exclusions were not configurable - javax was excluded since it was deemed to be rarely used. This is rather arbitrary and now that we have a mechanism to customize the excluded packages I think it would make sense to be more conservative in the packages excluded by default and limit those to fairly uncontroversial stuff.

Bottom line, I agree with @tgodzik and I think javax is a good candidate to be removed from the default exclusion list.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

iokacha picture iokacha  路  4Comments

vadeg picture vadeg  路  3Comments

olafurpg picture olafurpg  路  4Comments

romanowski picture romanowski  路  4Comments

FereX98 picture FereX98  路  4Comments