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

[CLOSED] Ignore Live Dev toggle when in a connecting state #6382

Open
core-ai-bot opened this issue Aug 30, 2021 · 17 comments
Open

[CLOSED] Ignore Live Dev toggle when in a connecting state #6382

core-ai-bot opened this issue Aug 30, 2021 · 17 comments

Comments

@core-ai-bot
Copy link
Member

Issue by redmunds
Saturday Mar 01, 2014 at 02:04 GMT
Originally opened as adobe/brackets#7049


This is for #7014

cc@ingorichter


redmunds included the following code: https://github.com/adobe/brackets/pull/7049/commits

@core-ai-bot
Copy link
Member Author

Comment by ingorichter
Tuesday Mar 04, 2014 at 00:50 GMT


Unfortunately, this is not fixing the issue. It's a great improvement and I need to click far more often too before it stops working. But then I'll see the "Unable to load Live Development page" and the "Needs to restart Chrome" Error.

@core-ai-bot
Copy link
Member Author

Comment by redmunds
Tuesday Mar 04, 2014 at 01:29 GMT


I'm not sure exactly how we'd handle the "click on button as many times as you can and as fast as you can" case -- I think this applies to almost any button in brackets.

I think this is helpful for the case where Live Preview is connecting very slowly or connection is timing out and user is wondering what's going on (so they click again). Do you think it's worth getting this change in for Release 37, and then leave issue open to try to improve more?

@core-ai-bot
Copy link
Member Author

Comment by peterflynn
Tuesday Mar 04, 2014 at 02:48 GMT


I've also seen some people double-click the icon right off the bat, which seems like it could cause issues too.

@core-ai-bot
Copy link
Member Author

Comment by ingorichter
Wednesday Mar 05, 2014 at 07:19 GMT


@redmunds I think this is already an improvement over the previous behavior and I'm fine with merging this PR and iterate on this, if we receive more reports that users hit this issue. My behavior of constantly clicking the live preview icon was probably not even close to what a user might be doing, but it's not very unlikely too. For now, we should merge this PR and wait for feedback.@peterflynn what do you think?

@core-ai-bot
Copy link
Member Author

Comment by redmunds
Wednesday Mar 05, 2014 at 15:48 GMT


@ingorichter I updated this branch for the new Chrome v34 API changes that I merged into master last night.

@peterflynn This change handles double-click when opening Live Preview. But closing Live Preview is much faster, so it's already INACTIVE by the time the second click arrives, so Brackets is re-opened.

Note: with Chrome v34, you will see the following error, but only once:

'CSS.getAllStyleSheets' wasn't found Object {code: -32601, message: "'CSS.getAllStyleSheets' wasn't found"} 

This is not really an error, so maybe this message should be suppressed?@jasonsanjose Is there a way to detect what version of Chrome is being used so we could suppress this if version >= 34?

@core-ai-bot
Copy link
Member Author

Comment by jasonsanjose
Wednesday Mar 05, 2014 at 17:20 GMT


@redmunds I thought there would be some way to ask the inspector protocol what version is running, but there isn't. We'd have to modify our startup to do some user agent sniffing and make a best guess from there on whether or not to try the deleted API.

@core-ai-bot
Copy link
Member Author

Comment by ingorichter
Thursday Mar 06, 2014 at 19:36 GMT


@redmunds I'm going to give it a try later this afternoon.

@core-ai-bot
Copy link
Member Author

Comment by redmunds
Friday Mar 07, 2014 at 22:08 GMT


@jasonsanjose Any way to make this message sound less like an error?

'CSS.getAllStyleSheets' wasn't found 
    Object
        code: -32601
        message: "'CSS.getAllStyleSheets' wasn't found"
        __proto__: Object

    Object
        id: 8
        method: "CSS.getAllStyleSheets"
        params: Object
        __proto__: Object

_onError

Maybe something like:

'CSS.getAllStyleSheets' wasn't found - using 'CSS.addStyleSheet/removeStyleSheet' API

@core-ai-bot
Copy link
Member Author

Comment by jasonsanjose
Friday Mar 07, 2014 at 22:14 GMT


@redmunds I filed adobe/brackets#7127 for the error logging bug.

@core-ai-bot
Copy link
Member Author

Comment by jasonsanjose
Friday Mar 07, 2014 at 22:48 GMT


@ingorichter I branched off this PR into https://github.com/adobe/brackets/compare/jasonsanjose;issue-7014?expand=1. I added an extra precautions around reentrancy into open and close. Can you see if that fixes the errors causing you to see the "unable to load..." and "relaunch chrome..." dialogs?

@core-ai-bot
Copy link
Member Author

Comment by njx
Monday Mar 10, 2014 at 18:38 GMT


Are we planning to merge this for Sprint 37?

@core-ai-bot
Copy link
Member Author

Comment by ingorichter
Monday Mar 10, 2014 at 18:41 GMT


I would like to merge this. I'm currently testing it.

@core-ai-bot
Copy link
Member Author

Comment by jasonsanjose
Monday Mar 10, 2014 at 18:41 GMT


I would like to yes. I'm working with@ingorichter and@redmunds to see if my branch (with Randy's fixes) fixes the additional issues Ingo was seeing.

@core-ai-bot
Copy link
Member Author

Comment by njx
Monday Mar 10, 2014 at 18:52 GMT


OK, sounds good.

@core-ai-bot
Copy link
Member Author

Comment by njx
Monday Mar 10, 2014 at 18:57 GMT


Tagged sprint 37

@core-ai-bot
Copy link
Member Author

Comment by ingorichter
Monday Mar 10, 2014 at 19:05 GMT


@jasonsanjose this looks much better now. I haven't been able to repro the dialogs. I've tested your branch with Chrome 34 Beta and Chrome 33 Stable.

@core-ai-bot
Copy link
Member Author

Comment by jasonsanjose
Monday Mar 10, 2014 at 19:36 GMT


Thanks@ingorichter. I'll close this PR and open a new one for my branch, see #7148.

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

1 participant