fmu-sumo 2.4.5__py3-none-any.whl → 2.4.6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,5 +17,5 @@ __version__: str
17
17
  __version_tuple__: VERSION_TUPLE
18
18
  version_tuple: VERSION_TUPLE
19
19
 
20
- __version__ = version = '2.4.5'
21
- __version_tuple__ = version_tuple = (2, 4, 5)
20
+ __version__ = version = '2.4.6'
21
+ __version_tuple__ = version_tuple = (2, 4, 6)
@@ -1553,7 +1553,11 @@ class SearchContext:
1553
1553
  if (
1554
1554
  ("sum_other_doc_count" in v)
1555
1555
  and (v["sum_other_doc_count"] > 0)
1556
- or v["buckets"][0]["doc_count"] != tot_hits
1556
+ or (
1557
+ "buckets" in v
1558
+ and len(v["buckets"]) > 0
1559
+ and v["buckets"][0]["doc_count"] != tot_hits
1560
+ )
1557
1561
  )
1558
1562
  ]
1559
1563
  if len(conflicts) > 0:
@@ -1612,12 +1616,11 @@ class SearchContext:
1612
1616
  return self._to_sumo(res)
1613
1617
 
1614
1618
  def aggregate(self, columns=None, operation=None) -> objects.Child:
1615
- if len(self.hidden) > 0:
1616
- return self.hidden._aggregate(columns=columns, operation=operation)
1619
+ sc = self.filter(realization=True, column=columns)
1620
+ if len(sc.hidden) > 0:
1621
+ return sc.hidden._aggregate(columns=columns, operation=operation)
1617
1622
  else:
1618
- return self.visible._aggregate(
1619
- columns=columns, operation=operation
1620
- )
1623
+ return sc.visible._aggregate(columns=columns, operation=operation)
1621
1624
 
1622
1625
  async def _verify_aggregation_operation_async(
1623
1626
  self, columns, operation
@@ -1657,13 +1660,14 @@ class SearchContext:
1657
1660
  async def aggregate_async(
1658
1661
  self, columns=None, operation=None
1659
1662
  ) -> objects.Child:
1660
- length_hidden = await self.hidden.length_async()
1663
+ sc = self.filter(realization=True, column=columns)
1664
+ length_hidden = await sc.hidden.length_async()
1661
1665
  if length_hidden > 0:
1662
- return await self.hidden._aggregate_async(
1666
+ return await sc.hidden._aggregate_async(
1663
1667
  columns=columns, operation=operation
1664
1668
  )
1665
1669
  else:
1666
- return await self.visible._aggregate_async(
1670
+ return await sc.visible._aggregate_async(
1667
1671
  columns=columns, operation=operation
1668
1672
  )
1669
1673
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fmu-sumo
3
- Version: 2.4.5
3
+ Version: 2.4.6
4
4
  Summary: Python package for interacting with Sumo in an FMU setting
5
5
  Author: Equinor
6
6
  License: Apache License
@@ -1,7 +1,7 @@
1
1
  fmu/__init__.py,sha256=ftS-xRPSH-vU7fIHlnZQaCTWbNvs4owJivNW65kzsIM,85
2
2
  fmu/sumo/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
3
  fmu/sumo/explorer/__init__.py,sha256=Bc1wd1lQO3HP3tsVyPbqaesf2boZwGdtookWp8lmG-k,317
4
- fmu/sumo/explorer/_version.py,sha256=agt6014xoIR-2Pjd3clvPyl78U4pI7z7EzFGI5OfP8k,511
4
+ fmu/sumo/explorer/_version.py,sha256=A7m3JGqv6GgWxdlAhxGqiDnKOY6QWqyUQuVpQYGKv-s,511
5
5
  fmu/sumo/explorer/cache.py,sha256=uvz8TciwBnDEwJIHa9wneC0WVWuzhUqyF3dzk4kvGNk,1037
6
6
  fmu/sumo/explorer/explorer.py,sha256=_3nUTO1E_nf6jqpivjgjKcX6rX1fx_mIG76YOM8xb-8,2931
7
7
  fmu/sumo/explorer/filters.py,sha256=_t2PmHeTY9XiBvQeEGM-BpudWUaxIfyUSdNyG70xfRU,875
@@ -10,7 +10,7 @@ fmu/sumo/explorer/objects/__init__.py,sha256=72G0yfWWMTXA-oZw5GMRkrWvQqAYfadjerE
10
10
  fmu/sumo/explorer/objects/_child.py,sha256=RrH3W3GF5Nhje7VnhmlEwG_jhX0z6CloJgdGJJzk3po,6035
11
11
  fmu/sumo/explorer/objects/_document.py,sha256=uPAkNzcOk8U4LCtXthWkm7kfU9W4HYHrrqV9HERDhe8,1835
12
12
  fmu/sumo/explorer/objects/_metrics.py,sha256=WITAFAV-3VRd-AqTg0tUwWpOChW4YFfF8ffT2fvOrAo,8144
13
- fmu/sumo/explorer/objects/_search_context.py,sha256=ozyl7xUmun2kouoSnDvNhWgPK8ANJebb7KjDAN0AcEY,63162
13
+ fmu/sumo/explorer/objects/_search_context.py,sha256=tHOxcOK6Mj1pJRKT6JwIKfZ_ogVugAHs8SP4-hIRKNk,63363
14
14
  fmu/sumo/explorer/objects/case.py,sha256=fKp7X43ETLE1RaH3rMYxZiIuduRmf0JSnJ5gRoUgNPE,3813
15
15
  fmu/sumo/explorer/objects/cases.py,sha256=i2bnvk7NWIkzbdWMs3BXU7TCqD5tH2r7pg1m1QXUj3o,561
16
16
  fmu/sumo/explorer/objects/cpgrid.py,sha256=nuRgZ6FVEOPZT1ibd-rJhlbYYZ6BuUxXZPzovcH0kVc,2548
@@ -26,8 +26,8 @@ fmu/sumo/explorer/objects/realization.py,sha256=Th3zr_nT2I1HYHkBojOAKnf_RSIPc-Ti
26
26
  fmu/sumo/explorer/objects/realizations.py,sha256=4agtQFJ5pxLyWMeIzdJbkBMc8__Md-tZOj8Un4ol22c,1562
27
27
  fmu/sumo/explorer/objects/surface.py,sha256=zHBtjLCIfkRHBv39OeJjA9lq3puLTfTII6TndZTtxVI,1627
28
28
  fmu/sumo/explorer/objects/table.py,sha256=vLor3YTddHkDWZSMyWPQsddFNQ2_VXE_O-stmPIWIaQ,4900
29
- fmu_sumo-2.4.5.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
30
- fmu_sumo-2.4.5.dist-info/METADATA,sha256=ZZESEXOqjSMgM6fPAaCrC5nyr01h3q2SqZPjJktyHF0,14781
31
- fmu_sumo-2.4.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
32
- fmu_sumo-2.4.5.dist-info/top_level.txt,sha256=Z-FIY3pxn0UK2Wxi9IJ7fKoLSraaxuNGi1eokiE0ShM,4
33
- fmu_sumo-2.4.5.dist-info/RECORD,,
29
+ fmu_sumo-2.4.6.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
30
+ fmu_sumo-2.4.6.dist-info/METADATA,sha256=YHRaMJwrrPD0zJij7bAC-4voTDVaz4lFxs4a24HEULk,14781
31
+ fmu_sumo-2.4.6.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
32
+ fmu_sumo-2.4.6.dist-info/top_level.txt,sha256=Z-FIY3pxn0UK2Wxi9IJ7fKoLSraaxuNGi1eokiE0ShM,4
33
+ fmu_sumo-2.4.6.dist-info/RECORD,,