Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion libs/core/garf_core/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.

__version__ = '0.1.2'
__version__ = '0.1.3'
5 changes: 5 additions & 0 deletions libs/core/garf_core/parsers.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ def parse_row(

def get_nested_field(self, dictionary: dict[str, Any], key: str):
"""Returns nested fields from a dictionary."""
if result := dictionary.get(key):
return result
key = key.split('.')
try:
return functools.reduce(operator.getitem, key, dictionary)
Expand All @@ -102,6 +104,9 @@ def convert_field(value):
return type_(value)
return value

if result := dictionary.get(key):
return convert_field(result)

key = key.split('.')
try:
field = functools.reduce(operator.getitem, key, dictionary)
Expand Down
Loading