Skip to content

Conversation

@monchier
Copy link
Collaborator

@monchier monchier requested a review from tvst August 26, 2019 16:32
# Parse the contents of functions, With statements, and for statements
if (node_type is ast.FunctionDef or node_type is ast.With or
node_type is ast.For):
_modify_ast_subtree(node)
Copy link
Contributor

Choose a reason for hiding this comment

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

Bringing the conversation from the old repo in here:

tvst 3 days ago
You removed the body[i] = thing. Are you sure that's not needed? (i.e. is node always being modified in-place?)

monchier 3 days ago
Yeah, I was about to add a note. From some tests seems it is not. You have a specific case in mind? _modify_ast_subtree should recurse and node is an object, so it is mutated.

Actually I think you're right. That part of the code is probably no longer needed. We used to do some heavier AST modifications that did not mutate the original nodes, but from a quick pass it looks like they're gone now.

@monchier monchier changed the base branch from 1216 to develop August 26, 2019 19:03
@monchier monchier merged commit e6ec7c0 into streamlit:develop Aug 26, 2019
tconkling added a commit to tconkling/streamlit that referenced this pull request Aug 27, 2019
* develop:
  st.map() using deck_gl (streamlit#14)
  Adding support for if and for to magic (streamlit#12)
  Fix vertical spacing in Streamlit reports (streamlit#7)
  Fix streamlit#6: report should loads element by element (was broken since Sidebar PR) (streamlit#9)
tvst added a commit that referenced this pull request Sep 14, 2021
* Make h1 bolder by adding extrabold font.

* Reduce base font to 16px again.

* Make h1 a little bigger.

* Set vertical rhythm in headers (always add to integer rems).

Stop using margin so no need to tweak first-child case.

* Make headers in sidebar smaller (i.e. undo previous change).

* Add more space to report top.

* Improve vertical rhythm on st.metric

* Add typography e2e test. Screenshots coming in next PR.

* Fix JS snapshot test.

* Add name for 1.125rem font.

* Fix typography test spec
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.

2 participants