Bug 117721 - [Modules] Problem with "Check out into an existing project"
Summary: [Modules] Problem with "Check out into an existing project"
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: CVS (show other bugs)
Version: 3.1.1   Edit
Hardware: PC Windows 2000
: P5 minor (vote)
Target Milestone: ---   Edit
Assignee: platform-cvs-inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2005-11-23 09:28 EST by Mauro Molinari CLA
Modified: 2022-03-04 07:36 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mauro Molinari CLA 2005-11-23 09:28:48 EST
Hello!

I have a problem with the function "Check out into an existing project"
when importing files from the CVS repository (or using the function
"Check Out As" in the CVS Repository Exploring perspective). The problem
is this: I can import/extract files from the CVS into my existing
unshared project, but those files will not be linked to the CVS
counterparts (so I cannot use version control, do synchronization, etc.).

As I said, the project into which I import is unshared, but in Eclipse
Help System I can read:

"Note: Only folders within non-shared projects or projects shared with
the same CVS repository as the selected remote folder are valid targets
for the Checkout Into operation. Also, if the target project of the
operation is an unshared project, the project will be connected to the
CVS repository (i.e. the project will become a shared CVS project) but
any pre-existing content will be ignored."

From this I understand that my project should then be connected to the
CVS and the extracted files should then be subject to version control.
But this is not the case, actually.

I posted a thread about this issue in the newsgroups:
http://www.eclipse.org/newsportal/article.php?id=48020&group=eclipse.platform#48020

I cannot really work-around this project doing a check out into a new project, because the import process doesn't let me specify to which folder of the target project import files.

Another symptom that might be related to this problem is the following: if I create a new project, select Team | Share Project... and select a module from my CVS repository, then I do an import from that module and use "Check out into an existing project" and select this now-shared project (connected to the same repository, off course), nothing is imported (files from the CVS are not physically imported in the workspace and the package explorer does not show them).

STEPS TO REPRO:
1) New project => Java Project => use separate folders for src and bin; call this project something like "test"
2) right click on "test" in the package explorer, Import | Checkout projects from CVS => Next
3) select a CVS repository => Next
4) use an existing module and select one => Next
5) Check out into an existing project => Next
6) select test\src => Next
7) select HEAD => Finish

EXPECTED BEHAVIOUR:
Files should be checked out from the CVS and my project should now be a shared project, connected to the CVS repository. The package explorer should show CVS icons, version numbers, etc. and the Team contextual menu should give the options to update, commit, etc.

OBSERVED BEHAVIOUR:
Files are checked out, but the project is still unshared (no version control, no CVS icons, no options in Team contextual menu, except for "Apply patch" and "Share project").
Nothing appears in the error log.

ENVIRONMENT
Eclipse 3.1.1 - Win32 version
Build ID: M20050929-0840
I tried this in two Eclipse 3.1.1 installations (one under Windows 2000, one under Windows XP Professional), with the same results.
Comment 1 Mauro Molinari CLA 2005-11-24 03:59:11 EST
I just verified that the same problem is also present in Eclipse 3.1.0 (Build id: I20050627-1435): I tried fresh installation on Win32 of the package available for download in Eclipse WebTools project page, containing Eclipse 3.1.0 + WTP 0.7 all-in-one. 

My big question is that one day I could do this job without problems, so I'm trying all the versions I used in the past to determine which one made the job... I hope to succeed.
Comment 2 Mauro Molinari CLA 2005-11-24 04:22:04 EST
I also tried a fresh new installation of Eclipse 3.1.0 (same build id) from the original package downloaded from Eclipse.org (without WTP 0.7): same result! :-(
Comment 3 Mauro Molinari CLA 2005-11-24 05:09:41 EST
Nope... I also tried Eclipse 3.0.2, but this didn't work either. At this point, I really don't know what's wrong and how I got it to work in the past (I really have a project with a "src" folder containing a folder structure checked out from the CVS repository and connected to it... and I'm pretty confident to say that I used "Check out into an existing project" function...), anyway, by now I made a lot of tests and tryings, but I couldn't succeed.

The only work around seems to be to use an external CVS client software, but in this way I cannot use Eclipse built-in facilities and diff functions :-(
Comment 4 Michael Valenta CLA 2005-11-24 10:16:36 EST
The scenario you described works for me in 3.2. I don't recall fixing related to this in 3.2 so it should be the same as 3.1. To confirm, can you try 3.2 M3 to see if that works for you? Is the module your checking out a folder or a module (i.e. does it corrspond to a folder on the server or a module defined in the CVSROOT/modules file)?
Comment 5 Mauro Molinari CLA 2005-11-24 11:53:56 EST
(In reply to comment #4)
> The scenario you described works for me in 3.2. I don't recall fixing related
> to this in 3.2 so it should be the same as 3.1. To confirm, can you try 3.2 M3
> to see if that works for you? Is the module your checking out a folder or a
> module (i.e. does it corrspond to a folder on the server or a module defined in
> the CVSROOT/modules file)?

Dear Michael, I just tried 3.2M3 (build ID: I20051102-1600): no, it does not work.

I just tried to check out both a module (= folder that is mapped to an entry in CVSROOT/modules file) and a "normal" folder (= that is not mapped to an entry in CVSROOT/modules file), but the result is the same. The only difference is that in the first case I cannot do an Import => "Check out into an existing project", because the "Next" button is greyed out after I select the module and Eclipse automatically creates a new project for me. So, to perform the task, I must follow the other way (CVS Repository Exploring perspective => Check Out As => "Check out into an existing project").

The strange thing is this: suppose I have an unshared project "X" with an "src" folder and that I check out a folder "com" (with its subfolders) into the "src" folder of project "X". The result is a still unshared project "X" with an "src" folder that contains "com" folder and if I explore the workspace directory with Windows Explorer, I see that INSIDE "com" there are all the checked out subfolders AND a CVS folder. Inside these folders there are recursively the other CVS folders... but the strange thing is that there is NOT a CVS folder at the same level of "com" and this might be the reason for which che project remains disconnected from the CVS repository...

In other words, the structure of my just created unshared folder "X" is the following:
$workspace\X\.project
$workspace\X\.classpath
$workspace\X\bin
$workspace\X\src

I check out a folder (or a module) called "com" from the CVS repository, with the following structure:
com\something\folder1\...
com\something\folder2\...
etc.
The result is the following:
$workspace\X\.project
$workspace\X\.classpath
$workspace\X\bin
$workspace\X\src
$workspace\X\src\com
$workspace\X\src\com\something
$workspace\X\src\com\CVS
$workspace\X\src\com\something\folder1
$workspace\X\src\com\something\folder2
$workspace\X\src\com\something\CVS
etc.

But there are neither $workspace\X\CVS nor $workspace\X\src\CVS !!

In the project where I was able (some time ago) to make the CVS synchronization work, instead, I have a structure like the following:
$workspace\Y\.project
$workspace\Y\.classpath
$workspace\Y\bin
$workspace\Y\src
$workspace\Y\CVS
$workspace\Y\src\com
$workspace\Y\src\CVS
$workspace\Y\src\com\something
$workspace\Y\src\com\CVS
$workspace\Y\src\com\something\folder1
$workspace\Y\src\com\something\folder2
$workspace\Y\src\com\something\CVS
etc.

Inside the folders $workspace\Y\CVS and $workspace\Y\src\CVS (the ones that are missing in my new projects) there's also a file named Entries.Static that is not present in the CVS folders inside "com".

Maybe the problem is that Eclipse does not create these two folders? Why this could happen?

I checked again: nothing is written to the log.
Comment 6 Michael Valenta CLA 2005-11-24 12:47:24 EST
That's what I would have guessed the result was. Eclipse ads those folders to an unshared project when performign a Checkout Into but they are not being added for you. As I said, this works for me so clearly there must be something different about what you are doing. Can you think of anything that might be unique about your situation? Is there anything about the original steps you gave that might be ambiguous (i.e. I choose one way that worked but perhaps you did something slighttly different that didn't)?
Comment 7 Mauro Molinari CLA 2005-11-25 04:00:03 EST
(In reply to comment #6)
> That's what I would have guessed the result was. Eclipse ads those folders to
> an unshared project when performign a Checkout Into but they are not being
> added for you. As I said, this works for me so clearly there must be something
> different about what you are doing. Can you think of anything that might be
> unique about your situation? Is there anything about the original steps you
> gave that might be ambiguous (i.e. I choose one way that worked but perhaps you
> did something slighttly different that didn't)?

Unfortunately, I must say... no... I do EXACTLY what I'm writing in "STEPS TO REPRO", not a single click more, not a single click less.
I tried this on two different PCs, using the same repository, but the result is the same.

I'm starting to think that there's something broken in our CVS repository that makes Eclipse manifest this bug, but we use other clients (such as TkCVS and LinCVS) without problems. 
Do you have a link to some CVS from which I can do a checkout of a couple of files just to try it? One from which you do this operation without problems...

Otherwise, is there a way to make Eclipse verbose on the log?
Comment 8 Mauro Molinari CLA 2005-11-25 05:08:16 EST
I just tried also Eclipse 3.1.1 Linux GTK version, but the result is the same.
Comment 9 Michael Valenta CLA 2005-11-25 08:38:51 EST
I tested it using the Eclipse open source repository :pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse. There are plenty of projects to test this with (e.g. org.eclipse.compare).

I doubt that tracing would help since it appears that the checkout is occurring properly. However, here is a link that describes how to get a trace of the operation.

http://dev.eclipse.org/viewcvs/index.cgi/%7Echeckout%7E/platform-vcm-home/docs/online/cvs_features2.0/cvs-faq.html#misc_0
Comment 10 Mauro Molinari CLA 2005-11-25 11:00:03 EST
(In reply to comment #9)
> I tested it using the Eclipse open source repository
> :pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse. There are plenty of
> projects to test this with (e.g. org.eclipse.compare).

Dear Michael, I could get it to work!!!
First of all, checking out from dev.eclipse.org works flawlessly.

The problem was in the configuration of the CVS: in CVSROOT/modules there were:
1) one module mapped to a folder that didn't exist
2) another module mapped twice, the first time to a folder that didn't exist and the second time to an existing folder

Even if both modules were not related to the folders or modules that I tried to check out, this seemed to annoy Eclipse, in the way I explained in the bug report.

Since other CVS clients still work, I leave to you the decision if this is a bug of Eclipse or not. Anyway, because of this, I'm lowering its severity from major to minor.

Lastly, I would like to thank you very much for your prompt and kind support!

Mauro.
Comment 11 Michael Valenta CLA 2005-11-25 11:21:04 EST
I will leave this open since it is a problem that the Eclipse client should address in some way (i.e. it appears to mostly work). However, we don't have the manpower to addess it at the current time. Patches will be accepted.
Comment 12 Eclipse Webmaster CLA 2019-09-06 16:09:01 EDT
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.
Comment 13 Eclipse Genie CLA 2022-03-04 07:36:49 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. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. 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.

--
The automated Eclipse Genie.