The Artima Developer Community
Sponsored Link

.NET Buzz Forum
Being "Mono Aware"

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Jason Alexander

Posts: 112
Nickname: jalexander
Registered: Oct, 2003

Jason Alexander is lead developer for Match.com.
Being "Mono Aware" Posted: Oct 14, 2003 8:30 AM
Reply to this message Reply

This post originated from an RSS feed registered with .NET Buzz by Jason Alexander.
Original Post: Being "Mono Aware"
Feed Title: Jason Alexander's Blog
Feed URL: http://www.asp.net/err404.htm?aspxerrorpath=/jalexander/Rss.aspx
Feed Description: Tales from the .NET trenches...
Latest .NET Buzz Posts
Latest .NET Buzz Posts by Jason Alexander
Latest Posts From Jason Alexander's Blog

Advertisement
Recently I have taken up porting various pieces of Open Source software written in C# to the Mono platform. Though a tedious process, it actually has many benefits for Mono. The dictionary states that a porter is "a person stationed... [Ben Maurer]
With Ben having taken up this initiative on Mono, I posted my own interest in seeing that nGallery will port to Mono. Ben has since grabbed nGallery and started porting himself! Very exciting! In doing so, he's already found a few things that I obviously wasn't aware of.

One question I had to Ben was: What are some tips to keep in mind so that you're project is "Mono aware"?

Ben has some great suggestions:

Registry entires:
Well, besides the obvious "dont use the registry", basically you should make the assumption that anything not documented on MSDN is going to work wrong on Mono. Programming with that assumption in mind will prevent alot of bugs, and may help you when 2.0 comes out.
Exception loss:
Also, one problem i have seen (which is not really a compatibility problem, but hurts porting) is code like this: try { ... } catch { throw new Exception ("foo baz failed!"); } This removes all the data from the old exception, making debugging *much* harder. It is better to use the innerException so that you retain the origional metadata.
Test Cases:
Also, providing NUnit tests for your class library is useful, as it allows us to ensure that we are really doing things right. As well, if you have a set of smoke tests that you use, that can be very helpful. Providing a "default dataset" with a wide varity of inputs can help us to catch bugs that might otherwise require alot of effort to reproduce.
And, finally, Frequent Releases:
Making frequent releases can also be helpful once we get one version ported, so that we can make sure we keep up with you.
He also has a few ideas and thoughts on helping out Windows developers stay “Mono Aware“:
One thing I have been thinking about to make porting easier for Windows developers is developing a custom plugin for ASP.net that would detect case sensitivity problems. On each request it would just see if the file actually had the correct case. This would allow web developers to see when they made a mistake. I have also been thinking about making a utility IO library that would check for windowsisms, and warn the developer.
These are all very important to keep in mind if you have a project that you hope to be able to run on Mono some time in the future. And, if we as a community are to embrace Mono and true interoperability between different operation systems, we should all become more "Mono aware".

Read: Being "Mono Aware"

Topic: .NET Nightly 27 Previous Topic   Next Topic Topic: WikiWiki for the .NET docs?

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use