CCBR / ASPEN

CCBR pipeline for preliminary QC and peak calling from ATACseq datasets 🌲
https://ccbr.github.io/ASPEN/
MIT License
0 stars 2 forks source link

warning during `git clone`: large files should be handled with `git lfs` #25

Open kelly-sovacool opened 10 months ago

kelly-sovacool commented 10 months ago

Warning message when attempting to clone this repo:

Cloning into 'ASPEN'...
remote: Enumerating objects: 1103, done.
remote: Counting objects: 100% (200/200), done.
remote: Compressing objects: 100% (131/131), done.
remote: Total 1103 (delta 71), reused 158 (delta 64), pack-reused 903
Receiving objects: 100% (1103/1103), 645.99 MiB | 3.98 MiB/s, done.
Resolving deltas: 100% (604/604), done.
Updating files: 100% (125/125), done.
Encountered 4 files that should have been pointers, but weren't:
        resources/blacklistFa/hs1.blacklist.fa.gz
        resources/frip/hs1.DHS.bed.gz
        resources/frip/hs1.enhancers.bed.gz
        resources/tssBed/hs1_tssbeds.tar.gz

This causes an error when trying to commit other unrelated changes:

An unexpected error has occurred: CalledProcessError: command: ('/Library/Developer/CommandLineTools/usr/libexec/git-core/git', '-c', 'core.autocrlf=false', 'apply', '--whitespace=nowarn', '/Users/sovacoolkl/.cache/pre-commit/patch1704842321-37084')
return code: 1
stdout: (none)
stderr:
    error: the patch applies to 'resources/tssBed/hs1_tssbeds.tar.gz' (555ec58cde1546d9624e100af8985918dfcfbc3e), which does not match the current contents.
    error: resources/tssBed/hs1_tssbeds.tar.gz: patch does not apply
Check the log at /Users/sovacoolkl/.cache/pre-commit/pre-commit.log

Looks like something went wrong when these files were initially commited?

kopardev commented 9 months ago

Using this solution tried:

git rm .gitattributes
git add -A
git reset --hard

but no change

╰─(dev) ○ git clone https://github.com/CCBR/ASPEN.git
Cloning into 'ASPEN'...
remote: Enumerating objects: 1273, done.
remote: Counting objects: 100% (144/144), done.
remote: Compressing objects: 100% (56/56), done.
remote: Total 1273 (delta 95), reused 89 (delta 87), pack-reused 1129
Receiving objects: 100% (1273/1273), 631.48 MiB | 57.48 MiB/s, done.
Resolving deltas: 100% (691/691), done.
Updating files: 100% (133/133), done.
Encountered 4 files that should have been pointers, but weren't:
    resources/blacklistFa/hs1.blacklist.fa.gz
    resources/frip/hs1.DHS.bed.gz
    resources/frip/hs1.enhancers.bed.gz
    resources/tssBed/hs1_tssbeds.tar.gz
kopardev commented 9 months ago

Previously, these 4 files were showing as "modified" right after clone-ing the repo. But now:

╰─(dev) ⠠⠵ git status
On branch main
Your branch is up to date with 'origin/main'.

nothing to commit, working tree clean

So I guess not a big issue.. possibly can be ignored. Keep git-lfs in PATH.

kelly-sovacool commented 9 months ago

@kopardev I think the problem is there's a commit in the history where those files were changed without lfs, so a fix would have to modify the commit history and track them with lfs. Maybe this? https://github.com/git-lfs/git-lfs/issues/1939#issuecomment-353247795

kelly-sovacool commented 1 month ago

@kopardev I think the problem is there's a commit in the history where those files were changed without lfs, so a fix would have to modify the commit history and track them with lfs. Maybe this? git-lfs/git-lfs#1939 (comment)

@kopardev this is still a problem when I try to clone this repo. Can you try the possible solution linked above?