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

Completion in svg file proposes many duplicates #386

Closed
NikolasKomonen opened this issue May 23, 2019 · 2 comments · Fixed by #396
Closed

Completion in svg file proposes many duplicates #386

NikolasKomonen opened this issue May 23, 2019 · 2 comments · Fixed by #396
Labels
bug Something isn't working completion This issue or enhancement is related to completion support XSD
Milestone

Comments

@NikolasKomonen
Copy link
Contributor

Editing an svg file like this one causes completion to return many duplicate items:

<?xml version="1.0" standalone="no" ?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg xmlns="http://www.w3.org/2000/svg">
    <animate attributeName="foo">
        <
    </animate>
</svg>

Screen Shot 2019-05-22 at 6 41 07 PM

Referenced from: redhat-developer/vscode-xml#141

@NikolasKomonen NikolasKomonen added this to the v0.7.0 milestone May 23, 2019
@fbricon fbricon added bug Something isn't working completion This issue or enhancement is related to completion support XSD labels May 24, 2019
angelozerr added a commit that referenced this issue May 24, 2019
This PR fixes #386 The problem comes from of populate of DTD element children when it is loaded. As elements can be declared in many area, we need to check that children element name was not added.

This PR is just to see how to fix problem. Please ignore it and creates a new PR with tests.
@angelozerr
Copy link
Contributor

@xorye please see my PR at #391 which fixes this issue. Ignore it if you wish and create a new PR.

angelozerr added a commit that referenced this issue May 27, 2019
This PR fixes #386 The
problem comes from of populate of DTD element children when it is
loaded. As elements can be declared in many area, we need to check that
children element name was not added.

This PR is just to see how to fix problem. Please ignore it and creates
a new PR with tests.
angelozerr added a commit that referenced this issue May 27, 2019
This PR fixes #386 The
problem comes from of populate of DTD element children when it is
loaded. As elements can be declared in many area, we need to check that
children element name was not added.

This PR is just to see how to fix problem. Please ignore it and creates
a new PR with tests.

Signed-off-by: azerr <[email protected]>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue May 27, 2019
@fbricon
Copy link
Contributor

fbricon commented May 27, 2019

Proposed solution fixes the duplicate entries issue.
Dunno if it's related or not, but initial completion request is usually not working. It takes several tries before I get completion results after restarting the server. Something's fishy here.

NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue May 27, 2019
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue May 27, 2019
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue May 27, 2019
fbricon pushed a commit that referenced this issue May 27, 2019
Fixes #386

Signed-off-by: Nikolas Komonen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working completion This issue or enhancement is related to completion support XSD
Projects
None yet
3 participants