Refrest metada not working

Issue #503 resolved
Julio Enrique created an issue

I'm trying to refresh an apex class but nothing happens. It seems that is only refreshing the metadata from the package.xml file (the file i'm trying to refresh was retrieved). I tried also adding the class name to the package.xml but have still no success.

Comments (19)

  1. Scott Wells repo owner

    Julio, do you mind adding the following to Help>Debug Log Settings so I can see what's happening exactly?

    #com.illuminatedcloud.intellij.builder.RetrieveAction
    #com.illuminatedcloud.intellij.builder.RefreshAction
    #com.illuminatedcloud.intellij.builder.ForceComBuilder
    #com.illuminatedcloud.intellij.builder.ForceComMetadataRetriever
    

    Perform the refresh operation and then send me the resulting idea.log using Help>Show Log in Explorer/Finder. I'll take a look and see if I can understand what's going on.

  2. Scott Wells repo owner

    Thanks, Julio. It's saying that no metadata was selected for refresh. Can you show me your metadata subscription? Feel free to email it if it's sensitive information.

  3. Scott Wells repo owner

    Julio, do you mind installing this build using Settings>Plugins>Install plugin from disk, repeating the refresh operation, and then providing the idea.log again? It should have considerably more debugging info to help me understand what's going on.

  4. Scott Wells repo owner

    Julio, in this log you're refreshing a class called AccountSetAssociationTest which is not in your package.xml. Would you mind trying to refresh one of the files that is part of your active subscription that has the same results?

  5. Julio Enrique reporter

    Attaching the new log. The behaviour is strange, sometimes it performs the refresh but I need to close and open again the file to see the new changes.

  6. Scott Wells repo owner

    The last log is very helpful, Julio. In the previous log I can see where I'm scanning the metadata subscription for intersection with the request selection, but I don't see that in the latest log. Let me try to reproduce this a bit now that I know how your subscription is configured. Hopefully I'll be able to do so and then will be able to resolve it for you. I'll let you know something very shortly. Thank you very much for all the diagnostic info!

  7. Julio Enrique reporter

    Thanks to you Scott! The only thing that I don't have really clear is if I can refresh metadata that is not on the package.xml (metadata that was download via the retriever).

  8. Scott Wells repo owner

    I don't believe you can since it filters the metadata that will be refreshed based on what's present locally and what's in your configured subscription. It has to be in both to be considered for refresh.

  9. Scott Wells repo owner

    Julio, I'm still unable to reproduce this but have thoughts on how it might be happening. I've added a bit more debug logging to help flesh out those thoughts. Could you install this, reproduce the issue, and send over another log? Hopefully this will be the one that helps find the root cause!

  10. Scott Wells repo owner

    Thanks. So this:

    2017-01-04 11:10:15,989 [  36402]  DEBUG - intellij.builder.RefreshAction - Using metadata subscription:
    {
      "version": "38.0"
    } 
    

    tells me that it's either not able to read your package.xml properly but isn't throwing an error, or that it's misconfigured. Hopefully one last thing...do you mind sending me your .iml file for this module so I can look at exactly how your subscription is configured?

  11. Julio Enrique reporter

    Sure, attaching it. I remember that when I created the project based on my package.xml the file wasn't moved to the project directory. I had to moved it manually into there, I'll attach you the structure I have actually

  12. Scott Wells repo owner

    That file has the path to your package.xml as:

    <option name="packageXmlRelativePath" value="$USER_HOME$/Desktop/package.xml" />
    

    I bet that's the issue. Can you open the subscription settings screen (File>Project Structure>Modules>CCE DS1>Illuminated Cloud) and re-select the package.xml as the one in your src directory? After doing that, let's see whether this works properly.

  13. Scott Wells repo owner

    Julio, I'm going to resolve this for now. If you update your settings to point to the correct package.xml and things still aren't working properly, feel free to reopen.

  14. Julio Enrique reporter

    Hi Scott. Yes, it it working now, I didn't know that the project was directly referencing to the original suscriptor. Thank you very much.

  15. Scott Wells repo owner

    My pleasure! Thanks for providing so much diagnostic info so that we could get to the bottom of it.

  16. Log in to comment