Commit Graph

9 Commits

Author SHA1 Message Date
Michael Davis fcfd531859
erlang_ls: Add 'deps/*/' to include dirs
This allows scanning for `src/*.hrl` files under each deps directory
entry, fixing lookup for lines like:

    -include("src/rabbit_feature_flags.hrl").

in `deps/rabbit/src/rabbit_feature_flags.erl` or

    -include("src/amqp10_client.hrl").

in `deps/amqp10_client/test/mock_server.erl`.
2024-04-12 09:49:34 -04:00
Michael Davis df827452f7
erlang_ls: Look for lib includes in extra_deps
This fixes ErlangLS include lookups for `include_lib` attributes like

```erl
-include_lib("khepri/lib/include.hrl").
```

when running erlang_ls and building with Bazel.

`khepri` ends up in the `extra_deps` directory as a symlink after
running `bazel run //tools:symlink_deps_for_erlang_ls`, so this change
picks up that `khepri` directory as a lib for `include_lib`s.
2023-02-14 17:34:13 -06:00
Rin Kuryloski a8658ae68d Add "bazel run //tools:symlink_deps_for_erlang_ls"
for symlinking 3rd party deps into a place that erlang_ls can use them
2023-01-05 13:02:02 +01:00
Luke Bakken b50d0fafbb
Be sure to inclued apps/ dirs
Otherwise erlang_ls complains about missing refs
2022-05-02 13:47:24 -07:00
Karl Nilsson 795b5b576c QQ: better handle repeated requeues.
Repeated re-queues are a problem for quorums queues. A consumer
that repeatedly re-queues all messages may eventually cause the
quorum queue to run out of messages as the log cannot be truncated
if messages are not consumed in a fifo-ish order.

This change addresses this as follows:

All return commands are not send directly to the log but instead
are sent to the aux machine which evaluates how the return should be
processed. After this decision it will use the new "append" effect
to add it to the log as before.

If the queue has a delivery_limit configured the return command
will be appended as before and the message will be returned
to the front of the queue as before. This is safe as eventually
the message will be dropped or dead-letter when it reaches
it's delivery limit.

If the queue has _not_ configured a delivery_limit the return
will be turned into a new command that includes the original
message in full and will be returne to the back of the queue.
This ensure that messages in the queue will be cycled in fifo-ish
order and thus snapshots will be taken.
2022-02-28 16:27:56 +01:00
Luke Bakken 53ed2c3d40
Tweak more erlang_ls settings
As suggested in #3647:

* Add commented-out section to disable bound_var_in_pattern
* Comment-out `elvis` as that is not yet a standard used by the team

cc @kjnilsson @mkuratczyk
2021-11-03 09:15:55 -07:00
Luke Bakken 2741b75937
Comment-out code_reload
If RabbitMQ is not running, `erlang_ls` returns `nodedown` which is shown in your text editor console.
2021-11-03 07:59:10 -07:00
Alexey Lebedeff 1969d8d527 Add missing application to Erlang LS config
`rabbit_prelaunch` lives only in `deps/rabbit/apps/rabbit_prelaunch`,
and Erlang LS was not able to find it there.
2021-07-11 21:18:04 +02:00
Michal Kuratczyk 8d4800a0e7 erlang_ls config file for better dev experience 2021-03-12 11:53:16 +01:00