Bug 408752 - Add 4.3 examples to PDE's download site
Summary: Add 4.3 examples to PDE's download site
Status: VERIFIED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.3   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.3 RC3   Edit
Assignee: Curtis Windatt CLA
QA Contact:
URL: http://www.eclipse.org/pde/samples/si...
Whiteboard:
Keywords: example
: 408751 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-05-22 16:18 EDT by Martin Oberhuber CLA
Modified: 2013-05-29 04:27 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Oberhuber CLA 2013-05-22 16:18:43 EDT
+++ This bug was initially created as a clone of Bug #366810 +++

Build ID: Eclipse SDK 4.3 RC 1

1. Launch Eclipse SDK, on Welcome page click Samples / SWT and install
2. New > Other > Code Samples > SWT Examples, Finish
--> The "org.eclipse.swt.examples" project shows a warning

Problems view shows:
Description	Resource	Path	Location	Type
Source folders should not be added to the src.includes list because they are included by default in source builds.	build.properties	/org.eclipse.swt.examples	line 19	Plug-in Problem

See also bug 408751 .
Comment 1 Dani Megert CLA 2013-05-24 08:32:23 EDT
This has been fixed a while ago (download the samples from the download page), but the PDE download site has not been updated.
Comment 2 Dani Megert CLA 2013-05-24 08:32:51 EDT
*** Bug 408751 has been marked as a duplicate of this bug. ***
Comment 3 Curtis Windatt CLA 2013-05-24 14:26:37 EDT
The problem is that we no longer have the code that generated the samples feature.  We have the sdk examples feature, but it is packaged differently (though it has similar content).

The samples feature contains a single plug-in that contains specifically named zips for the individual sample content.  Possible solutions:

1) Try to manually modify an existing sample plug-in/feature with the new SWT sample code.  This breaks the versioning scheme and might cause problems with the p2 metadata.
2) Try to recreate the steps to generate the sample plug-in.  Will probably involve some manual steps.
3) Try using the sdk examples feature.  This is available from the repositories so it would remove PDE from storing the samples on the webiste.  However, this could be an enormous chunk of work and could require changes to the welcome API.
Comment 4 Dani Megert CLA 2013-05-24 14:31:02 EDT
(In reply to comment #3)
> The problem is that we no longer have the code that generated the samples
> feature.  We have the sdk examples feature, but it is packaged differently
> (though it has similar content).
> 
> The samples feature contains a single plug-in that contains specifically
> named zips for the individual sample content.  Possible solutions:
> 
> 1) Try to manually modify an existing sample plug-in/feature with the new
> SWT sample code.  This breaks the versioning scheme and might cause problems
> with the p2 metadata.
> 2) Try to recreate the steps to generate the sample plug-in.  Will probably
> involve some manual steps.
> 3) Try using the sdk examples feature.  This is available from the
> repositories so it would remove PDE from storing the samples on the webiste.
> However, this could be an enormous chunk of work and could require changes
> to the welcome API.

Manually create it is the only feasible approach at this time. I would not care about p2. Those who use the sample via p2 will download the sample repo from the downloads page and not via Welcome.
Comment 5 Curtis Windatt CLA 2013-05-24 14:35:40 EDT
(In reply to comment #4)
> Manually create it is the only feasible approach at this time. I would not
> care about p2. Those who use the sample via p2 will download the sample repo
> from the downloads page and not via Welcome.

The welcome page uses p2 to install the samples feature so getting the p2 metadata correct is a requirement.
Comment 6 Curtis Windatt CLA 2013-05-24 15:31:11 EDT
I attempted to update the content manually and it appears the metadata generated from the site.xml is correct, as I can install the new version from Help > Install New Software.  However, the PDE samples action doesn't find the newest version when querying.  This could be some caching, or a problem with searching for the feature IU.
Comment 7 Dani Megert CLA 2013-05-24 15:59:29 EDT
(In reply to comment #6)
> I attempted to update the content manually and it appears the metadata
> generated from the site.xml is correct, as I can install the new version
> from Help > Install New Software.  However, the PDE samples action doesn't
> find the newest version when querying.  This could be some caching, or a
> problem with searching for the feature IU.

The only scenario where this will be used is via Welcome. Not via Install New Software.
Comment 8 Curtis Windatt CLA 2013-05-24 16:02:50 EDT
Confirmed that this is a caching problem on my machine by testing on Mike's machine.  The new version was installed correctly.

However, I now see the content is incorrect.  The content I used came from the binary output of the examples download.  As we want the samples to create a project with useful content I will have to redo the feature with content from the git repository.
Comment 9 Curtis Windatt CLA 2013-05-28 16:30:13 EDT
The content of the samples now matches what is in the git repository of the SWT examples plug-ins.

There are still warnings in a new workspace.  If they are a problem, the SWT team should fix them in their repo and I will remake the sample content again.

Description	Resource	Path	Location	Type
Build path specifies execution environment J2SE-1.4. There are no JREs installed in the workspace that are strictly compatible with this environment. 	org.eclipse.swt.examples		Build path	JRE System Library Problem
No required execution environment has been set	MANIFEST.MF	/org.eclipse.swt.examples.paint/META-INF	line 1	Plug-in Problem
No required execution environment has been set	MANIFEST.MF	/org.eclipse.swt.examples.controls/META-INF	line 1	Plug-in Problem
No required execution environment has been set	MANIFEST.MF	/org.eclipse.swt.examples.layouts/META-INF	line 1	Plug-in Problem
No required execution environment has been set	MANIFEST.MF	/org.eclipse.swt.examples.launcher/META-INF	line 1	Plug-in Problem
Comment 10 Dani Megert CLA 2013-05-29 04:27:22 EDT
(In reply to comment #9)
> The content of the samples now matches what is in the git repository of the
> SWT examples plug-ins.

Verified in I20130528-2000.


> There are still warnings in a new workspace.  If they are a problem, the SWT
> team should fix them in their repo and I will remake the sample content
> again.
> 
> Description	Resource	Path	Location	Type
> Build path specifies execution environment J2SE-1.4. There are no JREs
> installed in the workspace that are strictly compatible with this
> environment. 	org.eclipse.swt.examples		Build path	JRE 
> System Library Problem

This is fine. Just install the corresponding VM. I would not want to change the JRE of the samples this late.


> No required execution environment has been set	MANIFEST.MF
> /org.eclipse.swt.examples.paint/META-INF	line 1	Plug-in Problem
> No required execution environment has been set	MANIFEST.MF
> /org.eclipse.swt.examples.controls/META-INF	line 1	Plug-in Problem
> No required execution environment has been set	MANIFEST.MF
> /org.eclipse.swt.examples.layouts/META-INF	line 1	Plug-in Problem
> No required execution environment has been set	MANIFEST.MF
> /org.eclipse.swt.examples.launcher/META-INF	line 1	Plug-in Problem

Filed bug 409361 and added a patch. I also updated the samples JAR on the PDE web site.