Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dispatch error while scitype on an SentinelArray which is used by CSV.jl #104

Closed
OkonSamuel opened this issue Jul 31, 2020 · 2 comments
Closed

Comments

@OkonSamuel
Copy link
Member

julia> using MLJScientificTypes, SentinelArrays

julia> b =SentinelArray([1,2,3,4])
4-element SentinelArray{Int64,1,Int64,Missing,Array{Int64,1}}:
 1
 2
 3
 4

julia> scitype(b)
Unknown

julia> scitype(b, MLJScientificTypes.ScientificTypes.convention())
Unknown

julia> scitype(b, MLJScientificTypes.ScientificTypes.convention(), Val(trait(b)))
AbstractArray{Union{Missing, Count},1}

I thinking this is a julia bug. Making a small tweak to the code resolves the issue but i can't seem to understand why this is an issue in the first place.
@ablaom , @tlienart thoughts??

@OkonSamuel
Copy link
Member Author

OkonSamuel commented Aug 26, 2020

This issue has been fixed in the recent julia 1.5.1 patch release.

julia> using MLJScientificTypes, SentinelArrays

julia> b =SentinelArray([1,2,3,4])
4-element SentinelArray{Int64,1,Int64,Missing,Array{Int64,1}}:
 1
 2
 3
 4

julia> scitype(b)
AbstractArray{Union{Missing, Count},1}

julia> scitype(b, MLJScientificTypes.ScientificTypes.convention())
AbstractArray{Union{Missing, Count},1}

julia> scitype(b, MLJScientificTypes.ScientificTypes.convention(), Val(trait(b)))
AbstractArray{Union{Missing, Count},1}

julia> InteractiveUtils.versioninfo()
Julia Version 1.5.1
Commit 697e782ab8 (2020-08-25 20:08 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: Intel(R) Core(TM) i3-5005U CPU @ 2.00GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-9.0.1 (ORCJIT, broadwell)

@OkonSamuel
Copy link
Member Author

closing this. Since it's been resolved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants