Skip to content

Commit 697f4c7

Browse files
authored
Merge pull request #25033 from ccordoba12/issue-25019
PR: Fix error when kernel fails to start (Profiler)
2 parents 5cf8451 + 92dc9e5 commit 697f4c7

File tree

4 files changed

+9
-8
lines changed

4 files changed

+9
-8
lines changed

spyder/plugins/application/confpage.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,7 @@ def setup_page(self):
7979
section='update_manager'
8080
)
8181
disable_zoom_mouse_cb = newcb(
82-
_("Disable zoom with mouse wheel"),
83-
'disable_zoom_mouse'
82+
_("Disable zoom with Ctrl/Cmd + mouse wheel"), "disable_zoom_mouse"
8483
)
8584

8685
# Decide if it's possible to activate or not single instance mode

spyder/plugins/ipythonconsole/widgets/shell.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1560,13 +1560,13 @@ def focusOutEvent(self, event):
15601560
return super().focusOutEvent(event)
15611561

15621562
def eventFilter(self, obj, event):
1563-
etype = event.type()
15641563
if (
1565-
etype == QEvent.Wheel
1564+
event.type() == QEvent.Wheel
15661565
and self._control_key_down(event.modifiers())
15671566
and self.get_conf('disable_zoom_mouse', section='main')
15681567
):
15691568
return False
1569+
15701570
return super().eventFilter(obj, event)
15711571

15721572
# ---- Python methods

spyder/plugins/profiler/widgets/main_widget.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,7 @@ def update_actions(self):
394394
callers_or_callees_action.setChecked(False)
395395
callers_or_callees_action.setEnabled(False)
396396

397-
if widget is not None:
397+
if not widget_inactive:
398398
if widget.is_profiling:
399399
self.start_spinner()
400400
else:
@@ -420,7 +420,8 @@ def update_actions(self):
420420
# ProfilerWidgetActions.Home,
421421
ProfilerWidgetActions.SlowLocal,
422422
ProfilerWidgetActions.SaveData,
423-
ProfilerWidgetActions.Search
423+
ProfilerWidgetActions.LoadData,
424+
ProfilerWidgetActions.Search,
424425
]:
425426
action = self.get_action(action_name)
426427
if action_name in [
@@ -430,6 +431,8 @@ def update_actions(self):
430431
action.setEnabled(
431432
not tree_empty and not callers_or_callees_enabled
432433
)
434+
elif action_name == ProfilerWidgetActions.LoadData:
435+
action.setEnabled(not widget_inactive)
433436
else:
434437
action.setEnabled(not tree_empty)
435438

spyder/utils/tests/test_vcs.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
# Standard library imports
1212
import os
1313
import os.path as osp
14-
import sys
1514

1615
# Test library imports
1716
from spyder.utils import programs
@@ -31,7 +30,7 @@
3130

3231

3332
@skipnogit
34-
@pytest.mark.skipif(running_in_ci(), reason="Not to be run outside of CIs")
33+
@pytest.mark.skipif(not running_in_ci(), reason="Not to be run outside of CIs")
3534
def test_vcs_tool():
3635
if not os.name == 'nt':
3736
with pytest.raises(ActionToolNotFound):

0 commit comments

Comments
 (0)