Playing with NDepend

Few days ago I used NDepend tool to analyze the code of one of our bigger projects in Sogeti. Here are my thoughts on the tool.

NDepend is a static dependency analyzer tool. It scans your compiled code, the PDBs and the source code and produces a “map” of your code dependencies, metrics and structures. It has been around for several years now, and it has kept beeing better in every new edition.

The default view of NDepend is the so-called “Report” that highlights all the potential issues with your code. It gives you a trove of information to optimize your code, in a HTML format that’s easy to share. The report contains the summary of all the main features of the tool: rule violations, dependency cycles, complex code and so on.

NDepend Report

The next feature that I used is the dependency visualization. There are two “flavours” to it: the dependency graph and the dependency matrix.

The dependency graph is easy to grasp but it can only be meaningfully used with a handful of classes and namespaces. It quickly becomes a mess with more than a couple of dozen objects.

NDepend Dependency Graph

The dependency matrix is a much more powerful tool. It can be used to spot dependency cycles, infrastructure classes, “god” classes, cohesion and coupling and so on. However, it’s not as intuitive to analyze as the graph, it takes some time playing with it to grasp the information without consulting the help windows.

NDepend Dependency Matrix

NDepend has a full set of code complexity and maintainibility rules. It can quickly highlight the most important issues so that you can concentrate on fixing the most critical parts of your code.

NDepend Code Rules

But it’s just the surface of it. NDepend has a full-blown language called CQLinq, akin to SQL, that allows you to query your code. You can find classes that have high coupling, methods that are too complex, nested structures in the code and a myriad of other code patterns.

NDepend CQLinq

In my opinion, NDepend is an invaluable tool if you’re concerned about your code quality (and you should be). It takes some time to grasp and master all the power of it, as it can be an overwhelming experience for a first-time user, but it’s a time well invested.

Thanks to Patrick Smacchia (the main force behind NDepend) for the NDepend license for MVPs, that allowed me to fully evaluate the tool.

 

The “Inner Circle” syndrome and MVP Program

After an overwhelming response to my last week post about the lack of diversity and inclusion in the technical communities, I wanted to speak about a specific diversity problem in more detail.

This problem is the “inner circle” syndrome.

As I mentioned in the previous post:

Even in the Spanish community, I’ve been mostly involved with the people I know well, mainly the Spanish MVPs and user group leaders. We know each other as we always hang around the same events, and thus unintentionally we create an “inner circle” in the community that makes it difficult for new people to come inside. It’s not that there aren’t any new community members, but it’s more of a mental barrier of always having “the usual suspects”. I have heard several comments lately from bright technical people that don’t submit to events because “there are always the same guys” speaking there.

The “syndrome” is the feeling or an opinion, backed by some evidence, that in technical communities there is a small core of people who share a disproportionally large amount of the “spotlight”, this being sessions in technical events, articles, publications. I have received many, many comments of technically proficient people that don’t bother to propose a talk because “it’s always going to be the same people chosen for the sessions“.

Let’s go deep into the problem, shall we?

It’s a small community

The technical communities are usually led by a small group of people, who are motivated enough to invest their time and efforts into providing value for the rest of the members of the community. By its own nature, this is something altruistic and we can’t expect everyone to be a community leader. So, the number of the people actively leading a community is low and there’s no problem with that.

pasta-composition-1-1543750-639x958

At the same moment, the fact of being a leader in a technical community also shapes another community of sorts: the community of community leaders. I suspect that there is a natural disposition to mingle with those who are like us. It’s not a problem, per se. I benefit from interacting with other community leaders, for example, sharing strategies and tips on how to have a more successful community or how to drive attendance and awareness for our events. That’s the good part.

The bad part is that, if left unchecked, it’s easy to mistake the community of our peers (community leaders) for the community at large. It can lead to the “inner circle” syndrome if we do nothing to include checks and balances against it.

How you get accepted to speak at events?

If there’s one measure of the public perception of an “expert” in a technical community, that’s speaking at technical events. Those people are usually recognized or taken by the rest of the technical audience as the ones who excel on something in their respective domain of knowledge.

However, there are many more people knowledgeable about something than speakers at the events. It’s a matter of combining several characteristics:

  1. Being knowledgeable about something
  2. Having sufficient skill (and bravery) to speak in public
  3. Being aware of an event where your contribution can be welcome
  4. Actually submitting a proposal to talk at the event
  5. Having been accepted to speak at the event

In a 100% meritocratic world, this would be a pure number’s game. However, in the real world there are unseen obstacles to this straightforward process.

Once you fulfill the condition 1, you have to acquire skills about speaking in public. Many people don’t come forward at this step, as public speaking is something very stressful for mostly an introvert population. (Introversion is highly correlated with abstract thinking capacity we need to understand computers, so our technical communities are necessarily skewed to the introvert half of the population).

Let’s say you have the skills to speak. How do you become aware of a prospective event (the condition number 3)? In many cases, it’s a random thing. Usually, you read it on Twitter or a technical blog you follow. The “inner circle” members have an advantage here, because if you are already in the community “inner circle”, chances are that you already know about the event either because it’s organized by your peers or because somebody mentions in the conversation.

The condition number 4 requires you to choose a topic and craft a cohesive and appealing proposal for your talk. You need some marketing advice in order to find that what’s unique about your talk and you have to “sell” it to the event decision board. This is another skill in which the most of the technical audience are not well-versed.

Finally, the last barrier is getting accepted to speak. If you have a good proposal, your chances are better. But the sad truth is that if you are part of the “inner circle”, your chances are SO much greater. Sad but true.

Why is that?

The people choosing your talk are probably the people who are your acquaintances or friends. It’s a small community we are talking about, and we mostly know each other. When you have a talk from someone you know (and trust) as opposed to a talk by someone you haven’t heard of, then it’s just natural to lend more credibility to your friends. It’s our human nature. And it’s detrimental to our community diversity.

Also, the number of speaking slots is usually always much less than the number of prospective speakers. Due to this pressure, the selection board tries to “stick to the well-known” and minimize the risk.

We have to tread carefully not to close the doors on the any prospective contribution, and the fact of not being “known” in the community is such a huge handicap. The mere fact of having someone in the “inner circle” to rely on and to ask for advice is the most frequent way I’ve seen for the people to become speakers. I’ve done it, a couple of times. But, that’s not the way I’d want it to be in the future.

The trouble with MVP program in the technical community

And here I explicitly mention the Microsoft MVP (Most Valuable Professional) program as a factor in this imbalance of speaking sessions. I’m a current MVP, and I speak out of the knowledge of how things are run in our local community (Spain and Europe).

MVP Logo

The MVP program is an award (not a certification, not an entitlement) for past year contributions (posts, articles, speaking sessions, open-source contributions etc) in the technical community that aligns with one or more Microsoft products or technologies. It’s awarded every year.

That’s the good part.

However, MVPs represent only a portion of the valuable community leaders and contributors (I suppose that’s why it’s called “Most Valued” though). For starters, there is a limited number of MVPs per category and per region. The evaluation criteria are opaque (even though you can nominate yourself or other people) and there is no formula that let’s you know if or why you are accepted or rejected as an MVP. If I’d change one thing in the MVP program, I’d make the criteria and the nomination process more transparent. I don’t think that it should be totally objective (because it could be gamed), but I’d like to see the explanations about the selection results for each MVP. Until then, the rest of the community can only take educated guesses and fuel rumours about how the whole process works. More transparency will bring more accountability to the program, in my opinion.

Additionally, the MVP Award in the Microsoft technical community is almost a guarantee that you are in the “inner circle”. Your sessions proposals are going to weigh more in the event selection boards, you are going to be in contact with other MVPs and you’ll be aware of more community engagements. However, now you have a vested interest to keep being an MVP so you will submit to those events, knowing that your MVP status makes it easier to keep it. It’s much more easier to keep your MVP status than to get one. It’s not that the entry barrier is high (which is true) but the fact that the advantage the renewing MVPs have over you is so much greater.

Don’t get me wrong. I think that MVP program is very valuable, both to the community and to Microsoft, but it’s easy to misrepresent it and to mistake the MVP community for “the whole community”. You’re going to think of the fellow MVPs as your “inner circle” in the community and you’re going to reap the benefits. It’s not fair, but it’s real.

Ok, how should we fix it?

I wish I knew!

Notwitstanding that, I can suggest some possible actions.

First and foremost, the community leaders should be less of a rock star and more of a servant leader. It means serving the community and getting out of the way of others. You don’t brag about you, you don’t abuse the advantage you have as a community leader by grabbing more spotlight. You consciously move out of the spotlight to let the others be illuminated.

Our role as the community leaders is more to the people that are still outside the community than it is to the people already inside. We should focus on expanding the numbers and diversity of the community, not our own numbers.

Don't be a rock star

We can also help the prospective new members. As leaders, we are exposed to potential valuable contributors more than the average community member. We should act as a benevolent gatekeeper that brings people in instead of letting them out. The feeling of “not being one of us” that trickles down in the technical community, is a very strong barrier to entry. I don’t think that it’s something we do on purpose, but it has a real effect. We should be aware of it and correct for it. How?

  • Mentor other community members that show potential value
  • Teach soft skills such as public speaking, personal branding and community engagement, not only technical stuff
  • Spread the word about potential speaking and engagement opportunities. Make a goal to bring in one new speaker for every event in your expertise domain. Help them writing their proposal and help them with the session preparation if you can.
  • Make the proposal selection a blind process. Strip the biography from the submission and let a board of peers rank the proposals for their merit, not for the speaker.
  • Be conscious about your unfair advantage as a community leader. Concentrate your contributions to non-competitive channels (your own blog, GitHub, magazines and selected events) and resist the urge to cover all possible outlets. Don’t be a rock star! If you really have something to tell, help organize your own event 😉
  • If you are organizing an event, reserve a sizable portion of the agenda for first-time speakers and traditionally underrepresented communities. Don’t let the “same old faces” steal the show. Even if it feels lowering the quality of the agenda, it’s the other way round. You are strengthening it.

Microsoft can also do a lot about fixing the “inner circle” syndrome:

  • Make the MVP nomination process more transparent and accountable. Not everyone who applies should be an MVP, but we really need more transparency around the process to make the “inner circle” dissappear. Explain why someone is awarded and someone else is not.
  • Reserve slots for first-time speakers and underrepresented communities at your events

I’m really looking forward for comments on this issue. Am I being right? Wrong? Misled? Please use the form below to contribute to the discussion.

The dark, hidden side of our technical communities

For a long time now, I’ve been wishing to write about the gender and diversity gap in the technical community. Today felt like that day, so here it is. It’s the longest post I have ever written, I think. Don’t worry, you don’t have to read it now. Save it for when you have some time to spare. No TL/DR here, I’m afraid.

As an active community member for some years now, I’ve been exposed to the rich ecosystem of user groups, formal and informal events, online collaboration, banter and gossip, articles, blog posts and other outlets of the technical community at large and SharePoint-specific community in particular. The personal rewards of interacting with other people in the community are enormous, and I feel grateful for the insights I got and for the opportunity to exchange points of view. Based on a voluntary participation, the community is one of the best examples of intrinsic motivation that I have ever seen.

However, the technical community isn’t the rose-painted picture nor it exists in the void. The real-world issues also seep into the technical community and not all what I have seen inside is something that I’d like to see again. I’ll try to explain it in the following lines.

The technical community is based mainly on the underlying politics of meritocracy. The more you work to benefit the community, the more benefit you get from doing it. We are used to think that our communities are as egalitarian and democratic as possible, but it’s a flawed illusion.

Who is the “community”?

Enter the blissful ignorance of conformity bias.

Let me check the circles of my personal interactions in the community. Mainly I’ve been involved in Spanish technical community around Microsoft technologies. I also have an active European participation, mainly in community-run events. In the end, I have participated in a couple of US and Canadian events, but my main field of action is Spain and Europe. I feel enriched by my community work, but let’s make a closer look.

Even in the Spanish community, I’ve been mostly involved with the people I know well, mainly the Spanish MVPs and user group leaders. We know each other as we always hang around the same events, and thus unintentionally we create a “inner circle” in the community that makes it difficult for new people to come inside. It’s not that there aren’t any new community members, but it’s more of a mental barrier of always having “the usual suspects”. I have heard several comments lately from bright technical people that don’t submit to events because “there are always the same guys” speaking there.

And there’s true to that. It’s true that in the Microsoft communities the preponderance of MVPs in the speaker rosters is something that makes it easier for the attendees to choose interesting events but it also shuts the door (or leaves it almost closed) for new people and new blood in the community. As MVPs we have to do community activities to keep our MVP status, and I think that it has this side-effect of erecting walls around the technical events for potential speakers that aren’t part of the “privileged” few.

Furthermore, my community interactions are mainly with the people similar to me: white males, with university studies, middle to upper-middle class. For years I’ve been blissfully ignorant of the biased world I was in, but for some time I’ve been growing a conscience that ultimately makes me write this post, due to several things in the last years. I’ll line them up for you, if you are still with me.

Women in Technology

Vanessa Estorach is one of the founders of “Women in Mobile”, an advocacy group that helps raise the profile of women in the male-dominant world of mobile technology and marketing. She also happens to be my wife. She explains to me that one of the problems women face in the tech sector is that they have no role models. I haven’t thought about that before, but it’s painstakingly clear: while the boys have Bill Gates, Linus Torvalds or Mark Zuckerberg (nerd, geek stereotype included), the girls have no modern Ada Lovelace to refer to. I can only see some timid examples such as Marissa Meyer in Yahoo!. In fact, the stereotyped image of a tech person as a young nerd with zero social skills is the main factor that drives the girls out of technical careers even before stepping in.

I also read the “Lean In” book by Sheryl Sandberg, where Sheryl, a Facebook COO, paints a feminine/feminist view of a more egalitarian tech world and how to “lean in” to make it possible. My main takeaway from the book was there is a lot of effort to be done if we really want to see some change.

And last, but not the least, I’ve been subscribed to a newsletter called “Technically Speaking” for some time. It’s run by Chiu-Ki Chan and Cate Huston who write about technical speaking, a subject dear to my heard, but from the point of view of a minority, with special focus on codes of conduct and inclusive events. They are a female voice in a male-dominated sector, and collect positive examples of more diverse events and community. Their newsletters struck a chord in me and made me conscious of the “granted by default” privileges that I have as a white male, first-world technical community member.

The more I read and discussed about the “gender gap”, the more I felt that I could do more. I started to raise the issue at my work, in discussions with HR and management. I made a conscious choice of positive discrimination, recommending women over men from the candidates pool for our new hires. While positive discrimination is a discrimination, I think that it’s necessary until the field is leveled and the things regulate themselves. We have to apply extra effort to change the inertia that by itself will only perpetuate the existing situation, that’s why we have to discriminate positively.

Woman with laptop

However, the one thing that I try to avoid is to foster a token female presence. To have a single women in the team is almost as bad as having none. There is some research that says that starting with 3 women in the team is when you begin to see the effects of more diversity of opinion.

My community “girls club”

While my community circles are still mainly “boy clubs”, I have to acknowledge remarkable women in the community that I have the privilege of knowing personally:

  • Cristina González, the MVP lead for Spain, Portugal, Italy (and some other countries). The envy of other MVPs who don’t have the privilege of having her as their lead, she has a soft and caring communication style and a brilliant mind that makes for very interesting conversations.
  • Martina Grom, Office 365 MVP from Austria. For me she’s the embodiment of what I’d like to see more in the world: a competent professional, engaged in the community and true to her values about the women in the IT.
  • Agnes Molnar, SharePoint MVP from Hungary. Agnes is a mother of three and a frequent community speaker and traveler. If that wasn’t enough, she even writes books and helps other women in the IT.
  • Isabel Cabezas, Microsoft Technical Evangelist from Spain. Isabel is a former student of mine, that became coworker and now she participates in Microsoft Developer Experience team in Spain to communicate her passion about technology. Isabel also works to fix the gender gap by organizing events such as Ada Code Group or AdaJS/JSLadies.
  • Iris Classon, Swedish MVP. Iris was a dietitian who discovered programming in 2011 and hasn’t been looking back since then. Her passion for technology is unbounded and she transmits it on her talks and her blog. While I still can’t make my mind about whether her previous look was a good or a bad role model for women in IT, she’s undeniably an example for other women in the programming community.

Beyond gender inequality

So, if we have more women in the technology, then the problem is solved, right? Well…there are still some issues beyond the mere presence of female talent in the community.

Do the women in the IT feel welcome in the community? The sexual harassment raises its ugly head even in our meritocratic communities. We won’t have more diverse communities without eradicating sexist jokes, patronizing talk and innuendo. There have been several high-profile incidents in the technical events lately, and we’re talking about supposedly more-than-average open and forward-looking communities.

What about the lactating mothers who want to come to an event? Will they feel welcome? And even for the parents regardless of the gender, what if they want to bring their children to the conference? How can we make it possible so that they won’t have to pay a babysitter?

And that’s only one of the diversity issues in our communities: the gender gap. But there are many more lurking around. How many times you had a speaker from emerging countries? By focusing ourselves on our cozy Western environment, we lose the valuable insights of the people whose experiences in the IT are radically different in scope and impact.

What about the economic inequality? As a members of the privileged middle-class, we tend to forget that not everyone can afford to travel to a conference to speak, even more so in the real community events where the budget is stretched. It’s a real barrier to more diverse events, and I can feel it even in Spain where outside Barcelona and Madrid, few speakers can show up because of the economic downturn that hit the areas outside the metropolis much harder. How many voices we lose due to the companies that can’t (or won’t) pay the travel costs for their people?

What about the people with disabilities? Can they participate in the technical community as it is now? Or do we need to change the community itself. Even such a small detail as the wheelchair ramp or the subtitles for people with hearing problems can mean that a person who wants to participate cannot do so.

What about the LGBT people in the technical world? Do they feel welcome when somebody cracks a joke or uses a derogatory term even without thinking about it. There is a sincere post on Medium by a black lesbian programmer and her experiences about the diversity in the tech industry.

I have just scratched the surface of the unconscious bias that we have in our technical communities. You can find a lot, lot more information just by searching on Internet. For example, the Python community has a set of guiding principles for a more inclusive community.

Diverse world

What can I do about it?

So, what can I personally do to foster the more diverse community? As a user group leader and a technical speaker I do have some freedom of action and I intend to do something to increase the diversity:

  • I will make our user group events (such as SharePoint Saturday Barcelona) more inclusive by inviting speakers outside our “white, privileged boys club” and by helping that everyone who wants to participate can do so, regardless of the gender, sex, sexual preferences, economic situation or physical condition
  • I will promote the awareness of the diversity gap in the technical community and be vocal about it
  • I will decline to participate in the events where there’s no effort to bring more diverse backgrounds or where there’s no clear code of conduct (such as this one for instance)

I know that I won’t change the world, as I realized many years ago I can’t change it by myself. What I can do, however, is change what I do. By “being the change you want to see in the world” I can stay coherent with my beliefs and help bring in a richer, more diverse world to the communities I’m involved with.