Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 344941 - CVS does not propagate "not in sync" decorators on complex working sets
Summary: CVS does not propagate "not in sync" decorators on complex working sets
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: CVS (show other bugs)
Version: 4.1   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: platform-cvs-inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-06 05:53 EDT by Laurent Goubet CLA
Modified: 2019-11-14 02:19 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Laurent Goubet CLA 2011-05-06 05:53:56 EDT
I have a workspace in which projects under several different VCS are mixed together : SVN, CVS, GIT. For the purpose of this bug, let's say that all of my projects have local changes (and thus, decorated with their little ">" to tell me I need to synchronize them with the repository.

If I create a working set in which I put a project under CVS, the ">" decorator will properly be propagated to the working set level so that I know something is not in sync.

If I put a new project with no VCS in this working set, it remains decorated.

However, if I include a new project that is under Git or SVN (or under my own implementation of a RepositoryProvider), the working set no longer gets decorated, even though it still includes a project, under CVS, that is itself decorated.

This behavior is due to org.eclipse.team.internal.ccvs.ui.CVSLightweightDecorator#isMappedToCVS() :

-------------------
private boolean isMappedToCVS(ResourceMapping mapping) {
    IProject[] projects = mapping.getProjects();
    boolean foundOne = false;
    for (int i = 0; i < projects.length; i++) {
        IProject project = projects[i];
        if (project != null) {
            RepositoryProvider provider = RepositoryProvider.getProvider(project);
            if (provider instanceof CVSTeamProvider) {
                foundOne = true;
            } else if (provider != null) {
                return false; <- even if we "foundOne", return false if any single one of the projects is not under CVS version control
            }
        }
    }
return foundOne;
}
-------------------

I do not know if this is a behavior that was implemented to avoid conflicts between different RepositoryProvider all providing their own decorators ... feel free to invalidate this enhancement request if such a conflict can happen. However, if there is no conflict in such cases ("first come, first serve" and only the first decoration is chosen) then I think the accurate behavior would be to propagate the decoration to working sets even if it contains projects under mixed repository providers.
Comment 1 Lars Vogel CLA 2019-11-14 02:19:41 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

If the bug is still relevant, please remove the "stalebug" whiteboard tag.