Code Monkey home page Code Monkey logo

Comments (20)

bdkjones avatar bdkjones commented on September 23, 2024

Do you see any errors in the browser's JavaScript console?

Sent from my iPhone

On May 18, 2016, at 09:34, RJ McCollam [email protected] wrote:

Quick, short summary
The red "lost contact with CodeKit" bar is constantly appearing when viewing the project through the .local domain.

Expected results
You should click this so that it can re-establish the connection to CodeKit and it should correct itself.

Actual results
The page will refresh, but the connection back to CodeKit cannot be made so the red bar persists.

Exact steps to reproduce

Added project to CodeKit
Viewed project via .local:5757 domain
Visited new page and problem occurred
A link to download a simplified project or file that shows the issue.
https://www.dropbox.com/s/l22yvs5z2qpktp1/hector.zip?dl=0 (just theme that is the actual CodeKit project)

Your configuration (any details about your system that you think might be relevant).

Running OS X 10.11.5
The CodeKit project is a WordPress theme
Using MAMP Pro (most current version) as server and doing browser refreshing via the MAMP Pro URL

You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub

from codekit.

rjmccollam avatar rjmccollam commented on September 23, 2024

Yes I see the following error in the console

WebSocket connection to 'ws://rjs-imac.local:5758/' failed: Connection closed before receiving a handshake response

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024

Does the issue persist if you use the other two preview server addresses?

Sent from my iPhone

On May 18, 2016, at 11:43, RJ McCollam [email protected] wrote:

Yes I see the following error in the console

WebSocket connection to 'ws://rjs-imac.local:5758/' failed: Connection closed before receiving a handshake response


You are receiving this because you commented.
Reply to this email directly or view it on GitHub

from codekit.

rjmccollam avatar rjmccollam commented on September 23, 2024

When I use the other two server addresses it is not constant. Browser refreshing works like you would expect.

The red bar does still pop up every time I click a link to visit a new page though, but is gone when the new page loads.

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024

Ok, this may be related to your network. Which router are you using? Next, can you test the app on a different network? Work, coffee shop, etc?

In some cases, your router handles Bonjour name resolution, which can produce all sorts of issues if you're on old hardware.

from codekit.

rjmccollam avatar rjmccollam commented on September 23, 2024

I am using the most recent iteration of Apple's Time Capsule.

I switched off that network and onto my phone for tethering since I am running this on an iMac. At first the red bar only displayed when i would click to another page and then stay gone when the new page loaded, but then the issue of it always being there started happening again.

I did just go ahead and clear my cookies and cache in Chrome just in case there was anything in the browser causing it, and it seemed to have helped. At the moment the bar is not there consistently, but it does still pop up when I click a link to another page and then disappears when the new page loads.

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024
  1. Can you test this on a different LAN? Work, coffeeshop, etc?
  2. Does this issue also affect you in CodeKit 2.0?

from codekit.

silverjerk avatar silverjerk commented on September 23, 2024

I had the same issue. Running a Netgear Nighthawk. Latest version of OS X, MAMP, using .local URL's.

  1. Issue was not present on another network. Issue was not present when using a wired connection on current network. Issue was not present while drinking coffee at a local Starbucks, while Mac was at home...presumably.
  2. Cannot reproduce the issue with CodeKit 2.0.

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024

Ok. Is it always an issue with 3.0 on your home network? And is SSL off?

Sent from my iPhone

On May 20, 2016, at 15:43, Joey English [email protected] wrote:

I had the same issue. Running a Netgear Nighthawk. Latest version of OS X, MAMP, using .local URL's.

Issue was not present on another network. Issue was not present when using a wired connection on current network. Issue was not present while drinking coffee at a local Starbucks, while Mac was at home...presumably.
Cannot reproduce the issue with CodeKit 2.0.

You are receiving this because you commented.
Reply to this email directly or view it on GitHub

from codekit.

silverjerk avatar silverjerk commented on September 23, 2024

It's intermittent; trying to find a consistent way to reproduce it. So far, it only happens (or appears to only happen) on Wifi connections; SSL is off.

Edit: ...on Wifi connections, on MY network.

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024

The folks seeing this: do you have any other websocket connections running? Maybe in the site you're working on, with another app on your Mac, etc? Anything that's using an HTML5 websocket?

from codekit.

rjmccollam avatar rjmccollam commented on September 23, 2024

I hate to be that dumb person who says I don't know, but I don't.

As for applications on my Mac go the only other one that I could think would be possibly doing that would be MAMP Pro, but I can't imagine that is the issue.

The sites I am working on aren't using websockets at all.

from codekit.

dnabeast avatar dnabeast commented on September 23, 2024

I found this an issue with mine as well.
I dragged in a project I had already used in ver 2. The site loaded and I got the red bar. It appeared on every reload. Went to server options and turned External Server Required off and the red bar went away. When I turned it back on I didn't have the problem.

edit Hmm. maybe not. Problem has returned and fix no longer works.

from codekit.

dnabeast avatar dnabeast commented on September 23, 2024

Okay. I'm not sure if this is valuable info but I've discovered this about the problem. The problem occurs when I have a cookie that has an expires/Max-age of 'Session'. If I delete these cookies the bar vanishes and only appears while the browser loads a new page.
cookie

from codekit.

dnabeast avatar dnabeast commented on September 23, 2024

This issue is still in beta 4.
I'm setting the keys using Laravel's cookie queue function.

from codekit.

dnabeast avatar dnabeast commented on September 23, 2024

Here is a simple file that activates the problem.
cookieBreak.php.zip

from codekit.

dnabeast avatar dnabeast commented on September 23, 2024

It seems to be related to the amount of data stored in the cookie in total. A single cookie with 705 characters in it returns the same problem.

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024

@dnabeast Nailed it. The lack of data in headers is why this never reproduced for me, but did for @rjmccollam and others who have cookies of a certain length set.

CodeKit uses Libwebsockets for the refresh server because it's as low-level as you can get without writing assembly. (Read: it's freaking FAST.) Libwebsockets, by default, limits header data on incoming HTTP requests. That limit is 1024 bytes. If your request contains more data than that, libwebsockets just silently fails to do anything with the incoming request. I have increased the limit to 32,767. If you send more than 32 megs in headers with a single request, you deserve your red banner of shame.

Fixed for Beta 6. Great catch, everyone. It's stuff like this that makes me appreciate betas.

from codekit.

dnabeast avatar dnabeast commented on September 23, 2024

You mean 32 kilobytes?

On Thu, Jun 2, 2016 at 12:41 PM, Bryan Jones [email protected]
wrote:

Closed #6 #6.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#6 (comment), or mute
the thread
https://github.com/notifications/unsubscribe/ADFIQ87xZvxM2nNXbFsgqSyOQzu5SxIVks5qHkLPgaJpZM4IheTz
.

from codekit.

bdkjones avatar bdkjones commented on September 23, 2024

I do indeed. I've filed a request with libwebsockets to let me raise it beyond that. Until they give me that ability, keep your HTTP headers to less than 32kb.

from codekit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.