![]() ![]() He was born just south of Salem in Lynn, painted scenes all along the North Shore of Massachusetts into southern Maine (where I was brought up), where he ran a popular and influential art school in Ogunquit (where I held all my summer jobs). Woodbury (1864-1940), who led his long and productive life in the same general setting that I seem to be living mine, painting scenes that are both familiar and not-so-familiar to me. The vitality of the early twentieth century is particularly notable, given the long-held view that Salem’s “golden age” was a century before. Why wouldn't it stop? The code looped around, waiting for the finished() flag of the Inflater to return "true" – but it never did.Not being a local historian or an art historian, one of the consistent pleasures of writing (and curating) this blog has been the discovery of local artists: I knew of a few well-known Salem painters like Frank Benson before I started blogging, but had no idea there was such a dynamic artistic community on the North Shore during his time, before and after. It would keep on going, stumble when it found there was no more data to be had, and the " Unknown zlib error" would get thrown. Both Harmony and Sun were performing this identically, except for one disparity: when JGit was running on Harmony, and had uncompressed the whole of an item, it sometimes wouldn't stop there. JGit uses the Java Inflater class to decompress that stored data, and then does a bunch of checks to ensure that no data has been corrupted. The error was occurring when JGit was "unpacking" the Git packfile – packfiles hold the lion's share of your repo's data, stored in an special compressed format. I added logging to the key parts of the JGit code. It also didn't explain why some repos consistently did work with Harmony – what was the poison pill that broke the others? That was great, because it confirmed that the problem was a discrepancy between Sun vs Harmony Java, but it didn't immediately tell me what that difference was. Identifying the difference by running code on my phone would have been laborious, but thankfully I didn't have to – the Harmony version of Java is easily installed onto a laptop, and once I did, I was able to see the same behaviour again, with the code failing in the Harmony VM. I suspected that somewhere between the two there was a difference causing my problem – and I needed to work out precisely where it was. Apache wrote this code from scratch – and wasn't able to get a license from Sun for the Java-compatibility test kit – so it's not quite the same as regular Sun Java. What's the difference? Zero difference with HarmonyĪndroid apps run on a Java-like set of libraries based on the open-source Apache Harmony project. Using JGit to clone a list of test Git repositories worked perfectly on my laptop (with the standard version of Java supplied by Sun, as was), but worked with only a few of them when I ran it on my phone – mostly, it crashed, throwing me this message: Packfile corruption detected: Unknown zlib error. ![]() This is the second blogpost about the development of Agit you can read the first post in this series here, which gives an overview of Agit and Git in general.Īndroid apps run on a version of the Java platform, and given JGit, a marvellous open-source Java implementation of Git, there should have been no problem getting Git up and running on an Android phone. Although I didn't know it at the time, the bug was actually hidden deep within the source code of Android itself.Īt the Guardian we encounter a lot of interesting bugs ('cos we do a lot of interesting things) and the process of fixing them is usually made much easier because we tend to use Open Source Software – though I worked on Agit in my spare time, I got to exercise a lot of the same skills in tracking this bug down. When I wrote Agit, the Git client for Android, I encountered a strange little bug that nearly stopped me dead in my tracks. As soon as a software developer tries something unusual, they stand a good chance of encountering our mighty friend – The Bug. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |