Best way to serve media files via flask?
Hello,
Working on a flask project currently which will serve a lot of media files. Photos aren't really an issue just videos, im not streaming them since the hadware isn't great enough to do so.
What would be the best way to serve them with low hardware? Use object storage? Or even use flask?
/r/flask
https://redd.it/1hae62n
Hello,
Working on a flask project currently which will serve a lot of media files. Photos aren't really an issue just videos, im not streaming them since the hadware isn't great enough to do so.
What would be the best way to serve them with low hardware? Use object storage? Or even use flask?
/r/flask
https://redd.it/1hae62n
Reddit
From the flask community on Reddit
Explore this post and more from the flask community
Flask socketio production server
I have a flask application that is only accessed by me. It is hosted on a google cloud linux VM and I have a firewall set up to only allow my IP.
I've been using socketio.run(app) for now, but get the warning that this is a development server. I tried following tutorials for gunicorn and nginx but encountered problems with socketio and selenium chromedriver (there is so scraping that periodically runs in my app).
Since I don't have problems using the development server and I'm the only person accessing the web app, is there any problem with me leaving my app running like this? I've spent a whole day trying to get a production server up following various tutorials but always seem to have problems.
/r/flask
https://redd.it/1hacdg2
I have a flask application that is only accessed by me. It is hosted on a google cloud linux VM and I have a firewall set up to only allow my IP.
I've been using socketio.run(app) for now, but get the warning that this is a development server. I tried following tutorials for gunicorn and nginx but encountered problems with socketio and selenium chromedriver (there is so scraping that periodically runs in my app).
Since I don't have problems using the development server and I'm the only person accessing the web app, is there any problem with me leaving my app running like this? I've spent a whole day trying to get a production server up following various tutorials but always seem to have problems.
/r/flask
https://redd.it/1hacdg2
Reddit
From the flask community on Reddit
Explore this post and more from the flask community
Tuesday Daily Thread: Advanced questions
# Weekly Wednesday Thread: Advanced Questions 🐍
Dive deep into Python with our Advanced Questions thread! This space is reserved for questions about more advanced Python topics, frameworks, and best practices.
## How it Works:
1. **Ask Away**: Post your advanced Python questions here.
2. **Expert Insights**: Get answers from experienced developers.
3. **Resource Pool**: Share or discover tutorials, articles, and tips.
## Guidelines:
* This thread is for **advanced questions only**. Beginner questions are welcome in our [Daily Beginner Thread](#daily-beginner-thread-link) every Thursday.
* Questions that are not advanced may be removed and redirected to the appropriate thread.
## Recommended Resources:
* If you don't receive a response, consider exploring r/LearnPython or join the [Python Discord Server](https://discord.gg/python) for quicker assistance.
## Example Questions:
1. **How can you implement a custom memory allocator in Python?**
2. **What are the best practices for optimizing Cython code for heavy numerical computations?**
3. **How do you set up a multi-threaded architecture using Python's Global Interpreter Lock (GIL)?**
4. **Can you explain the intricacies of metaclasses and how they influence object-oriented design in Python?**
5. **How would you go about implementing a distributed task queue using Celery and RabbitMQ?**
6. **What are some advanced use-cases for Python's decorators?**
7. **How can you achieve real-time data streaming in Python with WebSockets?**
8. **What are the
/r/Python
https://redd.it/1haod3g
# Weekly Wednesday Thread: Advanced Questions 🐍
Dive deep into Python with our Advanced Questions thread! This space is reserved for questions about more advanced Python topics, frameworks, and best practices.
## How it Works:
1. **Ask Away**: Post your advanced Python questions here.
2. **Expert Insights**: Get answers from experienced developers.
3. **Resource Pool**: Share or discover tutorials, articles, and tips.
## Guidelines:
* This thread is for **advanced questions only**. Beginner questions are welcome in our [Daily Beginner Thread](#daily-beginner-thread-link) every Thursday.
* Questions that are not advanced may be removed and redirected to the appropriate thread.
## Recommended Resources:
* If you don't receive a response, consider exploring r/LearnPython or join the [Python Discord Server](https://discord.gg/python) for quicker assistance.
## Example Questions:
1. **How can you implement a custom memory allocator in Python?**
2. **What are the best practices for optimizing Cython code for heavy numerical computations?**
3. **How do you set up a multi-threaded architecture using Python's Global Interpreter Lock (GIL)?**
4. **Can you explain the intricacies of metaclasses and how they influence object-oriented design in Python?**
5. **How would you go about implementing a distributed task queue using Celery and RabbitMQ?**
6. **What are some advanced use-cases for Python's decorators?**
7. **How can you achieve real-time data streaming in Python with WebSockets?**
8. **What are the
/r/Python
https://redd.it/1haod3g
Discord
Join the Python Discord Server!
We're a large community focused around the Python programming language. We believe that anyone can learn to code. | 413614 members
How do we send email using django-allauth now when Less Secure Apps are disabled?
Is there any way to use Oauth2.0 with django-allauth to keep sending verification emails now? I cant find anything on how to do this ( too dumb to figure it out )
/r/django
https://redd.it/1haju0a
Is there any way to use Oauth2.0 with django-allauth to keep sending verification emails now? I cant find anything on how to do this ( too dumb to figure it out )
/r/django
https://redd.it/1haju0a
Reddit
From the django community on Reddit
Explore this post and more from the django community
DNS server written in Python
Hi All
I am researching the DNS protocol in depth (security research) and have written a DNS server in Python that relies on responses from a upstream service (Quad9,for now). Hope you all like it. Do recommend improvements.
Link: https://xer0x.in/dns-server-in-python/
PS: I am aware of the Blocklist parsing inconsistency bug.
/r/Python
https://redd.it/1hagkql
Hi All
I am researching the DNS protocol in depth (security research) and have written a DNS server in Python that relies on responses from a upstream service (Quad9,for now). Hope you all like it. Do recommend improvements.
Link: https://xer0x.in/dns-server-in-python/
PS: I am aware of the Blocklist parsing inconsistency bug.
/r/Python
https://redd.it/1hagkql
Suggestions
I have been working with Django framework for like 1.5 years or more. Built couple of projects.However at this point i m confused, if i am eligible for the entry level job.What kind of code will we be writing in the actual workplace and what essential topics are required to master in backend frameworks like django or flask or restapi
/r/django
https://redd.it/1harpqr
I have been working with Django framework for like 1.5 years or more. Built couple of projects.However at this point i m confused, if i am eligible for the entry level job.What kind of code will we be writing in the actual workplace and what essential topics are required to master in backend frameworks like django or flask or restapi
/r/django
https://redd.it/1harpqr
Reddit
From the django community on Reddit
Explore this post and more from the django community
Looking to Transition from Web Development to Python – Seeking Tips and Insights
I’ve been working as a JS web developer for over 8 years now, but I’ve found myself losing interest in it. I’m really looking to make a switch to something new, and I’ve been getting advice to get into Python and move into that field. However, I’m not entirely sure what the career opportunities in Python are like, or how I can best break into it.
Has anyone else made a similar transition? I’d love to hear about your experiences and any advice you have on how to make this switch successfully. Specifically, I’m curious about:
The job market for Python developers
The skills and projects I should focus on to get noticed. How much time would it take.
Any roadmaps or resources you’d recommend.
Thank you in advance!
/r/Python
https://redd.it/1hagupi
I’ve been working as a JS web developer for over 8 years now, but I’ve found myself losing interest in it. I’m really looking to make a switch to something new, and I’ve been getting advice to get into Python and move into that field. However, I’m not entirely sure what the career opportunities in Python are like, or how I can best break into it.
Has anyone else made a similar transition? I’d love to hear about your experiences and any advice you have on how to make this switch successfully. Specifically, I’m curious about:
The job market for Python developers
The skills and projects I should focus on to get noticed. How much time would it take.
Any roadmaps or resources you’d recommend.
Thank you in advance!
/r/Python
https://redd.it/1hagupi
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
3rd year university student with solid skills developing in Django, looking to work on projects or under someone. I can send link to my resume and some projects I've worked if interested.
On winter break from university and looking for some things to do, hoping to learn and expand my skills. Been applying to internships, but no luck so far. Reach out if interested.
/r/django
https://redd.it/1hanfcf
On winter break from university and looking for some things to do, hoping to learn and expand my skills. Been applying to internships, but no luck so far. Reach out if interested.
/r/django
https://redd.it/1hanfcf
Reddit
From the django community on Reddit
Explore this post and more from the django community
I build PdfDing with Python
Hi r/Python,
over the last six months I have build PdfDing. You can find it on GitHub.
What My Project Does
PdfDing is a selfhosted PDF manager and viewer offering a seamless user experience on multiple devices. Some of its features include:
Remembers current position - continue where you stopped reading on any device
Share PDFs with an external audience via a link or a QR Code. Shared PDFs can be access controlled
Dark Mode, colored themes and custom theme colors
Inverted color mode for reading PDFs
SSO support via OIDC
I have used the following tech stack:
the web app is build using Python (Django)
The frondend is build using Alpine.js, htmx, jQuery and Tailwind CSS
Mozilla's PDF.js is used for viewing PDF files in the browser
Target Audience
Homelabs or businesses who want a self-hosted solution for their PDFs.
Comparison
There are solutions like self-hosted ebook readers. However, they are using the inbuilt PDF viewer of the browser. This works fine on desktops and laptops but on smartphones it will simply download the PDF file and not display it in the browser (at least it is like this on my mobile devices). This solution also does not allow you to continue reading where you stopped on another
/r/Python
https://redd.it/1haxeb7
Hi r/Python,
over the last six months I have build PdfDing. You can find it on GitHub.
What My Project Does
PdfDing is a selfhosted PDF manager and viewer offering a seamless user experience on multiple devices. Some of its features include:
Remembers current position - continue where you stopped reading on any device
Share PDFs with an external audience via a link or a QR Code. Shared PDFs can be access controlled
Dark Mode, colored themes and custom theme colors
Inverted color mode for reading PDFs
SSO support via OIDC
I have used the following tech stack:
the web app is build using Python (Django)
The frondend is build using Alpine.js, htmx, jQuery and Tailwind CSS
Mozilla's PDF.js is used for viewing PDF files in the browser
Target Audience
Homelabs or businesses who want a self-hosted solution for their PDFs.
Comparison
There are solutions like self-hosted ebook readers. However, they are using the inbuilt PDF viewer of the browser. This works fine on desktops and laptops but on smartphones it will simply download the PDF file and not display it in the browser (at least it is like this on my mobile devices). This solution also does not allow you to continue reading where you stopped on another
/r/Python
https://redd.it/1haxeb7
GitHub
GitHub - mrmn2/PdfDing: Selfhosted PDF manager, viewer and editor offering a seamless user experience on multiple devices.
Selfhosted PDF manager, viewer and editor offering a seamless user experience on multiple devices. - mrmn2/PdfDing
Django-tenant: Accessing tenant data in public domain
I was working on Django-tenant where I have tenant model called Appointment now I want to get the appointment of a specific tenant from the public domain but I'm having an issue when rendering it in the template
class OrganizationAppointmentList(LoginRequiredMixin, TenantMixin, ListView):
templatename = 'main/appointments/listappointment.html'
paginateby = 10
def getqueryset(self):
tenantid = self.kwargs.get('pk')
try:
tenant = Organization.objects.get(id=tenantid)
self.schemaname = tenant.schemaname
with schemacontext(self.schemaname):
queryset = Appointment.objects.all()
return queryset
/r/django
https://redd.it/1hazu2h
I was working on Django-tenant where I have tenant model called Appointment now I want to get the appointment of a specific tenant from the public domain but I'm having an issue when rendering it in the template
class OrganizationAppointmentList(LoginRequiredMixin, TenantMixin, ListView):
templatename = 'main/appointments/listappointment.html'
paginateby = 10
def getqueryset(self):
tenantid = self.kwargs.get('pk')
try:
tenant = Organization.objects.get(id=tenantid)
self.schemaname = tenant.schemaname
with schemacontext(self.schemaname):
queryset = Appointment.objects.all()
return queryset
/r/django
https://redd.it/1hazu2h
Reddit
From the django community on Reddit
Explore this post and more from the django community
Difference between get and filter? Cant understand even after reading several posts.
I am trying to write a function which requires to get some values from the database.
following is the model.
class Questions(models.Model):
category = models.CharField(maxlength=50)
question = models.CharField(maxlength=255)
answer1 = models.CharField(maxlength=255)
answer2 = models.CharField(maxlength=255)
answer3 = models.CharField(maxlength=255)
answer4 = models.CharField(maxlength=255)
answerkey = models.CharField(maxlength=25)
so in shell when I use
but when I use
When I use
I will get
So what's the difference? All articls/post answers say that
/r/django
https://redd.it/1hb2rj2
I am trying to write a function which requires to get some values from the database.
following is the model.
class Questions(models.Model):
category = models.CharField(maxlength=50)
question = models.CharField(maxlength=255)
answer1 = models.CharField(maxlength=255)
answer2 = models.CharField(maxlength=255)
answer3 = models.CharField(maxlength=255)
answer4 = models.CharField(maxlength=255)
answerkey = models.CharField(maxlength=25)
so in shell when I use
Questions.objects.get(id = 1) I get <Questions: Questions object (1)>but when I use
Questions.objects.get(id = 1).values() i get an error. AttributeError: 'Questions' object has no attribute 'values'When I use
Questions.objects.filter(id = 1).values()I will get
<QuerySet [{'id': 1, 'category': 'gk', 'question': 'What is the 10th letter of english alphabet?', 'answer1': 'K', 'answer2': 'j', 'answer3': 'l', 'answer4': 'i', 'answer_key': 'answer2'}]>So what's the difference? All articls/post answers say that
filter will filter results and will give all objects where id = 1 (in this case id is default primary key so its only one), while get will get you exact match. But then why cant values() does not work with get if it has found/r/django
https://redd.it/1hb2rj2
Reddit
From the django community on Reddit
Explore this post and more from the django community
Pype - Python Desktop App Framework
I created a python framework that easily enables users to create reactive desktop applications with Python backend and HTML frontend.
What My Project Does
Easily enables the user to create desktop applications with a Python backend and a HTML frontend. Using the frameworks functions listed in the documentation reactive variables, state-management and dynamic UI-s can be created with ease.
Feel free to use it if you see fit. Also im very much open to discussion as this is my first public project that i published, errors have a very high chance of appering.
PyPI pype-framework
Pype Github
edit: I used a post template so i can post here and forgot the delete the post templates text...
/r/Python
https://redd.it/1hb0jr4
I created a python framework that easily enables users to create reactive desktop applications with Python backend and HTML frontend.
What My Project Does
Easily enables the user to create desktop applications with a Python backend and a HTML frontend. Using the frameworks functions listed in the documentation reactive variables, state-management and dynamic UI-s can be created with ease.
Feel free to use it if you see fit. Also im very much open to discussion as this is my first public project that i published, errors have a very high chance of appering.
PyPI pype-framework
Pype Github
edit: I used a post template so i can post here and forgot the delete the post templates text...
/r/Python
https://redd.it/1hb0jr4
GitHub
GitHub - kokasmark/Pype: Python + HTML desktop app framework
Python + HTML desktop app framework. Contribute to kokasmark/Pype development by creating an account on GitHub.
Looking for a mid-ish level web project in django or flash more info below
I am working on transitioning some data projects to the web. I know an okay amount of HTML CSS and a bit of JS so I could do it that way. I would rather build a couple sites just using python using flash or django. I just can't seem to find a repo or tutorial thats not super basic or advanced. Anyone have one that falls in the middle area they would be willing to share?
/r/Python
https://redd.it/1hb8f7h
I am working on transitioning some data projects to the web. I know an okay amount of HTML CSS and a bit of JS so I could do it that way. I would rather build a couple sites just using python using flash or django. I just can't seem to find a repo or tutorial thats not super basic or advanced. Anyone have one that falls in the middle area they would be willing to share?
/r/Python
https://redd.it/1hb8f7h
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
Where would you host a web app expecting only about ~100 visitors per month?
Where would you suggest a relatively new dev host a django app expecting about \~100 users per month, with a postgres database containing about 100-200 entries? I have experience with Heroku and pythonanywhere but Heroku is a bit too expensive for now($5 hosting + $9 postgres). I've also used DO spaces but never hosted there and don't want to deal with DevOps right now. I've also seen Namecheap suggestions but not a lot of reviews.
/r/django
https://redd.it/1hb8hn4
Where would you suggest a relatively new dev host a django app expecting about \~100 users per month, with a postgres database containing about 100-200 entries? I have experience with Heroku and pythonanywhere but Heroku is a bit too expensive for now($5 hosting + $9 postgres). I've also used DO spaces but never hosted there and don't want to deal with DevOps right now. I've also seen Namecheap suggestions but not a lot of reviews.
/r/django
https://redd.it/1hb8hn4
Reddit
From the django community on Reddit
Explore this post and more from the django community
Inventory management Schema
I figured this would be more appropriate asked in a database design group, but since I'm using Django, I'd like to get a better understanding with Django.
How would you handle items with different sizes and quantity in an inventory. For example, a pack of cigarettes has 12 pieces, a crate of eggs has 30 eggs. I procured 3 crates of eggs and 2 packs of cigarettes, how do I track that? How about if I have a liquid that comes in 20 liters, 30 liters and 10 liters bottles. How do I track these items including those properties in an inventory.
/r/django
https://redd.it/1hba5yb
I figured this would be more appropriate asked in a database design group, but since I'm using Django, I'd like to get a better understanding with Django.
How would you handle items with different sizes and quantity in an inventory. For example, a pack of cigarettes has 12 pieces, a crate of eggs has 30 eggs. I procured 3 crates of eggs and 2 packs of cigarettes, how do I track that? How about if I have a liquid that comes in 20 liters, 30 liters and 10 liters bottles. How do I track these items including those properties in an inventory.
/r/django
https://redd.it/1hba5yb
Reddit
From the django community on Reddit
Explore this post and more from the django community
Wednesday Daily Thread: Beginner questions
# Weekly Thread: Beginner Questions 🐍
Welcome to our Beginner Questions thread! Whether you're new to Python or just looking to clarify some basics, this is the thread for you.
## How it Works:
1. Ask Anything: Feel free to ask any Python-related question. There are no bad questions here!
2. Community Support: Get answers and advice from the community.
3. Resource Sharing: Discover tutorials, articles, and beginner-friendly resources.
## Guidelines:
This thread is specifically for beginner questions. For more advanced queries, check out our [Advanced Questions Thread](#advanced-questions-thread-link).
## Recommended Resources:
If you don't receive a response, consider exploring r/LearnPython or join the Python Discord Server for quicker assistance.
## Example Questions:
1. What is the difference between a list and a tuple?
2. How do I read a CSV file in Python?
3. What are Python decorators and how do I use them?
4. How do I install a Python package using pip?
5. What is a virtual environment and why should I use one?
Let's help each other learn Python! 🌟
/r/Python
https://redd.it/1hbg7qh
# Weekly Thread: Beginner Questions 🐍
Welcome to our Beginner Questions thread! Whether you're new to Python or just looking to clarify some basics, this is the thread for you.
## How it Works:
1. Ask Anything: Feel free to ask any Python-related question. There are no bad questions here!
2. Community Support: Get answers and advice from the community.
3. Resource Sharing: Discover tutorials, articles, and beginner-friendly resources.
## Guidelines:
This thread is specifically for beginner questions. For more advanced queries, check out our [Advanced Questions Thread](#advanced-questions-thread-link).
## Recommended Resources:
If you don't receive a response, consider exploring r/LearnPython or join the Python Discord Server for quicker assistance.
## Example Questions:
1. What is the difference between a list and a tuple?
2. How do I read a CSV file in Python?
3. What are Python decorators and how do I use them?
4. How do I install a Python package using pip?
5. What is a virtual environment and why should I use one?
Let's help each other learn Python! 🌟
/r/Python
https://redd.it/1hbg7qh
Discord
Join the Python Discord Server!
We're a large community focused around the Python programming language. We believe that anyone can learn to code. | 413614 members
Question about storing audio files
I am creating a web application where you can put music files inside that are added to a list where you can start, delete and eventually download in the future all your files that you have put. Now, what I was thinking of doing was using a database that keeps the path where each user's files are (divided into folders and subfolders; example: songs/Amanda56/song.mp3). I was thinking of creating these in urls that are added dynamically over time (example: when a user registers with the nickname Giorgio192, a url called: https:/www.mysite.com/storage/songs/Giorgio192/ will be created. The songs url already exists, the one that will be added is Giorgio192 (his username therefore). When Giorgio192 adds a new song to his list, this song will be stored in songs/Giorgio192/song.mp3 while the url that is used to extract the songs from there will be saved in my database. Is this method strange? Would it slow down my site a lot over time? If so, how? Is there a way to do what I want?
/r/flask
https://redd.it/1hb6fp0
I am creating a web application where you can put music files inside that are added to a list where you can start, delete and eventually download in the future all your files that you have put. Now, what I was thinking of doing was using a database that keeps the path where each user's files are (divided into folders and subfolders; example: songs/Amanda56/song.mp3). I was thinking of creating these in urls that are added dynamically over time (example: when a user registers with the nickname Giorgio192, a url called: https:/www.mysite.com/storage/songs/Giorgio192/ will be created. The songs url already exists, the one that will be added is Giorgio192 (his username therefore). When Giorgio192 adds a new song to his list, this song will be stored in songs/Giorgio192/song.mp3 while the url that is used to extract the songs from there will be saved in my database. Is this method strange? Would it slow down my site a lot over time? If so, how? Is there a way to do what I want?
/r/flask
https://redd.it/1hb6fp0
Reddit
From the flask community on Reddit
Explore this post and more from the flask community
D From Unemployment to Lisp: Running GPT-2 on a Teen's Deep Learning Compiler
A couple months ago I found myself unemployed, uncertain about what to do next. I wanted to learn more about deep learning, but from a systems prespective. Coming from Andrew's Ng course on supervised learning, I was eager to learn more about how deep learning frameworks (or deep learning compilers) like Pytorch or Tinygrad.
I started to poke around Tinygrad, learning from the tutorials I found online, and I found it fascinating because it was an actual compiler, it took conventional python code and translated them into an Abstract Syntax Tree that was parsed into UOps and ScheduleItems, to finally have a codegen layer. While the design was interesting, the code was hard to read.
That's when I stumbled across something completly unexpected, A deep learning compiler built on Common Lisp, maintained by a Japanese 18-year-old during his gap year. And currently we have acomplished something great, it can run gpt2!
For now, it just generates C-kernels, but in the future we would like to support cuda codegen as well as many other features, and serve as a learning tool for anyone who would like to get to work on deep learning compilers in Common Lisp.
This is an open source project and anyone
/r/MachineLearning
https://redd.it/1hb7v5h
A couple months ago I found myself unemployed, uncertain about what to do next. I wanted to learn more about deep learning, but from a systems prespective. Coming from Andrew's Ng course on supervised learning, I was eager to learn more about how deep learning frameworks (or deep learning compilers) like Pytorch or Tinygrad.
I started to poke around Tinygrad, learning from the tutorials I found online, and I found it fascinating because it was an actual compiler, it took conventional python code and translated them into an Abstract Syntax Tree that was parsed into UOps and ScheduleItems, to finally have a codegen layer. While the design was interesting, the code was hard to read.
That's when I stumbled across something completly unexpected, A deep learning compiler built on Common Lisp, maintained by a Japanese 18-year-old during his gap year. And currently we have acomplished something great, it can run gpt2!
For now, it just generates C-kernels, but in the future we would like to support cuda codegen as well as many other features, and serve as a learning tool for anyone who would like to get to work on deep learning compilers in Common Lisp.
This is an open source project and anyone
/r/MachineLearning
https://redd.it/1hb7v5h
Reddit
From the MachineLearning community on Reddit: [D] From Unemployment to Lisp: Running GPT-2 on a Teen's Deep Learning Compiler
Explore this post and more from the MachineLearning community
D Why are the Stella embedding models so much smaller than other models of similar quality?
On the MTEB Leaderboard,
What is the secret sauce here? Alternatively, what is the catch? There is no paper yet. Anyone know details?
/r/MachineLearning
https://redd.it/1hbkww5
On the MTEB Leaderboard,
stella_en_v5 is currently ranked 3rd overall, while using one fifth the memory of all non-Stella models in the top 10.stella_en_400M_v5 is ranked 10th, while using 15-20 times less memory than the models ranked near it. This appears to be relatively consistent across several subtasks of the benchmark (for English).What is the secret sauce here? Alternatively, what is the catch? There is no paper yet. Anyone know details?
/r/MachineLearning
https://redd.it/1hbkww5
huggingface.co
MTEB Leaderboard - a Hugging Face Space by mteb
Select and customize benchmarks for different tasks like image-text, domain-specific, and language-specific evaluations. Choose from multilingual options, specific languages, and various domains in...
Did an open source tool for code exploration
# Denoscription
Treeline is a code analysis and visualization tool designed to help developers understand the quality and structure of their Python codebases. It does some complexity metrics, detects code smells, and generates an interactive HTML-based visualization for relatively easy exploration. I hope it will give developers some insights into architectural dependencies, complexity hotspots, and maintainability issues.
# Links
* [https://github.com/duriantaco/treeline](https://github.com/duriantaco/treeline)
* [https://pypi.org/project/treeline/](https://pypi.org/project/treeline/)
# What My Project Does
* **Dependency Analysis**: Identifies which modules import others, which classes belong to which modules, and which functions call which, creating a complete dependency graph.
* **Metrics Computation**: Calculates cyclomatic complexity, cognitive complexity, maintainability index, function length, and code smell occurrences.
* **Visualization**: Renders an interactive HTML report using D3.js, where each node represents a module, class, or function. You can hover over nodes to see detailed metrics, search for specific elements.
* **Quality Reporting**: Produces Markdown and HTML reports summarizing complexity hotspots.
# Target Audience
* Anyone using Python
# Extra Details
Started of as a simple ASCII tree generator. Promised to add more stuff so here i am.
# Conclusion
Hopefully you guys will find it useful. If you think it's a stupid idea or ways to improve, do let me know too. I'm open to criticisms and constructive feedback. If you find any bugs
/r/Python
https://redd.it/1hbnasw
# Denoscription
Treeline is a code analysis and visualization tool designed to help developers understand the quality and structure of their Python codebases. It does some complexity metrics, detects code smells, and generates an interactive HTML-based visualization for relatively easy exploration. I hope it will give developers some insights into architectural dependencies, complexity hotspots, and maintainability issues.
# Links
* [https://github.com/duriantaco/treeline](https://github.com/duriantaco/treeline)
* [https://pypi.org/project/treeline/](https://pypi.org/project/treeline/)
# What My Project Does
* **Dependency Analysis**: Identifies which modules import others, which classes belong to which modules, and which functions call which, creating a complete dependency graph.
* **Metrics Computation**: Calculates cyclomatic complexity, cognitive complexity, maintainability index, function length, and code smell occurrences.
* **Visualization**: Renders an interactive HTML report using D3.js, where each node represents a module, class, or function. You can hover over nodes to see detailed metrics, search for specific elements.
* **Quality Reporting**: Produces Markdown and HTML reports summarizing complexity hotspots.
# Target Audience
* Anyone using Python
# Extra Details
Started of as a simple ASCII tree generator. Promised to add more stuff so here i am.
# Conclusion
Hopefully you guys will find it useful. If you think it's a stupid idea or ways to improve, do let me know too. I'm open to criticisms and constructive feedback. If you find any bugs
/r/Python
https://redd.it/1hbnasw
GitHub
GitHub - duriantaco/treeline: Directory analysis that can create ASCII tree representations as well as light code quality analysis…
Directory analysis that can create ASCII tree representations as well as light code quality analysis as well as architectural flow - GitHub - duriantaco/treeline: Directory analysis that can creat...
Django Web Application Hosted on LAN
Is it possible to set up a centralized application server that hosts a Django web app and a local database, allowing clients on separate computers to access the app for CRUD operations (e.g., managing mail/blacklists) while storing updates locally? The server would also communicate with a ROS2 system on another computer (running AI models and managing daily logs) and optionally sync data to the cloud. Are there any potential challenges or considerations with this architecture?
/r/django
https://redd.it/1hbnynb
Is it possible to set up a centralized application server that hosts a Django web app and a local database, allowing clients on separate computers to access the app for CRUD operations (e.g., managing mail/blacklists) while storing updates locally? The server would also communicate with a ROS2 system on another computer (running AI models and managing daily logs) and optionally sync data to the cloud. Are there any potential challenges or considerations with this architecture?
/r/django
https://redd.it/1hbnynb
Reddit
From the django community on Reddit
Explore this post and more from the django community