I have tried a couple times.  My Android gradle stuff seems fine.
The geb-example-gradle ran (so I think it got everything.)

I'm pulling in the same module/versions with @Grab as I see in 
geb-example-gradle, so I guessed it was @Grab vs. whatever gradle does for 
dependencies { testCompile ... bla bla.)

My script starts with:

#!/bin/bash
//usr/bin/env groovy  -cp extra.jar:spring.jar:etc.jar -d 
-Dlog4j.configuration=file:/etc/myapp/log4j.xml "$0" $@; exit $?


@Grab(group='org.gebish',module='geb-spock', version='1.0-rc-1')
@Grab(group='org.seleniumhq.selenium',module='selenium-firefox-driver', 
version='2.51.0')
@Grab(group='org.seleniumhq.selenium',module='selenium-support', 
version='2.51.0')

import geb.Browser
import geb.Page

and those seem to match 

ext {
    // The drivers we want to use
    drivers = ["firefox", "chrome", "phantomJs"]

    ext {
        groovyVersion = '2.4.5'
        gebVersion = '1.0-rc-1'
        seleniumVersion = '2.51.0'
        chromeDriverVersion = '2.19'
        phantomJsVersion = '1.9.7'
    }
}

.... more stuff from the working geb-example-gradle-master....

dependencies {
    // If using Spock, need to depend on geb-spock
    testCompile "org.gebish:geb-spock:$gebVersion"
    testCompile("org.spockframework:spock-core:1.0-groovy-2.4") {
        exclude group: "org.codehaus.groovy"
    }
    testCompile "org.codehaus.groovy:groovy-all:$groovyVersion"

    // If using JUnit, need to depend on geb-junit (3 or 4)
    testCompile "org.gebish:geb-junit4:$gebVersion"

    // Drivers
    testCompile 
"org.seleniumhq.selenium:selenium-chrome-driver:$seleniumVersion"
    testCompile 
"org.seleniumhq.selenium:selenium-firefox-driver:$seleniumVersion"

The only difference seems to be @Grab vs gradle's depend.   (Might not be a 
special character, the default @Grab config stuff might differ from the 
Gradle, don't know, but that was my guess.)   


On Monday, September 26, 2016 at 5:17:54 PM UTC-4, Marcin Erdmann wrote:
>
> How did you get from the error you got to "Grab not supporting some 
> special characters somewhere"?
>
> Looks like it might simply be a connectivity issue. Did you try retrying?
>
> On Mon, Sep 26, 2016 at 9:54 PM, Dan Schmitt <[email protected] 
> <javascript:>> wrote:
>
>> So, if I wanted a command line web scraper with geb, and tried to use 
>> @Grab and got:
>>
>> General error during conversion: Error grabbing Grapes -- [download 
>> failed: commons-io#commons-io;2.4!commons-io.jar]
>>
>> but the https://github.com/geb/geb-example-gradle build works fine, 
>> that's likely some issue with Grab not supporting some special characters 
>> somewhere?
>>
>>   
>>
>> On Tuesday, June 7, 2016 at 3:11:21 AM UTC-4, Marcin Erdmann wrote:
>>>
>>> You need more Geb modules in your classpath. If you're a masochist then 
>>> you can have a look at the pom of geb-core and work out which dependencies 
>>> it has, there might be some that are transitive. Otherwise use a build 
>>> system to resolve your dependencies. I personally prefer Gradle but for the 
>>> purpose of resolving deps Maven will do just fine. If this thing will never 
>>> get serious and will stay a script forever then your third choice might 
>>> be using Groovy's @Grab annotation(s).
>>>
>>> On Tuesday, 7 June 2016, Sean Lanter <[email protected]> wrote:
>>>
>>>> I have a 2-line script "example.groovy" that does nothing more than 
>>>> create a default Browser:
>>>>
>>>>    import geb.Browser
>>>>    def browser = new Browser()
>>>>
>>>> When I run it as follows:
>>>>
>>>>    groovy -cp 
>>>> geb-core-0.13.1.jar:selenium-server-standalone-2.53.0.jar:.  example.groovy
>>>>
>>>> this is what comes back:
>>>>
>>>>    Caught: java.lang.NoClassDefFoundError: 
>>>> geb/error/UnableToLoadException
>>>>    java.lang.NoClassDefFoundError: geb/error/UnableToLoadException
>>>>        at geb.Browser.<init>(Browser.groovy:58)
>>>>        at example.run(example.groovy:2)
>>>>
>>>> The script and the two jars file are all in the same directory.
>>>>
>>>> I am certain I am missing something obvious...  Can someone point out 
>>>> what I am overlooking?
>>>>
>>>> TIA!
>>>>
>>>>
>>>> -- 
>>>> You received this message because you are subscribed to the Google 
>>>> Groups "Geb User Mailing List" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send 
>>>> an email to [email protected].
>>>> To post to this group, send email to [email protected].
>>>> To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/geb-user/94dcf964-a3a4-4443-81a2-e141a4b015ec%40googlegroups.com
>>>>  
>>>> <https://groups.google.com/d/msgid/geb-user/94dcf964-a3a4-4443-81a2-e141a4b015ec%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>> .
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Geb User Mailing List" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> To post to this group, send email to [email protected] 
>> <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/geb-user/3fe5318a-4cff-40d7-8742-9304de69ed7f%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/geb-user/3fe5318a-4cff-40d7-8742-9304de69ed7f%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups "Geb 
User Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/geb-user/87a41922-03e5-4c1b-8a3a-260db8b6afca%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to