Skip to content

Conversation

@DavidKutu
Copy link

@DavidKutu DavidKutu commented Jul 11, 2019

For #6367
Added a Code Lens and a snippet to add new cells.

  • Pull request represents a single change (i.e. not fixing disparate/unrelated things in a single PR)
  • Title summarizes what is changing
  • Has a news entry file (remember to thank yourself!)
  • Appropriate comments and documentation strings in the code
  • Has sufficient logging.
  • Has telemetry for enhancements.
  • Unit tests & system/integration tests are added/updated
  • Test plan is updated as appropriate
  • package-lock.json has been regenerated by running npm install (if dependencies have changed)
  • The wiki is updated with any design decisions/details.
David Kutugata added 2 commits July 11, 2019 15:43
add a new cell, in order to make it easier
@DavidKutu DavidKutu self-assigned this Jul 11, 2019
@rchiodo
Copy link

rchiodo commented Jul 11, 2019

I don't think this is what Rong intended. You added 'Add new cell' at the end of every code lens line. I think we want to only have this on the last line of a file. It's a special case, not part of the default case.

Also ALT+ENTER should be wired to match Add new cell (or whatever Jupyter normally uses for adding a new cell). #Resolved

Copy link

@rchiodo rchiodo left a comment

Choose a reason for hiding this comment

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

🕐

add cell when you press Alt+Enter, update codewatcher.unit.test.ts to expect more code lenses
@rchiodo
Copy link

rchiodo commented Jul 12, 2019

Still not sure I like the behavior.

There's an Add New cell just on the end, and the user specifies it as a code lens.

But if you run current cell on the last cell, it adds a new cell anyway.

Hmm. The problem I have is that the user specifies the code lens, and it doesn't show up. What if I want to add a new cell in the middle?


In reply to: 510685632 [](ancestors = 5106856)

@DavidKutu
Copy link
Author

True, I could remove it from settings and just force it to appear on the last cell.


In reply to: 510949886 [](ancestors = 510949886,510685632)

changed the command for the keybing 'alt+enter', user can now make 'Add Cell' code lens appear anywhere he likes, but it will always appear as the last code lens in the last cell, updated codewatcher unit test to reflect the changes in code lens
Copy link
Member

@IanMatthewHuff IanMatthewHuff left a comment

Choose a reason for hiding this comment

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

🕐

added instruction comments at the begining of imported jupyter files, and added a keybinding for alt+enter with a command that matches the behaviour in jupyter.
@rchiodo rchiodo dismissed their stale review July 16, 2019 23:37

revoking review

Copy link

@rchiodo rchiodo left a comment

Choose a reason for hiding this comment

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

🕐

the codewatcher command, and returned codewatcher unit test to its original expected Code Lenses amount
Copy link

@rchiodo rchiodo left a comment

Choose a reason for hiding this comment

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

:shipit:

unit test with correct amount of code lenses
@@ -1,443 +1,456 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
Copy link
Member

Choose a reason for hiding this comment

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

Did you change line endings or something on this? Not sure why the whole thing is showing up as changed.

@DavidKutu DavidKutu merged commit a7256df into master Jul 17, 2019
@DavidKutu DavidKutu deleted the davidkutu/add_new_cell_in_code_lens branch July 17, 2019 20:37
@lock lock bot locked as resolved and limited conversation to collaborators Jul 29, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

4 participants