cloud-code-intellij icon indicating copy to clipboard operation
cloud-code-intellij copied to clipboard

Hot reload on debug mode without flask

Open yfried opened this issue 2 years ago • 1 comments

Not sure if skaffold issue or CloudRun - will repost to skaffold if needed

Additional Information

Hi, My application isn't using flask, so I'm relying on hupper to preform hot-reload on file changes. The entry point becomes hupper -m mypackage.mymodule instead of python -m mypackage.mymodule (or python /path/to/mypackage/mymodule.py

This works nicely on "Run", but when working with "Debug" the entry point changes to

-  command:
    - /dbg/python/launcher
    - --mode
    - pydevd
    - --port
    - "5678"
    - --
    - hupper
    args:
    - -m
    - mypackage.mymodule

which runs, but doesn't stop on breakpoint (the debugger tab isn't even opened and there's no Connected to pydev debugger (build 213.5744.248)

If I use python directly (without hupper) then it works as expected (stops on breakpoints and opens the debug tab) but there's no hot-reload, so I need to rebuild and redeploy on every change to the files.

What is the recommend way to enable hot reload without flask?

  • IDE type (e.g. IntelliJ, Pycharm): Pycharm
  • IDE version: Build #PY-213.5744.248, built on November 30, 2021
  • Cloud Code version (Settings > Plugins > Cloud Code): 21.12.1-213
  • Cloud SDK (Settings > Cloud Code > Cloud SDK)
    • Are you allowing the plugin to manage the Cloud SDK: Yes
    • Version of the Cloud SDK: 366.0.0
  • Skaffold version (If you are using Kubernetes features; Settings > Cloud Code > Kubernetes): 1.34.0
  • Operating System: MacOs BigSur 11.6.1

yfried avatar Dec 13 '21 10:12 yfried

hi any update on this? @etanshaul

yfried avatar May 30 '22 08:05 yfried