Comments (8)
Have you tried this with the latest version, since that one does not reproduce the above error on a casual attempt (might also depend on the Mercurial version > 3.7)? It looks a lot like 822c6e4 addresses this.
from git-remote-hg.
My apologies for commenting on an old issue, however I am experiencing the same issue when attempting to clone as well. I'm using the homebrew version on macOS, which I believe points to this repo's HEAD if I'm not mistaken.
...
remote:
requesting all changes
adding changesets
adding manifests
adding file changes
added 39 changesets with 110 changes to 30 files
adding remote bookmark master
adding remote bookmark remote/master
Traceback (most recent call last):
File "/usr/local/bin/git-remote-hg", line 1343, in <module>
sys.exit(main(sys.argv))
File "/usr/local/bin/git-remote-hg", line 1307, in main
repo = get_repo(url, alias)
File "/usr/local/bin/git-remote-hg", line 440, in get_repo
updatebookmarks(repo, peer)
File "/usr/local/bin/git-remote-hg", line 379, in updatebookmarks
bookmarks.write(repo)
AttributeError: 'module' object has no attribute 'write'
from git-remote-hg.
I'm getting the same as @peterdimou, with the exact same traceback.
from git-remote-hg.
The traceback shown above refers to bookmarks.write(repo)
on line 379. However, git-remote-hg in HEAD (which is 822c6e4 at this time) does not have such on line 379. That line, however, does have exactly that content in HEAD^ (tagged v0.3). So, it looks like homebrew is pointing to that revision, not HEAD, where the HEAD commit is highly likely one that addresses this very issue.
from git-remote-hg.
I'm getting the same issue, and can verify that Homebrew is installing version 0.3.
Any chance of getting a new release of this so it can be updated in Homebrew? I don't think it's unreasonable to expect that the following should work:
$ brew install git-remote-hg
$ git clone hg::https://bitbucket.org/morphus_imaia/django-otp
Cloning into 'django-otp'...
requesting all changes
adding changesets
adding manifests
adding file changes
added 100 changesets with 892 changes to 321 files
adding remote bookmark stable/0.1.x
adding remote bookmark stable/0.2.x
adding remote bookmark stable/0.3.x
Traceback (most recent call last):
File "/usr/local/bin/git-remote-hg", line 1343, in <module>
sys.exit(main(sys.argv))
File "/usr/local/bin/git-remote-hg", line 1307, in main
repo = get_repo(url, alias)
File "/usr/local/bin/git-remote-hg", line 440, in get_repo
updatebookmarks(repo, peer)
File "/usr/local/bin/git-remote-hg", line 379, in updatebookmarks
bookmarks.write(repo)
AttributeError: 'module' object has no attribute 'write'
from git-remote-hg.
Note that this issue is fixed (as well as other issues with recent Mercurial) in the latest version of this fork, though it is another matter for downstream to pick that up (see also issue #69).
from git-remote-hg.
I'm getting a similar issue with bookmarks
even when using the latest version from HEAD instead of v0.3.
$ git clone hg::https://www.octave.org/hg/octave
Cloning into 'octave'...
real URL is https://hg.savannah.gnu.org/hgweb/octave
requesting all changes
adding changesets
adding manifests
adding file changes
added 25590 changesets with 170203 changes to 13870 files (+1 heads)
adding remote bookmark @
new changesets 22412e3a4641:c21edcb90cbf
Traceback (most recent call last):
File "/usr/local/bin/git-remote-hg", line 1356, in <module>
sys.exit(main(sys.argv))
File "/usr/local/bin/git-remote-hg", line 1320, in main
repo = get_repo(url, alias)
File "/usr/local/bin/git-remote-hg", line 453, in get_repo
updatebookmarks(repo, peer)
File "/usr/local/bin/git-remote-hg", line 374, in updatebookmarks
localmarks[k] = hgbin(v)
File "/usr/local/lib/python2.7/site-packages/mercurial/bookmarks.py", line 106, in __setitem__
raise error.ProgrammingError("use 'bookmarks.applychanges' instead")
mercurial.error.ProgrammingError: use 'bookmarks.applychanges' instead
[~/local/repos]
$ hg --version ✘ 128
Mercurial Distributed SCM (version 4.6.2)
Any chance of getting this fixed, and a new release tagged?
from git-remote-hg.
Any chance of getting this fixed, and a new release tagged?
Yes, I finally got around to doing it. This should be fixed in v0.4.
The relevant commit is aaef56a.
from git-remote-hg.
Related Issues (20)
- TypeError: int() argument must be a string or a number, not 'changectx' HOT 8
- Git commit ID (SHA-1 hash) is not consistent between the committing repository and others HOT 2
- "Branch name doesn't conform to GIT standards" HOT 1
- Issue #72 is ok when using solution below, already mentionend by another user. HOT 2
- Pointer to more up-to-date fork from mnauw? HOT 1
- point to active repo? HOT 10
- About hg largefiles HOT 1
- pushes are rejected with a non-fast-forward error (looks like #36)
- Import of "lemon" hg repo failed HOT 1
- How can i get more debug information? HOT 1
- Push to hg fails with KeyError in to_rev() HOT 3
- Extra lines in commit comment changes the commit hash - breaks hg-git interoperability HOT 2
- mercurial.error.Abort: stream ended unexpectedly HOT 2
- Git ls-remote error: accessing `persistent-nodemap` repository without associated fast implementation HOT 1
- Cloning error due to decode HOT 3
- How to undo git config core.notesRef refs/notes/hg? HOT 1
- Transfer the githashes to the mercurial repository (locally) HOT 2
- SyntaxWarning about regexes
- Working with Mercurial topic branches HOT 1
- SyntaxWaring: invalid escape sequence \w HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from git-remote-hg.