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

Cant change parameters if imported. #6

Open
ksmith97 opened this issue Feb 5, 2017 · 1 comment
Open

Cant change parameters if imported. #6

ksmith97 opened this issue Feb 5, 2017 · 1 comment

Comments

@ksmith97
Copy link
Owner

ksmith97 commented Feb 5, 2017

Currently when run from the command line you can change the port and the encoding type. However, the variables are set as globals within the file instead of as class arguments. Given the HTTPServer takes a class as an argument and not an instance, I am not entirely certain how to modify the code to paramaterize the class in a way that would still make it usable with the BaseHTTPServer. The end result of this is that you are unable to modify the port and encoding used if you import the class. I am not normally a Python dev so I am not sure of an appropriate response to this issue.

@ksmith97
Copy link
Owner Author

ksmith97 commented Feb 5, 2017

I debated adding optional constructor params but it still has the issue of setting globals.

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

1 participant