aspire
aspire copied to clipboard
Python Support in Aspire
Hey team,
I’ve been exploring Aspire, and it’s impressive! But here’s the thing: Python support is a must for us. Many data science teams, including ours, rely on Python containers. Since Visual Studio already supports Python, adding it to Aspire would be a game-changer.
Cheers. @davidfowl - FYI
@dorgrin6 What do you mean by supporting Python?
There could be multiple things:
-
Running python based apps natively like with Node support?
-
ServiceDiscovery package for Python?
-
A whole separate Aspire.Python package which imitates behavior of Aspire but for Python?
I think you can easily hack together 1 and 2 and see how it goes.
As for 3 I don't think there is a need for this kind of thing - Python community can easily do the thing themselves.
I guess Node native support is a must because .Net backend + js/ts + node frontend is standard thing. I can't say the same for Python + .Net honestly.
I guess 1 & 2 would be nice but 3 is what's needed here.
I'll try to hack this together as proposed.
Would node integration be a good example for this? (AddNpmApp)
@dorgrin6 in terms of 1 & 2 I'd be interested in seeing a PR for Aspire. I think item 3 is probably a different open source project entirely.
I'm working on a separate package for Python support. https://github.com/wmeints/aspire-python
If it sounds useful, I can make a PR to integrate the code into the main project. Not sure if it's necessary as I haven't found any limitations while building python support as a separate package.
Turns out there are a couple of limitations for extending the hosting bits outside of the main repo. For one, testing is harder because you need to build your own testing infrastructure. Which involves copying over quite a lot of code. Also, there are a few handy utilities in the hosting project that I would like to use without copying over code to my own package.
So instead of building my own package, I propose to use my PR that I submitted.
Python support is almost certainly something we'd want to support in-tree anyway since its pretty common in things like AI and data science scenarios.
There is a meta conversation here which is not Python specific about how we want to handle closely related application frameworks:
https://github.com/dotnet/aspire/issues/4163
Interesting for Node.js we don't have APIs which are specific to say ExpressJS?
Fixed by https://github.com/dotnet/aspire/issues/2760
*fixed by #4142