8000 Sometimes annotation processing not working in Eclipse · Issue #507 · androidannotations/androidannotations · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Feb 26, 2023. It is now read-only.
This repository was archived by the owner on Feb 26, 2023. It is now read-only.

Sometimes annotation processing not working in Eclipse #507

@jeremiemartinez

Description

@jeremiemartinez

@DayS and I just ran into a problem in our project on annotation processing. We are using AA and aspectj in the same project. The annotation processing was not started after saving, so Eclipse could not find any generated AA classes. It caused a lot of errors in the project. My eclipse .project (Builder) was as follow:

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
    <buildSpec>
        [...]
        <buildCommand>
            <name>org.eclipse.ajdt.core.ajbuilder</name>
            <arguments>
            </arguments>
        </buildCommand>
        [...]
    </buildSpec>
    <natures>
        <nature>org.eclipse.ajdt.ui.ajnature</nature>
        <nature>com.android.ide.eclipse.adt.AndroidNature</nature>
        <nature>org.eclipse.jdt.core.javanature</nature>
        <nature>org.eclipse.m2e.core.maven2Nature</nature>
    </natures>
</projectDescription>

After, doing some search, we found out that this builder should be replaced by (+ remove nature) :

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
    <buildSpec>
        [...]
        <buildCommand>
            <name>org.eclipse.jdt.core.javabuilder</name>
            <arguments>
            </arguments>
        </buildCommand>
        [...]
    </buildSpec>
    <natures>
        <nature>com.android.ide.eclipse.adt.AndroidNature</nature>
        <nature>org.eclipse.jdt.core.javanature</nature>
        <nature>org.eclipse.m2e.core.maven2Nature</nature>
    </natures>
</projectDescription>

It probably comes from the fact we installed the AspectJ plugin. This is not really a bug but it could save some time for people in the same case. Maybe something to add to the documentation?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0