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

Inability to launch responsive server possibly due to package version issues #10

Closed
wrosko opened this issue May 14, 2020 · 5 comments
Closed

Comments

@wrosko
Copy link
Contributor

wrosko commented May 14, 2020

First, thanks for the work you've done on this, it's really neat.
I've recently tried to implement the project with the Wizard of Oz corpus and am intending on implementing with my own text data, but have run into several issues.

Side note: while figuring all of the below out I successfully created my embeddings for woz corpus.

Package versioning
First off, is a package versioning issue. The environment.yml specifies our required packages, and more specifically points to connexion=1.5.3. If I use conda to build my environment, and then install the required spacy package you mention, getting the flask app to build fails with the error outlined here: spec-first/connexion#1149

According to that issue, and after inspecting versions of packages, the werkzeug <-> connexion integration is the culprit. I was able to get around this in several ways.

  1. by removing the connexion version restriction I get past the initial error, but then run into a problem associated with line 24 of main.py: app = connexion.FlaskApp(__name__, static_folder='client/dist', specification_dir='.'). In this case the static_folder command is no longer a part of werkzeug (which is now v1.0.1).
  2. I then took connexion and then pinned werkzeug=0.16.1. This also does not make it through the running of python server/main.py due to the reason mentioned in 1. Commenting out static_folder can bypass the issue, but obviously this isn't preferable/I'm sure there is a reason why you've included it there.
  3. I finally set connexion=1.5.3 and werkzeug=0.16.1, and made sure that line 24 of the main.py was set to it's original values, and this starts the server. ✅

Accessing the web server
Initially I had Node.js v14 installed. But recompiling the frontend kept failing continuously. Finally, I was able to do npm install by downgrading to Node v 10.16.3 due to some dependency issues regarding node-gyp. I found the suggestion via: nodejs/node-gyp#1906

After this, the npm run build fails, I've attached my terminal outputs as well as the associated log if there are any suggestions:
npm_install_and_build.log
2020-05-14T21_34_31_166Z-debug.log

Both before and after recompiling the frontend I am running into my final issue. Which was touched upon to some extent in another issue #6
This is what I'm seeing:
image
image

So long story short, do you have any suggestions? Addtionally, what should replace those demo lines that are referenced in the logs?

Thanks so much!

@wrosko wrosko changed the title Inability to launch responsive server due to package version issues Inability to launch responsive server possibly due to package version issues May 14, 2020
@bhoov
Copy link
Owner

bhoov commented Jun 19, 2020

Apologies for the long delay. We are preparing this repository for ACL 2020 Demos and I ported the backend to fastapi.

Would love to work with you to make sure you can run this locally on your machine for your needs. I will be switching from other things to polishing this for the next week or so.

@wrosko
Copy link
Contributor Author

wrosko commented Jun 20, 2020

@bhoov hey, no worries at all! Would love to try to work with you this week, helping identify bugs and whatnot for getting it going on my local machine. Hopefully will be helpful to you in polishing it up too.

@bhoov
Copy link
Owner

bhoov commented Jun 22, 2020

Awesome. Step 1 -- do you have any issues running python server/main.py with the new FastAPI architecture?

@wrosko
Copy link
Contributor Author

wrosko commented Jun 22, 2020

Step 1) No problem running the makefile command, although trying to get the server to start I ended up having to do a pip install -e . for the respective directories. I was hitting some error in spacyface

Upon starting the loading of various huggingface models worked seamlessly. I did run into a bug when switching models after I had already done a query. Will try to reproduce this

@bhoov
Copy link
Owner

bhoov commented Jul 7, 2020

Ok neat, I think I fixed the need to run a separate pip install -e . for the other directories. If you do manage to reproduce the bug feel free to make a new issue

@bhoov bhoov closed this as completed Jul 7, 2020
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

2 participants