18 March 2022

Using Android apps on a PC or Mac

This actually began as a search for whether I could install Ubuntu on my phone. Turns out there are some ways. There's even the Pine Phone. These would actually be a much better option than our current phones that contain bloatware and are gleefully invading our privacy.

Then I wondered, if Ubuntu could be installed on a phone, could Android OS be installed on a PC? Recently, WhatsApp had notified my uncle that it would no longer run on his old iPhone, and in the effort to help him find a solution, I found ways to install Android on PC or Mac.

 

CAUTION:  Before using any emulator or app, please read all license terms and check if what you are doing is permitted as per the EULA of the software.


Trying WhatsApp on BlueStacks

If you try BlueStacks (which I've written about earlier too) to install WhatsApp, you can do it as listed below (but make sure you check the license agreement to see if it's ok to do so):


  • Install BlueStacks5 and select the APK button on the right side menu and select the apk file you just downloaded.

  • Follow instructions on the screen to install WhatsApp.
  • Enter your phone number and you'll receive an SMS to confirm it. Once you verify it, you can add new contacts and start sending and receiving messages in WhatsApp.

Note that in this whole process, it isn't necessary to install WhatsApp on the phone. Whether using BlueStacks is safe or not (in terms of privacy and security), I don't know though. So I'd typically consider using it from within a sandbox or virtual box (again, it's necessary to check the license agreements to see if it's ok to do so).


Other Android options

You can also download ISO files and install Android on your computer just like how you'd install Ubuntu or any other operating system. This would possibly mean that it could be installed via Virtual Box too (I'll be trying this out in a while).

While there are various options, I'll probably also try one or more of: PrimeOS, Android x-86, Bliss OS or LineageOS

If you are a big fan of Android games, and while playing on your mobile phone you see yourself being defeated easily, there's a good chance the other players are either playing the game from their PC, using one of these operating systems or they would've connected a keyboard and mouse to their phone.


ps: Framework laptop even brings us modular laptops that we can repair ourselves. Not yet available in India though.


12 March 2022

Companies be careful: Your open source salad may go kaput if you don't perform basic checks

When providing my expertise to a company as a consultant many months ago, I reviewed their code and architecture. One of the suggestions I asked them as a question, was whether they maintained backups of the various versions of the open source code they used. That question seems ever more relevant now.

Today, I came across a shocking article by Niclas Gustaffson, which outlines how an open source developer introduced malicious code in his open source project as a mark of protest. This went on to cause problems in even a large company that used the code. 

 

What did he do?

According to the article, this developer named Marak Squires, introduced an infinite loop...

for (let i = 666; i < Infinity; i++;) {

...which caused a Zalgo text issue that makes gibberish appear on the screen of projects that used some of his code.

The gibberish that appeared on one users screen

The changes were made to colors.js (2,67,01,901 weekly downloads and allegedly, 19K projects dependent on it) and faker.js (apparently used to have 2.8 million weekly downloads and 2.5K dependent projects).

 

Why he did it

Marak had apparently announced in Nov 2020, that he'd no longer be supporting large companies who used his software for free. 


Why this isn't right

When anyone is accepted into the open source community as a creator or a contributor, it's done with a great amount of trust and respect. It should be an honour for a person that so many people use their open source project. If Marak didn't want to support large companies unless they paid him, he could have made an announcement that he's no longer working on the project, and stopped updating the repository. By introducing malicious code, he broke everyone's trust and even maligned the good reputation of the source community. A stark contrast to all the responsible developers who have built reliable systems like Linux, Git, Firefox and so many open source projects.


What can be done by companies?

  • Well, first of all, setup a CI/CD system right from day one. There are companies involved in projects of high importance (I'm not going into details), which do not have such basic infrastructure setup. The CI/CD infrastructure will ensure that you always have multiple working, shippable versions of your software even if the latest build broke.
  • Keep backup versions of all the open source code you use. Remember that the code comes with no guarantees.
  • Build a test-run framework where you can test the latest version of the project before you actually deploy it to a customer-facing server.
  • Have a security team perform an audit of all your code. Even the open source libraries you use. Learn about zero day exploits.
  • Consider donating to open source developers, Wikipedia, StackOverflow or any other such source where you get knowledge and resources for free. There are many ways to contribute.
  • Consider involving your developers in open source projects. Not on their time. Do it on company time. I know ThoughtWorks allows this.

 

I condemn what Marak did. However, it also reminded me of various ways in which deserving people like scientists are exploited (they make discoveries and publish it but don't get royalties or anything in return, even when companies use those ideas and massively profit from it), while un-deserving and deceitful people like fake god-men and other corrupt people and certain corporations are given respect and are allowed a pompous lifestyle by a gullible society. 

Anyway, open source developers, please maintain your integrity.

06 March 2022

A Guide for People Researching Eye Strain

During the past decade, on consulting multiple doctors, I realized that they were unable to cure my eye strain because of a lot of incorrect information floating around. This in turn, was possibly affecting the direction of research, because researchers probably didn’t know what to analyze.

Rather than begin with commonly propagated notions about the cause and cure of eye strain. A better way to begin, is by speaking with people who have experienced severe eye strain. It’ll help dispel a lot of the myths, when they tell you what solutions didn’t work.

My tips for researchers

Find a way to measure strain of the intraocular and extraocular muscles

It is necessary to find an objective method of measuring the various stages of severity of eye strain. These objective metrics need to be correlated with subjective feedback from the test subjects and compared with a control group. If there are mismatches, then a better method needs to be invented/innovated. This needs to be done under baseline conditions, and during variation of various test parameters. In subjects with chronic strain, at least the spasms of the inferior oblique muscles are somewhat easily detectable. The sharp, stabbing pain at the superior oblique, lateral and superior rectus are also important.

Name and quantify the various stages of eye strain

There are various stages. One is when the healthy eye begins to water a little, and there are reflexes where the tired eyes try to gently close, as a message to the person, to stop straining the eyes. People tend to ignore this and continue torturing the eyes. Then there’s the stage where the forehead muscles are tensed and pain (which people call “headache”). There’s another stage where the front of the eyeballs have a burning feeling. This is a severe stage. Then there are sharp stabbing pains around and behind the eyeball. This is an acute or chronic stage. In the chronic stage, even the cheek muscles are strained. There are possibly more severe stages, as experienced by Jack.

Know what factors affect the strain

At least in my experience, eye strain is affected by sleep duration (specifically, not getting uninterrupted sleep for an age-appropriate duration), food (proteins giving muscle endurance, and how various foods affect the digestive system, causing sleep loss), age, spectacle lens-type (plastic vs. glass), duration of strain, nature of strain (watching a movie, driving, reading a book, looking at a digital screen etc.), duration and quality of rest, naps, angle of viewing (also take note of which muscles get to relax while the subject reads when lying down), brightness, blink rate, muscle tension, and perhaps other medical conditions. Measure these with and without using aids like eye drops or spectacles. Check and find out how natural, commonsense methods can reduce strain.
The response from the subjects would also depend on their ability to comprehend and honestly respond to the test questions. The observations need to be noted everyday for a few years at a stretch. Sleep duration, interruptions in sleep and the type of edibles consumed (the quality and whether it was properly cooked/baked/fried) needs particular attention (because it affects sleep quality and muscle endurance).

Check and quantify if and how parts of the eye are affected by strain

These include the intraocular muscles, extraocular muscles, eye lens, pupils and cornea. It would also help to check if there are variations or swelling that affect the shape or size of any part of the eyeball, especially in cases of chronic strain. I would not be surprised if constant tension on the eyeball could be one reason for progressive myopia.
 

Measure the extent and rate of recovery when strain causing situations are removed

Remember that the rate of recovery differs. People with mild strain recover quickly, but people with severe strain can take months or years to recover. This can help avoid pointlessly prescribing spectacles to people who don’t really need spectacles. It can also help organizations and schools create guidelines that prevent people from overworking and damaging their eyesight. Normal vision is too precious a gift to ruin.
It may also be possible to re-design computer work in a way that does not require us to focus our eyes at a single location for too long.

Obtain statistics on normal sighted people too

Perform large-scale surveys on normal-sighted people. Check how many of them in rural and urban populations, have slight myopia, hypermetropia, astigmatism or any other eye issues, and are yet able to lead normal lives without requiring spectacles or medical intervention. Check for how many years the situation remains unchanged (or how and when it changes). This will help create a baseline and help provide deeper understanding into when medical intervention is really necessary and when it can be avoided. For example, it’ll help gauge if it is normal for one eye to be of a slightly different power than the other eye. It’ll help understand how eye power varies over the course of a day and returns back to normal, without any severe or long-lasting consequences.

Establish guidelines for spectacles

Measure how poorly aligned spectacles/lenses affect strain. Check how the position of the focal point of the spectacles affects strain. Objectively verify how distortions caused by lens-types affect the amount of adjusting that the eye muscles need to do (you’ll need test subjects with chronic eye strain to get measurable results). Quantifying the minute light distortion among various lens types at various radii and angles from the focal point, will also help (perhaps using lasers could help verify this). Establish guidelines for opticians and spectacle manufacturers to follow. Many of them are amateur/irresponsible enough to not even take any measurements when they take an order for spectacles. Some even try to force improperly aligned lenses onto their customers. It’s necessary to establish strict rules for opticians to measure the dimensions of the subject’s face and position the lenses at the correct focal point, at the right angle and distance from the eyes.

Establish guidelines for eye tests

The results from the studies above, can help establish guidelines for what questions doctors need to ask a patient. The one fundamental question I’ve noticed that’s lacking, is that doctors don’t bother asking and verifying if the patient is getting sufficient sleep, rest and nutrition. It would help to do more groundwork to help identify the right tests to do and identify the various stages of strain and know the causes. This can help avoid a lot of pointless tests (there are certain tests being done unnecessarily even though no symptoms are observed). There also needs to be a mechanism to periodically check and correct problems and alignment issues with the frames that hold trial lenses and perhaps even the computerised eye test equipment.


Know the source of funding

Know who is funding your research. Make sure it is from an unbiased source that actually cares about people’s health and wishes that people can enjoy normal vision.


Most importantly, don’t forget to think out of the box and look for other causes/factors/cures. If you discover that any of my assumptions were incorrect, do let me know (after thoroughly verifying it). As a person of science, I’ll be happy to correct myself.


Say thank you or donate