Moelf opened a new issue, #418:
URL: https://github.com/apache/arrow-julia/issues/418

   `eachindex()` can return useful index or garbage depending on the size of 
the Arrow file:
   ```julia
   julia> Arrow.append("./out2.feather", gendata())
   "./out2.feather"
   
   julia> tbl2 = Arrow.Table("./out2.feather")
   Arrow.Table with 3 rows, 2 columns, and schema:
    :x  Vector{Float64} (alias for Array{Float64, 1})
    :y  Vector{Float64} (alias for Array{Float64, 1})
   
   julia> tbl2.x
   3-element Arrow.List{Vector{Float64}, Int32, Arrow.Primitive{Float64, 
Vector{Float64}}}:
    [0.38906822055013135]
    [0.9737332599073911, 0.19757843080977833, 0.06268161159155239, 
0.9716472746828138, 0.8838743377016612, 0.951662206335832, 0.5973352614611379, 
0.8876145238421496, 0.5149018084376046]
    [0.9363691598185577, 0.3603564376862347, 0.6425331531623392, 
0.4465148469221817, 0.9705740924873874, 0.7543076133441144, 0.9591142326905828, 
0.1521499948934163, 0.49812895258696377]
   
   julia> eachindex(tbl2.x)
   Base.OneTo(3)
   ```
   
   ```julia
   julia> foreach(1:100) do _
              Arrow.append("./out2.feather", gendata())
          end
   
   julia> tbl2 = Arrow.Table("./out2.feather")
   Arrow.Table with 303 rows, 2 columns, and schema:
    :x  Vector{Float64} (alias for Array{Float64, 1})
    :y  Vector{Float64} (alias for Array{Float64, 1})
   
   julia> eachindex(tbl2.x)
   SentinelArrays.IndexIterator{Arrow.List{Vector{Float64}, Int32, 
Arrow.Primitive{Float64, Vector{Float64}}}}(Arrow.List{Vector{Float64}, Int32, 
Arrow.Primitive{Float64, Vector{Float64}}}[[[0.38906822055013135], 
[0.9737332599073911, 0.19757843080977833, 0.06268161159155239, 
0.9716472746828138, 0.8838743377016612, 0.951662206335832, 0.5973352614611379, 
0.8876145238421496, 0.5149018084376046], [0.9363691598185577, 
0.3603564376862347, 0.6425331531623392, 0.4465148469221817, 0.9705740924873874, 
0.7543076133441144, 0.9591142326905828, 0.1521499948934163, 
0.49812895258696377]], [[0.723214841767352, 0.43489448845317247, 
0.7435036925620425, 0.4503683881092432, 0.7568472306565802, 0.9434247930999995, 
0.1137908376766733, 0.9561139152795906], [0.48214812381208816, 
0.08258591275570137, 0.6524745829052587, 0.1384493817488982
   ```
   
   I understand this is because SentinelArrays, but this is really unintuitive


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to