Skip to content
This repository was archived by the owner on Apr 5, 2018. It is now read-only.

Stuck Task, Local Environment Only #130

Closed
smockensturm opened this issue Aug 5, 2016 · 12 comments
Closed

Stuck Task, Local Environment Only #130

smockensturm opened this issue Aug 5, 2016 · 12 comments
Labels

Comments

@smockensturm
Copy link

What would cause an import to hang up and never finish? ( tiny .csv, < 1k, 1 record ) Orange dot in the history, unfinished task at the bottom of the CP nav...

This only happens on the local dev environment (remote mySQL). We have to manually clear the task from the database in order to even try again.

Up on the server it works like a champ. (we've increased local env PHP max_execution_time to no avail.)

Thanks.

Craft 2.6.2903
Import 0.8.28

@smockensturm
Copy link
Author

'devMode' => false

gets it working locally. painful to develop a plugin with hooks in that state, tho.

@boboldehampsink
Copy link
Owner

Looks like something you should contact Craft support with.

@johanneslamers
Copy link

Have exactly the same... devMode on false solved the problem

@smockensturm
Copy link
Author

Not really a solution. The overhead in devMode is no joke. Here's what Brad at P&T says:

devMode uses a lot more memory on a given PHP request and importing probably already requires significant memory, so my guess is that you're running into your php.ini file's memory_limit or max_execution_time limits or something similar.

Oh well. ¯_(ツ)_/¯

@smockensturm
Copy link
Author

We have increased memory_limit 10 fold (1280M)
We have increased max_execution_time 100 fold (30000)
We have increased max_input_time 100 fold (60000)

And STILL this Import plug-in hangs up in the first half a second when Craft devMode is set to true. What are we doing wrong? What else can we be looking for?

@boboldehampsink
Copy link
Owner

Do you use automatic task running? Do you use gzip? (maybe even unnoticed?). Do the logs say anything?

@smockensturm
Copy link
Author

No automatic task running. No gzip. But now... version 0.8.32 (dev mode true) can't even get past this error:

Undefined index: assetsource

(We should be able to use this plug-in without having to define an asset source.) When we do define an asset source (albeit empty) we get this error:

#133

So that's one issue (or two).

Prior to installing 0.8.32, we did manage to isolate the hanging import (dev mode true) to the mere presence of a SmartMap field in the targeted section. SmartMap developer says "don't use import in dev mode". Well that's just nuts.

So, at the moment, I cannot even duplicate the original problem (hanging import) with your latest release.

@smockensturm
Copy link
Author

Installed the development release, which appears to suppress the PHP asset errors. So now we're back to the hanging import. Again, traced to the presence of SmartMap.

But... the logs that we try to force here

#137

do get output when dev mode is true. Even though the import is unsuccessful.

I've zipped up and attached all logs here
Archive.zip

@boboldehampsink
Copy link
Owner

Ok, looks like a SmartMap issue then. File a bug report there.

@smockensturm
Copy link
Author

We're working on it. Thanks.

@lindseydiloreto
Copy link

RE: Smart Map...

It's a super edge case, but it seems like there's a conflict with devMode, Import, and geolocation. To circumvent this conflict, simply disable geolocation while you run the import.

Smart Map Settings

I'll continue to investigate until this is fully resolved, but this workaround should be satisfactory in most situations.

@lindseydiloreto
Copy link

This has been fixed for the next release of Smart Map.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants