content.raw: Making gradio's auto-reload leaner and more robust 💪
content.type: text
content.value: Making gradio's auto-reload leaner and more robust 💪
content.type: new_line
content.type: new_line
content.raw: Auto-reload is one of the coolest (and maybe underrated) features of gradio in my opinion. It automatically detects changes in your python app file and hot swaps your backend and frontend without restarting the server. I may be biased, but that's a way nicer experience than most other reload mode features out there.
content.type: text
content.value: Auto-reload is one of the coolest (and maybe underrated) features of gradio in my opinion. It automatically detects changes in your python app file and hot swaps your backend and frontend without restarting the server. I may be biased, but that's a way nicer experience than most other reload mode features out there.
content.type: new_line
content.type: new_line
content.raw: This is all possible due to novel use of python's built in importlib module. Since this is a non-standard use of the module, our users have encountered some rough edges in the wild.
content.type: text
content.value: This is all possible due to novel use of python's built in importlib module. Since this is a non-standard use of the module, our users have encountered some rough edges in the wild.
content.type: new_line
content.type: new_line
content.raw: I'm happy to announce two improvements that will be out in the next release of gradio. They were both made possible by collaboration in the open source community.
content.type: text
content.value: I'm happy to announce two improvements that will be out in the next release of gradio. They were both made possible by collaboration in the open source community.
content.type: new_line
content.type: new_line
content.raw: 1. First, gradio's reload mode now works with the 
content.type: text
content.value: 1. First, gradio's reload mode now works with the 
content.code: python-dotenv
content.raw: `python-dotenv`
content.type: inline_code
content.raw:  library. Getting to the bottom of this one took a lot of sleuthing by our users and the fix got merged and released into the 
content.type: text
content.value:  library. Getting to the bottom of this one took a lot of sleuthing by our users and the fix got merged and released into the 
content.code: python-dotenv
content.raw: `python-dotenv`
content.type: inline_code
content.raw:  package last night! Thanks to 
content.type: text
content.value:  package last night! Thanks to 
content.raw: @theskumar
content.type: mention
content.user: theskumar
content.raw: , maintainer of python-dotenv, for all the help. 
content.type: text
content.value: , maintainer of python-dotenv, for all the help. 
content.type: new_line
content.raw: 2. Second, gradio's reload mode now consumes an order of magnitude less CPU. Depending on how many files are in your source directory, you may see between 2x to 10x less CPU utilization. Thanks to 
content.type: text
content.value: 2. Second, gradio's reload mode now consumes an order of magnitude less CPU. Depending on how many files are in your source directory, you may see between 2x to 10x less CPU utilization. Thanks to 
content.raw: @velaia
content.type: mention
content.user: velaia
content.raw:  for filing the issue and 
content.type: text
content.value:  for filing the issue and 
content.raw: @abidlabs
content.type: mention
content.user: abidlabs
content.raw:  for the review!
content.type: text
content.value:  for the review!
content.type: new_line
content.type: new_line
content.raw: More improvements to reload mode are planned. Stay tuned!
content.type: text
content.value: More improvements to reload mode are planned. Stay tuned!
rawContent: Making gradio's auto-reload leaner and more robust 💪
  
  Auto-reload is one of the coolest (and maybe underrated) features of gradio in my opinion. It automatically detects changes in your python app file and hot swaps your backend and frontend without restarting the server. I may be biased, but that's a way nicer experience than most other reload mode features out there.
  
  This is all possible due to novel use of python's built in importlib module. Since this is a non-standard use of the module, our users have encountered some rough edges in the wild.
  
  I'm happy to announce two improvements that will be out in the next release of gradio. They were both made possible by collaboration in the open source community.
  
  1. First, gradio's reload mode now works with the `python-dotenv` library. Getting to the bottom of this one took a lot of sleuthing by our users and the fix got merged and released into the `python-dotenv` package last night! Thanks to @theskumar, maintainer of python-dotenv, for all the help. 
  2. Second, gradio's reload mode now consumes an order of magnitude less CPU. Depending on how many files are in your source directory, you may see between 2x to 10x less CPU utilization. Thanks to @velaia for filing the issue and @abidlabs for the review!
  
  More improvements to reload mode are planned. Stay tuned!
reactions.reaction: ❤️
reactions.users: clem abidlabs osanseviero victor vladbogo gsarti samusenps radames chansung akashicmarga mathiasn1 Dlbk Wauplin kramp clefourrier velaia hysts
reactions.reaction: 🤝
reactions.users: abidlabs osanseviero clem radames chansung ashwinlimaye