Export Features Problem after SDK 2020-07 Upgrade

Since upgrading my KNIME SDK in late December I have not been able to locally build a Feature Project.

I upgraded my KNIME SDK in Dec-2020 to Eclipse 2020-09 (4.17.0) and use the knime_sdk_2020_12 releases/2020-12 KNIME-AP.target platform. I tried creating a new Feature Project using the Quick Start Instructions and hit the same error I encountered with my legacy Feature Project. This is what I did:

  1. File > New > Other > Plug-in Development > Feature Project

  2. Filled in the details:

    Project Name: test.feature
    Feature ID: test.feature
    Feature Name: Feature
    Feature Version: 1.0.0.qualifier
    Feature Vendor: Me
    Install Handler Library:

  3. Hit the [Next] button:

    Initialize from the plug-ins list:

  4. [Finish]

  5. In the [Dependencies] tab, hit [Compute]

  6. Ran [Export Wizard] using directory: D:\knime_sdk\test_features

At around 78% complete, the following “Problem Occurred” pop-up message appears:

'Export Features' has encountered a problem

D:\knime_sdk\workspace\test.feature\assemble.test.feature.group.group.group.xml:88: The following error occurred while executing this line:
D:\knime_sdk\workspace\test.feature\assemble.test.feature.group.group.group.xml:174: Messages while mirroring artifact descriptors.
An error occurred copying file D:\knime_sdk\workspace\.metadata\.plugins\org.eclipse.pde.core\tempp2metadata\plugins\com.scientificstrategy.premium_4.3.0.v202101151435.jar.

Any ideas?

I don’t know the solution to your problem, but I never use the compute dependencies option - always add them manually. I dont know whether that will solve the problem though.

Steve

1 Like

Hi @Edlueze
like steve said, don’t bother with the “compute dependencies” of the feature, that only makes problems in my experience. By the way we just released a template with instructions on how to build the extensions with maven. That should ease your development / deployment. Take a look here and thanks a lot to Steve, he tested it with his extension and added a very helpful conversion guide:

best,
Gabriel

1 Like

Thanks Steve and Gabriel!

I was trying to generate an Update Site for my Premium nodes. These are not publicly available but depend upon my Community nodes which are. I have not built the Community nodes locally for years - relying instead on the Jenkins build. But with my SDK upgrade, this may have been required. After building the Community nodes locally, I could build the Premium nodes as both a Feature and Update Site.

1 Like

Looks like this is a case of “1 step forwards, 2 steps backwards” as I’m having all sorts of build problems. But the main thing that really puzzles me is the auto-generation of this file:

\workspace.metadata.plugins\org.eclipse.pde.core\tempp2metadata\content.xml

This file is automatically generated when building a Feature Project. But it contains a long list of garbage entries, starting with this:

<?xml version='1.0' encoding='UTF-8'?>
<?metadataRepository version='1.2.0'?>
<repository name='file:/D:/knime_sdk/workspace/.metadata/.plugins/org.eclipse.pde.core/tempp2metadata - metadata' type='org.eclipse.equinox.internal.p2.metadata.repository.LocalMetadataRepository' version='1.0.0'>
  <properties size='2'>
    <property name='p2.timestamp' value='1610968161397'/>
    <property name='p2.compressed' value='false'/>
  </properties>
  <references size='2'>
    <repository uri='http://www.scientificstrategy.com' url='http://www.scientificstrategy.com' type='0' options='0'/>
    <repository uri='http://www.scientificstrategy.com' url='http://www.scientificstrategy.com' type='1' options='0'/>
  </references>
  <units size='52'>
    <unit id='com.scientificstrategy.premium' version='4.3.0.202101181754' generation='2'>

Two things to note:

  1. units size = ‘52’ seems to indicate that I’ve tried to build this project 52 times today. Each unit version number (eg 4.3.0.202101181754) has a different timestamp, but all from today. That seems like it is the .qualifier being updated as I found the setting [Qualifier replacement (default value is today’s date)]. But why is .qualifier matching all of today’s hhmm times? And why hang on to all these failed ‘unit’ builds?

  2. unit id = ‘com.scientificstrategy.premium’ indicates that the “premium” private nodes are being included in the Feature Project. But that makes no sense as I was building the public “community” Feature Project and the private project was closed.

How can I flush this auto-generated context.xml file and build a clean project? I found a “synchronize” button and tried every option. No other setting seems to offer any hope.

Hi @Edlueze,
Like I said I recommend you to switch to maven / tycho for building your extension, it is much more reliable and has fewer strange behaviors like the ones you are describing. If you need any help with the conversion feel free to send me an email.

best,
Gabriel

I am following your advice and switching to maven, but so far it hasn’t been a lot of fun. Cloning the Community Repository Template (https://github.com/knime-community/community-repository-template) you recommended has added 11 errors and 7 warnings (see attached). All this is very unfamiliar to me but I am working through it the best I can. Eclipse is now 100% up to date but the update hasn’t made any difference.

1 Like

Hi @Edlueze,
I sent you a mail with information on how I can help you.

Gabriel