JuliaStats / RDatasets.jl

Julia package for loading many of the data sets available in R
GNU General Public License v3.0
158 stars 56 forks source link

Specify file format explicitly #119

Open devmotion opened 3 years ago

devmotion commented 3 years ago

This PR fixes https://github.com/JuliaStats/RDatasets.jl/issues/117 - and does not seem to break the tests. It specifies the file format explicitly when loading ".rda" files instead of relying on the automatic discovery in FileIO. This PR is an alternative to https://github.com/JuliaStats/RDatasets.jl/pull/118.

@timholy My guess is that FileIO 1.6 changed the query mechanism. It seems it prioritized the file ending in FileIO <= 1.5 but with FileIO 1.6 the file type is determined incorrectly as Gzip due to the magic bytes of compressed RData files.

codecov-io commented 3 years ago

Codecov Report

Merging #119 (47b34c2) into master (c2b17d0) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #119   +/-   ##
=======================================
  Coverage   84.00%   84.00%           
=======================================
  Files           4        4           
  Lines          25       25           
=======================================
  Hits           21       21           
  Misses          4        4           
Impacted Files Coverage Δ
src/RDatasets.jl 100.00% <ø> (ø)
src/dataset.jl 90.90% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update c2b17d0...47b34c2. Read the comment docs.

devmotion commented 3 years ago

Bump 😃 What is the general opinion? Should this change be applied, even if FileIO already fixed the original issue?

codecov-commenter commented 3 months ago

Codecov Report

Attention: Patch coverage is 66.66667% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 81.48%. Comparing base (b1a5959) to head (fc0eedb).

Files Patch % Lines
src/dataset.jl 66.66% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #119 +/- ## ========================================== - Coverage 83.33% 81.48% -1.86% ========================================== Files 3 4 +1 Lines 24 27 +3 ========================================== + Hits 20 22 +2 - Misses 4 5 +1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.