Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError when pressing Ctrl+Shift+Tab in the Editor #16960

Closed
gabrc52 opened this issue Dec 5, 2021 · 2 comments
Closed

TypeError when pressing Ctrl+Shift+Tab in the Editor #16960

gabrc52 opened this issue Dec 5, 2021 · 2 comments

Comments

@gabrc52
Copy link

gabrc52 commented Dec 5, 2021

Description

What steps will reproduce the problem?

  1. Press Ctrl+shift+tab

Those are all the steps you need to reproduce. I am writing this 2 sentences because of the character minimum.

Traceback

Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/spyder/plugins/editor/widgets/editor.py", line 453, in <lambda>
    lambda: self.tab_navigation_mru(forward=False),
  File "/usr/lib/python3.10/site-packages/spyder/plugins/editor/widgets/editor.py", line 2170, in tab_navigation_mru
    self.tabs_switcher = TabSwitcherWidget(self, self.stack_history,
  File "/usr/lib/python3.10/site-packages/spyder/plugins/editor/widgets/editor.py", line 88, in __init__
    self.set_dialog_position()
  File "/usr/lib/python3.10/site-packages/spyder/plugins/editor/widgets/editor.py", line 136, in set_dialog_position
    self.move(self.editor.mapToGlobal(QPoint(left, top)))
TypeError: arguments did not match any overloaded call:
  QPoint(): too many arguments
  QPoint(int, int): argument 1 has unexpected type 'float'
  QPoint(QPoint): argument 1 has unexpected type 'float'

Versions

  • Spyder version: 5.1.5
  • Python version: 3.10.0
  • Qt version: 5.15.2
  • PyQt5 version: 5.15.6
  • Operating System: Linux 5.15.6-200.fc35.x86_64

Dependencies


# Mandatory:
atomicwrites >=1.2.0          :  1.4.0 (OK)
chardet >=2.0.0               :  4.0.0 (OK)
cloudpickle >=0.5.0           :  1.6.0 (OK)
cookiecutter >=1.6.0          :  1.7.3 (OK)
diff_match_patch >=20181111   :  20200713 (OK)
intervaltree >=3.0.2          :  3.1.0 (OK)
IPython >=7.6.0               :  7.26.0 (OK)
jedi >=0.17.2;<0.19.0         :  0.18.0 (OK)
jsonschema >=3.2.0            :  3.2.0 (OK)
keyring >=17.0.0              :  21.8.0 (OK)
nbconvert >=4.0               :  6.1.0 (OK)
numpydoc >=0.6.0              :  1.1.0 (OK)
parso >=0.7.0;<0.9.0          :  0.8.2 (OK)
pexpect >=4.4.0               :  4.8.0 (OK)
pickleshare >=0.4             :  0.7.5 (OK)
psutil >=5.3                  :  5.8.0 (OK)
pygments >=2.0                :  2.9.0 (OK)
pylint >=2.5.0                :  2.9.6 (OK)
pyls_spyder >=0.4.0           :  0.4.0 (OK)
pylsp >=1.2.2;<1.3.0          :  1.2.2 (OK)
pylsp_black >=1.0.0           :  None (OK)
qdarkstyle =3.0.2             :  3.0.2 (OK)
qstylizer >=0.1.10            :  0.2.0 (OK)
qtawesome >=1.0.2             :  1.0.3 (OK)
qtconsole >=5.1.0             :  5.1.1 (OK)
qtpy >=1.5.0                  :  1.11.2 (OK)
rtree >=0.9.4                 :  0.9.4 (OK)
setuptools >=49.6.0           :  57.4.0 (OK)
sphinx >=0.6.6                :  4.1.2 (OK)
spyder_kernels >=2.1.1;<2.2.0 :  2.1.1 (OK)
textdistance >=4.2.0          :  4.2.0 (OK)
three_merge >=0.1.1           :  0.1.1 (OK)
watchdog >=0.10.3             :  2.1.6 (OK)
xdg >=0.26                    :  0.27 (OK)
zmq >=17                      :  22.2.1 (OK)

# Optional:
cython >=0.21                 :  None (OK)
matplotlib >=2.0.0            :  3.5.0 (OK)
numpy >=1.7                   :  1.21.1 (OK)
pandas >=1.1.1                :  1.3.3 (OK)
scipy >=0.17.0                :  1.7.0 (OK)
sympy >=0.7.3                 :  None (OK)
@steff456
Copy link
Member

steff456 commented Dec 6, 2021

Hi @gabrc52,

I'm unable to reproduce this issue, can you please post a gif with the behavior on your end? Also, please update your Spyder to see if the error persists in the newer version.

Thanks for reporting!

@steff456 steff456 self-assigned this Dec 6, 2021
@ccordoba12 ccordoba12 changed the title I pressed Ctrl+Shift+Tab TypeError when pressing Ctrl+Shift+Tab in the Editor Dec 7, 2021
@ccordoba12
Copy link
Member

@steff456, I think this happens because floats are not automatically cast to ints in Python 3.10, so we have to take care of doing that manually now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants