Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 496014

Summary: Support completion and validation of properties-specific expressions
Product: [Modeling] Sirius Reporter: Pierre-Charles David <pierre-charles.david>
Component: PropertiesAssignee: Pierre-Charles David <pierre-charles.david>
Status: CLOSED FIXED QA Contact: Julien Dupont <julien.dupont>
Severity: normal    
Priority: P3 CC: arthur.daussy_ssii, hal, julien.dupont, robert.doczi, stephane.begaudeau, steve.monnier
Version: unspecifiedKeywords: triaged
Target Milestone: 4.1.0   
Hardware: All   
OS: All   
URL: https://tuleap.eclipse.org/plugins/tracker/?aid=497
See Also: https://git.eclipse.org/r/79139
https://git.eclipse.org/r/79138
https://git.eclipse.org/r/79137
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=10f13b75448bb9c81d401fff90013e9299eed335
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=04cc6c431dcf1943ecd6ae8382c5cd591dc2fe19
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=7144e40d03806a547fa7b02fd8dc545779f5121a
https://git.eclipse.org/r/79802
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=093cc6c77932558e6642db05d221f8ff9de3c644
https://git.eclipse.org/r/82699
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=a018f4ca7b6bb2135b1a0e4528ecd160664cc879
Whiteboard: needtest
Bug Depends on:    
Bug Blocks: 495366    
Attachments:
Description Flags
Use case to reproduce problem none

Description Pierre-Charles David CLA 2016-06-13 11:15:25 EDT
This requires integration into the Sirius mechanisms to tell it which variables are available in the context of a given expression, and for each of them, including "self", the type (or combination of possible types) it will have at runtime.

See org.eclipse.sirius.diagram.business.internal.dialect.description.DiagramInterpretedExpressionQuery for an entry point in the code for these mechanisms in Sirius.
Comment 1 Hallvard Traetteberg CLA 2016-06-27 03:37:28 EDT
I consider validation a pretty important feature, and although people may guess that validation errors for variables in properties view expressions aren't real, the user must still consider each to see which are real errors.

Completion is less important, but if you nevertheless must use a general mechanism, I guess it's for "free".
Comment 2 Pierre-Charles David CLA 2016-08-10 07:55:55 EDT
*** Bug 499495 has been marked as a duplicate of this bug. ***
Comment 3 Eclipse Genie CLA 2016-08-16 11:01:29 EDT
New Gerrit change created: https://git.eclipse.org/r/79139
Comment 4 Eclipse Genie CLA 2016-08-16 11:01:32 EDT
New Gerrit change created: https://git.eclipse.org/r/79138
Comment 5 Eclipse Genie CLA 2016-08-16 11:01:33 EDT
New Gerrit change created: https://git.eclipse.org/r/79137
Comment 9 Eclipse Genie CLA 2016-08-26 04:15:16 EDT
New Gerrit change created: https://git.eclipse.org/r/79802
Comment 11 Pierre-Charles David CLA 2016-09-23 09:06:05 EDT
Fixed, but some automated tests are needed before we close this.
Comment 12 Pierre-Charles David CLA 2016-10-04 08:53:03 EDT
Fixed.
Comment 13 Julien Dupont CLA 2016-10-05 03:49:39 EDT
The validation display false postives.
To reproduce problem:
- Open project.odesign
- Launch a validation
- The validation displays 4 errors (3 errors are not errors, problem with variables)
   
The validation seems don't know the variables.
Comment 14 Julien Dupont CLA 2016-10-05 03:50:07 EDT
Created attachment 264591 [details]
Use case to reproduce problem
Comment 15 Pierre-Charles David CLA 2016-10-06 11:44:41 EDT
The problem mentioned in comment 13 should be fixed by c11d7105cb7277b863ed6dd7c077d7574d656a77.
Comment 16 Eclipse Genie CLA 2016-10-07 03:51:24 EDT
New Gerrit change created: https://git.eclipse.org/r/82699
Comment 18 Pierre-Charles David CLA 2016-10-18 11:07:04 EDT
Available in Sirius 4.1.0, see https://wiki.eclipse.org/Sirius/4.1.0 for details.