[ https://issues.apache.org/jira/browse/GROOVY-8632?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
John Wagenleitner reassigned GROOVY-8632: ----------------------------------------- Assignee: John Wagenleitner > Groovy 2.5.0 fails to compile Google Java Client sample code > ------------------------------------------------------------ > > Key: GROOVY-8632 > URL: https://issues.apache.org/jira/browse/GROOVY-8632 > Project: Groovy > Issue Type: Bug > Components: Compiler > Affects Versions: 2.5.0 > Environment: Ubuntu 18.04, Oracle Java 1.8.0_171-b11, Groovy 2.5.0 > Reporter: Robert Kasanicky > Assignee: John Wagenleitner > Priority: Major > > I have been using Google Java Client libraries with Groovy 2.4.x successfully > but now I'm getting multiple compilation errors when trying to upgrade to > Groovy 2.5.0. Note that none of the classes mentioned are actually abstract > although the 2.5.0 compiler clearly thinks they are. > {code} > @Grab('com.google.apis:google-api-services-analyticsreporting:v4-rev124-1.23.0') > import com.google.api.services.analyticsreporting.v4.AnalyticsReporting > @Grab('com.google.apis:google-api-services-sheets:v4-rev525-1.23.0') > import com.google.api.services.sheets.v4.Sheets > @Grab('com.google.apis:google-api-services-drive:v3-rev120-1.23.0') > import com.google.api.services.drive.Drive > final HTTP_TRANSPORT = null > final JSON_FACTORY = null > def requestInitializer = null > def credential = null > def builderAnalytics = new AnalyticsReporting.Builder(HTTP_TRANSPORT, > JSON_FACTORY, requestInitializer) > def builderSheets = new Sheets.Builder(HTTP_TRANSPORT, JSON_FACTORY, > credential) > def builderDrive = new Drive.Builder(HTTP_TRANSPORT, JSON_FACTORY, credential) > {code} > {code} > org.codehaus.groovy.control.MultipleCompilationErrorsException: startup > failed: > /home/edited/bug25.groovy: 13: You cannot create an instance from the > abstract class > 'com.google.api.services.analyticsreporting.v4.AnalyticsReporting$Builder'. > @ line 13, column 24. > def builderAnalytics = new AnalyticsReporting.Builder(HTTP_TRANSPORT, > JSON_FACTORY, requestInitializer) > ^ > /home/edited/bug25.groovy: 15: You cannot create an instance from the > abstract class 'com.google.api.services.sheets.v4.Sheets$Builder'. > @ line 15, column 21. > def builderSheets = new Sheets.Builder(HTTP_TRANSPORT, JSON_FACTORY, > credential) > ^ > /home/edited/bug25.groovy: 17: You cannot create an instance from the > abstract class 'com.google.api.services.drive.Drive$Builder'. > @ line 17, column 20. > def builderDrive = new Drive.Builder(HTTP_TRANSPORT, JSON_FACTORY, > credential) > {code} > -- This message was sent by Atlassian JIRA (v7.6.3#76005)