lando / docs

The main docs site for Lando
https://docs.lando.dev/
GNU General Public License v3.0
20 stars 56 forks source link

Quotes are required for some version numbers #53

Closed travis-bradbury closed 5 years ago

travis-bradbury commented 5 years ago

Tell us about your setup

What is your lando version and operating system?

v3.0.0-rc.14 on Ubuntu 18.04.1 LTS

Tell us about your .lando.yml Tell us about the command you were running

$ cat .lando.yml 
name: test
recipe: drupal7
config:
  php: 7.0
$ lando start
Let's get this party started! Starting app..
error: TypeError: Invalid Version: 7.0
    at new SemVer (/snapshot/lando/build/cli/node_modules/semver/semver.js:312:11)
    at compare (/snapshot/lando/build/cli/node_modules/semver/semver.js:585:10)
    at Function.gt (/snapshot/lando/build/cli/node_modules/semver/semver.js:614:10)
    at new LandoPhp (/snapshot/lando/build/cli/plugins/lando-services/services/php/builder.js:0:0)
    at module.exports.app.events.on._.forEach.service (/snapshot/lando/build/cli/plugins/lando-services/app.js:0:0)
    at arrayEach (/snapshot/lando/build/cli/node_modules/lodash/lodash.js:516:11)
    at Function.forEach (/snapshot/lando/build/cli/node_modules/lodash/lodash.js:9344:14)
    at AsyncEvents.module.exports.app.events.on (/snapshot/lando/build/cli/plugins/lando-services/app.js:0:0)
    at AsyncEvents.handle (/snapshot/lando/build/cli/lib/events.js:0:0)
    at emit.Promise.each.fn (/snapshot/lando/build/cli/lib/events.js:0:0)
From previous event:
    at AsyncEvents.emit (/snapshot/lando/build/cli/lib/events.js:0:0)
    at module.exports.init.loadPlugins.then (/snapshot/lando/build/cli/lib/app.js:0:0)
From previous event:
    at App.init (/snapshot/lando/build/cli/lib/app.js:0:0)
    at initAndReport (/snapshot/lando/build/cli/lib/app.js:0:0)
    at App.start (/snapshot/lando/build/cli/lib/app.js:0:0)
    at Object.exports.appToggle (/snapshot/lando/build/cli/plugins/lando-core/lib/utils.js:0:0)
    at Object.run (/snapshot/lando/build/cli/plugins/lando-core/tasks/start.js:0:0)
    at module.exports.parseToYargs.checkForUpdates.then.lando.bootstrap.then.lando.events.emit.then.then.then.then.then (/snapshot/lando/build/cli/lib/cli.js:0:0)
From previous event:
    at module.exports.parseToYargs.checkForUpdates.then.lando.bootstrap.then.lando (/snapshot/lando/build/cli/lib/cli.js:0:0)
From previous event:
    at module.exports.parseToYargs.checkForUpdates.then (/snapshot/lando/build/cli/lib/cli.js:0:0)
    at runCallback (timers.js:696:18)
    at tryOnImmediate (timers.js:667:5)
    at processImmediate (timers.js:649:5)
From previous event:
    at Object.handler (/snapshot/lando/build/cli/lib/cli.js:0:0)
    at Object.runCommand (/snapshot/lando/build/cli/node_modules/yargs/lib/command.js:238:44)
    at Object.parseArgs [as _parseArgs] (/snapshot/lando/build/cli/node_modules/yargs/yargs.js:1063:30)
    at Function.get [as argv] (/snapshot/lando/build/cli/node_modules/yargs/yargs.js:1004:21)
    at Cli.run (/snapshot/lando/build/cli/lib/cli.js:0:0)
    at Object.<anonymous> (/snapshot/lando/build/cli/bin/lando.js:0:0)
    at Module._compile (pkg/prelude/bootstrap.js:1254:22)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:711:10)
    at Module.load (internal/modules/cjs/loader.js:610:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:549:12)
    at Function.Module._load (internal/modules/cjs/loader.js:541:3)
    at Function.Module.runMain (pkg/prelude/bootstrap.js:1309:12)
    at startup (internal/bootstrap/node.js:274:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:608:3)
$ sed -i "s/7.0/'7.0'/" .lando.yml
$ lando start
Let's get this party started! Starting app..
landoproxyhyperion5000gandalfedition_proxy_1 is up-to-date
Pulling appserver (devwithlando/php:7.0-apache-2)...
...
$ lando destroy
$ sed -i "s/'7.0'/7.1/" .lando.yml
$ lando start
Let's get this party started! Starting app..
landoproxyhyperion5000gandalfedition_proxy_1 is up-to-date
Creating network "test_default" with the default driver
Creating volume "test_data_appserver" with default driver
Creating volume "test_home_appserver" with default driver
Creating volume "test_data_database" with default driver
Creating volume "test_home_database" with default driver
Pulling appserver (devwithlando/php:7.1-apache-2)...

Tell us about the error you got

$ lando start -vvv
...
debug: App config for test is {"name":"test","recipe":"drupal7","config":{"php":7}}
Let's get this party started! Starting app..
debug: Emitting event message
debug: Event message has 0 listeners
verbose: Initiatilizing app test from /home/tbradbury/projects/landotest
debug: App test uses config {"name":"test","recipe":"drupal7","config":{"php":7},"files":["/home/tbradbury/projects/landotest/.lando.yml"]}
verbose: Loading event post-init priority 5
verbose: Loading event post-start priority 5
verbose: Loading event post-init priority 5
verbose: Loading event post-init priority 10
verbose: Loading event post-stop priority 5
verbose: Loading event post-start priority 1
verbose: Loading event post-start priority 10
verbose: Plugin lando-core loaded from /snapshot/lando/build/cli/plugins/lando-core/app.js
debug: Plugin lando-core has {"env":{"LANDO_APP_PROJECT":"test","LANDO_APP_NAME":"test","LANDO_APP_ROOT":"/home/tbradbury/projects/landotest","LANDO_APP_ROOT_BIND":"/home/tbradbury/projects/landotest","BITNAMI_DEBUG":"true"},"labels":{"io.lando.src":"/home/tbradbury/projects/landotest/.lando.yml","io.lando.http-ports":"80,443"}}
verbose: Plugin lando-events loaded from /snapshot/lando/build/cli/plugins/lando-events/app.js
debug: Plugin lando-events has undefined
verbose: Loading event post-start priority 1
verbose: Loading event post-init priority 1
verbose: Plugin lando-networking loaded from /snapshot/lando/build/cli/plugins/lando-networking/app.js
debug: Plugin lando-networking has undefined
verbose: Plugin lando-pantheon loaded from /snapshot/lando/build/cli/plugins/lando-pantheon/app.js
debug: Plugin lando-pantheon has undefined
verbose: Loading event pre-start priority 1
verbose: Loading event post-start priority 5
verbose: Loading event post-init priority 5
verbose: Plugin lando-proxy loaded from /snapshot/lando/build/cli/plugins/lando-proxy/app.js
debug: Plugin lando-proxy has undefined
verbose: Loading event pre-init priority 4
verbose: Loading event post-uninstall priority 5
verbose: Plugin lando-recipes loaded from /snapshot/lando/build/cli/plugins/lando-recipes/app.js
debug: Plugin lando-recipes has undefined
verbose: Loading event pre-init priority 5
verbose: Loading event post-init priority 5
verbose: Loading event ready priority 5
verbose: Loading event post-uninstall priority 5
verbose: Plugin lando-services loaded from /snapshot/lando/build/cli/plugins/lando-services/app.js
debug: Plugin lando-services has undefined
verbose: Plugin lando-sharing loaded from /snapshot/lando/build/cli/plugins/lando-sharing/app.js
debug: Plugin lando-sharing has undefined
verbose: Loading event post-init priority 5
verbose: Loading event ready priority 5
verbose: Loading event post-uninstall priority 5
verbose: Plugin lando-tooling loaded from /snapshot/lando/build/cli/plugins/lando-tooling/app.js
debug: Plugin lando-tooling has undefined
info: Starting app name test!
debug: Emitting event pre-init
debug: Event pre-init has 2 listeners
verbose: Building drupal7 named test
verbose: Building php 7 named appserver
error: TypeError: Invalid Version: 7.0
    at new SemVer (/snapshot/lando/build/cli/node_modules/semver/semver.js:312:11)
    at compare (/snapshot/lando/build/cli/node_modules/semver/semver.js:585:10)
    at Function.gt (/snapshot/lando/build/cli/node_modules/semver/semver.js:614:10)
    at new LandoPhp (/snapshot/lando/build/cli/plugins/lando-services/services/php/builder.js:0:0)
    at module.exports.app.events.on._.forEach.service (/snapshot/lando/build/cli/plugins/lando-services/app.js:0:0)
    at arrayEach (/snapshot/lando/build/cli/node_modules/lodash/lodash.js:516:11)
    at Function.forEach (/snapshot/lando/build/cli/node_modules/lodash/lodash.js:9344:14)
    at AsyncEvents.module.exports.app.events.on (/snapshot/lando/build/cli/plugins/lando-services/app.js:0:0)
    at AsyncEvents.handle (/snapshot/lando/build/cli/lib/events.js:0:0)
    at emit.Promise.each.fn (/snapshot/lando/build/cli/lib/events.js:0:0)
From previous event:
    at AsyncEvents.emit (/snapshot/lando/build/cli/lib/events.js:0:0)
    at module.exports.init.loadPlugins.then (/snapshot/lando/build/cli/lib/app.js:0:0)
From previous event:
    at App.init (/snapshot/lando/build/cli/lib/app.js:0:0)
    at initAndReport (/snapshot/lando/build/cli/lib/app.js:0:0)
    at App.start (/snapshot/lando/build/cli/lib/app.js:0:0)
    at Object.exports.appToggle (/snapshot/lando/build/cli/plugins/lando-core/lib/utils.js:0:0)
    at Object.run (/snapshot/lando/build/cli/plugins/lando-core/tasks/start.js:0:0)
    at module.exports.parseToYargs.checkForUpdates.then.lando.bootstrap.then.lando.events.emit.then.then.then.then.then (/snapshot/lando/build/cli/lib/cli.js:0:0)
From previous event:
    at module.exports.parseToYargs.checkForUpdates.then.lando.bootstrap.then.lando (/snapshot/lando/build/cli/lib/cli.js:0:0)
From previous event:
    at module.exports.parseToYargs.checkForUpdates.then (/snapshot/lando/build/cli/lib/cli.js:0:0)
    at runCallback (timers.js:696:18)
    at tryOnImmediate (timers.js:667:5)
    at processImmediate (timers.js:649:5)
From previous event:
    at Object.handler (/snapshot/lando/build/cli/lib/cli.js:0:0)
    at Object.runCommand (/snapshot/lando/build/cli/node_modules/yargs/lib/command.js:238:44)
    at Object.parseArgs [as _parseArgs] (/snapshot/lando/build/cli/node_modules/yargs/yargs.js:1063:30)
    at Function.get [as argv] (/snapshot/lando/build/cli/node_modules/yargs/yargs.js:1004:21)
    at Cli.run (/snapshot/lando/build/cli/lib/cli.js:0:0)
    at Object.<anonymous> (/snapshot/lando/build/cli/bin/lando.js:0:0)
    at Module._compile (pkg/prelude/bootstrap.js:1254:22)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:711:10)
    at Module.load (internal/modules/cjs/loader.js:610:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:549:12)
    at Function.Module._load (internal/modules/cjs/loader.js:541:3)
    at Function.Module.runMain (pkg/prelude/bootstrap.js:1309:12)
    at startup (internal/bootstrap/node.js:274:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:608:3)
...

Tell us generally about your bug

Yaml generally doesn't require quotes. Version numbers may be a case where numbers should be quoted since they're not really numbers, but if it's required it should be done that way in documentation. https://docs.devwithlando.io/tutorials/drupal7.html, for example, sets the php version without quotes: php: 7.2

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues.

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues.

pirog commented 5 years ago

unstale