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

can't clone ml-matrics - error: invalid path 'data/mp-n_elements<2.csv' #19

Closed
sgbaird opened this issue Feb 12, 2022 · 3 comments
Closed
Assignees
Labels
bug Something isn't working windows

Comments

@sgbaird
Copy link
Contributor

sgbaird commented Feb 12, 2022

(base) PS C:\Users\sterg\Documents\GitHub\sparks-baird> git clone https://github.com/janosh/ml-matrics.git
Cloning into 'ml-matrics'...
remote: Enumerating objects: 916, done.
remote: Counting objects: 100% (220/220), done.
remote: Compressing objects: 100% (157/157), done.
remote: Total 916 (delta 136), reused 134 (delta 57), pack-reused 696 eceiving objects:  96% (880/916), 3.74 MiB | 1.23 Receiving objects:  97% (889/9
Receiving objects: 100% (916/916), 3.88 MiB | 1.23 MiB/s, done.
Resolving deltas: 100% (640/640), done.
error: invalid path 'data/mp-n_elements<2.csv'
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry with 'git restore --source=HEAD :/'

(base) PS C:\Users\sterg\Documents\GitHub\sparks-baird> cd ml-matrics
(base) PS C:\Users\sterg\Documents\GitHub\sparks-baird\ml-matrics> git status
On branch main
Your branch is up to date with 'origin/main'.

Changes to be committed:
  (use "git restore --staged <file>..." to unstage)
        deleted:    .github/workflows/publish.yml
        deleted:    .github/workflows/svgo.yml
        deleted:    .github/workflows/test.yml
        deleted:    .gitignore
        deleted:    .pre-commit-config.yaml
        deleted:    assets/cumulative_error.svg
        deleted:    assets/cumulative_residual.svg
        deleted:    assets/density_hexbin.svg
        deleted:    assets/density_hexbin_with_hist.svg
        deleted:    assets/density_scatter.svg
        deleted:    assets/density_scatter_with_hist.svg
        deleted:    assets/err_decay.svg
        deleted:    assets/err_decay_multiple.svg
        deleted:    assets/hist_elemental_prevalence.svg
        deleted:    assets/hist_elemental_prevalence_log_count.svg
        deleted:    assets/marchenko_pastur.svg
        deleted:    assets/marchenko_pastur_rank_deficient.svg
        deleted:    assets/marchenko_pastur_significant_eval.svg
        deleted:    assets/normal_prob_plot.svg
        deleted:    assets/normal_prob_plot_multiple.svg
        deleted:    assets/precision_recall_curve.svg
        deleted:    assets/ptable_heatmap.svg
        deleted:    assets/ptable_heatmap_log.svg
        deleted:    assets/ptable_heatmap_log_cbar_max.svg
        deleted:    assets/ptable_heatmap_percent.svg
        deleted:    assets/ptable_heatmap_plotly.html
        deleted:    assets/ptable_heatmap_plotly.svg
        deleted:    assets/ptable_heatmap_plotly_custom_color_scale.html
        deleted:    assets/ptable_heatmap_plotly_custom_color_scale.svg
        deleted:    assets/ptable_heatmap_plotly_more_hover_data.html
        deleted:    assets/ptable_heatmap_plotly_more_hover_data.svg
        deleted:    assets/ptable_heatmap_plotly_no_labels.html
        deleted:    assets/ptable_heatmap_plotly_no_labels.svg
        deleted:    assets/ptable_heatmap_plotly_percent_labels.html
        deleted:    assets/ptable_heatmap_plotly_percent_labels.svg
        deleted:    assets/ptable_heatmap_ratio.svg
        deleted:    assets/ptable_heatmap_ratio_inverse.svg
        deleted:    assets/residual_hist.svg
        deleted:    assets/residual_vs_actual.svg
        deleted:    assets/roc_curve.svg
        deleted:    assets/scatter_with_err_bar.svg
        deleted:    assets/spacegroup_hist.svg
        deleted:    assets/spacegroup_hist_no_counts.svg
        deleted:    assets/spacegroup_sunburst.html
        deleted:    assets/spacegroup_sunburst.svg
        deleted:    assets/spacegroup_sunburst_percent.html
        deleted:    assets/spacegroup_sunburst_percent.svg
        deleted:    assets/true_pred_hist.svg
        deleted:    data/elem_counts_1.csv
        deleted:    data/elem_counts_2.csv
        deleted:    data/ex-ensemble-roost.csv
        deleted:    data/matbench-phonons.csv
        deleted:    data/mp-n_elements<2.csv
        deleted:    data/rand_clf.csv
        deleted:    data/rand_regr.csv
        deleted:    data/rand_tall_matrix.csv
        deleted:    data/rand_wide_matrix.csv
        deleted:    license
        deleted:    ml_matrics/__init__.py
        deleted:    ml_matrics/correlation.py
        deleted:    ml_matrics/cumulative.py
        deleted:    ml_matrics/elements.csv
        deleted:    ml_matrics/elements.py
        deleted:    ml_matrics/histograms.py
        deleted:    ml_matrics/parity.py
        deleted:    ml_matrics/quantile.py
        deleted:    ml_matrics/ranking.py
        deleted:    ml_matrics/relevance.py
        deleted:    ml_matrics/sunburst.py
        deleted:    ml_matrics/utils.py
        deleted:    readme.md
        deleted:    scripts/fetch_mp_data.py
        deleted:    scripts/generate_assets.py
        deleted:    scripts/generate_rand_data.py
        deleted:    setup.cfg
        deleted:    setup.py
        deleted:    tests/__init__.py
        deleted:    tests/test_correlation.py
        deleted:    tests/test_cumulative.py
        deleted:    tests/test_elements.py
        deleted:    tests/test_histograms.py
        deleted:    tests/test_parity.py
        deleted:    tests/test_quantile.py
        deleted:    tests/test_ranking.py
        deleted:    tests/test_relevance.py
        deleted:    tests/test_sunburst.py
        deleted:    tests/test_utils.py

(base) PS C:\Users\sterg\Documents\GitHub\sparks-baird\ml-matrics> git restore --source=HEAD :/
error: invalid path 'data/mp-n_elements<2.csv'
@janosh
Copy link
Owner

janosh commented Feb 12, 2022

Interesting. Cloning works fine on Linux and macOS which means it's Windows specific. Seems '>' is not allowed in Windows file paths:

Use any character in the current code page for a name, including Unicode characters and characters in the extended character set (128–255), except for the following:

The following reserved characters:

< (less than)
> (greater than)
: (colon)
" (double quote)
/ (forward slash)
\ (backslash)
| (vertical bar or pipe)
? (question mark)
* (asterisk)

I'll just rename the file

git mv data/{mp-n_elements\<2,mp-elements}.csv

@janosh janosh self-assigned this Feb 12, 2022
@janosh janosh added windows bug Something isn't working labels Feb 12, 2022
@janosh janosh closed this as completed in a46db92 Feb 12, 2022
@janosh
Copy link
Owner

janosh commented Feb 12, 2022

Can you let me know if cloning works now? Just occurred to me that since the offending path is still in git's history, it might still fail. If it fails, could you try git clone https://github.com/janosh/ml-matrics --depth 1 and let me know if that works? Either way, I'm not sure what's the right approach here. Purging the file from git history is possible but would break all existing forks that try to pull upstream. Since there are only two forks at the moment, I guess that's no big deal.

@sgbaird
Copy link
Contributor Author

sgbaird commented Feb 12, 2022

I was able to clone it just fine. Thanks for the fix! No need to mess with the history it seems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working windows
Projects
None yet
Development

No branches or pull requests

2 participants