Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[tycho-user] Cannot add artifact descriptor which has not been created by this repository

Hi,

I'm new here in this mailing list. I have used Tycho several times with success but now I'm facing an error I have no idea how to fix, even after several attempts.

I have a project with a set of plugins and fragments and it refers to another framework which is composed by a set of plugins and fragments as well as mine. Mine extends the other one which is of course based on Eclipse (Luna).

I'm using Tycho 0.24.0 and when it comes the time to packetize my product, the Maven build fail with the following error:

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-p2-repository-plugin:0.24.0:assemble-repository (default-assemble-repository) on project XXXXXX.hci.product: Execution default-assemble-repository of goal org.eclipse.tycho:tycho-p2-repository-plugin:0.24.0:assemble-repository failed: Cannot add artifact descriptor which has not been created by this repository -> [Help 1]

I was digging into the source code (even using the remote debug) and the error occurs in the file ModuleArtifactRepository.java at line 169.

Here's the snippet:
@Override
protected ModuleArtifactDescriptor getInternalDescriptorForAdding(IArtifactDescriptor descriptor)
        throws IllegalArgumentException {
    if (descriptor == null) {
        throw new NullPointerException();
    } else if (!(descriptor instanceof ModuleArtifactDescriptor) || descriptor.getRepository() != this) {
        throw new IllegalArgumentException(
                "Cannot add artifact descriptor which has not been created by this repository");
    }

In my case the descriptor.getRepository() is not this. In particular it happens with the fragments.

Thanks.
Alessio

Back to the top