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

Suddently stopped working #296

Open
fcojavierdomenech opened this issue May 14, 2020 · 26 comments
Open

Suddently stopped working #296

fcojavierdomenech opened this issue May 14, 2020 · 26 comments

Comments

@fcojavierdomenech
Copy link

Since a few hours it stopped working, something related to google servers? Anyone experimented the same?

@bresam
Copy link

bresam commented May 14, 2020

Yes, seems google changed something and the jsapi Endpoint gets now redirected to antoher source which does not work with the existing implementation.

Currently working on a fix

@fcojavierdomenech
Copy link
Author

Thank god, I'll be taking a look too, please update with anything

@fcojavierdomenech
Copy link
Author

fcojavierdomenech commented May 14, 2020

Umm, unfortunately I'm not the right guy for this task, more of a backend type. Anyway, I found a temp fix, just initialize yourself the map when on_ready:

/** Inittialize: hidding notifications **/
$( document ).ready(function() {
    ivory_google_map_load();
});

As far as I can tell: Loading Maps API with the jsapi loader is deprecated. So we should update the way we load Google's charts: https://developers.google.com/chart/interactive/docs/basic_load_libs

@ebrost
Copy link

ebrost commented May 14, 2020

Same problem but fix from vivoconunxino didn't solve the problem

/** Inittialize: hidding notifications **/
$( document ).ready(function() {
    ivory_google_map_load();
});

@ebrost
Copy link

ebrost commented May 14, 2020

my quick and dirty workaround:

  var i=setInterval(function(){
        if(typeof {{ map.variable }}!=='undefined'){
            clearInterval(i);
        }
        else{
            if (window.google){
                ivory_google_map_load();
            }
        }
    },100);

@fcojavierdomenech
Copy link
Author

Yep, I just realized mine works only on Firefox

@bresam
Copy link

bresam commented May 19, 2020

I have invested a lot of work in updating the package so far and have reached an aplha state. There are still issues with loading libraries and some fixes in the unit tests. Version 3.0.1 will then definitely be clean (probably by the end of the week).

I'm currently trying to contact the current maintainer to take over the maintenance, if he still hasn't answered by the end of the week, I will register my package at Packagist myself.

You can find the update at https://github.com/bresam/ivory-google-map
As I said, it is not quite stable at the moment, but soon.
It is being maintained and pull requests are welcome.

@fcojavierdomenech
Copy link
Author

fcojavierdomenech commented May 19, 2020

I hope the maintainer responses, otherwise I'll gladly switch to yours. Thanks

@gavelez35
Copy link

gavelez35 commented May 20, 2020

Thank you @bresam for stepping in to fix this. We are using this library for a software based on map routing, so this is a big deal for us - much appreciated!

If it is of any help, the issue was intermittent for us. For some days and hours it works and all loads correctly, and then for a few hours in the day it does not work. When this call loads correctly in the script WITHOUT a 302 redirect, it seems that everything loads correctly: https://www.google.com/jsapi?callback=ivory_google_map_load.

However, as is the case now in our app, whenever that call to jsapi returns a 302 redirect, it seems like the libraries are not loaded correctly.

@bresam
Copy link

bresam commented May 20, 2020

Hi @gavelez35

Yes we have observed the same thing, it seems that Google has temporarily fixed the redirection. For this reason I have now also reduced my workload on this fix to a human level, but I think the most issues should be done by the end of the week.

I've already switched to the new API URL, but I still have to fix the loading of the optional libraries (e.g. geometry library). Basic functionality is already running again with version 3.0.0.

For those of you who are interested, @egeloen has not responded yet.

@gavelez35
Copy link

You are awesome @bresam! Thank you for your note! I'll stay tuned

@alva2409
Copy link

alva2409 commented May 21, 2020

Hi @bresam
Thank you!!! Can you add support of php7.0? I am not able to use php7.2 in project :(

@gavelez35
Copy link

We also have php 7.0 :) but if absolutely needed, we'll have to see about upgrading.

cc @alva2409 @bresam

@gavelez35
Copy link

Hi folks, I have not uploaded to Samuel's 3.0 version but everything seems to be working well once again on the latest release from Eric (@egeloen) ... is anyone else experiencing this? It seems that Google has fixed the redirection for good for now, but I have not been able to dig up any definitive proof on the internet...

cc @bresam @egeloen @vivoconunxino @alva2409 @ebrost

@bresam
Copy link

bresam commented May 25, 2020

Yes the old way is working again, but i couldnt find any proof for that on the internet too. But in the long run it makes sense to switch to the new endpoints. But the good thing is, we dont have to hurry with that.

@gavelez35
Copy link

Thank you for the response @bresam, at least things are working once again :) It is also great to hear that we are not in a mad rush anymore, lol BTW, did you ever get a hold of @egeloen? I also sent him a quick message and I have not heard back. I hope all is well with him... we may have to adopt your repo if that will be maintained going forward...

@bresam
Copy link

bresam commented May 26, 2020

Nope, sent him 2 emails, but got no response yet. Theres nothing happening on that repo since 3 years, so i dont think he will respond these days.

@gavelez35
Copy link

Hey everyone, is anyone else seeing this same issue today?

@bresam @vivoconunxino @alva2409

@fcojavierdomenech
Copy link
Author

I'm stll going with the temp fix until bresam takes control over the repo, then I'll update or move to its repo, depending on whatever he decides.
So no, I'm not seeing the issue, I suggest you checking #296 (comment) or updating to bresam's

@gavelez35
Copy link

Thank you @vivoconunxino - I'll check it out! :)

@bresam
Copy link

bresam commented Jun 11, 2020

I've installed https://github.com/bresam/ivory-google-map right now on a project, works smooth.
All Tests passing.
But you have to require it by repository. will do a stable release on packagist supporting php7.0+ as soon as possible.

@bresam
Copy link

bresam commented Jun 11, 2020

@alva2409 @ebrost @vivoconunxino @gavelez35 @mariemchtourou

It's now available at packagist.

ivory/google-map
Or even ivory/google-map-bundle

I had to fork and update the bundle too due to some path issues.
I will maintain both, but firstable both are working fine, as far i can see.

If you notice that the Travis builds fail, all tests run successfully, I just have to fix the Travis config.

@gavelez35
Copy link

image
@bresam thank you once again, it seems that there is some syntax that only works in PHP 7.1 and above (see image attachment).

@bresam
Copy link

bresam commented Jun 12, 2020

@gavelez35
Huch, i missed these when downgraded to 7.0, will be fixed today, thanks for the report.
Feel free to use issues on the new repo.
Best Samuel

@bresam
Copy link

bresam commented Jun 12, 2020

Issue solved

@gavelez35
Copy link

@bresam I was thinking about that too when I caught that, lol :) Thank you very much Samuel and I'll be sure to report any new issues in that new repo 👍

Regards,
Gustavo

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

No branches or pull requests

5 participants