Skip to content
New issue

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

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

Already on GitHub? # to your account

Auto-completion sometimes shows duplicated entries #565

Closed
AlexanderWert opened this issue Feb 18, 2020 · 1 comment · Fixed by #902
Closed

Auto-completion sometimes shows duplicated entries #565

AlexanderWert opened this issue Feb 18, 2020 · 1 comment · Fixed by #902
Assignees
Labels
area/config-ui bug Something isn't working

Comments

@AlexanderWert
Copy link
Contributor

Sometimes the popup for the auto completion in the config UI shows duplicated entries:

image

@AlexanderWert AlexanderWert added the bug Something isn't working label Feb 18, 2020
@MariusBrill MariusBrill self-assigned this May 2, 2020
@JonasKunz
Copy link
Member

I guess I found the root cause in OcelotAutoCompleter.js:

export const enableOcelotAutocompletion = (aceEditor) => {
  if (!initialized) {
    const langTools = ace.require('ace/ext/language_tools'); // eslint-disable-line no-undef
    langTools.addCompleter(completer);
  }
  aceEditor.configAutoCompleteEnabled = true;
};

We check the initialized flag, but never set it.
This function is called whenever the Editor is created, causing the autocompleter to be registered multiple times.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
area/config-ui bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants