Julia Can';t读取csv文件:";没有与解析器匹配的方法。选项“;

Julia Can';t读取csv文件:";没有与解析器匹配的方法。选项“;,julia,Julia,读取csv文件应该是直截了当的,对吗?但当我这么做的时候: df = CSV.read("sources/diamonds2.csv") 我收到一些糟糕的错误消息: ERROR: MethodError: no method matching Parsers.Options(::Missing, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::Nothing, ::Nothing, ::Nothing, ::Bo

读取csv文件应该是直截了当的,对吗?但当我这么做的时候:

df = CSV.read("sources/diamonds2.csv")
我收到一些糟糕的错误消息:

ERROR: MethodError: no method matching Parsers.Options(::Missing, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::UInt8, ::Nothing, ::Nothing, ::Nothing, ::Bool, ::Bool, ::Nothing, ::Bool, ::Bool, ::Bool, ::Bool)
Closest candidates are:
  Parsers.Options(::Union{Missing, Nothing, Array{String,1}}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Nothing, Char, UInt8, String}, ::Union{Char, UInt8}, ::Union{Nothing, Array{String,1}}, ::Union{Nothing, Array{String,1}}, ::Union{Nothing, String, Dates.DateFormat}, ::Any, ::Any, ::Any, ::Any, ::Any) at /home/js/.julia/packages/Parsers/GLY4Q/src/Parsers.jl:60
  Parsers.Options(::Union{Missing, Nothing, Array{String,1}}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Nothing, Char, UInt8, String}, ::Union{Char, UInt8}, ::Union{Nothing, Array{String,1}}, ::Union{Nothing, Array{String,1}}, ::Union{Nothing, String, Dates.DateFormat}, ::Any, ::Any, ::Any, ::Any) at /home/js/.julia/packages/Parsers/GLY4Q/src/Parsers.jl:60
  Parsers.Options(::Union{Missing, Nothing, Array{String,1}}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Char, UInt8}, ::Union{Nothing, Char, UInt8, String}, ::Union{Char, UInt8}, ::Union{Nothing, Array{String,1}}, ::Union{Nothing, Array{String,1}}, ::Union{Nothing, String, Dates.DateFormat}, ::Any, ::Any, ::Any) at /home/js/.julia/packages/Parsers/GLY4Q/src/Parsers.jl:60
Stacktrace:
 [1] file(::String, ::Int64, ::Bool, ::Int64, ::Nothing, ::Int64, ::Int64, ::Bool, ::Nothing, ::Bool, ::Bool, ::Nothing, ::Nothing, ::Nothing, ::Array{String,1}, ::String, ::Nothing, ::Bool, ::Char, ::Nothing, ::Nothing, ::Char, ::Nothing, ::UInt8, ::Nothing, ::Nothing, ::Nothing, ::Nothing, ::Dict{Int8,Int8}, ::Bool, ::Float64, ::Bool, ::Bool, ::Bool, ::Bool, ::Nothing) at /home/js/.julia/packages/CSV/76SRf/src/CSV.jl:388
 [2] #File#15(::Int64, ::Bool, ::Int64, ::Nothing, ::Int64, ::Int64, ::Bool, ::Nothing, ::Bool, ::Bool, ::Nothing, ::Nothing, ::Nothing, ::Array{String,1}, ::String, ::Nothing, ::Bool, ::Char, ::Nothing, ::Nothing, ::Char, ::Nothing, ::UInt8, ::Nothing, ::Nothing, ::Nothing, ::Nothing, ::Dict{Int8,Int8}, ::Bool, ::Float64, ::Bool, ::Bool, ::Bool, ::Bool, ::Nothing, ::Type{CSV.File}, ::String) at /home/js/.julia/packages/CSV/76SRf/src/CSV.jl:262
 [3] CSV.File(::String) at /home/js/.julia/packages/CSV/76SRf/src/CSV.jl:262
 [4] #read#70(::Bool, ::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(CSV.read), ::String) at /home/js/.julia/packages/CSV/76SRf/src/CSV.jl:1156
 [5] read(::String) at /home/js/.julia/packages/CSV/76SRf/src/CSV.jl:1156
 [6] top-level scope at none:0
我做错什么了吗

我的Julia版本是1.3.1,CSV的软件包版本是0.6.1,我在Linux系统上


]st-m的输出

    Status `~/.julia/environments/v1.3/Manifest.toml`
  [1520ce14] AbstractTrees v0.3.3
  [bf4720bc] AssetRegistry v0.1.0
  [c52e3926] Atom v0.12.7
  [b99e7846] BinaryProvider v0.5.9
  [6e34b625] Bzip2_jll v1.0.6+2
  [00ebfdb7] CSTParser v2.3.0
  [336ed68f] CSV v0.6.1
  [7057c7e9] Cassette v0.3.3
  [324d7699] CategoricalArrays v0.7.7
  [53a63b46] CodeTools v0.7.0
  [da1fd8a2] CodeTracking v0.5.11
  [3da002f7] ColorTypes v0.10.3
  [5ae59095] Colors v0.12.0
  [34da2185] Compat v3.9.0
  [e66e0078] CompilerSupportLibraries_jll v0.3.3+0
  [d38c429a] Contour v0.5.2
  [9a962f9c] DataAPI v1.3.0
  [a93c6f00] DataFrames v0.20.2
  [864edb3b] DataStructures v0.17.15
  [e2d170a0] DataValueInterfaces v1.0.0
  [55939f99] DecFP v0.4.10
  [b4f34e82] Distances v0.8.2
  [33d173f1] DocSeeker v0.4.1
  [c87230d0] FFMPEG v0.3.0
  [b22a6f82] FFMPEG_jll v4.1.0+3
  [5789e2e9] FileIO v1.3.0
  [48062228] FilePathsBase v0.7.0
  [53c48c17] FixedPointNumbers v0.8.0
  [08572546] FlameGraphs v0.2.3
  [d7e528f0] FreeType2_jll v2.10.1+2
  [559328eb] FriBidi_jll v1.0.5+3
  [de31a74c] FunctionalCollections v0.5.0
  [28b8d3ca] GR v0.47.0
  [4d00f742] GeometryTypes v0.7.6
  [cd3eb016] HTTP v0.8.14
  [9fb69e20] Hiccup v0.2.2
  [9b13fd28] IndirectArrays v0.5.1
  [83e8ac13] IniFile v0.5.0
  [41ab1584] InvertedIndices v1.0.0
  [c8e1da08] IterTools v1.3.0
  [82899510] IteratorInterfaceExtensions v1.0.0
  [682c06a0] JSON v0.21.0
  [98e50ef6] JuliaFormatter v0.3.9
  [aa1ae85d] JuliaInterpreter v0.7.14
  [e5e0dc1b] Juno v0.8.0
  [c1c5ebd0] LAME_jll v3.100.0+1
  [7c4cb9fa] LNR v0.2.1
  [50d2b5c4] Lazy v0.15.0
  [1d6d02ad] LeftChildRightSiblingTrees v0.1.2
  [dd192d2f] LibVPX_jll v1.8.1+1
  [1914dd2f] MacroTools v0.5.5
  [739be429] MbedTLS v1.0.2
  [c8ffd9c3] MbedTLS_jll v2.16.0+2
  [442fdcdd] Measures v0.3.1
  [e89f7d12] Media v0.5.0
  [e1d29d7a] Missings v0.4.3
  [77ba4419] NaNMath v0.3.3
  [be6f12e9] ODBC v0.9.0
  [510215fc] Observables v0.3.1
  [e7412a2a] Ogg_jll v1.3.4+0
  [458c3c95] OpenSSL_jll v1.1.1+2
  [efe28fd5] OpenSpecFun_jll v0.5.3+3
  [91d4177d] Opus_jll v1.3.1+1
  [bac558e1] OrderedCollections v1.2.0
  [69de0a69] Parsers v1.0.3
  [fa939f87] Pidfile v1.1.0
  [b98c9c47] Pipe v1.2.0
  [ccf2f8ad] PlotThemes v1.0.3
  [995b91a9] PlotUtils v0.6.5
  [91a5bcdd] Plots v0.29.3
  [2dfb63ee] PooledArrays v0.5.3
  [3cdcf5f2] RecipesBase v0.8.0
  [189a3867] Reexport v0.2.0
  [ae029012] Requires v1.0.1
  [1277b4bf] ShiftedArrays v1.0.0
  [992d4aef] Showoff v0.3.1
  [a2af1166] SortingAlgorithms v0.3.1
  [276daf66] SpecialFunctions v0.9.0
  [90137ffa] StaticArrays v0.12.3
  [2913bbd2] StatsBase v0.32.2
  [88034a9c] StringDistances v0.6.4
  [3783bdb8] TableTraits v1.0.0
  [bd369af6] Tables v1.0.4
  [0796e94c] Tokenize v0.5.8
  [37b6cedf] Traceur v0.3.0
  [a2a6695c] TreeViews v0.3.0
  [30578b45] URIParser v0.4.1
  [ea10d353] WeakRefStrings v0.6.2
  [0f1e0344] WebIO v0.8.11
  [104b5d7c] WebSockets v1.5.2
  [cc8bc4a8] Widgets v0.6.2
  [83775a58] Zlib_jll v1.2.11+9
  [0ac62f75] libass_jll v0.14.0+2
  [f638f0a6] libfdk_aac_jll v0.1.6+2
  [f27f6e37] libvorbis_jll v1.3.6+4
  [1270edf5] x264_jll v2019.5.25+2
  [dfaa095f] x265_jll v3.0.0+1
  [2a0f44e3] Base64 
  [ade2ca70] Dates 
  [8bb1440f] DelimitedFiles 
  [8ba89e20] Distributed 
  [7b1f6079] FileWatching 
  [9fa8497b] Future 
  [b77e0a4c] InteractiveUtils 
  [76f85450] LibGit2 
  [8f399da3] Libdl 
  [37e2e46d] LinearAlgebra 
  [56ddb016] Logging 
  [d6f4376e] Markdown 
  [a63ad114] Mmap 
  [44cfe95a] Pkg 
  [de0858da] Printf 
  [9abbd945] Profile 
  [3fa0cd96] REPL 
  [9a3f8284] Random 
  [ea8e919c] SHA 
  [9e88b42a] Serialization 
  [1a1011a3] SharedArrays 
  [6462fe0b] Sockets 
  [2f01184e] SparseArrays 
  [10745b16] Statistics 
  [8dfed614] Test 
  [cf7118a7] UUIDs 
  [4ec0a83e] Unicode 
更新包:

using Pkg
pkg"update"
pkg"precompile"
解释 CSV.jl版本已通过
read
重新发布(请参阅)
无论是更新到
0.6.2
,还是降级到
0.5.26
(当您无法更新时),都应该非常有效

不是100%确定,但这看起来像是一些包不同步了-你能发布
]st-m的输出吗?好的,它可以工作。非常感谢。但是,孩子,这是一个麻烦。像读取csv文件这样简单的东西真的应该“像那样”工作。另外,我试图先只更新CSV包,但没有成功。我猜
CSV
的人进行了大量的代码重新设计,结果出了问题。我自己也遇到了和你一样的问题,一段时间以来我不得不回到0.5.26。但我知道他们在加快CSV解析方面做了多么大的工作(当你真的想做的时候,这真的不是琐事)。所以,让我们希望它在某个时刻变得稳定。再次感谢你的回答。