-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor tagging: create functions, better logs and names, textwrap.d…
…edent (#2239)
- Loading branch information
1 parent
6c47a89
commit 123d215
Showing
8 changed files
with
128 additions
and
91 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Copyright (c) Jupyter Development Team. | ||
# Distributed under the terms of the Modified BSD License. | ||
from tagging.hierarchy.images_hierarchy import ALL_IMAGES | ||
from tagging.manifests.manifest_interface import ManifestInterface | ||
|
||
|
||
def get_manifests(image: str | None) -> list[ManifestInterface]: | ||
if image is None: | ||
return [] | ||
image_description = ALL_IMAGES[image] | ||
parent_manifests = get_manifests(image_description.parent_image) | ||
return parent_manifests + image_description.manifests |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Copyright (c) Jupyter Development Team. | ||
# Distributed under the terms of the Modified BSD License. | ||
from tagging.hierarchy.images_hierarchy import ALL_IMAGES | ||
from tagging.taggers.tagger_interface import TaggerInterface | ||
|
||
|
||
def get_taggers(image: str | None) -> list[TaggerInterface]: | ||
if image is None: | ||
return [] | ||
image_description = ALL_IMAGES[image] | ||
parent_taggers = get_taggers(image_description.parent_image) | ||
return parent_taggers + image_description.taggers |
This file was deleted.
Oops, something went wrong.
This file contains 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