Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,559,893
Community Members
 
Community Events
185
Community Groups

Error on git-svn: fatal: Not a valid object name refs/remotes/origin/feature with spaces

Hi,

I'm migrating a SVN to Bitbucket following the guide https://www.atlassian.com/git/tutorials/migrating-convert 

My SVN repo had on an early revision a branch with a space on its name, and that caused mergeinfo to contain a reference to that branch. Giving this error:

Checking svn:mergeinfo changes since r7902: 106 sources, 1 changed
fatal: Not a valid object name refs/remotes/origin/feature 11870
cat-file commit refs/remotes/origin/feature 11870: command returned error: 128

I've tried using the --ignore-paths="^Branches/feature\s.*" option, but it does not solve the problem, since the mergeinfo is on another branch.

Any suggestions of how to fix it?

Regards,

Fran

1 answer

Hi @Fran Vicente

I'm assuming this might be related to the encoding issue and Git having an issue identifying the branch name. Could you run the following command and validate that the name of the branch is still relevant to the object name:

git branch -a

Best regards,
Baskar Annamalai 
ServiceRocket.

The branch does exist, but git-svn encodes the space to %20 -> remotes/origin/feature%2011870

The problem is that it only does that when creates the branch, and not during parent resolution based on mergeinfo.

fran@svn2git:~/prs-full.git$ git branch -a
remotes/origin/Active
remotes/origin/Inactive
remotes/origin/LongTerm
remotes/origin/ShortTerm
remotes/origin/ZeroMQ
remotes/origin/feature%2011870
remotes/origin/feature11033
remotes/origin/feature11220
remotes/origin/feature11242
remotes/origin/feature11242@284
remotes/origin/feature11421
...
remotes/origin/trunk

 I have tried other options like --ignore-refs without success.

With --no-follow-parent it continues and finishes, but the repo size seem to duplicate for every branch pushed.

The branch on SVN has a space in it, but the branch in git had this space converted to %20 (URL encoded). I don't think git would allow a space character in the branch or would read encoded characters directly. It might be worth fixing this from SVN and then reattempting the migration.

Best regards,
Baskar Annamalai 
ServiceRocket.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events