api: prepare for dvcx summon/publish#3251
Merged
Merged
Conversation
Also removed type python summons from `dvc.api`
dmpetrov
suggested changes
Jan 30, 2020
| raise SummonError(str(exc)) from exc | ||
| return self.objects[name] | ||
|
|
||
| def set(self, name, dobj, overwrite=True): |
Contributor
There was a problem hiding this comment.
I think we should separate pushing dvc-object to a remote repo and just writing an object to a repo.
I see a few scenarios:
- write a dvc-object to a summon file
- write and commit
- commit and push
- commit in a new branch and create a pull request (push to upstream)
The most important scenarios are (1) and (3). (4) is also good. And it is not clear if we need (3).
The current code implements (3). @Suor could you please incorporate (1) and (3) in this PR? Or it is better to do that in a separate PR?
Contributor
Author
There was a problem hiding this comment.
This https://github.com/iterative/dvcx/pull/7 should handle 1 and 3. 3 works with any existing branch. Not sure how 4 should be implemented, can you create an issue in dvcx for that?
dmpetrov
approved these changes
Jan 30, 2020
Will be added to dvcx instead.
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Based on @dmpetrov's #3238
Another change - removed type python summon support from here, moving it to dvcx, to keep everything there.