Unicode in online editor

I recently imported a local git project into bitbucket.  Everything went well, but when I edited a minor typo using the online source editor, it changed a non-ASCII Unicode UTF-8 character into some other encoding.  Specifically, it changed the Unicode copyright symbol (U+00A9) into a single-byte character A9, which is not a legal UTF-8 character.

I verified that this is where the character got changed by doing a diff between the two versions, the relevant lines being:

-# Copyright © 2018 Center for Advanced Study of Language University of Maryland
+# Copyright © 2018 Center for Advanced Study of Language University of Maryland

The version before my edit contains the sequence of bytes C2 (represented in the online diff tool as the funny kind of A-hat) + A9 (represented as a copyright symbol).  But in the version after the edit, it displays just A9, i.e. an 8-bit char.  It happens that C2 A9 is the sequence of bytes used in UTF-8 to encode U+00A9.  So it appears that when I edited the file using the on-line editor, it changed the valid UTF-8 byte sequence C2 A9 into just A9, which as I say is invalid UTF-8.

I'm using the Firefox browser, and it says the page with the editor is UTF-8.  So I don't think it's my browser.

Is the bitbucket on-line editor unsafe with Unicode?  If so, that's fine, I normally only edit things in my own editor; I just saw a typo and decided to fix it, but I could instead have pushed the fix from my own computer.

0 answers

Suggest an answer

Log in or Join to answer
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

691 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot