Django with visual studio for mac

broken image

Second, we need to have an executable file to set up the Python interpreter in Visual Studio and P圜harm. First, a script simplifies the way we can execute Python code with the interpreter included with Splunk. Note: We need a shell script for two reasons. Mac OS / Linux $SPLUNK_HOME/bin $ chmod +x python_splunk.sh On Mac OS / Linux, be sure to give permissions to execute the script: Otherwise, you’ll run into this PY-11992 issue. '$(dirname '$0')/splunk' cmd python However you name the scripts, just make sure the name starts with python. Mac OS / Linux (save it as python_splunk.sh) #!/bin/bash Windows (save it as python_splunk.cmd) '%~dp0\splunk.exe' cmd python %* To help run this command, let’s create a couple of small shell scripts under $SPLUNK_HOME/bin:

broken image

Windows %SPLUNK_HOME%\bin > splunk.exe cmd python To launch it, use the splunk cmd command (see Command line tools for use with Support): But it is possible, and I’ll show you how using pdb, P圜harm, and Visual Studio.ĭisclaimer: Don’t try this in a production environment. Using a debugger is a common way to find out what is wrong with your application, but debugging a Django application in Splunk might not be so obvious.