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

"M2Doc Interpreter" View in Eclipse is too aggressive in locking the template file #426

Closed
flatombe opened this issue May 26, 2021 · 0 comments
Milestone

Comments

@flatombe
Copy link
Contributor

I'm submitting a...


[ ] Regression (a behavior that used to work and stopped working in a new release)
[X] Bug report  
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please have a look to the support pages of our website : http://m2doc.org/support/

Current behavior

When using the "M2Doc Interpreter" View in Eclipse, the template file of the generation may end up in an unmodifiable state. This makes iterating painful, as the view must be switched to another contextual generation everytime we want to take into account recent changes in the template.
Moreover, closing the "M2Doc Interpreter" View does not always unlock the template file. In that case, restarting Eclipse is necessary to clear the locks.

Expected behavior

The "M2Doc Interpreter" View in Eclipse should not lock the template file for modifications, as it will only ever read from the file, and never write to it.
Closing the "M2Doc Interpreter" View should make sure it releases all locks taken on the template file.

Minimal reproduction of the problem with instructions

  • In the workspace, import the example project IFE with M2Doc
  • Open the "M2Doc Interpreter" View on the "Template SA Complete.genconf" generation.
  • Through the file system, open file "Template SA Complete.docx" in Word.
  • Edit it and save the file. Word 2019 has you believe the file is now saved.
  • Close the file: a dialog ask whether you want to save your document or not.
    • "Save" closes Word and re-opens it with your modifications still there
    • "Do not save" closes Word.
  • If you open the document, you can see that your changes were in fact not saved.
  • Close the "M2Doc Interpreter" View in Eclipse and open the template file.
  • Try to modify and save the template: you end up in the same situation a previously, as the lock on the file was actually not released. Re-opening the View to change the contextual generation does not fix that situation.
  • Closing Eclipse clears the locks.

What is the motivation / use case for changing the behavior?

Editing the template only in the Eclipse-embedded Word window is not always practical.

Environment


M2Doc version: 3.2.0.202105181517
Eclipse version: Capella 1.4.1.202006301603
Platform version:  Windows 10

Others:


@ylussaud ylussaud added this to the 3.2.2 milestone Jan 6, 2022
@ylussaud ylussaud modified the milestones: 3.2.2, 3.2.3 Sep 22, 2022
@ylussaud ylussaud modified the milestones: 3.3.0, 3.3.1 May 2, 2023
@ylussaud ylussaud modified the milestones: 3.3.1, 3.3.2 Sep 19, 2023
@ylussaud ylussaud modified the milestones: 3.3.2, 3.3.3 Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants