FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Allow widget model id to be set on creation via _model_id argument by SylvainCorlay · Pull Request #6180 · ipython/ipython · GitHub

Allow widget model id to be set on creation via _model_id argument - #6180

Closed
SylvainCorlay wants to merge 1 commit into
ipython:masterfrom
SylvainCorlay:set-model-id
Closed

Allow widget model id to be set on creation via _model_id argument#6180
SylvainCorlay wants to merge 1 commit into
ipython:masterfrom
SylvainCorlay:set-model-id

Conversation

Copy link
Copy Markdown
Member

Simple change meant to allow widget model ids to be set externally.

Copy link
Copy Markdown
Member

This would be simpler if it was based on #6151, as you wouldn't have to store _model_id, but could just directly instantiate the comm with the correct id in the init method. On second thought, I guess you might still want to store the model id in case open() is called more than once.

Copy link
Copy Markdown
Member

I think it would make more sense to me if we changed the widget class model_id from a property to an attribute, set the default to generating a new UUID, and then always set the comm id to the model id. Then setting the model_id becomes part of the standard trait machinery.

Copy link
Copy Markdown
Member Author

Closing. will open a PR to your branch, used for PR #6151 .

SylvainCorlay deleted the set-model-id branch July 23, 2014 23:05
minrk added this to the no action milestone Jul 29, 2014
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

3 participants


Back | FazBrowse Home | New Git URL