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

PR: Show symbols for namespace packages in the Outline #19332

Merged
merged 8 commits into from
Sep 6, 2022

Conversation

ccordoba12
Copy link
Member

@ccordoba12 ccordoba12 commented Sep 5, 2022

Description of Changes

Before

  • No symbols for namespace packages

    image

  • Showing relative imports in multiple lines as symbols

    image

After

  • Symbols are shown for namespace packages

    image

  • Relative imports in multiple lines are not shown

    image

Issue(s) Resolved

Fixes #16406.
Fixes #16352.

Affirmation

By submitting this Pull Request or typing my (user)name below,
I affirm the Developer Certificate of Origin
with respect to all commits and content included in this PR,
and understand I am releasing the same under Spyder's MIT (Expat) license.

I certify the above statement is true and correct: @ccordoba12

This makes easier to contribute to that fixture separately from the
tests that use it.
…om/ccordoba12/python-lsp-server.git external-deps/python-lsp-server

subrepo:
  subdir:   "external-deps/python-lsp-server"
  merged:   "0d654c287"
upstream:
  origin:   "https://github.com/ccordoba12/python-lsp-server.git"
  branch:   "more-symbol-fixes"
  commit:   "0d654c287"
git-subrepo:
  version:  "0.4.3"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "2f68596"
@ccordoba12 ccordoba12 added this to the v5.4.0 milestone Sep 5, 2022
@ccordoba12 ccordoba12 self-assigned this Sep 5, 2022
@pep8speaks
Copy link

pep8speaks commented Sep 5, 2022

Hello @ccordoba12! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 57:80: E501 line too long (84 > 79 characters)
Line 67:80: E501 line too long (119 > 79 characters)

Line 63:80: E501 line too long (86 > 79 characters)
Line 85:80: E501 line too long (97 > 79 characters)
Line 86:80: E501 line too long (96 > 79 characters)
Line 87:80: E501 line too long (99 > 79 characters)

Line 73:80: E501 line too long (95 > 79 characters)
Line 83:80: E501 line too long (95 > 79 characters)

Comment last updated at 2022-09-06 21:53:59 UTC

Copy link
Member

@dalthviz dalthviz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ccordoba12 ! Left a comment regarding the moving of other things from test_mainwindow.py to conftest.py.

Seems like a test on MacOS is failing (could it be caused due to the changes on the python-lsp-server?)

Also, could you add a screenshot of the outline before/after the changes here to understand better how the outline should be working? Thanks!

spyder/app/tests/test_mainwindow.py Outdated Show resolved Hide resolved
@ccordoba12
Copy link
Member Author

ccordoba12 commented Sep 6, 2022

Seems like a test on MacOS is failing (could it be caused due to the changes on the python-lsp-server?)

It seems more related to the refactoring I did to move the main_window fixture to conftest.py. I'll take a look at it.

Also, could you add a screenshot of the outline before/after the changes here to understand better how the outline should be working? Thanks!

Ok, will do.

Also fix error with tests using the preload_project marker
Copy link
Member

@dalthviz dalthviz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ccordoba12 ! Checked locally and seems like this is working as expected and 👍

I guess then this is only missing the merge of python-lsp/python-lsp-server#261 and updating here the subrepo, right @ccordoba12 ?

@ccordoba12
Copy link
Member Author

ccordoba12 commented Sep 6, 2022

I guess then this is only missing the merge of python-lsp/python-lsp-server#261 and updating here the subrepo, right @ccordoba12 ?

Yep, that's what's left.

…lsp/python-lsp-server.git external-deps/python-lsp-server

subrepo:
  subdir:   "external-deps/python-lsp-server"
  merged:   "6501e9eb8"
upstream:
  origin:   "https://github.com/python-lsp/python-lsp-server.git"
  branch:   "develop"
  commit:   "6501e9eb8"
git-subrepo:
  version:  "0.4.3"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "2f68596"
@dalthviz
Copy link
Member

dalthviz commented Sep 6, 2022

@ccordoba12 could it be that other changes done for v1.6.0 to the python-language-server are causing completion tests to fail?

This adds repeated entries in our completion widget
@ccordoba12
Copy link
Member Author

could it be that other changes done for v1.6.0 to the python-language-server are causing completion tests to fail?

Yep, the error was caused by a new option added in PR python-lsp/python-lsp-server#246, but I deactivated it here because it leads to repeated entries in our completion widget:

image

@ccordoba12 ccordoba12 merged commit 7434bf7 into spyder-ide:5.x Sep 6, 2022
@ccordoba12 ccordoba12 deleted the issues-16406-and-16352 branch September 6, 2022 23:09
ccordoba12 added a commit that referenced this pull request Sep 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants