Closed akiva closed 12 years ago
I can replicate this error; brew update
almost never works the first time I run it, but usually works the second time.
I see this as well. Started sometime this month. Probably a GitHub error.
Yeh, GitHub problem. Perhaps we should fall back to git:// if http:// fails (or vice-versa)?
Is it possible for us to determine if the failure was caused by an HTTP error vs. e.g. a merge conflict (easily)? Using only git pull
, I'm not sure.
Just do git fetch; git merge then :)
Well, they don't seem to be merge conflicts---otherwise re-running brew update
would fail again.
What I was getting at was "how can we programmatically differentiate between the failure we're seeing here (HTTP 403) and the merge part of git pull
" if git pull
fails. Because if git pull
fails because of merge conflicts, there is no sense in retrying using a different transport protocol.
But Mike is right.
Would be worth seeing if git pull
returns different exit status for HTTP 403 and merge conflicts.
I'll just mention without trying to analyze what you've done so far, that I started getting this on 10.6.8 last month too around the time Homebrew's version was bumped. No amount of git reset --hard
or other commands would fix it. I got tired of it, and wanted a sane foundation. So I deleted my /usr/local and started over. I don't get this error any more.
I always pull over ssh so I never see this; will try to use HTTP for a while and see if I ever encounter it.
Curiously, for me it'll fail almost every first attempt. Second one in a row succeeds just fine. Highly annoying for a cronjob.
I experience the same thing that yacoob experiences. It fails every time on the first attempt and succeeds just fine on the second attempt. I'm using 10.7.3 and XCode 4.3.2.
Yes, I should confirm that this is the initial response. Second attempt works.
This has stopped happening to me for about a week now. Perhaps the issue was on the GitHub end and has been solved?
i'm getting this too now, caused by this:
error: The following untracked working tree files would be overwritten by merge: Library/Formula/cocot.rb Please move or remove them before you can merge.
Why would I have an untracked working tree?
$ brew update error: Your local changes to the following files would be overwritten by merge: Library/Aliases/bjam Library/Aliases/gpg2 Library/Contributions/brew_bash_completion.sh Library/Contributions/manpages/brew.1.md Library/Formula/a2ps.rb Library/Formula/aalib.rb Library/Formula/abcde.rb Library/Formula/abiword.rb Library/Formula/abook.rb Library/Formula/ace.rb Library/Formula/ack.rb Library/Formula/activemq.rb Library/Formula/adobe-air-sdk.rb Library/Formula/advancecomp.rb Library/Formula/aescrypt.rb Library/Formula/afflib.rb Library/Formula/afsctool.rb Library/Formula/aften.rb Library/Formula/aget.rb Library/Formula/aggregate.rb Library/Formula/agrep.rb Library/Formula/aircrack-ng.rb Library/Formula/aldo.rb Library/Formula/algol68g.rb Library/Formula/alpine.rb Library/Formula/amap.rb Library/Formula/android-ndk.rb Library/Formula/android-sdk.rb Library/Formula/ansifilter.rb Library/Formula/antiword.rb Library/Formula/antlr.rb Library/Formula/anttweakbar.rb Library/Formula/aoeui.rb Library/Formula/apachetop.rb Library/Formula/apg.rb Library/Formula/apgdiff.rb Library/Formula/apiextractor.rb Library/Formula/apktool.rb Library/Formula/aplus.rb Library/Formula/app-engine-java-sdk.rb Library/Formula/aqbanking.rb Library/Formula/arabica.rb Library/Formula/aria2.rb Library/Formula/arm.rb Library/Formula/armadillo.rb Library/Formula/arping.rb Library/Formula/arss.rb Library/Formula/asciidoc.rb Library/Formula/aspell.rb Library/Formula/assimp.rb Library/Formula/astyle.rb Library/Formula/asymptote.rb Library/Formula/aterm.rb Library/Formula/atk.rb Library/Formula/atlassian-plugin-sdk.rb Library/Formula/atomicparsley.rb Library/Formula/atool.rb Library/Formula/auctex.rb Library/Formula/audiofile.rb Library/Formula/authexec.rb Library/Formula/auto-scaling.rb Library/Formula/autobench.rb Library/Formula/autoconf-archive.rb Library/Formula/autogen.rb Library/Formula/autojump.rb Library/Formula/automoc4.rb Library/Formula/autossh.rb Library/Formula/aview.rb Library/Formula/avra.rb Library/Formula/avro-c.rb Library/Formula/aws-cfn-tools.rb Library/Formula/aws-elasticache.rb Library/Formula/aws-iam-tools.rb Library/Formula/babl.rb Library/Formula/bagit.rb Library/Formula/bali-phy.rb Library/Formula/bash-completion.rb Library/Formula/bash.rb Library/Formula/bazaar.rb Library/Formula/bbcp.rb Library/Formula/bcrypt.rb Library/Formula/bcwipe.rb Library/Formula/bdw-gc.rb Library/Formula/beanstalk.rb Library/Formula/bedtools.rb Library/Formula/berkeley-db.rb Library/Formula/bibutils.rb Library/Formula/binutils.rb Library/Formula/bitlbee.rb Library/Formula/blahtexml.rb Library/Formula/blast.rb Library/Formula/blitz.rb Library/Formula/blueutil.rb Library/Formula/boost.rb Library/Formula/botan.rb Library/Formula/box2d.rb Library/Formula/boxes.rb Library/Formula/bsdiff.rb Library/Formula/bulk_extractor.rb Library/Formula/bullet.rb Library/Formula/bwa.rb Library/Formula/bwm-ng.rb Library/Formula/byobu.rb Library/Formula/cabal-install.rb Library/Formula/cabextract.rb Library/Formula/cadaver.rb Library/Formula/cairo.rb Library/Formula/cairomm.rb Library/Formula/cantera.rb Library/Formula/cassandra.rb Library/Formula/cd-discid.rb Library/Formula/cdargs.rb Library/Formula/cdecl.rb Library/Formula/cdparanoia.rb Library/Formula/cdrdao.rb Library/Formula/celt.rb Library/Formula/cfengine.rb Library/Formula/cfitsio.rb Library/Formula/cgal.rb Library/Formula/cgdb.rb Library/Formula/cheops.rb Library/Formula/cherokee.rb Library/Formula/chibi-scheme.rb Library/Formula/chicken.rb Library/Formula/chipmunk.rb Library/Formula/chkrootkit.rb Library/Formula/chromaprint.rb Library/Formula/chromedriver.rb Library/Formula/cimg.rb Library/Formula/clamav.rb Library/Formula/clay.rb Library/Formula/clisp.rb Library/Formula/cloc.rb Library/Formula/clojure.rb Library/Formula/closure-compiler.rb Library/Formula/cloud-watch.rb Library/Formula/cloudbees-sdk.rb Library/Formula/clozure-cl.rb Library/Formula/clucene.rb Library/Formula/clusterit.rb Libr error: The following untracked working tree files would be overwritten by merge: Library/Aliases/boost-jam Library/Aliases/fastcgi Library/Aliases/lcms2 Library/Aliases/nodejs Library/Aliases/ocio Library/Aliases/pocketsphinx Library/Aliases/sphinxbase Library/Contributions/cmds/brew-beer.rb Library/Contributions/cmds/brew-dirty.rb Library/Contributions/cmds/brew-graph Library/Contributions/cmds/brew-grep Library/Contributions/cmds/brew-leaves.rb Library/Contributions/cmds/brew-linkapps.rb Library/Contributions/cmds/brew-man Library/Contributions/cmds/brew-mirror-check.rb Library/Contributions/cmds/brew-missing.rb Library/Contributions/cmds/brew-pull.rb Library/Contributions/cmds/brew-readall.rb Library/Contributions/cmds/brew-server Library/Contributions/cmds/brew-switch.rb Library/Contributions/cmds/brew-tests.rb Library/Contributions/cmds/brew-unpack.rb Library/Contributions/cmds/brew-which.rb Library/Contributions/install_homebrew.rb Library/Formula/abcl.rb Library/Formula/adol-c.rb Library/Formula/ann.rb Library/Formula/ape.rb Library/Formula/apollo.rb Library/Formula/appledoc.rb Library/Formula/apt-dater.rb Library/Formula/arp-scan.rb Library/Formula/atkmm.rb Library/Formula/autoconf.rb Library/Formula/autoenv.rb Library/Formula/automake.rb Library/Formula/avocadodb.rb Library/Formula/bind.rb Library/Formula/bindfs.rb Library/Formula/binwalk.rb Library/Formula/blackbox.rb Library/Formula/boost-build.rb Library/Formula/bro.rb Library/Formula/bsdconv.rb Library/Formula/bsdmake.rb Library/Formula/bsponmpi.rb Library/Formula/cabocha.rb Library/Formula/calabash.rb Library/Formula/cbmbasic.rb Library/Formula/cc65.rb Library/Formula/ceylon.rb Library/Formula/cifer.rb Library/Formula/clam.rb Library/Formula/clhep.rb Library/Formula/cloog.rb Library/Formula/collada-dom.rb Library/Formula/conserver.rb Library/Formula/crf++.rb Library/Formula/crossroads.rb Library/Formula/crush-tools.rb Library/Formula/css-crush.rb Library/Formula/curlftpfs.rb Library/Formula/czmq.rb Library/Formula/dart.rb Library/Formula/dasm.rb Library/Formula/dfc.rb Library/Formula/di.rb Library/Formula/dnscrypt-proxy.rb Library/Formula/dsniff.rb Library/Formula/dupx.rb Library/Formula/echoping.rb Library/Formula/ecm.rb Library/Formula/eprover.rb Library/Formula/ettercap.rb Library/Formula/ext2fuse.rb Library/Formula/ezlupdate.rb Library/Formula/f3.rb Library/Formula/fasd.rb Library/Formula/fastx_toolkit.rb Library/Formula/fceux.rb Library/Formula/fcgi.rb Library/Formula/findbugs.rb Library/Formula/flex_sdk.rb Library/Formula/freerdp.rb Library/Formula/freexl.rb Library/Formula/funcoeszz.rb Library/Formula/fwknop.rb Library/Formula/gabedit.rb Library/Formula/getxbook.rb Library/Formula/gibbslda.rb Library/Formula/git-diffall.rb Library/Formula/git-ftp.rb Library/Formula/git-gerrit.rb Library/Formula/gitslave.rb Library/Formula/gmt.rb Library/Formula/gnu-arch.rb Library/Formula/gnumeric.rb Library/Formula/gnunet.rb Library/Formula/go-app-engine-32.rb Library/Formula/go-app-engine-64.rb Library/Formula/gobject-introspection.rb Library/Formula/goffice.rb Library/Formula/google-sql-tool.rb Library/Formula/gptfdisk.rb Library/Formula/grace.rb Library/Formula/grib-api.rb Library/Formula/griffon.rb Library/Formula/gsoap.rb Library/Formula/gtk-chtheme.rb Library/Formula/gtk-doc.rb Library/Formula/gtkglextmm.rb Library/Formula/gtmess.rb Library/Formula/hg-flow.rb Library/Formula/hqx.rb Library/Formula/ht.rb Library/Formula/htpdate.rb Library/Formula/imap-uw.rb Library/Formula/ipbt.rb Library/Formula/ipe.rb Library/Formula/ispell.rb Library/Formula/ivy.rb Library/Formula/jigdo.rb Library/Formula/jing.rb Library/Formula/jshon.rb Library/Formula/json_spirit.rb Library/Formula/justniffer.rb Library/Formula/kawa.rb Library/Formula/knife-completion.rb Library/Formula/konoha.rb Library/Formula/kytea.rb Library/Formula/lastfmlib.rb Library/Formula/legit.rb Library/Formula/libcouchbase.rb Library/Formula/libcsv.rb Library/Formula/libcuefile.rb L Aborting Error: Failure while executing: git pull -q origin refs/heads/master:refs/remotes/origin/master
...what A more useful error message would be great.
@firmousebutt
You need to git reset --hard FETCH_HEAD
inside your Homebrew installation.
In the future, please do not post hundreds of lines into a thread like that, it makes it impossible to navigate.
Closing since the 403 errors seem to be over; if they persist please open an issue with GitHub directly, as there is nothing we can do on our end.
I frequently receive this error when issuing a
brew update
:Often I just need to re-issue the statement a few times and it works.