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

[DONOTMERGE] Graft linearized positron-python repository history #2539

Merged
merged 5,377 commits into from
Mar 28, 2024

Conversation

wesm
Copy link
Contributor

@wesm wesm commented Mar 26, 2024

I'm opening this here to assist with evaluation and looking at changes necessary to get the CI working (and make changes relating to the change from git submodule to not git submodule). The scripts associated with creating these changes are located in https://github.com/posit-dev/positron-scripts, as well as tools to assist with pulling in incremental changes from the upstream microsoft/vscode-python repository.

Once the CI is fixed and everyone is satisfied with the historical git comments (which goes back to beginning of 2018 -- there were some esoteric quirks with the git history in the late 2017 transition to being an official Microsoft project, so I just squashed the early history of the repository to make things easier), this should be rebase-merged (no merge commit, no squashing).

@wesm wesm force-pushed the graft-positron-python branch from c6f1d1c to 28086cd Compare March 26, 2024 03:19
@wesm wesm force-pushed the graft-positron-python branch from c2ce0c2 to c73dde6 Compare March 28, 2024 19:58
seeM and others added 27 commits March 28, 2024 15:04
… >= 3.8

Merge pull request #118 from posit-dev/limit-registered-runtimes

limit registered runtimes to >= 3.8
--------------------
Commit message for posit-dev/positron-python@30bb1a5:

ignore pre-existing file with pyright issues

--------------------
Commit message for posit-dev/positron-python@cb6fca8:

limit registered runtimes to >= 3.8

Addresses #654.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…on runtime start instead of registration

Merge pull request #117 from posit-dev/install-ipykernel-on-start

prompt to install ipykernel on runtime start instead of registration
--------------------
Commit message for posit-dev/positron-python@0c1d9c0:

prompt to install ipykernel on runtime start instead of registration

This required moving that functionality to the language runtime.

It also lets us throw an error if the install failed, which currently gets
rendered in the console. We can replace that with a pop-up in future.

Addresses #436.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
Merge pull request #114 from posit-dev/magic-viewer


--------------------
Commit message for posit-dev/positron-python@6bab2da:

add all requirements from positron_jedilsp

--------------------
Commit message for posit-dev/positron-python@7f92125:

add pygls to build requirements

--------------------
Commit message for posit-dev/positron-python@38571ec:

Merge branch 'main' into magic-viewer

--------------------
Commit message for posit-dev/positron-python@c01c112:

add build requirements

--------------------
Commit message for posit-dev/positron-python@41122f6:

linting

--------------------
Commit message for posit-dev/positron-python@2ae5dd5:

add beginning of tests

These tests run an ipython kernel with a magic registered. They will
check to see if the %view magic exists and not error on run for pandas
dataframes and expressions. It will also check that a TypeError is
thrown if an incorrect type is used.

--------------------
Commit message for posit-dev/positron-python@934b395:

changes from suggestions

--------------------
Commit message for posit-dev/positron-python@194754a:

Apply suggestions from code review

Co-authored-by: Wasim Lorgat <[email protected]>
--------------------
Commit message for posit-dev/positron-python@495b2b3:

linting

--------------------
Commit message for posit-dev/positron-python@067e02d:

add ipython ViewerMagic

Create a linemagic that ingests user input and opens up in DataViewer tab


Authored-by: Isabel Zimmerman <[email protected]>
Signed-off-by: Isabel Zimmerman <[email protected]>
… cancel button during ipykernel install

Merge pull request #120 from posit-dev/ipykernel-progress-and-cancel

add a progress indicator and cancel button during ipykernel install
--------------------
Commit message for posit-dev/positron-python@d8c04ec:

add a progress indicator and cancel button during ipykernel install


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…on release 2023.10.0

Merge pull request #122 from posit-dev/merge/2023.10.0

Merging upstream vscode-python release 2023.10.0
--------------------
Commit message for posit-dev/positron-python@fc0926f:

Add typings to get updated EnvironmentVariableCollection API

--------------------
Commit message for posit-dev/positron-python@8c11f29:

Merge remote-tracking branch 'upstream/release/2023.10'

--------------------
Commit message for posit-dev/positron-python@fea895f:

Update version and readme for release (posit-dev/positron-python#21388)

Co-authored-by: Soojin (Min) Choi <[email protected]>
--------------------
Commit message for microsoft/vscode-python@ad9c899:

Update version for release candidate (microsoft/vscode-python#21369)


--------------------
Commit message for microsoft/vscode-python@a395e2e:

fix bug so canceling debug works in rewrite (microsoft/vscode-python#21361)

fixes microsoft/vscode-python#21336
--------------------
Commit message for microsoft/vscode-python@be829b3:

Unittest for large workspaces (microsoft/vscode-python#21351)

follows the same steps as making pytest compatible with large workspaces
with many tests. Now test_ids are sent over a port as a json instead of
in the exec function which can hit a cap on # of characters. Should fix
microsoft/vscode-python#21339.
--------------------
Commit message for microsoft/vscode-python@cd76ee1:

add pythonTestAdapter to experiment enum (microsoft/vscode-python#21357)

allow people to opt in and out of the pythonTestAdapter rewrite via the
settings `python.experiment.optInto` or `python.experiment.optOutfrom`
--------------------
Commit message for microsoft/vscode-python@dbd0b73:

adding extra log messages for rewrite debugging (microsoft/vscode-python#21352)

These logs print errors and other bits of information which will be
helpful for debugging workflows of users where we need to get
information such as args or which step in the process they got to.
--------------------
Commit message for microsoft/vscode-python@d968b8c:

Dont show command for button trigger in command pallet (microsoft/vscode-python#21350)

Fixes microsoft/vscode-python#21322
--------------------
Commit message for microsoft/vscode-python@e9a8dd5:

remove duplicates from test_ids array (microsoft/vscode-python#21347)

this will partially remediate
microsoft/vscode-python#21339 in regards to
the duplicate IDs being run.
--------------------
Commit message for microsoft/vscode-python@f148139:

allow pytest tests to handle multiple payloads (microsoft/vscode-python#21301)

As part of the switch to allow for dynamic run- the pytest discovery and
execution tests are now switched to be take lists of dicts where the
dicts are the payloads.
--------------------
Commit message for microsoft/vscode-python@c213491:

Apply environment variables after shell initialization scripts are run in `pythonTerminalEnvVarActivation` experiment (microsoft/vscode-python#21290)

For microsoft/vscode-python#11039 microsoft/vscode-python#20822
Closes microsoft/vscode-python#21297

Update proposed APIs to be used in Terminal activation experiment.
--------------------
Commit message for microsoft/vscode-python@72f7ef8:

Set up testing rewrite experiment (microsoft/vscode-python#21258)

is the beginning of this issue:
microsoft/vscode-python#21150, in that it will
start the process of implementing the setting in the extension
--------------------
Commit message for microsoft/vscode-python@4109228:

fix debugging with new pytest run script (microsoft/vscode-python#21299)

fix debugging for run_pytest_script.py setup
--------------------
Commit message for microsoft/vscode-python@b916981:

remove unneeded multiroot code (microsoft/vscode-python#21295)

removed extra steps to wrap data since this creates duplicate folders in
the controller and only keeps the most recent instead of all the roots
from different workspaces.
--------------------
Commit message for microsoft/vscode-python@e2a9cec:

allow large scale testing (microsoft/vscode-python#21269)

allows new testing rewrite to handle 500+ tests and load and run these
tests. High limit tested was 10,000 tests.
--------------------
Commit message for microsoft/vscode-python@f2f5fe2:

Check config type in the ChildProcessAttachEvents (microsoft/vscode-python#21272)


--------------------
Commit message for microsoft/vscode-python@4b4e5b7:

Update pyright version (microsoft/vscode-python#21296)

Fix error in tests, updating pyright version
--------------------
Commit message for microsoft/vscode-python@c9a7268:

Revert "Remove hack to check the vscode version" (microsoft/vscode-python#21294)

Reverts microsoft/vscode-python#21180
For microsoft/vscode-python#20769
--------------------
Commit message for microsoft/vscode-python@a74f1d1:

Detect installed packages in the selected environment (microsoft/vscode-python#21231)

Fixes microsoft/vscode-python#21140
--------------------
Commit message for microsoft/vscode-python@b0ebc9b:

Enable debug pytest (microsoft/vscode-python#21228)

fixes microsoft/vscode-python#21147

---------

Co-authored-by: Aidos Kanapyanov <[email protected]>
Co-authored-by: Karthik Nadig <[email protected]>
--------------------
Commit message for microsoft/vscode-python@be9662f:

revert testing to using socket (microsoft/vscode-python#21242)

switch back to using a socket instead of an output file for use in the
plugin communication during testing. This should work now that we
resolved the issue with python path for windows.
--------------------
Commit message for microsoft/vscode-python@b4a47bb:

Add reload flag on fastApi provider (microsoft/vscode-python#21241)


--------------------
Commit message for microsoft/vscode-python@fcfc54c:

Add option for pyenv interpreters when creating environments with venv (microsoft/vscode-python#21219)

Resolves microsoft/vscode-python#20881 .

Testing:

Behaves as expected when testing with Extension Development Host:


![image](https://github.com/microsoft/vscode-python/assets/30149293/d114d9ab-f2d8-4273-877b-d7dd030cfe76)
--------------------
Commit message for microsoft/vscode-python@b3d43e5:

Do not open "save as" window when running existing Python files (microsoft/vscode-python#21232)

Closes microsoft/vscode-python#21209
--------------------
Commit message for microsoft/vscode-python@b0da28c:

Remove IS_WINDOWS constant in favor of PlatformService (microsoft/vscode-python#21157)

Solves partially microsoft/vscode-python#8542
--------------------
Commit message for microsoft/vscode-python@0c4fa40:

Change name of command to run Python files in separate terminals (microsoft/vscode-python#21229)

Closes microsoft/vscode-python#14094
--------------------
Commit message for microsoft/vscode-python@1533818:

Added option to run multiple Python files in separate terminals (microsoft/vscode-python#21223)

Closes microsoft/vscode-python#21215
microsoft/vscode-python#14094

Added the option to assign a dedicated terminal for each Python file:


![image](https://github.com/microsoft/vscode-python/assets/13199757/b01248e4-c826-4de0-b15f-cde959965e68)
--------------------
Commit message for microsoft/vscode-python@eb9fde3:

Add `createEnvironment.contentButton` setting (microsoft/vscode-python#21212)

Closes microsoft/vscode-python#20982

---------

Co-authored-by: Luciana Abud <[email protected]>
--------------------
Commit message for microsoft/vscode-python@5eef525:

Add logging when interpreter path changes (microsoft/vscode-python#21210)

For microsoft/vscode-python#21208
--------------------
Commit message for microsoft/vscode-python@8d291f7:

Disable "snippets" expansion in Jedi LSP (microsoft/vscode-python#21194)

This brings the Jedi based completion experience in line with that
provided by Pylance. Completions now insert only the current symbol
rather than assuming that the user wants to e.g: call that symbol.

This means for example that completing `max` will insert just `max`
rather `max(arg1, arg2)`. While for this case this may be seen as less
useful, it means that insertions in places where a call is not desired
(such as imports and typing contexts) will not be forced to manually
remove the parentheses and template arguments which might otherwise be
inserted.

Users can still use the signature support UI to explore signatures and
of course insertion of an opening parenthesis will still insert a
closing one.

Hopefully this new configuration will be preferable to a majority of
users.

I've done some light testing to check that this disables the described
additional completion, however I'm not massively familiar with JediLSP
so I'm not sure what other behaviours this will disable.

Fixes microsoft/vscode-python#15858
--------------------
Commit message for microsoft/vscode-python@a85eb3b:

Fix startup telemetry issue (microsoft/vscode-python#21203)

Could fix microsoft/vscode-python#20874 based
on error trace.
--------------------
Commit message for microsoft/vscode-python@17daae4:

Open separate Python terminals when running different Python files (microsoft/vscode-python#21202)

Closes microsoft/vscode-python#21097
Closes microsoft/vscode-python#14094
--------------------
Commit message for microsoft/vscode-python@f0253e5:

Use actions from `vscode-github-triage-actions` in all Python automations (microsoft/vscode-python#21178)


--------------------
Commit message for microsoft/vscode-python@678f70d:

Remove hack to check the vscode version (microsoft/vscode-python#21180)

Closed: microsoft/vscode-python#20769
--------------------
Commit message for microsoft/vscode-python@6bdada0:

Use `saveEditor` proposed API for running untitled Python files (microsoft/vscode-python#21183)

Closes microsoft/vscode-python#21182

Lead-authored-by: Eleanor Boyd <[email protected]>
Co-authored-by: Peter Law <[email protected]>
Co-authored-by: Carlos Piña Martinez <[email protected]>
Co-authored-by: Jonathan Rayner <[email protected]>
Co-authored-by: Pete Farland <[email protected]>
Co-authored-by: paulacamargo25 <[email protected]>
Co-authored-by: Karthik Nadig <[email protected]>
Co-authored-by: Kartik Raj <[email protected]>
Signed-off-by: GitHub <[email protected]>
… server

Merge pull request #124 from posit-dev/pydoc-help

prototype help using a pydoc server
--------------------
Commit message for posit-dev/positron-python@16a2e81:

add pydantic to lsp requirements

--------------------
Commit message for posit-dev/positron-python@8cc9285:

simplify base frontend event

--------------------
Commit message for posit-dev/positron-python@16cd8b2:

add copyright notice

--------------------
Commit message for posit-dev/positron-python@6278a56:

simplify `get_qualname`

--------------------
Commit message for posit-dev/positron-python@7fff9a6:

`help()` shows help about the `help` function itself

--------------------
Commit message for posit-dev/positron-python@66c51fe:

add vertical ruler

--------------------
Commit message for posit-dev/positron-python@5705051:

fix help for keywords

--------------------
Commit message for posit-dev/positron-python@f92fa91:

special case pandas series

--------------------
Commit message for posit-dev/positron-python@ae4f5a5:

fix pydoc import error by special casing pandas

--------------------
Commit message for posit-dev/positron-python@57b8c7b:

add more test cases

--------------------
Commit message for posit-dev/positron-python@544c6c4:

forgot to add this change

--------------------
Commit message for posit-dev/positron-python@94f0cd1:

only format on save for python files

--------------------
Commit message for posit-dev/positron-python@2c6994f:

python development docs

--------------------
Commit message for posit-dev/positron-python@35b1a87:

add unit tests for frontend and help services

--------------------
Commit message for posit-dev/positron-python@204956d:

refactor `get_qualname` so that we can use it with types

--------------------
Commit message for posit-dev/positron-python@97e5626:

fix black + vscode config to avoid future errors

--------------------
Commit message for posit-dev/positron-python@d894eab:

add the frontend service; intercept `help()` and submit a show help event

--------------------
Commit message for posit-dev/positron-python@0667083:

add help service which manages pydoc server

--------------------
Commit message for posit-dev/positron-python@62f2058:

fix connection_file arg default value


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…obj?` and instead use positron's help functionality

Merge pull request #126 from posit-dev/redirect-pinfo

intercept `%pinfo obj` and `obj?` and instead use positron's help functionality
--------------------
Commit message for posit-dev/positron-python@9191032:

rename PositronInspector since we already had one

--------------------
Commit message for posit-dev/positron-python@5eb453b:

intercept `%pinfo obj` and `obj?` and instead use positron's help functionality

Addresses #760.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
… for `pandas.DataFrame` attributes/methods

Merge pull request #127 from posit-dev/fix-help-dataframe-attrs

fix import error on `help()` for `pandas.DataFrame` attributes/methods
--------------------
Commit message for posit-dev/positron-python@c188853:

fix import error on `help()` for `pandas.DataFrame` attributes/methods


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>


Merge pull request #129 from posit-dev/bugfix/homedir-693

Fix that addresses homedir #693
--------------------
Commit message for posit-dev/positron-python@770408c:

Fix that addresses homedir posit-dev/positron-python#693


Authored-by: Brian Lambert <[email protected]>
Signed-off-by: Brian Lambert <[email protected]>
Merge pull request #119 from posit-dev/prototype-687


--------------------
Commit message for posit-dev/positron-python@fe8d8a8:

move to even simpler solution using dict.fromkeys()

--------------------
Commit message for posit-dev/positron-python@0cef8b7:

Merge branch 'main' into prototype-687

--------------------
Commit message for posit-dev/positron-python@342fdf6:

Merge branch 'main' into prototype-687

--------------------
Commit message for posit-dev/positron-python@34f195e:

linting

--------------------
Commit message for posit-dev/positron-python@e326e47:

prototype dynamic qualname


Authored-by: Isabel Zimmerman <[email protected]>
Signed-off-by: Isabel Zimmerman <[email protected]>
…rings

Merge pull request #128 from posit-dev/parse-rst

parse reStructuredText docstrings
--------------------
Commit message for posit-dev/positron-python@ad4aedd:

forgot to add markdown-it-py dependency

--------------------
Commit message for posit-dev/positron-python@36b7203:

fix python 3.8 compatibility

`pydoc._getdoc` was only introduced in 3.9, so rather call `getdoc` directly.

--------------------
Commit message for posit-dev/positron-python@0b3a1c2:

test rst parsing

--------------------
Commit message for posit-dev/positron-python@471a320:

remove docrepr and revert rst_parser setting

--------------------
Commit message for posit-dev/positron-python@9f847df:

try python 3.7 to build requirements

--------------------
Commit message for posit-dev/positron-python@59c34f0:

revert `breaks` setting to use the full width of the help pane

--------------------
Commit message for posit-dev/positron-python@d2f5dc2:

parse reStructuredText docstrings to html

This allows two different parsers: `sphinxify` (via `docrepr`) and `docstring-to-markdown`. The intention is to test out both, and only keep the one we prefer. There is an editor setting to switch between them.

It adds three dependencies:

- `docrepr`, which depends on `sphinx` which is a bit heavy. `docrepr` is an optional dependency of IPython
- `docstring-to-markdown`, has no further deps and `jedi-language-server` already depends on it
- `markdown-it-py`, very lightweight (only one other dep)


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
Merge pull request #131 from posit-dev/customize-help


--------------------
Commit message for posit-dev/positron-python@17d3e78:

linting again

--------------------
Commit message for posit-dev/positron-python@f4f87c2:

ignoring more for pyright

--------------------
Commit message for posit-dev/positron-python@cebbbb0:

linting

--------------------
Commit message for posit-dev/positron-python@e0fb2ce:

add testing and version compatability

Pydoc in Python < 3.10 uses parameters fgcol and bgcol in
pydoc.HTMLDoc.heading, that no longer exist in later versions. This
checks to see if that parameter exists, and fills it if necessary.
Otherwise, it uses the modern function signature that does not include
hardcoding foreground/background colors.

--------------------
Commit message for posit-dev/positron-python@0982e63:

fix pyright issues

--------------------
Commit message for posit-dev/positron-python@4ecc000:

vendor in html_topicpage

this will allow lookup of keywords such as "False", "None", etc

--------------------
Commit message for posit-dev/positron-python@b6dc919:

updates from review

--------------------
Commit message for posit-dev/positron-python@4eea70c:

no need to change requirements.txt

--------------------
Commit message for posit-dev/positron-python@8c0d291:

stylizing _positron_url_handler

this handler is used in the pydoc server. it creates a module index
page, search and "get" textboxes, and styles all the headings. this
might be brittle across versions of python, and will need tests.
currently, much of the color scheme is using css variables created by
VSCode.

the updates from the original pydoc._url_handler are mainly colors,
removing all metadata from the header besides the python version,
removing keyword and topic pages, removing backgrounds of the text.


Authored-by: Isabel Zimmerman <[email protected]>
Signed-off-by: Isabel Zimmerman <[email protected]>
Merge pull request #137 from posit-dev/fix-help-module

fix `get_qualname` for modules
--------------------
Commit message for posit-dev/positron-python@95e7417:

fix `get_qualname` for modules

This fixes, for example, `help(pandas)`.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…c` improvements

Merge pull request #135 from posit-dev/pydoc-misc

Miscellaneous `positron.pydoc` improvements
--------------------
Commit message for posit-dev/positron-python@420df29:

add fallback styles when running positron.pydoc outside of positron

--------------------
Commit message for posit-dev/positron-python@aa9f115:

misc improvements to pydoc

Narrowed the interface to a single function: `start_server`.

Run `start_server` via `python -m positron.pydoc` for easier development.

Added a logger. We should add many more logs since pydoc tends to fail silently.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…ng change in python 3.11

Merge pull request #136 from posit-dev/fix-pydoc-breaking-change

fix pydoc css-related breaking change in python 3.11
--------------------
Commit message for posit-dev/positron-python@c5601ae:

fix source in comments

--------------------
Commit message for posit-dev/positron-python@0cbac07:

parameterize test; fix failing related test

--------------------
Commit message for posit-dev/positron-python@ef22df3:

fix pydoc breaking change in python 3.11

Vendored a whole bunch more. Note that we'd have to vendor these if we wanted to customize them anyway.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…. `help(pd.DataFrame.T)`

Merge pull request #138 from posit-dev/fix-help-property

fix: help for properties e.g. `help(pd.DataFrame.T)`
--------------------
Commit message for posit-dev/positron-python@c16ee4d:

fix: help for properties e.g. `help(pd.DataFrame.T)`


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
… numpy

Merge pull request #139 from posit-dev/fix-help-numpy-import

fix: don't let `help` reload numpy
--------------------
Commit message for posit-dev/positron-python@0dbd7f8:

fix source of functions in comments

--------------------
Commit message for posit-dev/positron-python@4d4be07:

fix: don't let `help` reload numpy

Also changed to explicit imports so we don't have to change as much of `html_getobj`.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…tes instead of displaying their full docs

Merge pull request #134 from posit-dev/class-and-module-lists

Link to class/module attributes instead of displaying their full docs
--------------------
Commit message for posit-dev/positron-python@6efafbd:

fix breaking change in `pydoc.getdoc` in Python 3.9

--------------------
Commit message for posit-dev/positron-python@c2e88b4:

link to class/module attrs instead of displaying their full docs

fixes posit-dev/positron-python#789

--------------------
Commit message for posit-dev/positron-python@a9c74c3:

pytest vscode config


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…rST docstrings

Merge pull request #130 from posit-dev/resolve-cross-refs

resolve cross-references in rST docstrings
--------------------
Commit message for posit-dev/positron-python@f0e6067:

fix typo

--------------------
Commit message for posit-dev/positron-python@70b43ae:

remove duplicate test

--------------------
Commit message for posit-dev/positron-python@65c261e:

fix: resolving a link from a module

--------------------
Commit message for posit-dev/positron-python@fb2aa27:

resolve cross-references in rST docstrings

Addresses #764.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…gments

Merge pull request #141 from posit-dev/help-syntax-highlighting

syntax highlighting using pygments
--------------------
Commit message for posit-dev/positron-python@b8844dd:

address review comments

--------------------
Commit message for posit-dev/positron-python@736b1cb:

syntax highlighting using pygments

Addresses #790.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
… and styling

Merge pull request #142 from posit-dev/tweak-help-layout-and-styling

small improvements to layout and styling
--------------------
Commit message for posit-dev/positron-python@412e137:

update tests

--------------------
Commit message for posit-dev/positron-python@e21dba5:

horizontally scroll code blocks

--------------------
Commit message for posit-dev/positron-python@1008f71:

small improvements to layout and styling

Simpler headings and sections using `<h*` and `<section>` tags instead of `<table>`s.

Let `<h*>` tags deal with formatting instead of using `<strong>`.

Disable the file link since it does nothing in Positron.

Update fallback fonts to match Positron on mac.

Styling:
- Tweaked autosummary tables
- Tweaked code blocks
- Re-enabled scroll bars


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
Merge pull request #144 from posit-dev/version


--------------------
Commit message for posit-dev/positron-python@c02d8ff:

update css

--------------------
Commit message for posit-dev/positron-python@de18acb:

add function version_text

--------------------
Commit message for posit-dev/positron-python@78618d5:

update test

--------------------
Commit message for posit-dev/positron-python@13f4ec6:

and linting

--------------------
Commit message for posit-dev/positron-python@67781c5:

pyright

--------------------
Commit message for posit-dev/positron-python@caa6936:

Merge branch 'main' into version
--------------------
Commit message for posit-dev/positron-python@11c0291:

add package-version div to module

--------------------
Commit message for posit-dev/positron-python@ae16ccf:

update tests

--------------------
Commit message for posit-dev/positron-python@2544159:

horizontally scroll code blocks

--------------------
Commit message for posit-dev/positron-python@172043d:

small improvements to layout and styling

Simpler headings and sections using `<h*` and `<section>` tags instead of `<table>`s.

Let `<h*>` tags deal with formatting instead of using `<strong>`.

Disable the file link since it does nothing in Positron.

Update fallback fonts to match Positron on mac.

Styling:
- Tweaked autosummary tables
- Tweaked code blocks
- Re-enabled scroll bars

--------------------
Commit message for posit-dev/positron-python@0a2a6ee:

Update pythonFiles/positron/pydoc.py

Co-authored-by: Wasim Lorgat <[email protected]>
--------------------
Commit message for posit-dev/positron-python@43914b9:

add tests

--------------------
Commit message for posit-dev/positron-python@3511cc4:

add version below docclass title

use `re` to match before the first '.' of an object name
if there is a match, see if importlib can find a version of that package


Lead-authored-by: Isabel Zimmerman <[email protected]>
Co-authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Isabel Zimmerman <[email protected]>
Merge pull request #145 from posit-dev/pre-commit


--------------------
Commit message for posit-dev/positron-python@375631d:

add pre-commit config


Authored-by: Isabel Zimmerman <[email protected]>
Signed-off-by: Isabel Zimmerman <[email protected]>
Merge pull request #146 from posit-dev/version-fix


--------------------
Commit message for posit-dev/positron-python@bded5dc:

to pass tests

--------------------
Commit message for posit-dev/positron-python@e064a1f:

fix headers for help docs


Authored-by: Isabel Zimmerman <[email protected]>
Signed-off-by: Isabel Zimmerman <[email protected]>
Merge pull request #147 from posit-dev/refactor-help-override

refactor overriding help
--------------------
Commit message for posit-dev/positron-python@9a1191f:

refactor overriding help


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
Merge pull request #140 from posit-dev/upkeep/update-dts

Update Positron declarations
--------------------
Commit message for posit-dev/positron-python@b1032ea:

Update Positron declarations


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Lionel Henry <[email protected]>
… and rename test files to match modules

Merge pull request #149 from posit-dev/rename-positron-tests

create positron tests folder and rename test files to match modules
--------------------
Commit message for posit-dev/positron-python@9e0416b:

create positron tests folder and rename test files to match modules


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
jgutman and others added 25 commits March 28, 2024 15:04
* update logic

* add unit test for changed behavior

* mock installed ipykernel

* only check if current interpreter
…thon#409)

* Implement `executeCommand` as OpenRPC contract

* Remove extraneous file
…ies version for django

Merge pull request #411 from posit-dev/security/django-test-requirements

Update pinned test dependencies version for django
--------------------
Commit message for posit-dev/positron-python@e5224d5:

Update pinned test dependencies version for django

Address snyk reported issues for django in our test dependencies.


Authored-by: Pete Farland <[email protected]>
Signed-off-by: Pete Farland <[email protected]>
Merge pull request #412 from posit-dev/smoke-tests

add smoke tests to ci
--------------------
Commit message for posit-dev/positron-python@0c99c55:

fix

--------------------
Commit message for posit-dev/positron-python@2e4791a:

enable experiments by writing user settings before starting the test script

--------------------
Commit message for posit-dev/positron-python@974ba0a:

fix typos

--------------------
Commit message for posit-dev/positron-python@142cc7b:

speed up smart send smoke test by 10s

--------------------
Commit message for posit-dev/positron-python@5fe5120:

remove unneeded await

--------------------
Commit message for posit-dev/positron-python@f6dce2b:

rewrite new versions to the same dir to save space

--------------------
Commit message for posit-dev/positron-python@078407b:

add pat to ci step

--------------------
Commit message for posit-dev/positron-python@6bb5518:

compile before running smoke tests

--------------------
Commit message for posit-dev/positron-python@30ffce5:

use application env service for package.json

--------------------
Commit message for posit-dev/positron-python@2e244ed:

add smoke tests to ci


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
Merge pull request #415 from posit-dev/unpin-pytest

Unpin pytest
--------------------
Commit message for posit-dev/positron-python@4f78002:

unpin pytest

our reason for pinning has been fixed upstream in microsoft/vscode-python#22799.

also bump pytest-asyncio to a compatible version.


Authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
…ssing patches, invalid semver (posit-dev/positron-python#417)

* use existing upstream function for compare descending to handle improper semver versions

* also add try catch within the for loop
…prettier checks (posit-dev/positron-python#416)

* unpin pytest

our reason for pinning has been fixed upstream in microsoft/vscode-python#22799.

also bump pytest-asyncio to a compatible version.

* extract positron-ipykernel ci job and test requirements

* remove pillow - it's another snyk pin

* remove unusued test requirements

* re-add pyright job

* re-add ruff to ci lint job

* re-add format-check; downgrade prettier to match upstream; fix format errors

* checkout before setting up pip cache
* add venv tests to ci

Relates to #890.

* run `yarn format-fix`
…on-python#414)

* try using P3M for snapshot

some of the pinned dependencies are not available on the dates we are
requesting, so pulling those. We might need to split these out?

* use element_size for tensors

* frame_equal for polars dataframes

* DRYer + move requirements.txt

* split envvar creation to own step
… Python Language Pack

Merge pull request #413 from posit-dev/feature/runtime-sessions

Add multi-session support to Python Language Pack
--------------------
Commit message for posit-dev/positron-python@fe3ca4e:

Merge remote-tracking branch 'origin/main' into feature/runtime-sessions

--------------------
Commit message for posit-dev/positron-python@7cc1d55:

Update src/client/positron/manager.ts

Co-authored-by: Wasim Lorgat <[email protected]>
--------------------
Commit message for posit-dev/positron-python@fd9ed20:

add metadata validator

--------------------
Commit message for posit-dev/positron-python@2bacdc1:

update type definitions for Positron API

--------------------
Commit message for posit-dev/positron-python@c219bfd:

simplify session start code from persisted data

--------------------
Commit message for posit-dev/positron-python@99f61c1:

format-fix for new files

--------------------
Commit message for posit-dev/positron-python@1b1a09e:

format jupyter-adapter types according to python extension rules

--------------------
Commit message for posit-dev/positron-python@1cb405a:

reapply patch for posit-dev/positron-python#417

--------------------
Commit message for posit-dev/positron-python@937f17c:

Merge remote-tracking branch 'origin/main' into feature/runtime-sessions

--------------------
Commit message for posit-dev/positron-python@8d9680c:

always start lazily (for untrusted workspaces)

--------------------
Commit message for posit-dev/positron-python@e1dbb76:

fix TS lint: jupyter-adapter.d.ts reference

--------------------
Commit message for posit-dev/positron-python@276e13c:

add session-mode argument

--------------------
Commit message for posit-dev/positron-python@c76ed94:

pass session mode as a kernel arg

--------------------
Commit message for posit-dev/positron-python@19a8593:

port fix for package JSON source

--------------------
Commit message for posit-dev/positron-python@9a43110:

Merge remote-tracking branch 'origin/main' into feature/runtime-sessions

--------------------
Commit message for posit-dev/positron-python@4d85695:

cleanup, comments

--------------------
Commit message for posit-dev/positron-python@b78430f:

semver throws an exception for versions with < 3 components

--------------------
Commit message for posit-dev/positron-python@45d59f9:

use lazy activation as needed

--------------------
Commit message for posit-dev/positron-python@2780de8:

use kernelspec to detect restored/new session

--------------------
Commit message for posit-dev/positron-python@df20e83:

move LSP creation to session start

--------------------
Commit message for posit-dev/positron-python@e373ead:

fire event when registering runtimes out of band

--------------------
Commit message for posit-dev/positron-python@28fbd37:

register runtime manager with Positron; store map of path to interpreter

--------------------
Commit message for posit-dev/positron-python@2db9ebf:

remove provider; clean up session start

--------------------
Commit message for posit-dev/positron-python@1679bce:

cache/replay environment id

--------------------
Commit message for posit-dev/positron-python@3fe2c45:

begin moving session creation work into the manager

--------------------
Commit message for posit-dev/positron-python@c3bc1b0:

update Jupyter Adapter API

--------------------
Commit message for posit-dev/positron-python@5902ccd:

implement runtime discovery

--------------------
Commit message for posit-dev/positron-python@d1a807c:

Merge remote-tracking branch 'origin/feature/runtime-sessions' into feature/runtime-sessions

--------------------
Commit message for posit-dev/positron-python@450a034:

update to latest Positron API

--------------------
Commit message for posit-dev/positron-python@8e08104:

stubs for runtime manager

--------------------
Commit message for posit-dev/positron-python@e075863:

use new jupyter adapter API

--------------------
Commit message for posit-dev/positron-python@304bcb9:

update type definitions from upstream


Lead-authored-by: Jonathan McPherson <[email protected]>
Co-authored-by: Wasim Lorgat <[email protected]>
Signed-off-by: Jonathan McPherson <[email protected]>
…/positron-python#425)

* check if active interpreter when new runtime added

* pull out into anonymous registerRuntime
… is incomplete in Python (posit-dev/positron-python#426)

* add wrapper command and use that instead
* prettier
* update unit test expected output
…pstream; fix ruff ignores

Merge pull request #431 from posit-dev/ci-fixes

downgrade pyright to match upstream; fix ruff ignores
--------------------
Commit message for posit-dev/positron-python@1a45ab6:

downgrade pyright to match upstream; fix ruff ignores


Authored-by: Pete Farland <[email protected]>
Signed-off-by: Wasim Lorgat <[email protected]>
* create function for usage

* prune GETTING HELP

* add tests

* change to positron-beta link

* Apply suggestions from code review

Co-authored-by: Wasim Lorgat <[email protected]>

---------

Co-authored-by: Wasim Lorgat <[email protected]>
* Initial implementation of the connections pane service.

* Make some improvements to the connections pane service

* Add mopre docs + typings

* Remove usages of lowercase any

* Fix typing errors

* more typing fixes

* move test connection to other file

* small tweak

* add SQLite implementation for PositronConnection

* lint

* Support SQLAlchemy + data explorer

* add requirements

* sqlite3 is bundled in python

* also specify as test requirement

* maybe pin here?

* move sqlite3 to type checking only

* Apply renaming suggestions

* add service method that wraps the connections.

* refactor out the `ConnectionRef`

* use third-party to import sqlalchemy

* move logic to wrap a connection into `register_connection`

* make sure failing `disconnect()` is not fatal, specially for `shutdown`.

* use `safe_isinstance`

* send errors to the UI

* correct typing

* Add backend tests for the connections pane

* Fix typing issues

* remove unused `ConnectionRef`

* Cleanup data_explorer_service to avoid breaking its tests.

* Support older pandas versions

* Use base_comm for tests so we also test the connections_comm deserialization.

* remove unused imports

* Use enum

Co-authored-by: Isabel Zimmerman <[email protected]>

* Update pythonFiles/positron/positron_ipykernel/tests/test_connections.py

Co-authored-by: Isabel Zimmerman <[email protected]>

* Update pythonFiles/positron/positron_ipykernel/connections.py

Co-authored-by: Isabel Zimmerman <[email protected]>

* Use comm_target_name from enum

* Fixes error with second connection

* fix typing

* Improve error messages

* Modify test assertion as the server keeps some state.

---------

Co-authored-by: Isabel Zimmerman <[email protected]>
submodule related matters from gulpfile, remove empty .gitmodules
expository from extensions/positron-python subdirectory.
@wesm wesm force-pushed the graft-positron-python branch from c73dde6 to d85cb93 Compare March 28, 2024 20:06
@petetronic petetronic self-requested a review March 28, 2024 21:20
Copy link
Collaborator

@petetronic petetronic left a comment

Choose a reason for hiding this comment

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

Ran locally both as a dev launch and a locally built application, and Python operations continued to work.

It seems devs will have to move their old extensions/positron-python folder from the former submodule out of the way before syncing these changes.

@wesm wesm merged commit d85cb93 into main Mar 28, 2024
27 checks passed
@wesm wesm deleted the graft-positron-python branch March 28, 2024 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.