Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug Fix] Prevents DB Queries running when Artisan is running commands #19

Merged
merged 2 commits into from
Dec 7, 2016

Conversation

OwenMelbz
Copy link

@OwenMelbz OwenMelbz commented Nov 30, 2016

Running the DB queries clashes with artisan cli when no database is available.

Meaning you cannot install/run artisan without setting up a database which makes deploying with systems like Envoyer, Codeship, Deploybot impossible.

@OwenMelbz OwenMelbz changed the title prevent schema testing from cli [Bug Fix] Prevents DB Queries running when Artisan is running commands Nov 30, 2016
@JoelESvensson
Copy link

My PR (#17) also fixes this

@tabacitu tabacitu merged commit e8381be into master Dec 7, 2016
@tabacitu tabacitu deleted the dev-artisanfix branch December 7, 2016 16:12
@OwenMelbz
Copy link
Author

<3 @tabacitu

@tabacitu
Copy link
Member

Hmm... @OwenMelbz this might have caused this issue: #21. Basically it won't publish the files anymore.

I think pulling these two lines out of the if (!\App::runningInConsole()) will fix it, but want to make sure it's still is ok with deploy systems. Could you please confirm? If so, I'll go ahead and make the fix.

Thanks, cheers!

@OwenMelbz
Copy link
Author

Ah shoot, yes that would make sense!

Sorry I was a bit rushed trying to get the project up for a demo and didn't notice that bit :(

@tabacitu
Copy link
Member

No worries, happens to all of us. Fixed in c82719f.

Cheers!

@Patabugen
Copy link

Is this addon not dependant on there being a Database? (since it stores the settings in the database?).

I'm probably missing a use case here - but making the library not work at all in Artisan so it can be run in some situations where someone's got no database but is still loading a library which depends on one seems like the lesser of the options.

Is there no way we can check for the presence of a database connection - and do nothing if we don't find one? Is it that common a problem to run Artisan without a DB where the HTTP version has one?

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.

None yet

4 participants