{"action":"created","issue":{"url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin/issues/11","repository_url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin","labels_url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin/issues/11/labels{/name}","comments_url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin/issues/11/comments","events_url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin/issues/11/events","html_url":"https://github.com/unbroken-dome/gradle-xjc-plugin/issues/11","id":381624337,"node_id":"MDU6SXNzdWUzODE2MjQzMzc=","number":11,"title":"Circular Dependency Error After Removing From Main Source Set","user":{"login":"aorze","id":45100313,"node_id":"MDQ6VXNlcjQ1MTAwMzEz","avatar_url":"https://avatars3.githubusercontent.com/u/45100313?v=4","gravatar_id":"","url":"https://api.github.com/users/aorze","html_url":"https://github.com/aorze","followers_url":"https://api.github.com/users/aorze/followers","following_url":"https://api.github.com/users/aorze/following{/other_user}","gists_url":"https://api.github.com/users/aorze/gists{/gist_id}","starred_url":"https://api.github.com/users/aorze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aorze/subscriptions","organizations_url":"https://api.github.com/users/aorze/orgs","repos_url":"https://api.github.com/users/aorze/repos","events_url":"https://api.github.com/users/aorze/events{/privacy}","received_events_url":"https://api.github.com/users/aorze/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-11-16T14:35:34Z","updated_at":"2018-11-23T19:52:45Z","closed_at":null,"author_association":"NONE","body":"I am attempting to separate my xjc generated sources from the main source set (for project specific reasons).  However, it keeps failing due to a circular dependency error.\r\n\r\nMy build.gradle contains:\r\n\r\n```\r\nxjc {\r\n  includeInMainCompilation = false\r\n}\r\n\r\nsourceSets {\r\n    generated { java { srcDir xjcGenerate.outputDirectory } }\r\n}\r\n\r\ncompileGeneratedJava {\r\n    dependsOn xjcGenerate\r\n}\r\n\r\ndependencies {\r\n    compile sourceSets.generated.output\r\n}\r\n```\r\n\r\nThe actual error message is:\r\n```\r\n* What went wrong:\r\nCircular dependency between the following tasks:\r\n:compileGeneratedJava\r\n\\--- :xjcGenerate\r\n     \\--- :generatedClasses\r\n          \\--- :compileGeneratedJava (*)\r\n\r\n(*) - details omitted (listed previously)\r\n```\r\n\r\nI am not understanding why adding the generated.output dependency on the compilation of the main source set is causing xjcGenerate to depend on the generatedClasses task.  If I remove the dependency, xjcGenerate is listed as having no dependencies (as seen using the task-tree plugin) which is what I would expect but obviously the xjc generated files are now no longer included while compiling main, which I need.  Is this a bug in the plugin or am I doing something wrong?\r\n\r\nI have attached a small but complete project that demonstrates this problem.\r\n[xjc-sample.zip](https://github.com/unbroken-dome/gradle-xjc-plugin/files/2589573/xjc-sample.zip)\r\n"},"comment":{"url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin/issues/comments/441310153","html_url":"https://github.com/unbroken-dome/gradle-xjc-plugin/issues/11#issuecomment-441310153","issue_url":"https://api.github.com/repos/unbroken-dome/gradle-xjc-plugin/issues/11","id":441310153,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MTMxMDE1Mw==","user":{"login":"tkrullmann","id":13819430,"node_id":"MDQ6VXNlcjEzODE5NDMw","avatar_url":"https://avatars3.githubusercontent.com/u/13819430?v=4","gravatar_id":"","url":"https://api.github.com/users/tkrullmann","html_url":"https://github.com/tkrullmann","followers_url":"https://api.github.com/users/tkrullmann/followers","following_url":"https://api.github.com/users/tkrullmann/following{/other_user}","gists_url":"https://api.github.com/users/tkrullmann/gists{/gist_id}","starred_url":"https://api.github.com/users/tkrullmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tkrullmann/subscriptions","organizations_url":"https://api.github.com/users/tkrullmann/orgs","repos_url":"https://api.github.com/users/tkrullmann/repos","events_url":"https://api.github.com/users/tkrullmann/events{/privacy}","received_events_url":"https://api.github.com/users/tkrullmann/received_events","type":"User","site_admin":false},"created_at":"2018-11-23T19:52:45Z","updated_at":"2018-11-23T19:52:45Z","author_association":"MEMBER","body":"Should be fixed in 1.4.1, please try"}}
{"actor":{"display_login":"tkrullmann"}}