loading...

Coding and Cannabis

damcosset profile image Damien Cosset ใƒป1 min read

Cannabis and coding

I just watched a documentary called Grass is Greener on Netflix. It talks about may things surrounding cannabis. How politicians demonised it despite scientific evidences, how minorities were targeted by anti-cannabis laws...

However, throughout the documentary, we hear a lot of testimonies from various artists such as jazz musicians, hip-hop and rap performers and songwriters. Different generations of artists find themselves more creative when they are high. Obviously, the question has to be asked:

Have you ever coded while being high? What was the result?

Note: Please do not get political on this topic. My question concerns the effect on cannabis on your productivity as a developer. Your views about whether cannabis should be legalised or not are irrelevant here. Thank you :)

Discussion

pic
Editor guide
Collapse
peter profile image
Peter Kim Frank

I've heard the phrase "Think high, work sober" and I basically agree with the premise.

If you're on a deadline or have to immediately release production-ready code, it's probably not a good idea to put yourself into a state of "impairment" before working. You should be as clear as possible to do your best and most diligent work.

However, if you're merely thinking through an issue or approach, changing your perspective and mind-space might put you into a more creative flow. It's likely that you'll make connections or go down a different path than you would have otherwise. This is ideal when you're on your "own time" and have the time to implement any ideas you might have later.

Collapse
therealkevinard profile image
Kevin Ard

I did the "think high" thing quite a bit when I was younger. I'm not much of a smoker these days, but I appreciate how it "trained" my brain. Not long ago, I was watching how the water flows in a creek - just zoned out on it. I got back to my desk and refactored a massive golang backend into 4 micros tethered by rabbit topics that can hold up to any chaos monkey.

From watching the water.

It's the same way things would click in my think high days, and it still happens pretty often - what, 15-20 years later.

Collapse
bennypowers profile image
Benny Powers ๐Ÿ‡ฎ๐Ÿ‡ฑ๐Ÿ‡จ๐Ÿ‡ฆ

Some of the most prolific thinkers and doers of the past century were users. Carl Sagan was a user, Bob Marley was a user, heck - Queen Victoria was a user.

If you can produce while using, it's between you and yourself.

If you can't produce while using, you probably shouldn't use while working.

Not sure it has to be more complicated than that...

If you live in a jurisdiction where it's legal, and you have no contractual obligations, and you want to find out whether or not it's good for your productivity or creativity, you probably shouldn't show up to work high for the first time. Instead, experiment on your own time (with plenty of buffer before you need to get back to the office).

Don't do anything to risk legal trouble.

Collapse
damcosset profile image
Damien Cosset Author

Didn't know Carl Sagan was a user :o

Thank you for your input.

Collapse
bennypowers profile image
Benny Powers ๐Ÿ‡ฎ๐Ÿ‡ฑ๐Ÿ‡จ๐Ÿ‡ฆ

He wrote a pro-cannabis paper under the pseudonym "Mr. X" in the late 60s.

bigthink.com/mind-brain/carl-sagan...

Collapse
jackharner profile image
Jack Harner ๐Ÿš€

The biggest advantage for me is the ability to hyper focus on one thing at a time. It helps me lock in and get into Flow easier. One of those skills I've developed over the years is getting stoned, and then immediately jump into a task, not allowing myself any time to get distracted. You've got to actively work towards not being the "Lazy Stoner"

Most recent issue I had was one night I was working on a project, fixing things adding features, etc only to find at the end of the night that I forgot to git pull in work I'd already done and every single merge conflict was essentially the exact same work I just did.

P.S.

My smoking is on my time working on my projects, not at work, for obvious reasons.

Collapse
ozzyogkush profile image
Derek Rosenzweig

Yes, and it usually helps, but not all the time. A little bit can help you relax and think clearer, but too much can make it harder to concentrate. Depends on the strain and a bunch of variables. Definitely doesn't help for meetings.

It also depends how familiar you are with the domain - if it's new ground, a clearer head is probably better. If you're doing stuff you're pretty familiar with, it shouldn't be a detriment. Keep in mind that you'd get basically the same effect as going for a run on your lunch break - the 'runners high' is caused by endocannabinoids like anandamide (which acts like Delta-9 THC on the CB1 and CB2 receptors).

I know people, coworkers, etc who can have a beer or two if we go out to lunch and still be able to work, but personally I hate combining alcohol and coding. Weed though, hell yeah.

Collapse
drbearhands profile image
DrBearhands

I'll try it for science.

Collapse
damcosset profile image
Damien Cosset Author

My man! ๐Ÿ’ช๐ŸคŸ

Collapse
drbearhands profile image
DrBearhands

So I did, and it was pretty much in line with my expectations for a downer. Great for drowning out distracting and stressful thoughts, so I can see why it would help with creative tasks that require more 'feeling' than reasoning as it can really help get into the zone.

As for my particular situation, I was having trouble getting Tensorflow to work with Haskell on a Jupyter Notebook. Thanks to a more relaxed state of mind I managed to dive far deeper into the problem than I normally would have as it didn't stress me out as much. However, I did not actually manage to fix it, and I think it may just be practically impossible due to conflicting version requirements. In a sober state I would have given up sooner, and thus wasted less time.

Thread Thread
drbearhands profile image
DrBearhands

I forgot some details:

  • using is legal where I live
  • I don't smoke so I made brownies, heating butter with weed in a bain marie for 2 hours to ensure an even distribution.
  • Used about 1/4 g, type similar to white widow.
  • I've used weed twice before in my life and tend to have strong reactions to mind-altering substances (alcohol, caffeine, antidepressants, ...)
Collapse
baronbeans profile image
Sean Barnard

I was working on a personal project recently, had been struggling for a few days with something and just could not get it to work.

Had a pretty heavy smoke session with my mates one night and basically went to bed and dreamed about the code I had been staring at for a week... and I spotted the issue.

I woke up and thought "that can't be it, there's no way I can have just dreamed that", but when I turned on my laptop and made the change everything worked as it should!

I'm a strong believer that weed isn't an impairment like some people in this thread are saying, but actually helps me unlock a part of my brain which is very useful in my line of work.

Collapse
francis77198756 profile image
Francis

I see it this way, coding while drinking a beer or smoking weed is the same thing. The premise in my view is that it allows you to take small breaks and relax during the session, increasing productivity. It doesn't make you a better coder, it just helps stay relaxed making you think better and solve issues related to logic faster.

Collapse
gazhayes profile image
G

I don't know if in reality it helps or not, I haven't ever tried to look at this objectively, maybe I should. But it definitely feels like it helps to see things from a different angle, a broader perspective. More of a 'meta' tool to think not only about what approaches to use to solve a particular problem, but also whether that is a legitimate problem or not (maybe there's something I'm missing), and also whether this is the particular problem you should be solving right now - is it actually in the critical path (and the critical path to what)?

Collapse
niorad profile image
Antonio Radovcic

I was gonna write a class, but then I got high.
I was gonna git-rebase, but then I got high.
Now the build is failin' and I know why.
Because I got high.
Because I got high.
Because I got high.

Collapse
n873 profile image
Nathan Joseph Alard

Depends on the strain and amount being consumed: Sativa vs Indica | Micro-dosing vs Macro-dosing

Micro-dosing increases productivity, and motivation while planning, designing and coding.
Environment & personality-type plays major roles when macro-dosing.

Collapse
jwollner5 profile image
John 'BBQ' Wollner

I'm not sure I could code high. I have trouble driving under a mild buz regardless of its cause. To me the case of whether you can or should code under the influence comes down to context. If I'm tinkering on a personal growth project, who cares if it's crap. On the flip side, I would consider it unethical (if not immoral or illegal) to write mission critical solutions with anything less than stone cold sobriety.

Collapse
albertogarrido profile image
Alberto Garrido

I'm not a frecuent user and I've never coded high, although I might try one day in a side project and see what happens. But I wouldn't do it ever on my job. Mostly because it's unpredictable what can happen.

I played challenging videogames (souls, sekiro, cuphead) high and felt that I did better (after later seeing the video) so it might be also good for some coding tasks.

Collapse
elijahbless4 profile image
ElijahBless4

The best for that moment you are stuck in a code.
Helps you to look thing from another perspective and think only in that thing without nothing to worry about.
Its like your personal mind helper.
We are artist we need some extra inspiration sometimes.

Collapse
frenterry profile image
Dwight Horert

Hey. Yeah, sometimes I do this. But I think smoking weed is much more better in free time, for relax. Also it can help against stress and depression. I usually order something interesting in Weed Shop in UK weedzy.co.uk/ there are a lot of different variants to try:) And what about you? What do you like?

Collapse
johnyyy12 profile image
johnyyy12

Hello, if to be sincere, I didn't notice something different if compared to your normal state of mind, the only thing I noticed is the fact that your brain starts to slow down, you feel more relaxed, and it is pretty hard to work in such an atmosphere. You can try some CBD oils, because they have different effects on your health. Actually you can find more on urbanaroma.com/how-to-find-weed-in... . It is one of the best websites related to CBD products, and you can learn a lot of new things here.

Collapse
massiveattack89 profile image
MassiveAttack89

Some times when you are high you can have a nice idea, it's like brain is thinking through another point of view. Most difficult is to save that idea on the next day. I had memory problems for years and because of that lack of focus was also a problem. There are different ways to make it better. baeys.com is a good answer because they are drug free and have cbd oil that works against depression and sleep problems also. Many benefits. You can check YouTube - itโ€™s full of videos about it. Many states open new stores and stuff.

Collapse
jorgecc profile image
Jorge Castro

How politicians demonized it despite scientific evidences, how minorities were targeted by anti-cannabis laws...

I beg to differ.

Cannabis is Russian Roulette and if you are one of the lucky (around 10% of the population), then congratulation, you are screwed your life. And there IS SCIENTIFIC EVIDENCE, so if you say me that there is not a piece of evidence against cannabis then no, there is evidence.

rcpsych.ac.uk/mental-health/parent...

The UK NHS has a long record of this topic with empiric information. However, who cares about the recommendation of a doctor when you could believe the word of a singer, artist or politic?.

btw, I worked on a psychiatric aisle (a short time) and trust me, it is like the game Silent Hill.

  • screams = check.
  • satanic scriptures = check (I'm not kidding).
  • the ambiance is creepy = check (nobody would want to work there).

Some patients are there because of the use of cannabis. How I know?. I worked with the people that have access to the database. The old patient arrived at 197x.

IMHO, let's say you are sick, for example, Cancer, then go ahead, you have nothing to lose. But other than, it is just a vice, it's not cheating, cheating is good if it works but it doesn't work.

Collapse
damcosset profile image
Damien Cosset Author

Please keep the comments related to the question I asked in the article :) Thank you.

NB: I was not making any scientific claims about cannabis. I was simply recapitulating some of the content of the documentary. These are not my views. But I thought I made that clear enough in my article.

Collapse
jorgecc profile image
Jorge Castro

https://www.ccohs.ca/images/products/infographics/download/Cannabis_impairment.png

In short this.

Collapse
robertpoole23t8x profile image
RobertPoole23t8X

I am not sure if we can actually consider cannabis benefiting our health. But I've tried CBD oil, and it helps me during a headache and insomnia. I've tried different medications, but only CBD could help me. The more I read reviews of CBD, the more I feel confident that it actually works, and not just a placebo effect. Now, I only use CBD oil, and I even found some vape pens with CBD oil on knockoutcbd.com and ordered a few samples there. I cannot wait for them to be delivered, and finally, try them.