Skip to content

Releases: krassowski/jupyterlab-go-to-definition

v0.5.0

05 Jul 21:26
Compare
Choose a tag to compare

This changelog covers changes since version 0.2.0:

  • ported to JupyterLab 1.0

  • added jumping to the imported module. Examples of supported syntax include:

    • Python 3 (Python 2 was not tested and the kernel resolution is not guaranteed to work):

      • import x,
      • from x import z,
      • import x.y

      alt-clicking on x or y in the above examples lead to an attempt to open relevant module; if a kernel is available (notebook only for now) the path to the source module will be resolved accurately, otherwise a simple guess (e.g. x.py for x) will be used. Relative imports are supported and the location of the file is considered.

    • R:

      • source('abc.R')
      • import::here(fun.1, .from='abc.R')

      in the first example, alt-clicking on source will open abc.R; in the second example, alt-clicking on .from will also open abc.R. This is planned to be extended to cover the string defining the path itself in future versions.

    Note: only files reachable by JupyterLab can be opened (which is limited due to security reasons, however, may be worked around in the future versions).

  • fixed regression from v0.1.3 in CodeJumper._findLastDefinition which rejected results of the first filtering step; relevant test case was included

  • fixed the element counter (CodeMirrorExtension._countUsagesBefore) mixing up variables and properties instead of focusing on one type only; added tests covering this function

  • added more Python jump tests, reuse the testing code

  • added test for CodeMirrorExtension.selectToken() with a challenging edge case.

v0.2.0

09 Apr 06:35
Compare
Choose a tag to compare

Improvements:

  • cell-specific language detection (parsing of cell magics in IPython) enabling better workflow for mixed R/Python notebooks.
  • jump back (alt + o) option is now active in notebook regardless of the editing state

The first change has a side-effect of enabling correct syntax highlighting for foreign-language cells.

Screenshots:

Highlighting:
Screenshot from 2019-04-06 16-32-43

Jumping to R cell in Python notebook:
jump_to_def_r_cells

v0.1.6

17 Mar 15:41
Compare
Choose a tag to compare

New Features:

  • Now also jumps to %store -r variable when looking for variable definitions, when using Python Kernel.

v0.1.5

16 Mar 19:44
Compare
Choose a tag to compare

Fixes:

  • Fix Safari compatibility issue (#3, #6)

v0.1.3

07 Jan 15:13
Compare
Choose a tag to compare

Fixes:

  • a regression introduced in 0.1.2 which rendered jumping to the definition of variables used in self-overwriting assignments incorrect.
  • an issue with arguments passed to a function call when using default arguments, which sometimes was mistakenly interpreted as tuples.

Implements tests for tuple and self-overwriting assignments.
Enables systematic testing of CodeJumpers in the future.