tweet-sense
tweet-sense copied to clipboard
server not working
I'm trying to hit localhost 8000 but it doesn't seem to respond. See if you can spot the error in the media ? The server doesn't seem to be running after the docker image is made . Need help ASAP
I followed these steps
Running the application
-
Download the trained model and put into the
server/mainfolder
(Note: This is the CNN model. if you want use the LSTM model, you'll need to follow the training steps below and put the saved model inserver/main. Also, don't forget to change the loaded model name inserver/main/init.py) -
Get your Twitter API credentials through Keys and Tokens tab under the Twitter Developer Portal Projects & Apps page and add them to the
/server/main/config.pyfile. -
Run
docker-compose up --buildin the terminal from the root folder
(Note: Ensure that you have Docker installed) -
Open
http://localhost:5000in your browser to access the app
Did you enter valid Twitter API credentials into the server config file?
Also, Please send the error message in the server logs
I did try to update the compose yaml file to uncomment the Server section code and it worked for me.
version: "2"
services:
server:
build: ./server/
command: >
gunicorn -b 0.0.0.0:8000 --access-logfile - --reload "main:app"
volumes:
- ./server:/app
ports:
- 8000:8000
client:
build: ./client/
command: npm run start
volumes:
- ./client:/app
- /app/node_modules
ports:
- 3000:3000
The issue seems to be an issue in gunicorn and the docker server, I don't know the conflict its causing, gunicorn -b 0.0.0.0:8000 --access-logfile - --reload "main:app"
Another question, after the --access-logfile do I have to specify the gunicorn file directory
The image is the problem that is being caused by gunicorn:
[image: WhatsApp Image 2022-10-12 at 2.19.32 PM.jpeg]
On Fri, Oct 14, 2022 at 1:06 PM Shivam Singh @.***> wrote:
I did try to update the compose yaml file to uncomment the Server section code and it worked for me.
version: "2"
services: server: build: ./server/ command: > gunicorn -b 0.0.0.0:8000 --access-logfile - --reload "main:app" volumes:
- ./server:/app ports:
- 8000:8000
client: build: ./client/ command: npm run start volumes: - ./client:/app - /app/node_modules ports: - 3000:3000
— Reply to this email directly, view it on GitHub https://github.com/agrawal-rohit/twitter-sentiment-analysis-web-app/issues/25#issuecomment-1278640475, or unsubscribe https://github.com/notifications/unsubscribe-auth/AOT5GSG2VGETQS6FLKWUZDDWDEH7JANCNFSM6AAAAAAQRYLDWI . You are receiving this because you authored the thread.Message ID: <agrawal-rohit/twitter-sentiment-analysis-web-app/issues/25/1278640475@ github.com>
I have changed the compose yaml file as @shivams07 said but got this error
Attaching to twitter-sentiment-analysis-client-1, twitter-sentiment-analysis-server-1 Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "gunicorn": executable file not found in $PATH: unknown
@murtazaali1999 Could you attach the image again? I can't seem to view it.
@zubairfazalkhan I haven't encountered this error before, even when working with a different OS (Mac or Windows). Did you try to google this error?

@agrawal-rohit Re-Uploaded
I am having the same error that the server not working...

I've fixed the issues regarding the docker containers, python dependencies, and the deprecated Twitter API. The project should work correctly through docker now, Please refer to the README for the updated steps to spin up the project 😇
when we are running the project with CNN Model...then how can we run the CNN model along with that code ?....can you please help me
On Wed, Dec 7, 2022 at 2:23 PM Rohit Agrawal @.***> wrote:
Closed #25 https://github.com/agrawal-rohit/twitter-sentiment-analysis-web-app/issues/25 as completed.
— Reply to this email directly, view it on GitHub https://github.com/agrawal-rohit/twitter-sentiment-analysis-web-app/issues/25#event-7975382976, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASVAQJXJV5ZV237LGEN2MSLWMBGADANCNFSM6AAAAAAQRYLDWI . You are receiving this because you commented.Message ID: <agrawal-rohit/twitter-sentiment-analysis-web-app/issue/25/issue_event/7975382976 @github.com>
@agrawal-rohit I am still getting error, client site and server site both are working now but when i give the text i got this
