File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -1881,7 +1881,11 @@ def find_domain_by_name(
1881
1881
:raises NotFoundError: if no domain with the provided name exists
1882
1882
"""
1883
1883
attributes = attributes or []
1884
- query = Term .with_name (name ) + Term .with_type_name ("DataDomain" )
1884
+ query = (
1885
+ Term .with_state ("ACTIVE" )
1886
+ + Term .with_name (name )
1887
+ + Term .with_type_name ("DataDomain" )
1888
+ )
1885
1889
return self ._search_for_asset_with_name (
1886
1890
query = query , name = name , asset_type = DataDomain , attributes = attributes
1887
1891
)[0 ]
@@ -1901,7 +1905,11 @@ def find_product_by_name(
1901
1905
:raises NotFoundError: if no product with the provided name exists
1902
1906
"""
1903
1907
attributes = attributes or []
1904
- query = Term .with_name (name ) + Term .with_type_name ("DataProduct" )
1908
+ query = (
1909
+ Term .with_state ("ACTIVE" )
1910
+ + Term .with_name (name )
1911
+ + Term .with_type_name ("DataProduct" )
1912
+ )
1905
1913
return self ._search_for_asset_with_name (
1906
1914
query = query , name = name , asset_type = DataProduct , attributes = attributes
1907
1915
)[0 ]
You can’t perform that action at this time.
0 commit comments