I'm receiving this error when trying to run a Jenkins Job. The file configuration seems to be valid. What steps should I take to troublshoot this issue?

Problem: failed to create task or type antlib:com.salesforce:deploy
    Cause: The name is undefined.
    Action: Check the spelling.
    Action: Check that any custom tasks/types have been declared.
    Action: Check that any <presetdef>/<macrodef> declarations have taken place.
    No types or tasks have been defined in this namespace yet

    This appears to be an antlib declaration. 
    Action: Check that the implementing library exists in one of:
            -a directory added on the command line with the -lib argument

Usually this means that your build.xml file can't find the salesforce ant jar file. Check out https://developer.salesforce.com/docs/atlas.en-us.daas.meta/daas/forcemigrationtool_install.htm

| improve this answer | |
  • Thanks... I'm getting this error now Git/build.xml:24: sf:deploy doesn't support the "testLevel" attribute – VanAlfredo Nov 10 '17 at 15:45
  • I ended up downloading an updated version of the migration tool and it seems to be working. Thanks! – VanAlfredo Nov 10 '17 at 17:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.