Skip to main content

All Questions

Tagged with
0 votes
0 answers
32 views

Socket.io connection detected on Python server but not triggering events in JavaScript client

I'm currently working on a project where I'm trying to establish a connection between a Flask-SocketIO server in Python and an HTML page using JavaScript. On the Python side, I can see that the ...
MaikeruDev's user avatar
0 votes
1 answer
348 views

SocketIO and Flask not displaying messages

I am having some trouble using JQquery with socketio. I want the messages that are typed into the text box by the user to appear displayed as a list at the beginning of the the chat page, but am ...
Beatrix's user avatar
  • 65
1 vote
2 answers
3k views

How can I send data though socket-io without the client requesting first with python and flask

My goal is for my Flask server to send the client data either every three seconds, or when a function is called. To do this I am using SocketIO. However based on some example code I am working with, ...
Alexander's user avatar
  • 1,288
3 votes
0 answers
149 views

Not able to stream vidoe from webpage to python server suing flask-socketio in python server and socetio in java script

I have been trying to stream video from the webpage to the python server and then process it in python and again send it back to the webpage. Unfortunately, I cannot send the video to the server from ...
bokey's user avatar
  • 65
0 votes
2 answers
150 views

javascript for loop not printing right dataset for each button in a class

I am creating a voting webapp using flask, javascript and socketio. I am looping through all the buttons belonging to the vote class. I am trying to get their data-vote values. For some reason, when ...
Serket's user avatar
  • 4,495
0 votes
0 answers
48 views

variable not found in javascript

Python Code: from flask import Flask, render_template, request, redirect, url_for, session from flask_socketio import SocketIO, emit, send from time import localtime, strftime app = Flask(__name__) ...
Pratham Dave's user avatar
1 vote
0 answers
49 views

Emit from flask server to client JavaScript not emitting to the sender

I'm trying to take text from HTML form input then emit it using JavaScript and Socket to the server-side which is python flask and then emit it to everyone and update the page for everyone with a <...
Ahmed Shoman's user avatar
1 vote
3 answers
699 views

Flask server not starting for SocketIO

I am trying to make a chat app using SocketIO and following this video: https://www.youtube.com/watch?v=RdSrkkrj3l4 and the corresponding GitHub code: https://github.com/PrettyPrinted/flask-socketio-...
Harshit Parikh's user avatar
1 vote
0 answers
194 views

Why does my socket seem to be closing on the client side even though I keep emitting messages from the server that the client should be listening to?

I am trying to create a stream of random numbers on a Flask server and then send those through a socket to the html such that a web page keeps updating with a new number. In my code here, I was just ...
Granteloupe's user avatar
1 vote
2 answers
303 views

Syntax error when trying to convert HTML file to JavaScript containing socket io, SyntaxError: Unexpected token <

I would like to convert HTML code to JavaScript. Currently I can send a message from the HTML file to a python server, which is then reversed and sent back to the HTML through socket io. I used this ...
W. Churchill's user avatar
0 votes
1 answer
471 views

Why isn't the browser updating with this real time push in Flask socketIO?

I'm new to Flask and a bit rusty on my Javascript. I have need to generate events in python externally and push them to a web page in realtime, so I've chosen Flask-SocketIO. I've built the simplest ...
Dribbler's user avatar
  • 4,711
3 votes
1 answer
2k views

How to Use Link a Server to a flask app running on an exposed local host

Right now I have a chatbox that uses socket.io and mongoDB to communicate with a server that allows the text to be sent to the chatbox. If need be i can do away with the mongoDB as long as it does not ...
DanielJomaa's user avatar
1 vote
1 answer
2k views

Flask + SocketIO - Stream command output to HTML element

I have a Flask Python webserver with websockets (socketIO). I want to run a command and stream the output to a <p id='streaming_text'> HTML element. This is my code: HTML div class='...
JahMyst's user avatar
  • 1,686
18 votes
4 answers
18k views

Code in Python, communicate in Node.js and Socket.IO, present in HTML

You have a python script diagnosis.py that generates realtime event-based data. Using Node.js, you can launch it as a child process and capture its output and then using Socket.IO emit that to the ...
melhosseiny's user avatar
  • 10.2k