Repository: ibis-project/ibis

Issue:
bug: can't preview table containing UUIDs
### What happened?

```python
import ibis
ibis.options.interactive = True

t = ibis.memtable(
    {
        "x": [1, 2, 3],
    }
)
con = ibis.duckdb.connect()
t = con.create_table("t", t, overwrite=True)
t = t.sql("SELECT *, uuid() as id FROM t")
t
```
After the .sql() call, there is to interactive preview showing up. If I remove the .sql() line, it does show up

<img width="421" alt="image" src="https://github.com/ibis-project/ibis/assets/10820686/26d952b9-97ef-4ae2-a4f9-f3019f7b4e85">

<img width="399" alt="image" src="https://github.com/ibis-project/ibis/assets/10820686/d41701b1-6bff-4a20-ae9b-57f54ff3328a">



### What version of ibis are you using?

8.0.0

### What backend(s) are you using, if any?

duckdb

### Relevant log output

_No response_

### Code of Conduct

- [X] I agree to follow this project's Code of Conduct

Discussion:
github-actions[bot]: **ACTION NEEDED**

Ibis follows the [Conventional Commits specification](https://www.conventionalcommits.org/en/v1.0.0/) for release automation.

The PR title and description are used as the merge commit message.

Please update your PR title and description to match the specification.
cpcloud: Confirming this fixes the repr:

```
In [3]: from ibis.interactive import *

In [4]: con = ibis.duckdb.connect()

In [5]: con.sql("select uuid()")
Out[5]:
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ uuid()                               ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ uuid                                 │
├──────────────────────────────────────┤
│ 46bdc7b4-152c-43b7-8f8a-8d136a8cc7dd │
└──────────────────────────────────────┘
```
NickCrews: This looks good, thanks @cpcloud !

Assuming that we don't want to actually ship a [pyarrow extension type](https://arrow.apache.org/docs/python/extending_types.html) (they have a uuid example there)?
cpcloud: > This looks good, thanks @cpcloud !
> 
> Assuming that we don't want to actually ship a [pyarrow extension type](https://arrow.apache.org/docs/python/extending_types.html) (they have a uuid example there)?

Eventually maybe, but not in this PR :)
cpcloud: Extension types run the risk of creating type fiefdoms, and that's not good for ibis because we have to interact with downstream systems. Placing a burden on them to understand our PyArrow extension types is asking quite a lot.

Patch:
diff --git a/ibis/formats/pyarrow.py b/ibis/formats/pyarrow.py
index 993ce20fe..dc1192ecd 100644
--- a/ibis/formats/pyarrow.py
+++ b/ibis/formats/pyarrow.py
@@ -90,6 +90,7 @@ _to_pyarrow_types = {
     dt.Unknown: pa.string(),
     dt.MACADDR: pa.string(),
     dt.INET: pa.string(),
+    dt.UUID: pa.string(),
 }
 
 


Test patch:
diff --git a/ibis/formats/tests/test_pyarrow.py b/ibis/formats/tests/test_pyarrow.py
index c94ce1886..063d75cbc 100644
--- a/ibis/formats/tests/test_pyarrow.py
+++ b/ibis/formats/tests/test_pyarrow.py
@@ -130,6 +130,7 @@ def test_dtype_from_nullable_list_type(value_nullable, list_nullable):
             dt.Set(dt.String(nullable=False)),
             pa.list_(pa.field("item", pa.string(), nullable=False)),
         ),
+        (dt.uuid, pa.string()),
     ],
 )
 def test_ibis_exclusive_types(ibis_type, arrow_type):