Skip to content

Commit

Permalink
Merge pull request #56 from fabric-testbed/slice-status
Browse files Browse the repository at this point in the history
request only slice state
  • Loading branch information
kthare10 authored Oct 2, 2024
2 parents d1e2d71 + bb34466 commit 41d3d2a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion fabric_cf/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "1.7.1"
__version__ = "1.7.3"
6 changes: 4 additions & 2 deletions fabric_cf/orchestrator/orchestrator_proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,8 @@ def delete(self, *, token: str, slice_id: str = None) -> Tuple[Status, Union[Exc

def slices(self, *, token: str, includes: List[SliceState] = None, excludes: List[SliceState] = None,
name: str = None, limit: int = 20, offset: int = 0, slice_id: str = None,
as_self: bool = True, search: str = None, exact_match: bool = False) -> Tuple[Status, Union[Exception, List[Slice]]]:
as_self: bool = True, search: str = None, exact_match: bool = False,
graph_format: str = GraphFormat.GRAPHML.name) -> Tuple[Status, Union[Exception, List[Slice]]]:
"""
Get slices
@param token fabric token
Expand All @@ -300,6 +301,7 @@ def slices(self, *, token: str, includes: List[SliceState] = None, excludes: Lis
@param as_self query as self
@param search search term
@param exact_match true if exact match
@param graph_format graph_format
@return Tuple containing Status and Exception/Json containing slices
"""
if token is None:
Expand All @@ -322,7 +324,7 @@ def slices(self, *, token: str, includes: List[SliceState] = None, excludes: Lis
states.remove(x)

if slice_id is not None:
slices = self.slices_api.slices_slice_id_get(slice_id=slice_id, graph_format=GraphFormat.GRAPHML.name,
slices = self.slices_api.slices_slice_id_get(slice_id=slice_id, graph_format=graph_format,
as_self=as_self)
elif name is not None:
slices = self.slices_api.slices_get(states=SliceState.state_list_to_str_list(states), name=name,
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ dependencies = [
"six >= 1.10",
"python_dateutil >= 2.5.3",
"requests>=2.28.1",
"fabric-fim==1.7.1",
"fabric-fim==1.7.2",
]

[project.optional-dependencies]
Expand Down

0 comments on commit 41d3d2a

Please sign in to comment.