Skip to content

Adds the option to throw an exception on missing parameters #107

Open
silvant wants to merge 3 commits into
Incenteev:masterfrom
silvant:excep-missing-params
Open

Adds the option to throw an exception on missing parameters #107
silvant wants to merge 3 commits into
Incenteev:masterfrom
silvant:excep-missing-params

Conversation

@silvant

@silvant silvant commented Jan 18, 2017

Copy link
Copy Markdown

in non-interactive mode, fixes #105

@stof stof left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this needs to be covered by tests

Comment thread Processor.php Outdated
{
// Simply use the expectedParams value as default for the missing params.
if (!$this->io->isInteractive()) {
if (isset($config['exception-when-missing'])) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should check the value of the config too. Setting it to false should not throw

@silvant silvant Jan 18, 2017

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree, I chose isset, as that is similar as keep-outdated. Recommend we change both them to !empty && Inline::parse !== false. Do you agree?

@silvant silvant force-pushed the excep-missing-params branch 2 times, most recently from 664d7e8 to c906e51 Compare January 18, 2017 19:32
…missing is true, and combines dist when exception-when-missing is false
@silvant silvant force-pushed the excep-missing-params branch from c906e51 to 111e111 Compare January 18, 2017 19:33
@silvant

silvant commented Jan 23, 2017

Copy link
Copy Markdown
Author

So apparently the Scrutinizer success result doesn't register here. Does somebody know how to fix this?
Otherwise I'll try an extra commit to see if that reruns Scrutinizer

@maffpool

Copy link
Copy Markdown

Any news about this feature ? I'm also very interested

@fduch

fduch commented Oct 25, 2017

Copy link
Copy Markdown

This one should be closed as duplicate in favor of #64

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Option to throw exception on missing parameters in non-interactive mode?

4 participants