• Resolved Felix

    (@ltse)


    Hi,

    When going to the Bulk Optimize tab, EWWW will ask me to Import the Attachements to the Database first.

    I ran this process already a few times but never managed to import all posts ~8000 and always ended with “Operation Interrupted” somewhere in the middle.

    Now the painful thing is that it doesn’t check the DB (I assume, didn’t look at the code) and always starts from the beginning.

    It would be really helpful if this process could be resumed.

    It would also help if there was a “try again” button for the failed ajax request instead of the “Operation Interrupted”. Maybe you could even implement an error handling mechanism to try the request again once or twice on error.

    https://www.ads-software.com/plugins/ewww-image-optimizer/

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author nosilver4u

    (@nosilver4u)

    My initial reaction was that I didn’t think it would be possible to implement an auto retry, but then I just had a very interesting thought that could be useful in several places. I’ll do some testing and get back to you.

    Thread Starter Felix

    (@ltse)

    Okay, cool!

    Looking forward to see what you come up with.

    Plugin Author nosilver4u

    (@nosilver4u)

    Well, it started out simple, but now I’m trying to make it a bit more elegant (with a timer and everything), and I’m running into some weirdness. I’ll push it out to ‘dev’ as soon as I figure out the problem.

    Plugin Author nosilver4u

    (@nosilver4u)

    Changes are in ‘dev’, allows 30 seconds/retries before dying completely:

    https://downloads.www.ads-software.com/plugin/ewww-image-optimizer.zip

    Plugin Author nosilver4u

    (@nosilver4u)

    sorry, forgot I only pushed it to the cloud version. porting the changes over to core shortly.

    Plugin Author nosilver4u

    (@nosilver4u)

    decided to go ahead and bump 1.9.3 out the door with the fix since I had a couple other things pending in there too, usually takes up to 15 minutes to become available.

    Thread Starter Felix

    (@ltse)

    Haha, cool I was looking at the code and couldn’t find any updates so I modified it myself.

    It’s running now and working quite well. I will update the plugin when it’s done with all posts and try out your method.

    You might want to consider optimizing the whole eio. It’s pretty confusing from a code style point of view and also doesn’t pass validation.

    Good job tho, don’t get me wrong ??

    Plugin Author nosilver4u

    (@nosilver4u)

    Yeah, it’s not a very organized bit of code, but I don’t look at it nearly as often, so it tends to get forgotten a bit. My javascript skills are not very polished either, so I could always use some pointers. What do you use for validating javascript?

    Thread Starter Felix

    (@ltse)

    Sorry for the late reply.

    For final validating, I like to use JSLint. However, you will most likely have to change the default options for your code to pass. It will always be best to adjust the options so that the code passes instead of ignoring errors.

    It will be easier for you if you have some Linting in your Editor. You could for example use SublimeLinter for Sublime Text 3 with the gjslint plugin (Interface for Google Closure Linter).

    If you need any help or more resources, I can email you.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Bulk Optimize Import to DB interrupted’ is closed to new replies.