On pages that I have signalR included I get the following error in firebug:
http://localhost:53604/signalr/signalr/negotiate?_=1352797361490
no element found
everything still works fine but just wanted to see if this will become an issue. thanks
Since you're using Firebug that means you're using Firefox. What transport are you using (if using Fiddler remember to turn Streaming on)? It should be:
1. Long Polling
2. Server Sent Events
3. WebSockets
If the transport is Long Polling then we probably have an issue in the underlying code(Firefox should prioritize WebSockets/SSE before LP).
However, if not then we have a content based issue. So that being said, what type of data are you retrieving from the server? Usually a no element found error comes from invalid markup.
Try stripping out all pieces of your application and see if you still get this error. AKA just a $.connection.hub.start().
Related
I initially asked this question, which shows that I see MVC errors of missing POST values. I was unable to reproduce - I still can't reproduce it on demand, but I did get the error myself on IE11, and I got a clue...
I have an application in IIS7.5 running with Basic authentication only. I look in Fiddler, and normally all transactions have Authorization: Basic xxxxx as expected. The body contains POST values as expected, and Content-Length is correct.
When I experienced this problem, I found that every single request (GETs and POSTs, including static content) was now showing Authorization: Negotiate xxxxx in Fiddler, with an empty body and zero Content-Length, even when I submitted a POST object via jQuery AJAX, and IE's dev tools shows the real POST body (which of course means IE is lying - not the first time). It gets a 401 response, and then a new request occurs with Basic, but also with an empty POST body, which means ASP.NET throws an error about missing parameter values.
Other web applications on the same top-level domain do use Windows authentication instead of Basic, and my suspicion is that the user goes to one of these sites, and IE becomes confused and thinks that my application should use Windows authentication as well - but I can't reproduce that every time. I have reproduced it twice, but out of a dozen or so times of doing the same thing over and over, so I'm not finding a way to make it reproduce every time.
I don't know why the POST body would get emptied, even if it does switch over and try to do WinAuth instead of basic - but that's when the problem occurs, so I'm sure it's related.
Any ideas on how to prevent IE from getting confused and using Negotiate, or at least how to detect and gracefully handle this on the server? I've only seen it in IE, but I can't be sure it's IE-only.
Here's what a normal POST looks like:
Then after the problem starts occurring, the exact same POST looks like:
EDIT
Here's an interesting edit - I just saw a new symptom. This time, all GET requests are coming in with no Authorization header at all, and the response comes back with a 401 for basic, and the GET is re-done properly with basic. But the POSTs are going through normally, with basic on the first try. I don't know what started this happening, but it's a similar symptom of the same problem.
I'm getting started with websocket-rails, trying to convert an old polling system for notifications (on Ruby 2.1/Rails 4.0) to something a bit more modern with WS. I'm using WebsocketRails in standalone mode, here is my configuration, basically, the default:
WebsocketRails.setup do |config|
config.standalone = true
end
I have also setup a fresh Redis running on the default port - there seems to be no communication issues here.
On the client side, I have added the websocket-rails's JS and when trying to open an connection and subscribe to a channel, with:
#dispatcher = new WebSocketRails "localhost:3001/websocket"
#channel = #dispatcher.subscribe "notifications"
I see an error in the Chrome console:
WebSocket connection to 'ws://localhost:3001/websocket' failed: Invalid frame header
In Firefox, the error is different but still an error:
The connection to ws://localhost:3001/websocket was interrupted while the page was loading.
From the websocket server logs, I can see that a connection has been initiated and then dropped, but there are no other logs, even tho log level is "debug"... There are no other errors that I can see and a cursory Google search doesn't bring up anything regarding "invalid frame header", so I'm pretty much stuck.
Any help would be appreciated!
EDIT: I ended up using NodeJS+Faye to get things moving, and it has been working so well that I'm happy to introduce this new moving part in the system. I'm sure the issue was just something temporary based on my specific setup but sometimes, you just have to get things done.
I think you are looking for the following resources:
From the question thread: debugging websocket in google chrome
Chrome developer tools now have the ability to list WebSocket frames and also inspect the data if the frames are not binary.
Process:
Launch Chrome Developer tools
Load your page and initiate the WebSocket connections
Click the Network Tab.
Select the WebSocket connection from the list on the left (it will have status of "101 Switching Protocols".
Click the Frames sub-tab. Binary frames will show up with a length and time-stamp and indicate whether they are masked. Text frames will show also include the payload content.
Theres also this (somewhat old) blog article from 2012: Inspecting WebSocket Traffic with Chrome Developer Tools
I think that there's something wrong with the format of the data being sent over the wire.
Carefully look at the format of the message. Has it been properly stringified? Do your brackets and parens, {}, [], and () all match? Did your IDE insert an extra somewhere? Try validating a message with a linter or an online validator.
Inspect the message on both the sender and receiver sides. Make sure that everything is correct.
This may not be the answer to the author's original question but I want to add a possible solution to this Invalid Frame Header error.
From my small research, Invalid Frame Header can be generated on Websocket protocol when the server sends an empty response (message with 0 length). 0 length in TCP signals that connection has been closed and therefore any data transmission after the empty message fails.
This is the link that helped me to find this solution. I hope someone in the future will find this useful and save some time.
While I was following the guide http://msdn.microsoft.com/en-us/library/vstudio/jj920163.aspx to add Bugs to the task board I ran into an unexpected issue.
Adding the fields to the WIT was successful but when I started adding the form fields I received a very strange error:
Failed to save the 'Bug' Work Item Type to the server. Please contact
your administrator. There was an error contacting the server.
Technical information (for administrator): HTTP code 200: OK
Now I played around trying to find what field was causing the error... I tried every field seperatly and when added seperately they worked, then I tried adding them in pairs, this worked as well, then I tried adding all of them and even this worked!
BUT: When I try to add all of them in a clean group and column I get the error!
This leads me to believe there is some sort of maximum amount of elements in the layout form of a WIT? For now we have left all the fields added to another category but I wanted to ask if someone else had run into this issue and if there is a solution for this?
Since these are all stored as columns in a SQL Server table, the maximum you can add is 1024 (less the TFS standard, which might be around 33 columns?)
If you think this is the problem, check the Tfs_Warehouse..DimWorkItem table and see if you exceed the maximum.
Any chance you can get more information from the event viewer log on the app server, or provide more information about your bug? That message isn't very useful.
For reference -
http://blogs.msdn.com/b/eugenez/archive/2009/05/07/work-item-customization-tidbits-limits-of-complexity-part-13-of-x.aspx
Today we figured out what was going on by using fiddler and more closely monitoring the exchange between Visual Studio and our TFS server. Apparently the request was hitting the Application Firewall that was installed on the TFS server. This is the reason why you receive the vague error HTTP code 200: OK. The Application Firewall replies with a plain HTML page containing a blocked request ID (so you can pass it to your system admin). Once we passed this ID on to our networking team and they adapted the rules there was no longer an issue.
I hope this helps anyone who unexpectedly runs into an Application Firewall on your TFS server like I did.
Error: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.
Details: Error parsing near '
http://servername/ScriptResource.axd?d=EltQ7pexCbRndWc7D3a....b2a49de
Line: 5
I recently converted a SmartPart + UserControl web part to a 'real' web part. The user control part remained essentially unchanged and contains an UpdatePanel. The aim is to have an interactive calendar control which updates its own data but does not cause a full page refresh. The main reason for converting to a real web part is to make use of personal storage so that users can choose a particular setting and store it.
The problem I now have is that when one of the LinkButtons in my web part are clicked I get the error listed above. I am not doing any Response.Writes and there don't seem to be any HttpHeader entries in IIS.
Can anyone help here? Thanks.
New clue
Just noticed that the postback events work when the page is checked out but not when it has been published. What is the significance of this?
Have you added the sharepoint script manager:
http://msdn.microsoft.com/en-us/library/ff650218.aspx
It sounds like a HttpModule is altering the json postback of the update panel
I just discovered a bug in tidhttp component. The scenario is this, im creating a small to fetch the pages of website using tidhttp get. I tried it in ebay all is ok, now after ebay i tried amazon thats where i encountered a problem. What happenned on my side is i searched for item "lenovo laptop" in amazon and copied the url of the second page and paste it in my small app, and whats happenning is it always gets the first page even if the url i used is the second page. Does anyone of you encountered this please see the source code i used in the link below. This source is defaulted to second page of amazon. Thanks you guys in advance.
http://www.yourfilelink.com/get.php?fid=577209
What version of Indy are you using? your code works fine for me as-is when I try it with the current Indy 10.5.8 snapshot release.
If the server returns a success reply, TIdHTTP.Get() saves whatever data the server decodes to send. If you are not seeing the data you are expecting, chances are that Amazon is either redirecting TIdHTTP back to the first page when you try to access the second page directly, or it is sending the first page's data by accident. Either way, I seriously doubt this is a bug in TIdHTTP itself.