Feel-good moments are difficult to come by on Twitter in Pakistan. In between the political infighting and trolls, though, there was a brief moment where the ugliness the platform often brings out in people gave way to the app’s potential for humanity. 

In October, a Karachi school teacher, Aimun Faisal, tweeted questions from her students about space and space travel. “Do you get scared that your space shuttle might get lost?” one 10-year-old asked. Ms. Faisal tagged NASA and other space agencies in the post, encouraging readers to retweet it and bring it to their attention. It worked.

A Canadian astronaut who has flown in a space shuttle twice replied that he wasn’t scared because Earth was nearby, and he could use the stars to find his way. “I felt especially comforted when I flew over home,” he tweeted. “Here’s a photo I took of Karachi — can you find your school?”

It’s the kind of interaction that leads one to believe that perhaps all you need in life is a Twitter account and a heart that still beats. The media ate it up too: Ms. Faisal and her tweet were in all the major newspapers and even on TV. We were gushy over Ms. Faisal; we wished there were more teachers like her. 

Just a few weeks later, people were suggesting that Ms. Faisal should go jump into a river or move to another country. 

It all turned after — what else? — a series of tweets. 

One evening this past September, a woman set out in her car on a motorway outside Lahore, her two children in tow. Motorways in Pakistan are safer than most roads there; they have their own police, who have a reputation, unlike other police units, for being well-dressed and resistant to corruption. 

That evening, the woman’s car ran out of fuel. She locked her car doors and made some phone calls, but the rescue service didn’t answer, and she couldn’t get through to her family. By now, it was past midnight. She made more calls and waited for a friend to come pick her up. While she waited, two men emerged from the darkness, broke her car window, and when she fought back, took her children into some nearby bushes. She scrambled to save them, and while she fought, she was gang-raped. 

In the pre–social media age, if a rape story ever got more than a couple of column inches on the inside pages of a newspaper, the victim not only had asked for it but, by reporting it and making it public, was asking for something more. 

In an interview with the Washington Post, Pakistan’s former president and army chief Pervez Musharraf (now absconded from the country) once said Pakistani women get themselves raped so they can get a Canadian visa. He probably thought he was being funny or insightful. When his office denied his having said it, the Post made the audio public. You can hear one of his aides laughing in the background. 

Attitudes toward rape haven’t changed much since the Musharraf days, but there was something about the awfulness of a woman trapped with her children on a motorway at night that struck a chord with the Pakistani public. As the news rippled through Twitter, #LahoreMotorwayIncident became a trending hashtag. The details of the crime were so grotesque that, for a few days, it seemed the nation actually believed that rape was a crime and that the woman hadn’t asked for it. 

Pakistan’s traditional and social media go into this kind of outrage cycle when children get raped, or get raped and then killed, which happens more often than one can stomach. There was genuine fury across the country when a 7-year-old girl was raped, strangled, and left in a rubbish heap two years ago. Her name was Zainab. On Twitter and Facebook, users argued over whether her rapist and killer should be hanged in public, quartered, doused in acid, or just locked up for life.

After the motorway incident, the usual bloodlust was on display. There were calls for public hangings and for chopping up the culprits. Prime Minister Imran Khan even appeared on a TV interview saying he has been contemplating chemical castration as a punishment for such crimes.

Rizwan Tabassum/AFP via Getty Images

And while the Lahore rapists were still on the loose, the newly appointed Lahore police chief appeared on one of the nightly news shows during the wall-to-wall media coverage. In effect, he said he was surprised that a mother of two had decided to take the motorway when another road would have sufficed for her journey. And if she had to take the motorway, he went on to ask, couldn’t she at least have checked her gas tank? 

Ms. Faisal, the teacher we had fawned over just weeks prior for her tweets about space travel, was outraged. On Twitter, she was one of many to demand the police chief’s resignation, tweeting in disgust at the craven responses to the news she and others were seeing, rhetorical questions as to why the woman had failed to prevent her own assault. 

In return, our beloved Ms. Faisal was met with a flood of insults; trolls suggested she leave Pakistan if she had a problem with it. Being stuck on the motorway without gas became an internet meme that small-time politicians and social media trolls lobbed at one another. Somewhere along the way, “Why didn’t she check her petrol tank before leaving her home?” replaced the original question: “What kind of beasts would rape a woman in front of her children?” 

How did this horror morph into a meme? Does every one of us carry inside us a bit of General Musharraf, smirking while his aides giggle? 

Long before we had social media, Pakistan swam through its sea of miseries on the backs of jokes. The mausoleum of Pakistan’s longest-serving dictator, General Zia’ul Haq, is jokingly referred to as Jaws Square. Guess why? Because, after ruling over us for 11 years, he died in a plane crash, and only his teeth survived. 

Jokes back then went viral before we ever began to call them “viral.” You would hear one about the dictator in Urdu in Karachi one day, and the next day in Peshawar, someone would tell you it in Pashto. Jokes eased us out of our terror. 

But now the jokes themselves have become the terror. You can make a joke about a dead dictator, or Osama bin Laden becoming fish food, but how do you laugh at a joke about a woman raped in front of her children on the side of the motorway in the dead of night? Jokes were meant to subvert the powerful, not kick the poor to the ground. 

For a brief moment, social media in Pakistan made it easy to laugh at despots and oppressors. They answered with troll farms, indoctrinating the youth to be subservient to power. Even in the midst of incidents so nauseating that they capture the attention of our fractured social media, the horrors of which seem undeniable, the trolls find ways to mock and belittle. 

In November, another shocking piece of news roiled Pakistan’s social media: A 4-year-old rape survivor told her gut-wrenching story in a video that went viral. It was so harrowing, I couldn’t bring myself to watch it, even for reporting purposes. In another video, also shared widely online, the doctor who treated her after the assault broke down crying. 

On Twitter, it’s easy to find redemption in the narrative too. In the middle of the outrage cycle, social media made a hero of the policeman who had found the girl’s rapist by enlisting his own daughter to lure him. The rapist was killed in a police encounter. 

The policeman and his underage daughter were forced to take this extreme step because there were no women officers in his district. The prime minister called to congratulate the man, and his daughter was awarded a million rupees as a prize along with a guaranteed college scholarship. 

Ms. Faisal, who by now has endured a litany of abuses online, questioned the collective satisfaction on social media. As proud as we are of the police officer, she tweeted, the story said more about the country’s broken system than it did about heroism. “No police officer should be forced to risk his family to perform his duty,” she wrote.

“Tum kabhi khush na hona,” someone tweeted back. “You’ll never be happy.”