diff --git a/ibis/expr/operations/generic.py b/ibis/expr/operations/generic.py index 19c96cbd44f8..fe4cb8afa64f 100644 --- a/ibis/expr/operations/generic.py +++ b/ibis/expr/operations/generic.py @@ -2,6 +2,7 @@ import enum import functools import itertools +import uuid import numpy as np import pandas as pd @@ -247,6 +248,7 @@ class Literal(ValueOp): str, tuple, type(None), + uuid.UUID, ) ), rlz.is_computable_input, diff --git a/ibis/tests/expr/test_value_exprs.py b/ibis/tests/expr/test_value_exprs.py index de292e2da2dc..12ba8907bf80 100644 --- a/ibis/tests/expr/test_value_exprs.py +++ b/ibis/tests/expr/test_value_exprs.py @@ -1,6 +1,7 @@ import functools import operator import os +import uuid from collections import OrderedDict from datetime import date, datetime, time from operator import methodcaller @@ -118,6 +119,8 @@ def test_literal_with_implicit_type(value, expected_type): (tuple(multipoint), 'multipoint'), (list(multipolygon1), 'multipolygon'), (tuple(multipolygon1), 'multipolygon'), + (uuid.uuid4(), 'uuid'), + (str(uuid.uuid4()), 'uuid'), ], ) def test_literal_with_explicit_type(value, expected_type):