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

Issues When Refactoring Element When Using Subversion With Needs svn:needs-lock #1132

Closed
philip-alldredge opened this issue Apr 13, 2018 · 3 comments
Assignees

Comments

@philip-alldredge
Copy link
Collaborator

philip-alldredge commented Apr 13, 2018

Summary

Expected and Current Behavior

When using OSATE with a subversion project that has the needs-lock property, an error can occur while renaming elements if the source file is not locked for editing. When manually editing a file, Eclipse will prompt to lock the file when saving. However, when refactoring, Eclipse will not prompt. An error is shown. Similiar issues affect the graphical editor.

Steps to Reproduce

This may not be a minimal model or steps but I was able to reproduce by doing the following.

  1. Create a subversion repository. Recommend just creating a local one using TortoiseSVN.
  2. Install Subversive into the OSATE installation.
  3. Checkout a subversion repository using TortoiseSVN or with Eclipse.
  4. Add an AADL project with two packages. Each package should contain a system. One of the systems should extend the other.
  5. Commit the files to the repository.
  6. Sets the needs-lock property on the folder/files. In TortoiseSVN that uses Properties command from the context menu.
  7. Ensure that all locks have been released.
  8. Open the project in OSATE and ensure that it is "shared" in Eclipse. Just make sure that the svn information is being displayed in the navigator.
  9. Use the rename element command from the text editor to rename the system that extends the other. In the example below, rename B.
  10. An error dialog appears with an exception.
package svn1
public
	with svn2;

	system B extends svn2::A
	end B;
	
end svn1;
package svn2
public
	system A
		
	end A;
end svn2;

Environment

  • OSATE Version: 2.3.2
  • Platform: Windows 10
@philip-alldredge
Copy link
Collaborator Author

As part of improving the graphical editor support in #1217, additional experimentation was done with subversion. Subclipse appears to handle locking better than subversive. There were occasional NPE when refactoring in the graphical editor with subversive.

Subclipse will try to automatically lock files in most cases. However, if subclipse fails to lock the file due to it already being locked, it will just output a message to the console. However, the message will describe the cause so from a user perspective, I believe subclipse provides the best experience. There may not be anything that is needed to do beyond the enhancements as part of #1217 other than recommend subclipse as the SVN plugin.

@lwrage lwrage removed the backlog label Jul 9, 2019
@lwrage
Copy link
Contributor

lwrage commented Mar 5, 2020

@philip-alldredge Is there anything that needs to be done except documenting that OSATE doesn't work with subversive?

@philip-alldredge
Copy link
Collaborator Author

I don't know of anything else that can be done other than discourage subversive use. I haven't checked this lately so I don't know if subversive's behavior has changed.

@lwrage lwrage self-assigned this Mar 30, 2020
@lwrage lwrage closed this as completed Mar 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants