This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/CODECOMPOSER: NullPointerException on deleting linked resource when original file does not exist anymore.

Part Number: CODECOMPOSER

Tool/software: Code Composer Studio

In my team we share through git some projects that are opened on CCS, some of which make extensive use of linked resources.

When one of the people in the team need to delete a file, they also delete any relative linked resource and commit both the deletion and the .project updated.

Now the problem is that, when somebody else pulls the changes and open the project on his CCS, he does not see the resource deleted and if he tries to delete it manually using the GUI a NullPointerException is raised.

Deleting the project ( or the .metadata folder) and reimporting the project from scratch fixes the issue.

The version if Version: 7.2.0.00013, with CDT 9.0.0.201606062011 and Eclipse Platform 4.6.0.v20160606-1342 Build id: I20160606-1100.

The stacktrace of the exception, taken from the log, is:

!ENTRY org.eclipse.ltk.ui.refactoring 4 10000 2019-04-04 18:16:36.261
!MESSAGE Internal Error
!STACK 0
java.lang.NullPointerException
    at com.ti.ccstudio.project.core.internal.temp.XMoveDeleteHook.deleteFile(XMoveDeleteHook.java:83)
    at org.eclipse.team.internal.core.MoveDeleteManager.deleteFile(MoveDeleteManager.java:50)
    at org.eclipse.core.internal.resources.Resource.unprotectedDelete(Resource.java:1827)
    at org.eclipse.core.internal.resources.Resource.delete(Resource.java:782)
    at org.eclipse.ltk.core.refactoring.resource.DeleteResourceChange.perform(DeleteResourceChange.java:163)
    at org.eclipse.ltk.core.refactoring.CompositeChange.perform(CompositeChange.java:280)
    at org.eclipse.ltk.core.refactoring.CompositeChange.perform(CompositeChange.java:280)
    at org.eclipse.ltk.core.refactoring.PerformChangeOperation$1.run(PerformChangeOperation.java:257)
    at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2240)
    at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2267)
    at org.eclipse.ltk.core.refactoring.PerformChangeOperation.executeChange(PerformChangeOperation.java:305)
    at org.eclipse.ltk.internal.ui.refactoring.UIPerformChangeOperation.executeChange(UIPerformChangeOperation.java:96)
    at org.eclipse.ltk.core.refactoring.PerformChangeOperation.run(PerformChangeOperation.java:221)
    at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2240)
    at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2267)
    at org.eclipse.ltk.internal.ui.refactoring.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:86)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:119)

For reference, I asked the same question on StackOverflow: https://stackoverflow.com/questions/55518637/eclipse-does-not-refresh-project-information, both places are ok to answer.

Thank you very much.

  • Hello,
    This is a known issue that has since been resolved. Please update your CCS version. I just tried this out with the latest CCS version (v9.0) and I am able to delete the broken linked resource without issue. I am able to reproduce the issue with my CCSv7.4 install.

    Thanks
    ki