Skip to content

Expand Session watcher when parantheses #1495

Closed

Description

@BoudSTER

Hi,
first of all thanks you fort this great extension !

Describe the bug
I have a problem with variable autocompletion when my code is in parantheses.
I alerady this issue :) #323

To Reproduce
No problem when I use this code:

  raw %>% select()

But from the moment I put my code in brackets, autocompletion no longer works:

(
  raw %>% select()
)

Additional context
It's actually quite limiting for me because I use this system of parentheses a lot in my code for debugging. Eg :

(
  umi_side_DuplexUMI
  %>% select(-umi2)
  %>% group_by(sample, umi1)
  %>% summarise(count = sum(count))
  %>% arrange(count)
  %>% mutate(count_cumsum=cumsum(count))
  %>% ungroup()
  %>% group_by(sample)
  %>% mutate(n = 1:n())
) -> umi1DuplexUMIyUMI

Thank you in advance for your positive or negative response :)

Have a nice day,

BoudSTER

Activity

  1. ElianHugh commented on Mar 2, 2024

    @ElianHugh
    Collaborator

    I think(?) this would be fixed by #1469

  2. renkun-ken commented on Oct 6, 2026

    @renkun-ken
    Member

    The previously suggested #1469 was closed without merging, so it does not establish a fix for this issue.

    Current pipeline completion still examines the first nonempty line of the selected expression and stops if that line is only (. The parenthesized-pipeline case remains unhandled.

    Keeping this open.

  3. ThomasSoeiro commented on Oct 23, 2026

    @ThomasSoeiro
    Collaborator

    @renkun-ken Maybe I am missing something, but I cannot reproduce with vscode-R 3.2.0. Has a fix been merged?

  4. BoudSTER commented on Oct 24, 2026

    @BoudSTER
    Author

    Hi,

    Thanks for looking into this issue!

    The problem is that autocompletion works correctly when the code is not wrapped in parentheses, but stops working as soon as I wrap the expression in parentheses.

    For example, autocompletion works here:

    raw %>% select()

    But it doesn't work here:

    (
      raw %>% select()
    )

    In the second case, column name suggestions no longer appear inside select().

    I frequently wrap my pipelines in parentheses for debugging purposes, so this is quite inconvenient.

    Let me know if you need any additional information!

    Thanks!

    Image Image
  5. ThomasSoeiro commented on Oct 24, 2026

    @ThomasSoeiro
    Collaborator

    @renkun-ken Maybe I am missing something, but I cannot reproduce with vscode-R 3.2.0. Has a fix been merged?

    @BoudSTER Thanks for providing more information. I can reproduce with vscode-r 3.2.0:

    data(mtcars)
    
    # mtcars columns suggeted in select() 
    mtcars |> dplyr::select(mpg, cyl)
    
    # mtcars columns *not* suggeted in select()
    (
      mtcars |> dplyr::select(mpg, cyl)
    )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions