Bug 539404 - No error dialog when trying to save to a readonly ecore-file
Summary: No error dialog when trying to save to a readonly ecore-file
Status: NEW
Alias: None
Product: Sirius
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 minor (vote)
Target Milestone: ---   Edit
Assignee: Project inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2018-09-25 02:37 EDT by Mike Rumpf CLA
Modified: 2018-10-15 08:45 EDT (History)
3 users (show)

See Also:


Attachments
Project to reproduce (12.41 KB, application/x-zip-compressed)
2018-10-15 08:29 EDT, Pierre Guilet CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Rumpf CLA 2018-09-25 02:37:48 EDT
We are using svn locks on ecore model files. However if you don't have such a lock and the file is read only the graphical editor will still allow to save the model diagram with no error dialog popping up. All changes made in the graphical editor will consequently be lost once the editor is closed (since the ecore model could not be changed in the background).

It would be good to inform the user that saving the model failed because the file is read only.
Comment 1 Pierre-Charles David CLA 2018-09-25 03:24:53 EDT
Moved to Sirius, the aird editor is not part of EMF itself.
Comment 2 Pierre Guilet CLA 2018-10-15 08:29:36 EDT
Created attachment 276245 [details]
Project to reproduce
Comment 3 Pierre Guilet CLA 2018-10-15 08:37:33 EDT
The problem is not particularly related to aird editor but to representations editor.

Steps to reproduce:

- import the attached project 
- open the aird 
- open the diagram
- got to your OS file explorer and set the ecore file to read only.
- change the name of NewEClass1 to ReadOnly
- Save
- Close the session with right click>close
- Reopen the aird and the diagram

KO the ECLass name has not been changed and nothing is logged in error log.
Comment 4 Pierre Guilet CLA 2018-10-15 08:45:08 EDT
Scenario with aird editor:

- import the attached project 
- open the aird editor
- got to your OS file explorer and set the ecore file to read only.
- select the NewEClass1 semantic element in Models part of aird editor and change the name to ReadOnly
- Save
- Close the session with right click>close
- Reopen the aird
KO the name is not changed.