{"record":{"id":"f57c81ef4096c2d1","repo":"Tencent/tinker","slug":"please-specify-name-option-in-gradle-project-pr","errorCode":null,"errorMessage":"Please specify '$name' option in gradle project properties.","messagePattern":"Please specify '\\$name' option in gradle project properties\\.","errorType":"exception","errorClass":"GradleException","httpStatus":null,"severity":"warning","filePath":"gradle/PublishArtifact.gradle","lineNumber":5,"sourceCode":"apply from: rootProject.file('gradle/WeChatPublish.gradle')\n\ndef checkAndGetOption(name) {\n    if (!project.hasProperty(name)) {\n        throw new GradleException(\"Please specify '$name' option in gradle project properties.\")\n    }\n    return project[name]\n}\n\nwechatPublish {\n    pom {\n        name = checkAndGetOption('POM_NAME')\n        description = checkAndGetOption('POM_DESCRIPTION')\n        url = checkAndGetOption('POM_URL')\n\n        scm {\n            url = checkAndGetOption('POM_SCM_URL')\n        }\n\n        licenses {\n            license {\n                name = checkAndGetOption('POM_LICENCE_NAME')\n                url = checkAndGetOption('POM_LICENCE_URL')","sourceCodeStart":1,"sourceCodeEnd":23,"githubUrl":"https://github.com/Tencent/tinker/blob/1b7ea02c239840f563ea64fb5bd286eb98d4011e/gradle/PublishArtifact.gradle#L1-L23","documentation":"GradleException from gradle/PublishArtifact.gradle: the WeChat/Maven publishing configuration requires a set of POM_* project properties, and one named in the error is missing. The checkAndGetOption helper fails the build immediately when publishing tasks run without the property defined.","triggerScenarios":"Running publish/upload tasks (e.g., ./gradlew publishToMavenLocal or bintray upload) on a module applying PublishArtifact.gradle without the required POM_NAME, POM_DESCRIPTION, POM_URL, POM_SCM_URL, etc., defined in gradle.properties or via -P flags.","commonSituations":"Contributors or CI building the Tinker project itself (not app consumers) triggering publish tasks without the release engineer's gradle.properties; forks renaming publishing config; migrating publishing to another plugin while old tasks remain.","solutions":["Add the missing property (named in the message) to gradle.properties or pass -P<name>=value","If you do not intend to publish, avoid invoking publish/upload lifecycle tasks","For maintainers: publish from the release environment whose gradle.properties carries the full POM_* set"],"exampleFix":"# before (gradle.properties)\nPOM_NAME=Tinker\n\n# after (gradle.properties)\nPOM_NAME=Tinker\nPOM_DESCRIPTION=Tinker hotpatch\nPOM_URL=https://github.com/Tencent/tinker\nPOM_SCM_URL=https://github.com/Tencent/tinker.git","handlingStrategy":"validation","validationCode":"// build.gradle / CI check before publish tasks\ndef requiredPomProps = ['POM_NAME','POM_DESCRIPTION','POM_URL','POM_SCM_URL','POM_SCM_CONNECTION']\ndef missing = requiredPomProps.findAll { !project.hasProperty(it) }\nif (!missing.isEmpty()) {\n    throw new GradleException(\"Missing publish properties: \" + missing.join(', ') + \" — add to gradle.properties or skip publish tasks\")\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Keep the full POM_* property set in the release gradle.properties (out of VCS if needed)","Run publish tasks only in the release CI job that injects these properties"],"tags":["gradle","publishing","missing-property","build-config"],"backgroundTag":null,"analyzedSha":"1b7ea02c239840f563ea64fb5bd286eb98d4011e","analyzedAt":"2026-08-14T15:16:52.110Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}