azure-samples / python-docs-hello-world Goto Github PK
View Code? Open in Web Editor NEWA simple python application for docs
License: MIT License
A simple python application for docs
License: MIT License
Can you create a sample dash app for azure?
Hi,
I have followed the tutorial and the deployment were successful. However I am getting HTTP Error 500.0 - Internal Server Error
.
That is what appear in the logs:
IIS received the request; however, an internal error occurred during the processing of the request.
IIS was not able to access the web.config file for the Web site or application.
This can occur:
Did I miss some step on the tutorial?
Was there not supposed to some Python sample code in this repo?
The tutorial seems to indicate so.
My first repository on GitHub
Hi there!
Many thanks for this tutorial!
I have a question though, in file web.2.7.config, line 6
D:\home\site\wwwroot\env\Scripts\activate_this.py
and also web.3.4.config:
D:\home\site\wwwroot\env\Scripts\python.exe
Can you confirm how to get this files in env/Scripts folder? From where do we get activate_this.py file?
Thanks!
See: Python Flask app on Azure Web App for Containers - there is a stub flask app, and no information about Azure Web App for Containers at all. No-one could figure out how to deploy a web app for containers from this sample.
Please add some deployment instructions for containers.
I added pymongo==3.5.1 to reqs and initiated client, which now causes my web app to crash (results in error 500.0 when trying to access). What might be the issue?
Code for deployment can be viewed in my fork:
I need to update pip to install opencv-python package.
I already installed a recent python version through the extension in webapp blade.
That created a folder D:\home\python364x86, and I change the following in the web.config:
<handlers>
<remove name="Python27_via_FastCGI" />
<remove name="Python34_via_FastCGI" />
<add name="Python FastCGI"
path="handler.fcgi"
verb="*"
modules="FastCgiModule"
scriptProcessor="D:\home\python364x86\python.exe|D:\home\python364x86\Scripts\wfastcgi.py"
resourceType="Unspecified"
requireAccess="Script" />
</handlers>
But it creates the venv with python 3.4 and a version of pip that don't let me install opencv-python.
I think the problem might be in ptvs_virtualenv_proxy.py but I don't really understand what is going there.
Some help please.
Thank you.
Originally, In main.py there is a function named hello_world
@app.route('/')
def hello_world():
return 'Hello, World!'
I added another function below
@app.route('/hello')
def hello_path():
return "HELLO FROM PATH"
So the full script is as follows:
from flask import Flask
app = Flask(__name__)
app.debug = True
@app.route('/')
def hello_world():
return 'Hello, World!'
@app.route('/hello')
def hello_path():
return "HELLO FROM PATH"
if __name__ == '__main__':
app.run()
When I run this on my localhost both endpoints work correctly and return their respective strings. However, after deploying via git to my azure website, I can only get the response from xxx.azurewebsites.net/
to work correctly (returns "Hello, World!"). When I try and hit xxx.azurewebsites.net/hello
I get a 404 error.
I'm not sure why it only works with the default route in the cloud when everything works fine locally. Is this a setup issue? Is there anyway I can debug the routing issues on Azure?
When I try to do the pop install I get this error
ImportError: cannot import name 'Feature' from 'setuptools' (c:\users\kkashani\python-docs-hello-world\env\lib\site-packages\setuptools_init_.py)
I am currently working on https://github.com/kusl/openroomazurewebsites
If you look at the first commit at kusl/openroomazurewebsites@c673623 , you will see the project used to use Python 2.
Python 2 will EOL on January 01, 2020. https://pythonclock.org/
I have made some changes in the above project to use Python3.
For instance, we don't use Ubuntu anymore.
We use python:stretch (Debian) which automatically gives us the latest Python3.
I think if we devops pipeline to python 3, it will help the azure developer community (especially the students who are trying to learn devops and tomorrow's IT manpower) a lot. Thanks!
Hello,
I am looking a way to retrieve the user email of the authenticated user.
I can get the first and last name, as showing in the sample example but I can't figure out a way to get the email.
Thanks for your help!
Best Regards,
Romain
Just followed the instructions as is but I received this error when trying to access the website.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.