Giter Site home page Giter Site logo

sfdx-travisci's Issues

"The callback URL provided is not valid" on JWT or SFDXURL Auth

I've been trying to login from Travis using the sfdx force:auth:sfdxurl:store command instead. However, when comes the time to spin-up a scratchorg, I am getting that error message:

 ERROR running force:org:create: The callback URL provided is not valid.

Any clue what can cause this / how it can be resolved?

travis login error from command line gitbash

    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/tools/github.rb:212:in `rescue in basic_auth'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/tools/github.rb:208:in `basic_auth'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/tools/github.rb:216:in `login'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/tools/github.rb:81:in `possible_tokens'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/tools/github.rb:50:in `each_token'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/tools/github.rb:37:in `with_token'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/cli/login.rb:31:in `login'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/cli/login.rb:40:in `run'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/cli/command.rb:198:in `execute'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/lib/travis/cli.rb:64:in `run'
    from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/travis-1.8.13/bin/travis:18:in `<top (required)>'
    from C:/Ruby26-x64/bin/travis:23:in `load'
    from C:/Ruby26-x64/bin/travis:23:in `<main>'

Tar ball file issue travis

Hi all,

I am currently encountering the following issue with the following line of the yml.
Error: "xz: (stdin): File format not recognized
tar: Child returned status 1
tar: Error is not recoverable: exiting now"

Line: "$ wget -qO- $URL | tar xJ -C sfdx --strip-components 1" when referencing the following variable
env:
matrix:
- URL=https://developer.salesforce.com/media/salesforce-cli/sfdx-linux-amd64.tar.xz

Guessing its an issue with what I am doing and not the script itself. Thanks.

Deleting Scrach Org failed with

I have been verifying the Travis CI aligned with the Trailhead module "Continuous Integration Using Salesforce DX"

https://trailhead.salesforce.com/en/content/learn/modules/sfdx_travis_ci

I revised the part of .travis.yml as shown below.

script:

However at the last line, deleting Scratch Org failed with following message.

image

Please let me know the correct way or any other workaround.

Best regards,

NoMethodError: undefined method `each_pair'

Im getting
NoMethodError: undefined method `each_pair'
while running the below command
travis env set CONSUMERKEY <your_consumer_key> travis env set USERNAME <your_username>

Build Error - YAML Line 16

screen shot 2017-07-05 at 4 06 16 pm

My builds keep failing, and I am not sure how to fix this. I tried changing server.key to server.key.enc since that is the file in the assets folder, but both ways failed.

ERROR running force:auth:jwt:grant: We encountered a JSON web token error, which is likely not an issue with Salesforce CLI. Here’s the error: error:0906D06C:PEM routines:PEM_read_bio:no start line

I'm able to use force:auth:jwt:grant locally and successfully log in to my org with the server.key file. However, when the build in travis-ci kicks off, i get this error:

ERROR running force:auth:jwt:grant: We encountered a JSON web token error, which is likely not an issue with Salesforce CLI. Here’s the error: error:0906D06C:PEM routines:PEM_read_bio:no start line

Not sure how to troubleshoot this one

Error when generating an RSA private key

Hi,
From within the certificates folder, I don't succeed to generate an RSA private key as described on the following screen copy:
image
Any insight would be greatly appreciated.

Scratch org definition is missing a closing } for the settings property

Now it is
{ "orgName": "wade.wegner Example", "edition": "Developer", "settings": { "lightningExperienceSettings": { "enableS1DesktopEnabled": true } }

it should be
{ "orgName": "wade.wegner Example", "edition": "Developer", "settings": { "lightningExperienceSettings": { "enableS1DesktopEnabled": true } } }

Travis CI builds failing on scratch org creation script

I thought I might drop this reference in the existing (and closed) issue #57 but not sure if this is due to some recent change on Salesforce's side?
Running the existing script with --wait 2 resulted in (from Travis logs):

$ sfdx force:org:create -v HubOrg -s -f config/project-scratch-def.json -a ciorg --wait 2
ERROR:  Invalid value was specified for wait. Please provide a wait value greater than 3 minutes.
The command "sfdx force:org:create -v HubOrg -s -f config/project-scratch-def.json -a ciorg --wait 2" exited with 1.

I literally just changed the value to 4, committed and pushed and the build went thru fine.
I'm new to both Salesforce and CI; Not sure if it's a temporary thing?

TravisCI build Error

I have got an error.when I build a job
travisci
can you please tell me.how to resolve the probelm
Thanks

Org creation and/or run test commands timeout or take much longer

As per the discussion on StackExchange I am still finding org creation hangs. I updated with the latest .yaml edits made to this repo and still had no luck. Is this build still working? I also see some comments from Travis support on the SE post above.

Finally i used the option described in the StackExchange post, while this works i do see a number of npm obsolete errors so would prefer to use the recommended approach from this repo.

My repository is https://github.com/afawcett/declarative-lookup-rollup-summaries. Note that the yaml also includes some changes to attempt to get test failures to abort the build. These edits in the script section where made afterward.

travisci build error

the log like this:

$ openssl aes-256-cbc -K $encrypted_79a2f6093848_key -iv $encrypted_79a2f6093848_iv -in assets/server.key.enc -out assets/server.key -d
bad decrypt
140707428578968:error:0606506D:digital envelope routines:EVP_DecryptFinal_ex:wrong final block length:evp_enc.c:518:
The command "openssl aes-256-cbc -K $encrypted_79a2f6093848_key -iv $encrypted_79a2f6093848_iv -in assets/server.key.enc -out assets/server.key -d" failed and exited with 1 during .
Your build has been stopped.
log.txt

Travis build fails due to depreciated settings in the project-scratch-de.json

Found this issue while running the trailhead this repository is used for. The ./config/project-scratch-de.json-file contains setting that are depreciated in sfdx. As recommended in the log (which can be found in the Travis CI build section), the parameter orgPreferences:

{
    "orgName": "wade.wegner Example",
    "edition": "Developer",
    "orgPreferences" : {
        "enabled": ["S1DesktopEnabled"]
    }
}

must be changed with settings according to the following:

{
    "orgName": "wade.wegner Example",
    "edition": "Developer",
    "settings": {
        "lightningExperienceSettings": {
           "enableS1DesktopEnabled": true
        }
    }
}

Have seen the warning about the depreciated parameter for scratch org configs in the interactive exercises within the SFDX trailhead lessons already, but the build on travis-ci probably handles the parameter more restricted.

Error in Travis CI build, bad decrypt, digital envelope routines:EVP_DecryptFinal_ex:wrong final block length:evp_enc.c:518:

I've been struggling a lot trying to complete this trailhead module. The first issue was while trying to log in with GitHub creds, which I solved using the GitHub-token flag.

Now, after I Kick-off Continuous Integration, it keeps failing over and over again.

The exception is iv undefined, which is no longer happening, not sure how it got fixed. And this
iv undefined
the last exception has become a real blocker. I can't figure out how to work around this.

Config File:

os: linux
dist: xenial
language: ruby
rvm:
  - 2.0.0
cache: false
env:
  - URL=https://developer.salesforce.com/media/salesforce-cli/sfdx-linux-amd64.tar.xz
before_install:
  - openssl aes-256-cbc -K $encrypted_79bf14636734_key -iv $encrypted_79bf14636734_iv
    -in assets/certs/server.key.enc -out assets/certs/server.key -d
  - export SFDX_AUTOUPDATE_DISABLE=false
  - export SFDX_USE_GENERIC_UNIX_KEYCHAIN=true
  - export SFDX_DOMAIN_RETRY=300
  - export SFDX_DISABLE_APP_HUB=true
  - export SFDX_LOG_LEVEL=DEBUG
  - mkdir sfdx
  - wget -qO- $URL | tar xJ -C sfdx --strip-components 1
  - "./sfdx/install"
  - export PATH=./sfdx/$(pwd):$PATH
  - sfdx --version
  - sfdx plugins --core
  - sfdx force:auth:jwt:grant --clientid $CONSUMERKEY --jwtkeyfile assets/server.key --username $USERNAME --setdefaultdevhubusername -a HubOrg
script:
  - sfdx force:org:create -v HubOrg -s -f config/project-scratch-def.json -a ciorg --wait 3
  - sfdx force:org:display -u ciorg
  - sfdx force:source:push -u ciorg
  - sfdx force:apex:test:run -u ciorg --wait 10
  - sfdx force:org:delete -u ciorg -p

I'm not sure what else to look at or do to make this work.

I'm trying to create a standard development pipeline, which is important to implement CI/CD.

Workstation settings:

Ruby version: 2.7.2
Travis version: 1.10.0
SFDX-cli version: 7.85.1
Already tested in Windows (local station) and AWS Ubuntu server, same results.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.