jorisvandenbossche commented on a change in pull request #11196:
URL: https://github.com/apache/arrow/pull/11196#discussion_r713255213



##########
File path: python/pyarrow/types.pxi
##########
@@ -2446,8 +2446,11 @@ cpdef DictionaryType dictionary(index_type, value_type, 
bint ordered=False):
         DictionaryType out = DictionaryType.__new__(DictionaryType)
         shared_ptr[CDataType] dict_type
 
-    if _index_type.id not in {Type_INT8, Type_INT16, Type_INT32, Type_INT64}:
-        raise TypeError("The dictionary index type should be signed integer.")
+    if _index_type.id not in {
+        Type_INT8, Type_INT16, Type_INT32, Type_INT64,
+        Type_UINT8, Type_UINT16, Type_UINT32, Type_UINT64,

Review comment:
       Hmm, that primitive types definition in types.pxi actually doesn't seem 
to be used in practice .. 
   
   (if we use more of those, it would certainly be worth moving them, though, I 
think. Something we can do when that comes up I suppose)




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to