File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -188,14 +188,15 @@ export class PythonDebugger extends DebugSession {
188188 }
189189 else {
190190 // When using modules ensure the cwd has been provided
191- if ( typeof args . cwd !== 'string' || args . cwd . length === 0 ) {
191+ if ( typeof args . cwd !== 'string' || args . cwd . length === 0 ) {
192192 return this . sendErrorResponse ( response , 2001 , `'cwd' in 'launch.json' needs to point to the working directory` ) ;
193193 }
194194 }
195195 this . sendEvent ( new TelemetryEvent ( telemetryContracts . Debugger . Load , {
196196 Debug_Console : args . console ,
197197 Debug_DebugOptions : args . debugOptions . join ( "," ) ,
198198 Debug_DJango : args . debugOptions . indexOf ( "DjangoDebugging" ) >= 0 ? "true" : "false" ,
199+ Debug_PySpark : typeof args . pythonPath === 'string' && args . pythonPath . indexOf ( 'spark-submit' ) > 0 ? 'true' : 'false' ,
199200 Debug_HasEnvVaraibles : args . env && typeof args . env === "object" ? "true" : "false"
200201 } ) ) ;
201202
Original file line number Diff line number Diff line change @@ -35,9 +35,11 @@ let jupMain: jup.Jupyter;
3535
3636export function activate ( context : vscode . ExtensionContext ) {
3737 let pythonSettings = settings . PythonSettings . getInstance ( ) ;
38+ const hasPySparkInCompletionPath = pythonSettings . autoComplete . extraPaths . some ( p => p . toLowerCase ( ) . indexOf ( 'spark' ) >= 0 ) ;
3839 telemetryHelper . sendTelemetryEvent ( telemetryContracts . EVENT_LOAD , {
3940 CodeComplete_Has_ExtraPaths : pythonSettings . autoComplete . extraPaths . length > 0 ? 'true' : 'false' ,
40- Format_Has_Custom_Python_Path : pythonSettings . pythonPath . length !== 'python' . length ? 'true' : 'false'
41+ Format_Has_Custom_Python_Path : pythonSettings . pythonPath . length !== 'python' . length ? 'true' : 'false' ,
42+ Has_PySpark_Path : hasPySparkInCompletionPath ? 'true' : 'false'
4143 } ) ;
4244 lintingOutChannel = vscode . window . createOutputChannel ( pythonSettings . linting . outputWindow ) ;
4345 formatOutChannel = lintingOutChannel ;
You can’t perform that action at this time.
0 commit comments