Skip to content

Releases: WhatsApp/erlang-language-platform

2024-07-16

16 Jul 08:20
Compare
Choose a tag to compare

Highlights

OTP 27 support

The internal copy of the erlc frontend now uses maybe, so it means we must remove OTP 25 build versions

eqWAlizer will now report uncovered function clauses

eqWAlizer will now report uncovered clauses, which means eqWAlizer is detecting that the corresponding pattern and guards cannot match the input type, and will not fully type-check it. In most cases, it means a spec or a type alias has to be updated. In some rarer cases, a clause may simply be dead code and can be deleted.

Improved diagnostics reported ranges

Various diagnostics that reported on a function call now report the range of the module:function part not the full MFA.

undefined function (W0017) diagnostic now reports for the erlang module too

Missing compile warn_missing_spec_all (W0012) diagnostic rework

We have a diagnostic to report that there is not a -compile(warn_missing_spec_all). directive for a file.
It is disabled by default. To enable it, add a .elp_lint.toml file to your project root, with contents

enabled_lints =['W0012']

This is now automatically read and used by ELP in language server mode, if it exists, and reloaded if it changes.

It can also have a disabled_lints section.

elp lint --one-shot CLI argument

If a given diagnostic code applies to a file, apply a fix for all occurrences if asked.
It normally only does one at a time, so the command needs to be called multiple times.
This will be made more logical in future, removing the need for this flag.

Raw Change Log

2aed828 Turn on vscode publishing for OTP 26.2 (Alan Zimmerman)
cd5e3b6 tests: OTP-27 compatible (Ilya Klyuchnikov)
ffad3c7 Bump vscode extension version for imminent release (Alan Zimmerman)
6ecc191 CI: remove OTP 25 from the matrix (#38) (Alan Zimmerman)
8462fa6 bump version to 0.7.0 (Alan Zimmerman)
6de370c Protect against panics from DidChangeTextDocument (Alan Zimmerman)
e055181 BE: fix currently unused enum variant warning (Alan Zimmerman)
eb10270 BE: Improve reported range in slow functions diagnostic (Alan Zimmerman)
e0e969e Add UseRange to DiagnosticTemplate (Alan Zimmerman)
00418bc BE: Improve reported range for cross_node_eval (Alan Zimmerman)
f8398ba Fix CallTarget.range for auto-erlang remote call (Alan Zimmerman)
57da3b2 BE: Improve reported range for undefined_function diagnostic (Alan Zimmerman)
a6e35f4 BE: supply range without args to find_cal_in_function callback (Alan Zimmerman)
05ae919 Fix buck project model to prevent false positive undefined function (Alan Zimmerman)
2e532f3 BE: Improve Target.private_header documentation (Alan Zimmerman)
8a316b3 report undefined function for erlang functions too (Alan Zimmerman)
4b9183f rename elp lint '--enable-erlang-service-diagnostics' to '--enable-erlc-diagnostics' (Alan Zimmerman)
c03acbd Add --include-otp-diagnostics option to "elp lint" (Alan Zimmerman)
1495d56 3/n: ReplaceInSpec assist: fix match (Alan Zimmerman)
a134c3e 2/n: ReplaceInSpec assist: detect match (Alan Zimmerman)
6622118 Ad-hoc handling of is_float/is_integer guards (Victor Lanvin)
fae41b5 Snapshot uncovered clause FP with numbers (Victor Lanvin)
ccaf672 1/n: ReplaceInSpec assist: initial infra and serialization (Alan Zimmerman)
ce6aac6 Fix typo in function name (Roberto Aloi)
f4bdf05 Add ability to pass custom prefix to glean sub-command (Roberto Aloi)
83c3c7c Update documentation links to reflect new format (Roberto Aloi)
773b00a Better erlang_service protocol (Michał Muskała)
ce0b616 Remove obsolete version of the scanner (Roberto Aloi)
109fe14 BE: Improve MFA Serde serialization (Alan Zimmerman)
9cffefc ensure elp:fixme takes effect on whole-file diagnostics (Alan Zimmerman)
914adfc add ignore and fixme assists to W0012 compile warn missing spec all (Alan Zimmerman)
fedc591 BE: use Expect for expected fix test results (Alan Zimmerman)
81c617b Fix offset calculation for sigils (Roberto Aloi)
ceef61e BE: Set lints_from_config while configuring lints (Alan Zimmerman)
efbd231 BE: rename DiagnosticConditions::explicit_enable to default_disabled (Alan Zimmerman)
b45363b Include event start time in telemetry (Alan Zimmerman)
db2cdef BE: remove disabling DiagnosticCode::MissingCompileWarnMissingSpec in tests (Alan Zimmerman)
ac9103b BE: Improve DiagnosticConfig initialization (Alan Zimmerman)
02bb478 reload LintConfig on config change (Alan Zimmerman)
e8ff008 server: always read .elp_lint.toml (Alan Zimmerman)
b13c59b elp lint: add test for lints explicitly enabled in config (Alan Zimmerman)
b952c15 switch fully to DiagnosticDescriptor for compile_warn_missing_spec diagnostic (Alan Zimmerman)
e0d2941 require compile_warn_missing_spec_all (Alan Zimmerman)
0d8f7cf Explictly filter explicitly enabled diagnostics (Alan Zimmerman)
3c3a5f5 BE: clarify include_otp flag when requesting diagnostics (Alan Zimmerman)
1195042 Add DiagnosticConditions.explicit_enable (Alan Zimmerman)
d041949 Snapshot: keep entire LintConfig, not just LintsFromConfig (Alan Zimmerman)
55e7d04 Move calculation of enabled diagnostics from config into ide crate (Alan Zimmerman)
881b659 Fix up typos (Ayoub Mansar)
80cadd3 Fix dependabot alert for vscode client (Alan Zimmerman)
3b84b94 add --one-shot to elp lint to apply all fixes at once (Alan Zimmerman)
c91b944 Shallow Dialyzer support on CLI (Tom Davies)
0fe3033 Handle sigil prefix/suffix in the scanner (Roberto Aloi)
50ba583 Update HIR for more-than-triple quote strings (Alan Zimmerman)
f8b673e Extend external scanner for triple quoted sigil strings (Alan Zimmerman)
1d7994a Add external scanner for triple quoted strings (Alan Zimmerman)
ba6e272 rename String::TripleQuoted to String::Verbatim (Alan Zimmerman)
6392db3 Update HIR for doc attribute (Alan Zimmerman)
f2be41c Update HIR for moduledoc attribute (Alan Zimmerman)
5968f13 6/n Update HIR for string sigils: term (Alan Zimmerman)
f3b2402 5/n update HIR for string sigils: type_expr (Alan Zimmerman)
60f7eb5 4/n Update HIR for string sigils: pat (Alan Zimmerman)
678752a 3/n Update HIR for string sigils: generalize lower_str_or_sigil (Alan Zimmerman)
e5fbb1a 2/n Update HIR for string sigils: expr (Alan Zimmerman)
1c24e7a 1/n Update HIR for string sigils (Alan Zimmerman)
e199f75 update grammar for string sigils (Alan Zimmerman)
eece0cc Update HIR to explicitly represent triple quoted strings (Alan Zimmerman)
ec0af1c Update grammar for triple quoted strings (Alan Zimmerman)
c9f1e31 Fix matching in scanner for triple quoted string continuation (Roberto Aloi)
e76a54a Update third-party grammar (Roberto Aloi)
fb463fe Fix use of maybe in macro argument (Roberto Aloi)
287c390 compiler: implementation of EEP-59 (Roberto Aloi)
5465e15 Implement warning for adjacent string literals without intervening white space (Roberto Aloi)
3625595 Preprocessor: Fail compilation for unknown functions (Roberto Aloi)
2e4fe37 Shorten code by list comprehension (Roberto Aloi)
aa86a80 Emit warning for triple quote chars (Roberto Aloi)
8c14904 Rename erl_scan_otp27 into elp_scan (Roberto Aloi)
2d67e73 Update scanner to always count of carriage return as zero (Roberto Aloi)
9541cb9 Export location type (Roberto Aloi)
f156ab6 Always consider maybe and else as keywords (Roberto Aloi)
599cf89 Modify erl_scan to use bytes (Roberto Aloi)
3e45eec Remove unnecessary has_fun (Roberto Aloi)
c2577d4 Remove ssa checks (Roberto Aloi)
48f021e Remove unused code (Roberto Aloi)
6b9ebca Format erl_scan (Roberto Aloi)
5495e9e Import latest erl_scan from OTP 27, strip away docs (Roberto Aloi)
d82f86f Error index entry for L1318 (Roberto Aloi)
8402121 New error codes for erl_lint/elp_lint (Roberto Aloi)
726ca97 Restore --force-warn-missing-spec-all flag (Roberto Aloi)
95b4ccb Upgrade elp_lint to latest available version (Roberto Aloi)
90398cb Implementation of EEP-59 Documentation Attributes (Roberto Aloi)
9b72b05 Remove trailing dot from erl_parse error messages (Roberto Aloi)
e2bac67 Fix bugs and distinguish between Sigil Type and Sigil Prefix (Roberto Aloi)
04d346e Remove ~r and fancy delimiters (Roberto Aloi)
aa99f88 Implement string sigils according to EEP 66 (Roberto Aloi)
37410c3 Remove unused argument (Roberto Aloi)
2b6dc11 Upgrade braces and ws dependencies (Roberto Aloi)
a303f92 CI: fix macOS x86_64 builds for eqWAlizer (#34) (Ali Sabil)
f7a3a14 Provide test example of using lints from config (Alan Zimmerman)
c2206f4 Add link to Slack channel in issue template (Roberto Aloi)
26960de Add telemetry for too-slow events (Alan Zimmerman)
a043fdc Add ELP installation instructions for Vim (Roberto Aloi)
9326281 Suggest elp shell when running eqwalize-all (Victor Lanvin)
bab39dc Make erlang service scoped per project and auto-started (Michał Muskała)

2024-06-07

07 Jun 13:48
Compare
Choose a tag to compare

Highlights

Fuzzy go-to-definition for functions

One of the challenges of a language server is to provide good ergonomics while working with partially correct code. Until now, go-to-definition would only work if the arity of the invoked function was exactly the same as the number of arguments passed in the invocation. We are now relaxing that constraint so that, if no definitions are found with an exact match (function name + arity) we fall back to a function with the same name but different arity. Handy if you are in the process of authoring code.

Support for Linux ARM64

Thanks to @asabil we now have a CI for Linux ARM64. Try the produced artifacts and let us know in case of issues!

No more "Background parsing" progress bar

The "Background Parsing" (separate from the "Loading Applications" one) spinner was displayed while the language server was populating its own internal cache. Many users interpreted this as part of the initial indexing process, so they were waiting for it to complete before using language features. This was not necessary - the background parsing is just an internal optimization -, so we are now hiding it from the user.

Bug fixes and improvements

  • New version of eqwalizer!
  • Fix crash in the elp shell that could happen during large rebases

Full ChangeLog

dd91c9a Bump extension (Roberto Aloi)
25154e0 Gracefully fail sending progress end (Michał Muskała)
ed3077e CI: add linux aarch64 build (#33) (Ali Sabil)
5754c77 Disable smart elaboration of negation in guards (Victor Lanvin)
42deec4 Repro -- invalid occurrence typing with negation of atoms (Victor Lanvin)
106b771 Sync file change logic from server to shell (Victor Lanvin)
687608f BE: Normalise types during lowering (Alan Zimmerman)
0968593 Only set eqWAlizer config if it has been changed (Victor Lanvin)
8fe7311 Avoid code duplication (Roberto Aloi)
6979267 Limit fuzzy search to go-to-definition (Roberto Aloi)
ff59c24 Fuzzy (any arity) go-to-definition for functions (Roberto Aloi)
3160b7a Add --clause-coverage option (Victor Lanvin)
e980308 EqwalizerConfig as Salsa input (Victor Lanvin)
f779dce Use correct name for [build_info] section (Roberto Aloi)
c37ed3b Remove "Background parsing" spinner (Alan Zimmerman)
8c47bb1 Reload project on change for ELP shell (Victor Lanvin)

2024-05-24

24 May 15:52
Compare
Choose a tag to compare

Highlights

✅ Completion and Hover information for built-in and imported functions.

We now correctly provide completions and signature help for BIFs and imported functions.

Screenshot 2024-05-28 at 18 29 56 Screenshot 2024-05-30 at 09 44 45

Fixes #28 , #29 .

📙 Documentation for NeoVim Support

Learn how to configure ELP in NeoVim here.

Thanks @mkuratczyk for the contribution!

✈️ Better navigation for Common Test suites

Screenshot 2024-05-30 at 09 55 03

It is now possible to navigate from a test-case name in the all/0 and groups/0 functions to its definition. It is also possible to quickly find the respective init_per_testcase/2, end_per_testcase/2 and the alike for a given test using the find references mechanism. Finally, renaming a test will also take care of updating all occurrences of the same test in a suite.

Full ChangeLog

f69546a Bump vscode extension version for imminent release (Alan Zimmerman)
0cf2364 completions for BIFs (Alan Zimmerman)
f413567 include module in DefMap::get_functions_in_scope (Alan Zimmerman)
025af9f lower imported functions and BIFs as remote calls (Alan Zimmerman)
7c2cae5 E2E test for as-you-type diagnostics (Roberto Aloi)
0ef4c22 Neovim support (#31) (Michal Kuratczyk)
f061fb5 Update meet for dynamic case (Victor Lanvin)
c270dac Implement go-to-def for CT testcases (Roberto Aloi)
4e17470 Add .globalcache to .gitignore (Alan Zimmerman)
e776a1c E2E test for unused macro (Roberto Aloi)
0772d13 E2E tests for extracting a function (Roberto Aloi)
4de26b7 E2E test for add edoc comment (Roberto Aloi)
efa8fca E2E test for types on hover (Roberto Aloi)
54d9b07 E2E test for compiler diagnostics (Roberto Aloi)
98b5ad1 use buck bxl query if asked (Alan Zimmerman)
7a3fd15 Use generic buck target cell names in tests (Alan Zimmerman)
e7a2948 Improve error reporting for 'elp project-info' (Alan Zimmerman)
5d6b729 Fix test failure (Alan Zimmerman)
a490e05 add buck bxl test (Alan Zimmerman)

2024-05-17

17 May 12:18
Compare
Choose a tag to compare

Highlights

⚙️ Easier configuration for custom projects

So far, it was only possible to use ELP with buck2 or rebar3 projects (via a plugin). An option to provide a custom build_info.json file was already available, but cumbersome for the user since it required creating and maintaining a large JSON file which listed all projects applications and dependencies.

You can now specify the structure of your project via a dedicated [build_info] section in the ELP config file. For example:

[build_info]
apps = "apps/*"
deps = "deps/*"

We hope this will make it easier to try ELP!

🎯 Precise ranges for undefined functions

We used to report a diagnostic for the whole -export attribute in case of an undefined function. We now restrict the range to the actual culprit.

Before:

Screenshot 2024-05-17 at 14 07 53

After:

Screenshot 2024-05-17 at 14 09 05

🐞 Bug Fixes

  • Fix a bug which caused the language server to report spurious diagnostics after switching branches
  • Do not try to compute code lenses for .config and .app.src files
  • Do not report syntax errors when the maybe (?=) operator is used
  • Avoid panic while calculating project-wide eqwalizer diagnostics due to 0 chunk size
  • Report correct ranges for diagnostics in presence of CRLF line endings
  • Fix handling of -file attributes
  • Fix detection of generated pragma in module preamble (fixes #24)

Full Changelog

ca7d3ab Bump version to 0.24.0 (Roberto Aloi)
e755c76 Add a test project for elp bxl query (Alan Zimmerman)
2bb78a7 Fix build by commenting out meta_only line (Alan Zimmerman)
50a2f7c Add config option to select buck project model query (Alan Zimmerman)
77d5d98 Include raw buck query result in elp project-info (Alan Zimmerman)
42b1f68 Temporarily ignore some files for CI 'elp parse-elp' (Alan Zimmerman)
e984d23 Handle -file attribute in .erl files (Roberto Aloi)
2957db5 Introduce build_info section in ELP config file (Roberto Aloi)
cbbec20 Generate dynamically build_info file (Roberto Aloi)
1f39bbc Add glob crate (Roberto Aloi)
64bd24a Bump tree-sitter-erlang version to 0.6.0 (for OSS) (Alan Zimmerman)
8efc68c Disarm unused trait method warning (Alan Zimmerman)
cc60e18 regen eqwalizer snapshot test (Ilya Klyuchnikov)
e2f6fbd Bump version to 0.6.0 (Alan Zimmerman)
113f969 Fix detection of generated pragma when 2001 is not a char boundary (Roberto Aloi)
0b99dae Add testcase for sigils (Roberto Aloi)
d197467 Add testcase for docstrings (Roberto Aloi)
18c7026 Bump tree-sitter crate to 0.22.5 (Alan Zimmerman)
fcdd3c1 Bump tree-sitter-cli to 0.22.5 (Alan Zimmerman)
e516a37 more precise handling of maps:remove (Ilya Klyuchnikov)
20130c8 BE: fix flaky test (Alan Zimmerman)
17cc6c7 Uncovered clause detection (Victor Lanvin)
d5627c5 Do not warn about usages of binary_to_term (Roberto Aloi)
99ebfe9 combine related errors for eqwalizer cli reporting too (Alan Zimmerman)
27769e0 Import epp_dodger from OTP 27 in Erlang Service (Roberto Aloi)
a07c9a4 Fix branch change diagnostic problem (Alan Zimmerman)
bb9612f Restrict L1227 (undefined function) diagnostics range (Roberto Aloi)
4f3b9eb Add test case showing the range for L1227 (undefined function) diagnostics (Roberto Aloi)
ee4b03d Do not panic if provided list of files is empty (Roberto Aloi)
fbd43eb Only generate lenses for elp-supported files (Alan Zimmerman)
bbd75be Add support for on-call links (Roberto Aloi)
ecb40d7 Add meta-only doc links (Roberto Aloi)
ee84c5b BE: make cross_node_eval config completely static (Alan Zimmerman)
076deb2 BE: make atoms_exhaustion config completely static (Alan Zimmerman)
bf8e8bf BE: make application_env BAD_MATCH completely static (Alan Zimmerman)

2024-04-29

29 Apr 08:32
Compare
Choose a tag to compare

The main visible improvements are

  • Do not crash when changing branches on project
  • Put full set of configuration options into the VS Code client, using Erlang Language Platform as the extension name
  • Properly deal with files having CRLF line endings

Detail

320ff4b CI: Update ci.yml for latest changes in github (#25) (Alan Zimmerman)
a0751fb Add infrastructure to cross node eval for custom error message per match (Alan Zimmerman)
8d5a1f6 Bump VS Code extension version to 0.23 for imminent release (Alan Zimmerman)
41b95be Introduce meta-only doc links (Roberto Aloi)
a387109 Prepare doc_links to handle multiple sources (Roberto Aloi)
18e0b2a Update erlang_service to process CRLF the same as ELP (Alan Zimmerman)
a937386 Capture LineEnding in LoadResult (Alan Zimmerman)
3125746 BE: use the same processing path converting from vfs to salsa (Alan Zimmerman)
bfff8ce Transparently calculate ProjectId from FileId in Type API (Roberto Aloi)
3c61178 dynamic() -> eqwalizer:dynamic() in tests (Victor Lanvin)
3ce7f9b Avoid project-wide diagnostics disappear upon closing (Roberto Aloi)
50f5a7f sort out panic for get_file_contents on a created file (Alan Zimmerman)
e4bac91 Bump version to 0.22 for imminent release (Alan Zimmerman)
331072a Update VS Code configuration options (Alan Zimmerman)
0926a13 Simplify filtering mechanism for EDoc and CT Diagnostics (Roberto Aloi)
11c54f3 Move include_otp to DiagnosticsConfig (Roberto Aloi)
45759fd Make OTP diagnostics configurable (Roberto Aloi)
28a3fcd Do not report OTP diagnostics by default (Roberto Aloi)
c97d4ab Fix subtyping dict < shape being too lenient (Victor Lanvin)
06e2065 Issue refining unions of maps (Victor Lanvin)
3e23e8c Fix W0017 documentation (Alan Zimmerman)

2024-04-17

17 Apr 13:58
Compare
Choose a tag to compare

b92293b specify escript path from cli (Roman Perehonchuk)
0d5865c specify erl path from cli (Roman Perehonchuk)
80bdc5b Bump extension version to 0.21.0 for imminent release (Alan Zimmerman)
ab022db Move unsafe integer conversion to dedicated linter (Roberto Aloi)
24092d9 BE: Enable eqwalizer types when using elp lint (Alan Zimmerman)
bc169cf Add for_each_function helper to sema (Roberto Aloi)
d809f50 Make target range extraction more discoverable (Roberto Aloi)
3529e62 Add string as known name (Roberto Aloi)
ae06332 ExportBuilder: put new export_type form after function exports (Alan Zimmerman)
fbb930b BE: use Expect for check fix tests (Alan Zimmerman)
67aa65d index per file (Roman Perehonchuk)
54ffca4 add code comments (Roman Perehonchuk)
0980351 eqwalizer assist for non exported type (Alan Zimmerman)
873deed export_type assist (Alan Zimmerman)
342a1e5 Generalise ExportBuilder to work on type exports too (Alan Zimmerman)
2f26898 fix build by inserting missing shipit tag (Alan Zimmerman)
9c1a002 output fully valid json for elp config command (Alan Zimmerman)
55b7e47 Add elp config command to dump all possible config options (Alan Zimmerman)
ca8b2a2 Add --include-suppressed flag (Roberto Aloi)
a925676 Enable inlay hints and signature help by default (Roberto Aloi)
2daeff8 use add_wip assist (Alan Zimmerman)
110ce5f Improve text fixture annotation removal regexp (Alan Zimmerman)
ca1a9b4 elp lint: bringing in code action fixes (Alan Zimmerman)
e7253ca track context diagnostic for assist (Alan Zimmerman)
efe7e59 Add request for task id to user input data (Alan Zimmerman)
3581077 add prompt field to user input (Alan Zimmerman)
6f4d773 add_fixme assist (Alan Zimmerman)
472b1a2 Allow setting group label in assist builder (Alan Zimmerman)
499c5fa Add UserInput String type (Alan Zimmerman)
d4e0774 Improve AssistContextDiagnosticCode (Alan Zimmerman)
825b4ec fact per file (Roman Perehonchuk)
aa0b3ac Add with_severity method (Roberto Aloi)
4e230e7 doc declaration for types (Roman Perehonchuk)
f3ae74c doc declarations for records (Roman Perehonchuk)
96b5118 doc declarations for macro (Roman Perehonchuk)
6c47f0b Remove test module uniqueness checker (Alan Zimmerman)
e6578f0 Remove ignore pragmas from type-based tests (Alan Zimmerman)
7a06306 Only create the eqwalizer exe once (Alan Zimmerman)
ccead8f doc declarations for vars (Roman Perehonchuk)
f4c2b62 doc declaration for functions (Roman Perehonchuk)
38282e4 backport v2 features to v1 (Roman Perehonchuk)
13012bf add header declarations (Roman Perehonchuk)
4e92ec9 Fix Erlang Service crash on ms_transform error (Roberto Aloi)
25a5ce8 Add E2E Test to verify no syntax errors for CAFs (Roberto Aloi)
a173ce0 Remove redundant check in atoms exhaustion linter (Roberto Aloi)
46f2e7f migrate erlint wids_everywhere diagnostic to ELP (Alan Zimmerman)
05a1390 add Diagnostic.with_fixme_fix (Alan Zimmerman)
dea0f3a xrefs only for files we indexed (Roman Perehonchuk)
015c6d7 xrefs only for files we indexed for v2 facts (Roman Perehonchuk)
ff9d544 don't serialize none (Roman Perehonchuk)
6bd3230 schema renames (Roman Perehonchuk)
661ec8d migrate xref v2 to key (Roman Perehonchuk)
feb2493 migrate declaration v2 to key (Roman Perehonchuk)
5ffc7f3 migrage xref fact to key (Roman Perehonchuk)
a624bc6 migrate declaration fact to key (Roman Perehonchuk)
d61008d migrate file lines fact to key (Roman Perehonchuk)
8281404 add keys to every predicate (Roman Perehonchuk)
c544d0c pretty print (Roman Perehonchuk)
8b48cfd macro expansion (Roman Perehonchuk)
39715cc use eqwalizer types only for vars (Roman Perehonchuk)
42ee297 clean-up (Roman Perehonchuk)
d9df2e0 utilize eqwalizer types and introduce var declaration (Roman Perehonchuk)
71ce3bc prepare testing infra to run with eqwalizer enabled (Roman Perehonchuk)
d88fbb0 add ods url to macro target (Roman Perehonchuk)
596143d refactor ods links (Roman Perehonchuk)
d521cda xref types (Roman Perehonchuk)
45edaff xref record in types (Roman Perehonchuk)
92bdff9 xref record index in patterns (Roman Perehonchuk)
c97175c xref record in patterns (Roman Perehonchuk)
ace1da8 xref record update (Roman Perehonchuk)
666a49a xref record field (Roman Perehonchuk)
0d177c3 xref record index (Roman Perehonchuk)
a7dcc43 xref for records (Roman Perehonchuk)
e07190b xref headers in include attributes (Roman Perehonchuk)
0baea06 move callback to separate function (Roman Perehonchuk)
65f358f xref functions in deprecated attribute (Roman Perehonchuk)
8bd2f32 xref functions in export statement (Roman Perehonchuk)
ac2419e xref macro in term (Roman Perehonchuk)
374d1ce xref macro in type (Roman Perehonchuk)
6fd1f7b xref macro in pat (Roman Perehonchuk)
14984e2 xref macro calls (Roman Perehonchuk)
d68a694 add captured function test v2 schema (Roman Perehonchuk)
152f4d8 add function xrefs to v2 schema (Roman Perehonchuk)
a9ea8c7 add record declaration to v2 schema (Roman Perehonchuk)
a43040f add type declaration to v2 schema (Roman Perehonchuk)
807c296 add macro declarations (Roman Perehonchuk)
b043285 add spec string to function declaration (Roman Perehonchuk)
b621018 add functions to new declaration facts (Roman Perehonchuk)
8fd0e13 prepare for v2 schema (Roman Perehonchuk)
febffe9 process glean in parallel (Roman Perehonchuk)
5d56af7 preparation step to paralelization (Roman Perehonchuk)
5df9c24 move declaration test to new test infra (Roman Perehonchuk)
bd149d2 move file fact and line facts to new test infra (Roman Perehonchuk)
4104e1b range for record update (Roman Perehonchuk)
cd1b363 range for record index (Roman Perehonchuk)
bda834c range for record fields (Roman Perehonchuk)
2049843 range for record expr (Roman Perehonchuk)
44a6bc2 range for functions without the args (Roman Perehonchuk)
72adf7c extract body_with_expr_source for future use (Roman Perehonchuk)
90dcd7b rewrite glean xref tests (Roman Perehonchuk)
d79711a refactor indexer to incorporate better test infra part2 (Roman Perehonchuk)
311fd8a refactor indexer to incorporate better test infra part1 (Roman Perehonchuk)
e0c7923 Go To Type Definition (Roberto Aloi)
261ca49 Add Body::range_for_any() function (Alan Zimmerman)
bb97a02 diagnostic descriptor for meta_only #1 (Alan Zimmerman)
e3c1add diagnostic descriptor: redundant_assignment (Alan Zimmerman)
dbb6602 diagnostic descriptor: trivial_match (Alan Zimmerman)
81cd23c diagnostic descriptor: unused_function_args (Alan Zimmerman)
2da4677 diagnostic descriptor: unused_macro (Alan Zimmerman)
f6e3e63 diagnostic descriptor: unused_record_field (Alan Zimmerman)
01ca341 diagnostic descriptor: mutable_variable (Alan Zimmerman)
1d33caa diagnostic descriptor: effect_free_statement (Alan Zimmerman)
e3e53e1 diagnostic descriptor: expression_can_be_simplified (Alan Zimmerman)
9338b0f diagnostic descriptor: application_env (Alan Zimmerman)
7720d85 disgnostic descriptor: missing_compile_warn_missing_spec (Alan Zimmerman)
e2403d2 diagnostic descriptor: slow_functions (Alan Zimmerman)
ace5919 diagnostic descriptor for dependent_header (Alan Zimmerman)
3a9850a diagnostics descriptor deprecated_function (Alan Zimmerman)
c2b0f64 diagnostic descriptor undefined_function (Alan Zimmerman)
74b20ec diagnostics descriptor for head_mismatch_semantic (Alan Zimmerman)
be8075f diagnostics descriptor for missing_separator (Alan Zimmerman)
2be92e3 Fix build. Missing colon in shipit comment (Alan Zimmerman)
120016a diagnostics descriptor for atoms_exhaustion (Alan Zimmerman)
78c6dea Introduce a diagnostic descriptor, to manage when they should run (Alan Zimmerman)
27952dd Add page for W0024 slow functions (Alan Zimmerman)
2ab3c5e Migrate slow functions diagnostic (Alan Zimmerman)
2060ade Diagnostics: Add helper to declaratively generate a diagnostic if a function is used (Alan Zimmerman)
4d9df03 Do not compute project-wide eqwalizer diagnostics until the first pass is completed (Roberto Aloi)
8ca7cdf Simplify caching logic (Roberto Aloi)
d6d1268 Add eqwalizer_caller test project (Roberto Aloi)
8779ff2 Upgrade Erlang grammar (Roberto Aloi)
f568f38 Configurable chunk for project-wide eqwalization (Roberto Aloi)
5e89d90 Configurable number of tasks for project-wide eqwalization (Roberto Aloi)
8895a71 Performance optimizations for project-wide eqwalization (Roberto Aloi)
5fd19ff Preliminary support for project-wide Eqwalizer diagnostics (Roberto Aloi)
0022987 Add EqwalizerConfig for IDE (Roberto Aloi)
6e22a87 Convert should_eqwalize to analysis method (Roberto Aloi)
7635718 On-the-fly collection of diagnostics (Victor Lanvin)
336d4ae fix a typo in a help message (Roman Perehonchuk)
2af4c7e Improvements to ElabApply with shapes (Victor Lanvin)
7b89b6d Improvements to maps:fold with shapes (Victor Lanvin)
4236b1e Snapshots -- lambdas with shapes and >2 clauses (Victor Lanvin)
ae703aa eqwalize multiple modules (Roman Perehonchuk)
02913ea Back out "Move erlang_service to use unix domain socket for communication" (Roberto Aloi)
6c703e5 Move erlang_service to use unix domain socket for communication (Michał Muskała)
1e5ee67 Bump eetf (Michał Muskała)
b9ec9e2 Fix unused field warning (Michał Muskała)
8c0fadd Add undefined function in export diagnostic as related info if syntax error in the function (Alan Zimmerman)
6ae0065 Back out "Remove test ignore for type-based tests" (Alan Zimmerman)
f96778c rework combining diagnostics: make combination symmetric (Alan Zimmerman)
690c4e0 BE: Remove On field from AnyCallBackCtx (Alan Zimmerman)
db161fc Add panic context for server vfs.file_contents call (Alan Zimmerman)
141baa4 BE: remove Diagnosti...

Read more

2024-03-21

21 Mar 16:13
Compare
Choose a tag to compare

Highlights

First batch of eqwalizer quick fixes, for spec mismatches

432263918_424477790162460_6032735865574995637_n
432389973_394938450197563_5652832251277663400_n

Improved completion by adding ok, undefined, true, false to keyword completion

Screenshot 2024-03-20 at 14 53 14

Improved feedback when a rename cannot be performed

Screenshot 2024-03-20 at 16 05 28

Changes

7c4b763 Bump VS Code extension version for imminent release (Alan Zimmerman)
f119709 Report an error if given L1500 for elp lint command (Alan Zimmerman)
961cf29 Fix tests after completion keywords update (Alan Zimmerman)
087c70c Use LSP 3.17 error code RequestFailed to report rename inapplicable (Alan Zimmerman)
bf2fec5 Completion: add common atoms to keywords (Alan Zimmerman)
39bc4eb Type assists 7/n: Improve assist wording (Alan Zimmerman)
573157a Type assists 6/n: expected type : leading atom tuple, fix spec (Alan Zimmerman)
2ae1108 BE: Introduce sema.find_enclosing_function_body, and helper for spec body (Alan Zimmerman)
f4b6fe8 Type assists 5/n: expected type : leading atom tuple, fix return value (Alan Zimmerman)
08a18f2 BE: make contains_annotation regex more lenient (Alan Zimmerman)
56a26a5 BE: Simplify expected_type code (Alan Zimmerman)
93ae1ef Add spec to FunctionBody (Alan Zimmerman)
0d9d932 Type test flakiness: Re-use erlang service connection for declarative tests (Alan Zimmerman)
90d65b1 BE:Fix some clippy warnings on ide crate (Alan Zimmerman)
b1f8432 Type Assists 4/n: mismatched atom, fix spec (Alan Zimmerman)
beeae5a BE: improve check_specific_fix (Alan Zimmerman)
c04a373 BE: strip annotations in expected fix test results (Alan Zimmerman)
a0d747a Type Assists 3/n: initial type based assist, for mismatched atom (Alan Zimmerman)
03cce8f Type Assists 2/n: Add initial plumbing for adding eqwalizer assists (Alan Zimmerman)
bfd9d13 Type Assists 1/n: Add eqwalizer assists to code_action request handler (Alan Zimmerman)
f1a6ab5 Put mutex around erlang service for tests (Alan Zimmerman)
2bd51fa Bump tree-sitter-erlang crate to 0.5.0 (Alan Zimmerman)
2a6c568 Bump version to 0.5.0 (Alan Zimmerman)
5a5ee4a bump tree-sitter to 0.22.1 (Alan Zimmerman)

2024-03-13

13 Mar 12:42
Compare
Choose a tag to compare

e6fdf63 Bump version in package.json (Roberto Aloi)
86b0213 BE: fix erlang_service_server request() type (Alan Zimmerman)
134982f Single collection of annotations (Roberto Aloi)
263b584 Avoid &String type and un-necessary cloning (Roberto Aloi)
44ca9b6 Re-export DiagnosticCode from top to simplify usage (Roberto Aloi)
3f16ba9 Remove unused Ignore struct (Roberto Aloi)
023009d Construct set of DiagnosticCode when extracting annotations (Roberto Aloi)
d0a31d6 Move DiagnosticCode from ide to ide_db crate (Roberto Aloi)
1cca863 Leverage metadata to decide when to suppress a diagnostic (Roberto Aloi)
b102268 Split metadata extraction into a separate query (Roberto Aloi)
4664abe Split collection of metadata from conversion to EETF format (Roberto Aloi)
cac672d Also collect generic ELP fixmes and ignores (Roberto Aloi)
00868a4 Make patterns for ELP Metadata extraction configurable (Roberto Aloi)
81ea215 Move tuple wrapping for eqwalizer_fixmes to fixme.rs (Roberto Aloi)
e5a9a9d Flakiness: Introduce a lock to serialise check_type test (Alan Zimmerman)
9636560 Bump mio to 0.8.11, and all cargo deps (Alan Zimmerman)
e4ea328 Add more context to eqwalizer ipc json decode (Alan Zimmerman)

2024-03-07

07 Mar 09:13
Compare
Choose a tag to compare

The main highlight is improved responsiveness from

  • Keeping the main message loop responsive when there are long-running erlang service tasks and the source changes.
    (f55b3ae, 677d09b, bbe6fd6)
  • More precisely tracking header files used in the erlang_service/eqwalizer, so we know when to recompute diagnostics
  • New experimental linter to identify meck misusage

8b8dbe5 Bump VS Code Version for imminent release (Alan Zimmerman)
2aa13cc rework combining diagnostics: split labeled into undefineds and syntax errors (Alan Zimmerman)
ce16fb5 Add context for lsp send panic (Alan Zimmerman)
8e1bc47 More context for eqWAlizer errors (Victor Lanvin)
bca9e09 rename diagnostics to native_diagnostics (Alan Zimmerman)
b0f6698 BE: clippy in ide crate (Alan Zimmerman)
87e99be BE clippy on elp crate (Alan Zimmerman)
ff3d6ad BE: clippy in ide_assists crate (Alan Zimmerman)
6cc3a43 BE: clippy in ide_completions crate (Alan Zimmerman)
2d4e8c6 BE: clippy in ide_db crate (Alan Zimmerman)
5be8df0 BE: clippy in project_model crate (Alan Zimmerman)
c2eb683 BE: clippy in types_db crate (Alan Zimmerman)
93d9c51 BE: clippy in syntax crate (Alan Zimmerman)
7f0e1f6 Add context-level mechanism to allow Meta-specific exclusions for the atoms exhaustion linter (Roberto Aloi)
b18b7cb Add mechanism to allow Meta-specific exclusions for the atoms exhaustion linter (Roberto Aloi)
f68d196 Better handling of union of atoms in maps:get (Victor Lanvin)
cce4677 Tests - union of atoms in maps:get (Victor Lanvin)
1c5ec0c BE: use HIR to check if in anonymous fun in meck diagnostic (Alan Zimmerman)
dd0019e Expose fold parents in find_call_in_function CheckCallCtx (Alan Zimmerman)
6351a2f Introduce parents in fold callback context (Alan Zimmerman)
5bcb776 BE: Improve find_call_in_function API (Alan Zimmerman)
de6616a erlang_service files via string rather than terms (Alan Zimmerman)
c5067e3 Add structured diagnostic to eqWAlizer diagnostics (Victor Lanvin)
db84030 Implement TC diagnostics in ELP (Victor Lanvin)
bc1d9cd Reorganising types_db/eqwalizer (Victor Lanvin)
760c6e4 BE: rip out include_file_revision (Alan Zimmerman)
93bbbf2 BE: Track included header files for erlang service module_ast() (Alan Zimmerman)
0ff6030 Do not warn about atoms exhaustion in tests (Roberto Aloi)
8fe178b elp lint does not respect --include-generated flag (Roberto Aloi)
ddcdcad Back out "print escaped regex string in test runner output on vscode" (Roman Perehonchuk)
d16b3a1 print escaped regex string in test runner output on vscode (Pulkit Agarwal (WhatsApp))
aedf05f bring back error level for project loading issues (Roman Perehonchuk)
71ca29f BE: Add ELP config for erlang_service (Alan Zimmerman)
3062861 BE: Use static regexes in erlang service (Alan Zimmerman)
a55f092 BE: Introduce MakeDiagCtx in find_call_in_function (Alan Zimmerman)
de9f44e Extend ide test fixture to allow Eqwalizer to find the erlang module (Alan Zimmerman)
7d32349 Add type query interface for PatId (Alan Zimmerman)
f3b8dfe Add support for file ranges in type_at_position (Victor Lanvin)
5c6a685 Add eqWAlizer analyses and reporting (Victor Lanvin)
80fb59e Add forms and AST visitors (Victor Lanvin)
77bcd15 Add types to visitor (Victor Lanvin)
99b1854 Rename type visitor (Victor Lanvin)
dcf6fb4 Rewriting visitor (Victor Lanvin)
3267596 Remove re-export of types from eqwalizer crate (Alan Zimmerman)
7e60d5c BE: Move find_range utility function to be a method on AnyCallBackCtx (Alan Zimmerman)
16e9c78 Use BodyOrigin in folds (Alan Zimmerman)
e02a9df Introduce TypedMFA for FunctionMatcher (Alan Zimmerman)
f0600b8 Semantic::expr_type (Alan Zimmerman)
b81f07d Add origin to Body (Alan Zimmerman)
66cfb68 Introduce FileKind::TestModule (Roberto Aloi)
7e40bed Fix OSS CI (Roberto Aloi)
f55b3ae unwind ct-info (Roman Perehonchuk)
677d09b unwind request-parse (Roman Perehonchuk)
bbe6fd6 unwinding for edoc (Roman Perehonchuk)
bba5ee2 telemetry renames (Roman Perehonchuk)
89d59e6 Introduce atoms exhaustion linter (Roberto Aloi)
808c5f8 Handle meck missing no_link option on empty lists (Roberto Aloi)
af67449 Introduce meck linter (Roberto Aloi)
4fe26af BE: add tests for serialize/deserialize ElpConfig (Alan Zimmerman)
073e680 track mainloop performance (Roman Perehonchuk)
f7635c6 introduce timeit_slow to publish only slow telemetry (Roman Perehonchuk)
2034ac0 BE: Split sema.find_body_and_map (Alan Zimmerman)
99e5cca BE: rename sema.find_body to sema.find_body_and_map (Alan Zimmerman)
062baba Add TypedSemantic to DefDatabase (Alan Zimmerman)
aa8d6d4 Add eqwalizer_type_at_position to TypedSemantic (Alan Zimmerman)
34c385e Move eqwalizer enum Type to types_db crate (Alan Zimmerman)
7203d2a Used TypedSemantic for ide crate eqwalizer diagnostics (Alan Zimmerman)
f3f1411 Move EqwalizerDiagnostic to types_db crate (Alan Zimmerman)
ed6162d Introduce elp_types_db crate (Alan Zimmerman)
ad8c937 Explain that Eqwalizer max_tasks affects CLI only, improve buck2 warnings (Alan Zimmerman)
ee01f68 Remove deprecated version of the UnusedInclude diagnostic (Roberto Aloi)
4b80e3f BE: Standardise on using Semantic rather than RootDatabase (Alan Zimmerman)
99c42f1 Solve panic for build_info command in presence of complex macros (Roberto Aloi)
0d3fa85 Do not process generated files for types-on-hover (Alan Zimmerman)
5a3f955 More friendly error message when module does not exist during lint (Roberto Aloi)
fb07580 Remove restriction on setting rebar3 profiles in .elp.toml (Alan Zimmerman)
425a5da Move eqWAlizer tests to ELP (Victor Lanvin)
72a4bee Function for batch-running eqWAlizer tests (Victor Lanvin)
4712e5a Add eqWAlizer config (to be used for tests) (Victor Lanvin)
cde9ece Add max_tasks option to .elp.toml (Victor Lanvin)
5276f03 Add instructions on how to install ELP from source (Roberto Aloi)
1e0720a Rename eqwalizer_diagnostics to eqwalizer_diagnostics_by_project (Alan Zimmerman)

2024-02-16

16 Feb 17:05
Compare
Choose a tag to compare

e09e01b Bump vs code extension version for OSS release (Jane Olszewska)
005f87b Document common EDoc errors (O0006 and O0007) (Roberto Aloi)
b33b594 Set both include_dirs and include_path for rebar3 deps (#13) (Benedikt Reinartz)
c3ce494 Fix errors showing in ignored files (Jane Olszewska)
1b93a05 Enable OTP 26 packages for Mac, pin OTP to 26.2 (Roberto Aloi)
af58b26 Document limitation for project configuration (Roberto Aloi)
a09bf96 Fix title and description for site (Roberto Aloi)
710292d Enable sitemap for ELP website (Roberto Aloi)
0a0a929 Remove duplicated info from README, point to Documentation instead (Roberto Aloi)
7ef5d6c Restructure configuration documentation (Roberto Aloi)
a4b48c9 Create dedicated section for editors (Roberto Aloi)
067dba7 Add page dedicated to the CLI (Roberto Aloi)
3b53f20 Move ELP installation instruction to a separate page (Roberto Aloi)
455104a Add intro, explaining what ELP is (Roberto Aloi)
5b7ed46 BE: Rename MinDefDatabase to DefDatabase (Alan Zimmerman)
5774a8f BE: Rename MinInternDatabase to InternDatabase (Alan Zimmerman)
1ba3cde Add rebar3 configuration instructions to configuration page (Alan Zimmerman)
0eec5b1 Add support for running tests interactively via lenses (Roberto Aloi)
1ce11ed Remove nested syntax errors (Alan Zimmerman)
daa5bfe BE: rename convert parameter for clarity (Alan Zimmerman)
4955bdb Introduce open_interactive command (Roberto Aloi)
4e4ffda Helper method to compute workspace root (Roberto Aloi)
87a553f Refactor Buck2 Test Runnables (Roberto Aloi)
d29a47c Implement buck2_test method for runnable (Roberto Aloi)
a53b92c Rename buck2_args into buck2_test_args (Roberto Aloi)
d6ec224 BE: Distinguish between Syntax Error and Missing item when converting from tree-sitter (Alan Zimmerman)
6cb08a9 adding config instructions to the web site (Alan Zimmerman)
cb69b75 Fill out P1711 in the error index (Alan Zimmerman)
32412bd Exclude callback functions from unreachable test case diagnostics (Roberto Aloi)
38f6018 Improve Syntax Error messages (Alan Zimmerman)
15e9ca7 BE: remove @generated tag from diagnostics.rs (Alan Zimmerman)
3d33778 Add rebar profile to .elp.toml (Alan Zimmerman)
5aa272a BE: Move EqwalizerConfig structure into project_model::lib (Alan Zimmerman)
3cf1ce5 22/n Declarative Tests: Enable edoc diagnostics (Alan Zimmerman)
93d6822 21/n Declarative Tests: in fixture, use %%< to indicate start at left margin (Alan Zimmerman)
19b8942 20/n Declarative Tests: eqwalizer tests (Alan Zimmerman)
43733a3 19/n Declarative Tests: remove scratch_buffer annotations (Alan Zimmerman)
dee774e 18/n: Declarative Tests: Use a fresh temp dir for common test (Alan Zimmerman)
8f2324a 17/n Declarative Tests: drop-proof annotation test fixtures (Alan Zimmerman)
9f70e8f 16/n Declarative Tests: enable erlang service everywhere (Alan Zimmerman)
03ec2d1 15/n Declarative Tests: Test Fixture: dump full fidelity to temp dir (Alan Zimmerman)
55d0d41 13/n Declarative Tests: Introduce a test Builder (Alan Zimmerman)
f59a0cc 12/n Declarative Tests: Do not populate ebin dir in test fixture (Alan Zimmerman)
12a841c 11/n Declarative Tests: prevent build info being deleted prematurely in tests (Alan Zimmerman)
b8b0e0d 10/n Declarative Tests: rename temp_dir::TestDir to temp_dir::TempDir (Alan Zimmerman)
4b0e687 9/n Declarative Tests: make a copy of RA testdir.rs as temp_dir.rs (Alan Zimmerman)