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

Development server? #87

Closed
cxw42 opened this issue Jan 20, 2020 · 6 comments
Closed

Development server? #87

cxw42 opened this issue Jan 20, 2020 · 6 comments
Assignees

Comments

@cxw42
Copy link
Contributor

cxw42 commented Jan 20, 2020

While working on #78, I wrote a small Perl script that provides a local development server wrapping the existing web.py. Would the maintainers be interested in that script? I have found it very helpful.

On the other hand, is there already a recommended development server? I didn't see one listed in README.md, other than Apache itself. I also didn't see one in the code, although I may have missed it.

@michaelopdenacker
Copy link

Hi Chris,
This sounds interesting indeed. So far, I'm making tests through a separate Apache install but I have to make my tests through a browser. I'd rather use the command line instead...
Is this way this script is about?
Your PRs are always welcome. I'll be happy to test :)
Thanks,
Michael.

@cxw42
Copy link
Contributor Author

cxw42 commented Feb 1, 2020

Good point about command line --- I hadn't thought of that. This script as is prevents you from having to run the separate Apache. However, it would make it easier to run command-line tests, and automated test suites. I am working on some tests myself, in order to make sure I don't break anything when adding "documented in" :) . I will add an example of command-line testing.

@michaelopdenacker
Copy link

Hi Chris,
I understand better now. This sounds very useful.
Thanks a lot for all this :)
Michael

@cxw42
Copy link
Contributor Author

cxw42 commented May 29, 2020

While working through #133, I discovered uwsgi. uwsgi can be used as a local development server for api.py. If web.py were changed from CGI to WSGI, uwsgi could also be used for web.py.

As far as I can tell, changing to WSGI would improve speed in production, and make it easier to run development servers. uwsgi can also auto-reload on code changes. It looks like this would be a cleaner option than my development server. What do you think?

CC @MaximeChretien since you probably know more about WSGI than I do :)

@tpetazzoni
Copy link

@fstachura will improve the README to detail how to set up a local development server in an easy way using a Docker container

@fstachura
Copy link
Collaborator

#299 got merged recently, information about how to use the Docker image for development is now in README

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

4 participants