IndyWatch Education Feed Archiver

Go Back:30 Days | 7 Days | 2 Days | 1 Day

IndyWatch Education Feed Today.

Go Forward:1 Day | 2 Days | 7 Days | 30 Days

IndyWatch Education Feed was generated at Community Resources IndyWatch.

Wednesday, 07 November

22:16

Whats the Document Object Model, and why you should know how to use it. "IndyWatch Feed Education"

The DOM explained by an easy way. Photo by Remi Yuan on Unsplash

So, youve studied HTML, youve created your first tags, learned about CSS, made beautiful forms, amazing buttons, responsive pages and have started to show everyone how amazing all that was.

But then you decide that you want to take another step in your learning, and youve started wonder to yourself: How can I add animation to my page? I wish that button made some animation on my page when I clicked it!

Well, thats where the DOM comes to solve your problem. Youve probably heard a lot about it, but you might not know yet what is it and what problems it solves. So lets dig in.

So, whats the DOM?

Do you know all those cool animations that you see around, that make you think to yourself, Wow, I wish I could make something like that? All of those animations are made by manipulating the DOM. I will now explain to you how to start manipulating it and making your websites look cooler.

The DOM (Document Object Model) is an interface that represents how your HTML and XML documents are read by the browser. It allows a language (JavaScript) to manipulate, structure, and style your website. After the browser reads your HTML document, it creates a representational tree called the Document Object Model and defines how that tree can be accessed.

Advantages

By manipulating the DOM, you have infinite possibilities. You can create applications that update the data of the page without needing a refresh. Also, you can create applications that are customizable by the user and then change the layout of the page without a refresh. You can drag, move, and delete elements.

As I said, you have infinite possibilitiesyou just need to use your creativity.

Representation by the browser

The representational tree that the browser create after it read your document.

In the image above, we can see the representational tree and how it is created by the browser. In this example, we have four important elements that youre gonna see a lot:

  1. Document: It treats all the HTML documents.
  2. Elements: All the tags that are inside your HTML or XML turn into a DOM element.
  3. Text: All the tags content.
  4. Attributes: All the attributes from a specific HTML el...

21:57

How a lost kid went from failure to iOS developer against all the odds "IndyWatch Feed Education"

Before I decided to pick up coding, I shot 44% from 3 point range my senior year playing Division III basketball.

Let me start by briefly stating my background. I graduated high school in 2012 knowing two things for certain: I wanted to play college basketball and I had no idea what I wanted to study in college.

Fortunately enough, I went on to college lucky enough to be given the chance to play college basketball with my mind made up that I was going to study psychology. I did and still do enjoy picking peoples brains and trying to understand what motivates one individual to behave the way they do.

But thats not the whole story.

The Best of Times

Fast forward to May 2017 and suddenly I was preparing to receive my bachelors degree from a small school in the northern part of Illinois. As soon as I was handed that overrated piece of carbon copy I immediately realized that my days of getting by as a student-athlete had come to an abrupt halt. What was I to do now?

While I had a small feeling of accomplishment from obtaining a college diploma, it was already beginning to wane. I had NO idea what my next move was.

If I wanted to pursue a lucrative profession in my field of study I knew I would have to do at least two more years of school. That was not an option. I was completely burned out by my sophomore year of college, that the only thing that kept me enrolled and attending classes was basketball. I had to get decent grades if I wanted to continue to play. But I never really thought about the long game after basketball once school was over.

It wasnt until I was driving back home after graduation that I discovered something I might actually be interested in pursuing: making mobile apps. I dont remember the exact train of thought I was in that made me decide I wanted to make mobile apps. I believe I was just scrolling on my iPhone through some app and the idea just popped in my head, This app sure is convenient! Wait can I make my own app?.

Sure enough, after hours of research, I determined indeed I could create my own apps (without needing any type of degree). After some deep thought I decided that I wanted to give it a shot and learn mobile development to see if I could make it my profession. But the first thing I needed to ask myself before I started coding was what tools did I need in order to start creating mobile apps.

The Beginning of the End

There were three things I quickly realized I needed: a computer, the ability to code, and the platform I wanted to build on....

19:10

Whats new on Coursera for Business October 2018 "IndyWatch Feed Education"

October was a banner month for content on Coursera: we released over 65 new courses across a range of subjects, from Sports Marketing to Private Equity and Venture Capital, Handheld AR App Development, and an entire Big Data specialization in Spanish.

Here are our top picks for October:

18:38

How to start using C++ code in your Android project "IndyWatch Feed Education"

Last year I gave a talk at the GDG DevFest in Ankara, Turkey. I have been planning to share that talk here ever since. Now that Im a PhD candidate and have a bit more time, Im putting the post down here.

If you would like to get the presentation, its available on my drive.

Warm Up

I would like to start by explaining the build process of an app in Android. Because you need to know some basic internal stuff, this topic is somewhat technical.

You dont need to know everything shown in the image abovebut its a good reference.

Now say that you write an application for Android using Java. Youre going to have:

  • the source code for that application
  • some sort of resource files (like images or xml files for the arrangement of the GUI)
  • and perhaps some AIDL files, which are Java interfaces that make processes talk to each other.

Youre probably also going to use additional libraries and their related files in your project.

When building a working app, you first compile those source codes together. A compiler will yield a DEX file which then can be read by a virtual machine. This machine-readable file and some additional information about the app will be packaged together by a package manager. The final packagecalled an APK packageis the final app.

This is the build process of an Android package in the simplest terms.

Android Run Time

Now lets talk about the run time stuff. You have an app, and when it starts running its read by a machine. Android has two kinds of virtual machines to run an app. I wont introduce the old one, called Dalvik, as today most Android devices run a virtual machine called Android Run Time, ARTso thats what well talk about here.

ART is a just-in-time (JIT) virtual machine. So, what does that mean? Let me explain. When your app starts running for the first time, its code is compiled to machine code which can then be read by the real machine. This means that the code isnt compiled part by part at run time. This enhances the install time of the app while reducing the battery usage.

In sum, you write an app then compile it to binary code which is read by the ART. Then the ART converts that code to native code which can be read by the device itself.

ART & C++

...

17:45

The tools and resources that landed me a front-end developer job "IndyWatch Feed Education"

Learning front-end development can be a bit overwhelming at times. There are so many resources and tools, and so little time. What should you pick? And what should you focus on?

In my previous article How I switched careers and got a developer job in 10 months, I talked about my journey. I was an English teacher with no related experience, and I managed to land a front-end developer job in a Madrid startup.

In this article, I would like to dive deep into the resources and tools that I used to get there.

We will visit the courses I took, see their pros and cons. And talk about the projects I made with them. Then well have a detailed tour around all the other cornerstones of succeeding on this journey. Things like using GitHub, building a portfolio, and staying motivated.

What to study and where?

I sat in front of the screen staring at an image of the sun. I wanted to scream, laugh, and cry all at once. This was not any image of the sun, this was an image that I had just pulled from the NASA database! I had finally managed it after what seemed like forever trying to figure out how to use the NASA API. I felt like a top hacker, I will soon be able to control traffic lights!

In fact, I was nowhere near controlling traffic lights, and I still am not. But what I didnt know at that moment was that I was only days away from getting a real job offer.

Sun Image source: NASA Image and Video Library

So how does someone go from no knowledge in front-end development to a job in the field? What do you have to study and where do you do it?

When I first started learning, this was one of my biggest concerns. My time was precious and I needed to invest it in the best way possible. I get asked this question all the time, especially by my Twitter community. This is something that beginners always worry about.

It may come as a surprise to many, but I would pick this as the least important factor out of the entire process of career change. Its not as decisive as it may seem at first.

You will learn and get better at this no matter what you use, as long as you are persistent, and remain motivated.

Dont get me wrong, there are sub-level courses out there and others that are great. And finding out the right path to learn all the skills necessary is very important.

Yet, even the best laid out path and the greatest course would be of no use if you lose...

Go Back:30 Days | 7 Days | 2 Days | 1 Day

IndyWatch Education Feed Today.

Go Forward:1 Day | 2 Days | 7 Days | 30 Days

Tuesday, 06 November

20:19

Information Systems Specialization: Q&A with Dr. Soumya Sen "IndyWatch Feed Education"

The University of Minnesota is one of the founding schools for the Management Information Systems (MIS) discipline and is home to the MIS Quarterly, one of the top academic journals in the field. Teaching the Information Systems Specialization is Assistant Professor Soumya Sen from the Department of Information & Decision Sciences in the Carlson School of Management. Soumyas research takes a multi-disciplinary approach involving computer networks, economics, and human-computer interaction, and his work has won multiple recognitions and awards, among which include the BITSAA 30 under 30 Award and the INFORMS ISS Design Science Award.  Read on to discover how IT infrastructure impacts business success and what you can learn from this Specialization.

What is Information Systems?

Information Systems are software processes and hardware systems that help businesses collect, organize, store, filter, generate, and distribute information. These include a range of technologies, such as cloud computing, web communications, enterprise systems, security systems, network communications, and data analytics. Together these processes support operations, facilitate communication, and improve decision-making. And these are essential for any business today to compete effectively in the digital world.

What excites you about Information Systems?

The topic of IT Infrastructure and emerging trends is the most exciting for me. Thats because the success of any business today is critically dependent on the digital infrastructure it operates on and how innovative it is in applying information technology to gain competitive advantage in the market. From retail to healthcare to banking, each domain is undergoing a digital transformation with technologies like mobile, cloud, blockchains, and analytics, while struggling to keep its infrastructure secure and robust. The most successful executives and managers will be those who understand the underlying technology well enough to use them effectively and innovatively in their respective domains.

Why was this Specialization created?

Today most executives are wary of digital disruption of their business, and they would rather be the disruptors themselves. But...

05:43

6 Week Challenge Mid-Point Weigh-in: Despair "IndyWatch Feed Education"

Oof.

We had our midpoint weigh-in tonight, meaning weve been at it three weeks and have three more weeks to go. I was so excited as Ive been feeling well, my clothes are fitting differently and I felt like Ive been doing really well. I was sure Id be at least halfway to my (or, the challenges) goal of 6% body fat lost in six weeks.

I lost 1% body fat.

Normally I wouldnt be disappointed about that at all. I lost body fat! And Ive lost over five pounds. But if Ive lost 1% body fat, that means I need to lose another 5% in the next three weeks in order to get my $500 back.

Also, with the weight Ive lost and the adjusted body fat percentage, that means Ive lost 5.2 lbs, of which 3.3 lbs has been fat and 1.9 lbs has been muscle. Three weeks of intense HIIT workouts to lose 1.9 lbs of muscle. I could cry (actually Ive been crying most of the evening).

This feels awful. I feel the danger here of falling into a disordered eating trap (Im still confident I wont as Im pretty well set up in that regard), and I also feel like Ive already lost the $500 so why even bother with the rest of the challenge?

Truthfully I dont even have that $500 to lose. I took it from a spot I should not have. I was just so determined that I could follow the plan and give it my all, and Ive done just that. Why should I be penalized for the plan not working to the organizers own requirement?

I do like her and I think her gym is good, for workouts. But if I lose my $500 I will most definitely be posting everywhere possible online about this challenge. And yes, if that happens Ill be editing these posts to give the name of the business and trainer.

Tonight I feel like a failure at everything and have lost all motivation to do anything exercise meal prep write Ugh.

04:44

How you can go wrong with Gitand what to do instead. "IndyWatch Feed Education"

How you can go wrong with Gitand what to do instead.

red Wrong Way signage on road by NeONBRAND on Unsplash

I am not able to commit to the remote repository, let me do a force push.

Let me run rebase on the remote repository, to make the commit history neater.

Let me amend my previous commit which is in the remote repository.

The points mentioned above are some of the things to avoid doing in Git. 

In my previous posts I covered Git basics and Git amend and rebase. Click on the links to know more about them.

Git has amazing features and is very helpful for developers. But mistakes still happen while using Git. Here I will be mentioning some of the things to avoid while using Git and also explain why you should avoid them.

Force push to remote repository

Photo by Tim Mossholder on Unsplash

Lets say two developers are working on a single branch. Developer 2 is a beginner to Git.

  1. Developer 1 has finished their changes and pushed the code to the remote repository.
  2. Now Developer 2 has finished their changes, but is unable to push the code to the remote repository.
  3. Developer 2 does a quick google search and finds out about force push command and uses it. The command is git push -f
  4. Developer 1 checks the remote repository only to find out the code they wrote has completely disappeared.

This is because force push overrides the code in the remote repository and, hence, the existing code in remote repository gets lost.

Ideal way of handling this scenario

Developer 2 needs to pull the latest code changes from the remote repository and rebase the code changes into the local repository. Once the rebase is done successfully, Developer 2 can push the code into the Remote repository. Here we are talking about rebase from remote to local repo in the same branch.

Avoid force push unless absolutely necessary. Use it only as a last r...

02:59

How to Create Generative Art In Less Than 100 Lines Of Code "IndyWatch Feed Education"

Generative art, like any programming topic, can be intimidating if youve never tried it before. Ive always been interested in it because I love finding new ways that programming can be utilized creatively. Furthermore, I think anyone can appreciate the concept of artwork that literally creates itself.

Labeled for reuse from Pexels

What is generative art?

Generative art is the output of a system that makes its own decisions about the piece, rather than a human. The system could be as simple as a single Python program, as long as it has rules and some aspect of randomness.

With programming, its pretty straightforward to come up with rules and constraints. Thats all conditional statements are. Having said that, finding ways to make these rules create something interesting can be tricky.

Conways Game of Life (Labeled for reuse)

The Game of Life is a famous set of four simple rules that determine the birth and death of each cell in the system. Each of the rules play a part in advancing the system through each generation. Although the rules are simple and easy to understand, complex patterns quickly begin to emerge and ultimately form fascinating results.

Rules may be responsible for creating the foundation of something interesting, but even something as exciting as Conways Game of Life is predictable. Since the four rules are the determining factors for each generation, the way to produce unforeseeable results is to introduce randomization at the starting state of the cells. Beginning with a random matrix will make each execution unique without needing to change the rules.

The best examples of generative art are the ones that find a combination of predictability and randomness in order to create something interesting that is also statistically irreproducible.

Why should you try it?

Not all side projects are created equal, and generative art may not be something youre inclined to spend time on. If you decide to work on a project however, then you can expect these benefits:

  • ExperienceGenerative art is just another opportunity to hone some new and old skills. It can serve as a gateway to practicing concepts like algorithms, data structures, and even new languages.
  • Tangible ResultsIn the programming world we rarely get to see any thing physical come out of our efforts, or at least I dont. Right now I have a few posters in my living room di...

01:57

What gets logged in the console when youre mutating objects "IndyWatch Feed Education"

A lot of developers are not using a debugger while developing. Instead they are relying on their old friend console.log().

It is important to note that the console shows the objects value which is evaluated at the time of the first expansion in the console.

First, let me clarify what I mean by expansion. When we console.log an object (which covers arrays also), the objects value is collapsed. For example:

console.log( "users: ", [{name: "John"}]);

The browsers console will look like this:

Then, when you click on the triangle, the object expands. At that exact time, the objects value is evaluated and displayed.

Let's dive more into this and check out an example:

https://medium.com/media/d3a38b2d14591e722922a3b751c33ac7/href

On line 1 we are initializing a new users variable, which is an array of objects.

On line 6 we are writing the value of the users variable to the console.

Next, we iterate through users, check if the user is valid, and depending on the return, we disable the user. For the sake of argument, let's assume the validateUser()returns false and code on line 10 is executed.

Even though map is creating a new array, changing the user object is also changing the user object in the users array. It changes because it has the same reference. (For a better explanation of whats happening, check out this article ).

The question is: what will be shown in the console which is called on line 6?

When we open this example in Chrome and Firefox, the object is collapsed. Then upon expansion, we see the values:

Enabled is set to false, even though the value was true at the time of the output. The reason behind this is that the objects value is evaluated the first time when we click to expand the object (lazy read).

Note: Chrome will show an info icon which states: Value below was evaluated just now.

Lets now take a look at Safari:

Hm, enabled is set to true. So we can see...

01:26

How to add Ionicons to your Angular 6 apps "IndyWatch Feed Education"

Ionicons and Angular

I have had to work on a lot of Angular apps recently and Font Awesome has literally tired me out. So I decided to use Ionicons off the popular Ionic framework.

This post shows how to set up Ionicons on your Angular project. We will take the following steps:

  • Install Angular CLI v6
  • Create a new Angular v6 app
  • Install Ionicons
  • Setup Ionicons for use on your Angular v6 app

Install Angular CLI v6

npm install -g @angular/cli@latest

Create a new Angular v6 app

At this point, you have installed the Angular CLI globally on your PC. Now you get to create a new Angular app. We use the ng new name-of-my-incredible-app command, it allows us to create an Angular application.

ng new my-ionicons-angular-app --style=scss

The SCSS bit is there to allow us to use SCSS. This takes a bit. When it is done, we then navigate to the newly created app.

cd my-ionicons-angular-app

As soon as we are in the project directory, we can then start the development server.

ng serve

This returns the following:

** Angular Live Development Server is listening on localhost:4200, open your browser on http://localhost:4200/ **

Running the URL http://localhost:4200/ shows you your brand new app. If you see the screen below. You are good to go.

Default Angular Homepage

Install Ionicons

Like we did earlier, we use npm again to install Ionicons.

npm install ionicons

Setup Ionicons for use on your Angular v6 app

As soon as it installs, we need to tell angular where and how to load it. Best way to do it is inside our styles.scss file and you do this by adding the following lines:

$ionicons-font-path: "~ionicons/dist/fonts...

01:21

How I Discovered that C# SortedList Uses Binary Search, and Why You Should Care "IndyWatch Feed Education"

There is an age old debate: can programmers make do with just knowing how to code? Or do they need to understand some of their framework internals, basic data structures, and search/sort algorithms?

I have encountered many bugs created by being unaware of how hash tables are implemented. Or by a minor overlook which would have been a complete mystery to someone who didnt know a binary search even existed. So you may guess that Im of the opinion that you must have basic data structures/algorithms knowledge. I hope after reading this you will agree with mebut if not, you may leave your disagreements in the comment section below.

System Overview

Imagine a system of customer service reps, where each user writes notes for tracking actions and conversations with clients. If the note requires future action, the user can add a due date for a specific date and time, and it becomes a task. At any point, the user can mark the task as done and the task will be removed while remaining in the list of notes.

For easy access, all the notes are displayed in a descending order by insert date (oldest note first). Tasks are displayed in ascending order by due date (upcoming/overdue tasks first).

https://medium.com/media/65eba3ee2f07c1688747c6317ed2ee82/href

Implementation

Lets start with the Note class definition:

https://medium.com/media/4a8d66291a4f8b6cc18f35ba82163472/href

Its a simple data object.

Next, well create a NotesManager class which holds all the notes/tasks and manages access to them:

https://medium.com/media/3d47ac7f0d595eb08d7c1f25d2475e14/href

The NotesManager class uses a SortedList to keep the Notes/Tasks in t...

01:07

How to set up Google Sign In SDK with Swift for iOS "IndyWatch Feed Education"

This post is a clearer explanation of the implementation presented in the Google Developer tutorial. The Google tutorial recommends you to use pod, however, I dont like to use podI want more freedom. So, this tutorial installs and sets the SDK manually.

The Google tutorial wrote their sample project in Objective-C. At the end of this post, you can find a sample project written in Swift.

Lets start

When you download the SDK youre going to see the following files and folders:

  • CHANGELOG.md
  • GoogleAppUtilities.framework
  • GoogleSignIn.bundle
  • GoogleSignIn.framework
  • GoogleSignInDependencies.framework
  • GoogleSymbolUtilities.framework
  • README.md
  • Sample: This is a sample project written in Objective-C.

Now create a project using Xcode. Were going to link all necessary frameworks to it. Put the frameworks located in the SDK folder anywhere you want. I prefer collecting all the libraries in a folder called Library under my main Projects folder.

Open your project and go to Build Settings. Enter the path where your frameworks are located.

Next copy the GoogleSignIn.bundle file by drag-dropping into the project. You have to drag and drop the frameworks too but do not copy them.

We need two more frameworks: Safari Services and System Configuration. Apple provides them. You can link them in the Build Phases > Link Binary with Libraries.

The last thing you should do in this part is to add a linker flag. Add the flag below in Build Settings > Other Linker Flags:

$(OTHER_LDFLAGS) -ObjC

Configuration File

Its time for getting a configuration file for your project. You should start an app in the Google Developer page. However, youll not copy the configuration file. Ins...

00:29

How to monitor network changes using Redux Saga in React Native "IndyWatch Feed Education"

Image CreditUnspash

Why should I use Redux Saga to monitor Network Changes?

Image CreditImgFlip

Redux Saga is an alternate side effect model for redux apps. It is easier to manage, execute, test and catch errors.

Rather than implementing the logic to manage the network state in your react component, the side-effects should be handled separately. Redux Saga provides us with eventChannel as an out of the box solution for handling such cases.

What is an Event Channel?

Image CreditsUnspash

Redux Saga consists of eventChannels to communicate between external events and sagas as a factory function. The events are from the event sources other than the redux store.

Heres a basic example from the docs:

import { eventChannel } from 'redux-saga'
function countdown(secs) {
return eventChannel(emitter => {
const iv = setInterval(() => {
secs -= 1
if (secs > 0) {
emitter(secs)
} else {
// this causes the channel to close
emitter(END)
}
}, 1000);
return () => {
clearInterval(iv)
}
}
)
}

Things to note:

  • The first argument of the eventChannel is a listener function.
  • The return method is the unregister listener function.

Emitter initializes the listener once after which all the events from the listener are passed to the emitter function by invoking it.

How should I hook up Redux Sagas Event Channel with React Natives Network(NetInfo) API?

The React Natives NetInfo isConnected API asynchronously fetches a boolean which determines whether the device is online or offline.

Dive into the code

Image CreditUnsplash

First, we need to cre...

00:25

Searching for rivers in Unterfranken: how to use Elasticsearch to find features on a map "IndyWatch Feed Education"

Photo by Julien Lanoy on Unsplash

One of the great things about working remotely is that I can work from wherever I want to. So, this month I have swapped my city desk in London for one in the spa town of Bad Kissingen, Germany.

Ive also had fun building search engines with Elasticsearch. In this post, Im going to explore how it can be used to search for features on a map.

Search indices

Sitting here at my new desk, Im leafing through an old textbook. At the back, there is an index. It tells me on which pages certain keywords appear. So, if I want to read about something specific I can find the relevant page numbers quickly. Without the index, I would have to scan through all the pages of the book to find what Im interested in.

Similarly, when we search for things on the internetalthough we may not be aware of itwe are, likely, also using a (more sophisticated) index to make our search fast. We put questions to the index and get answers back. More accurately, with regard to Elasticsearch, we query the index by sending RESTful API requests, in the form of JSON. Results are returned.

The JSON family

JSON is a commonly used format for giving structure to data. Put simply, it expresses data as groups of name/value pairs, in a text string. For example:

{
"city": "Erlangen",
"country": "Germany"
},
{
"city": "Wrzburg",
"country": "Germany"
}

Minified, our example looks like this:

{"city":"Erlangen","country":"Germany"},{"city":"Wrzburg","country":"Germany"}

Often we are concerned with indexing fields of data, like a product record, or full text, like a blog post. Elasticsearch handles these very well. It can also index spatial data: map features, such as locations and boundaries. We use a special kind of JSON to describe map features, called GeoJSON. It looks like this:

{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [49.792762, 9.939119]
},
"properties": {
"city": "Wrzburg",
"country": "Germany"
}
}

A geometry type may be a: Point, LineString, or Polygon. There are multi types for these:...

Monday, 05 November

22:58

How to build a web app using Pythons Flask and Google App Engine "IndyWatch Feed Education"

A small tutorial project for learning Flask, APIs, and Google App Engine for beginners

If you want to build web apps in a very short amount of time using Python, then Flask is a fantastic option.

Flask is a small and powerful web framework (also known as microframework). It is also very easy to learn and simple to code. Based on my personal experience, it was easy to start as a beginner.

Before this project, my knowledge of Python was mostly limited to Data Science. Yet, I was able to build this app and create this tutorial in just a few hours.

In this tutorial, Ill show you how to build a simple weather app with some dynamic content using an API. This tutorial is a great starting point for beginners. You will learn to build dynamic content from APIs and deploying it on Google Cloud.

The end product can be viewed here.

This tutorial will also cover: (1) basic CSS design, (2) basic HTML with Jinja, and (3) deploying a Flask app on Google Cloud.

The steps well take are listed below:

  • Step 0: Installing Flask (this tutorial doesnt cover Python and PIP installation)
  • Step 1: Building the App structure
  • Step 2: Creating the Main App code with the API request
  • Step 3: Creating the 2 pages for the App (Main and Result) with Jinja, HTML, and CSS
  • Step 4: Deploying and testing on your local laptop
  • Step 5: Deploying on Google Cloud.

Step 0Installing Flask and the libraries we will use in a virtual environment.

Well build this project using a virtual environm...

22:51

The Riddle of Sphinx: How to Document Your Code Easily "IndyWatch Feed Education"

Photo by Daniel H. Tong on Unsplash

Why Am I Here?

You, the reader, are here because you wrote some awesome tool in Python, and you want to make it accessible and easy to use.

I, the writer, am here because I was right where you are a few months ago. I wanted to use the Sphinx package to make a ReadTheDocs-style documentation for my project.

I found the onboarding of Sphinx nontrivial, which is why I made this GitHub repo that can be used as a template for your project.

Before we start, some basic assumptions, to make sure we are on the same page:

  • You are writing in Python.
  • You wrote docstrings for the pieces of code you wish to document.
  • Your goal is to make a ReadTheDocs-style documentation that, at least partially, will automagically generate itself.
  • You are aware that in 10 minutes you could publish the first version of your documentation, that is going to look something like this:

Part 1 - Setting the Stage

  • Install Sphinx: pip install sphinx
  • Go to github.com/DalyaG/Sphinx185:
  • Download the folder documentation_template_for_your_next_project
  • Copy to your project
  • Rename the folder documentation

Part 2 - Personalize

  • Open the file /documentation/conf.py in your favorite editor. Search for the pattern #CHNAGEME# and follow the instructions.
  • Similarly, edit the file /documentation/index.rst and follow the inline instructions.
...

22:46

The Most Important Non-Programming Skills for Programmers "IndyWatch Feed Education"

The most important non-programming skills for programmers

When I think about the people I would like to work with as a programmer, I think so much more about the non-technical skills rather than technical skills that make somebody a good co-worker.

In fact, all of the skills that are in this post contribute to writing good code that improves technical projects. Most of them are really helpful for careers outside of programming too, but Im going to focus on why theyre useful for programmers specifically.

Empathy

To build a great product, you must put yourself in the shoes of your users. How will they be using your product? What features will be helpful for them? How can your program help them or improve their lives? Andconverselyhow could it harm them or negatively impact their lives? What are the ethical implications of your application?

Empathy is essential for so many pieces of your programs. If they arent secure, then your users information could be used negatively by a third party.

If they arent accessible, then you are limiting the number of people that can use your project. If they run slowly or needs huge amounts of bandwidth to run, then users will leave and people in areas with slow internet or mobile users wont be able to run them.

It seems like every day an article comes out with some harmful algorithm a company has implemented, like the YouTube algorithm radicalizing the alt-right, Amazon creating a sexist hiring algorithm (which they didnt end up using), or AI misgendering black women. Think about everybody when you are writing your code!

Also, empathy is helpful for being a team member and a mentor. Put yourself in your manager or another developers shoes. Why are they making their decisions? What can you do to help them? Having empathy will definitely improve your ability to be an effective teammate. If youre an employer, you can retain your employees for longer, and they will be more effective workers if you display empathy (source).

Have patience for other programmers, especially ones that are learning new things. Remind yourself of something that was really hard for you to learn and how that felt. They probably feel similarly. Being rude to them, diminishing their progress, or being pedantic...

22:38

How to make realtime SoundCloud Waveforms in React Native "IndyWatch Feed Education"

Image CreditsUnsplash

Introduction

SoundCloud is a music and podcast streaming platform for listening to millions of authentic tracks. They have a really interactive interface for playing / listening to the tracks.

The most important feature in their interface is showing the progress of the track based on its frequency waveform. This helps the users to identify the nature of it.

They also have a blog post which describes how to use the waveform based on its image. It is hard to use the same techniques to generate the waveform in a React Native app. Their Waveform.js SDK translates a waveform into floating points to render on an HTML5 canvas and is currently no longer operational.

In this article well discuss how to use the same waveform for our React Native apps.

Why Should I use SoundClouds Waveforms?

Image CreditsKnowYourMeme
  • The SoundClouds waveform looks more impressive than the old boring way of showing the progress bar.
  • The pre-loaded waveform will give the user an idea of the different frequencies present in the song.
  • It is also much easier to show the buffered track percentage on a waveform rather than showing it on a blank progress bar.

Lets learn more about SoundClouds Waveforms

Image CreditsBackstage Blog by SoundCloud Developers

The SoundCloud provides a waveform_url in its tracks API.

  • Each track has its own unique waveform_url .
  • The waveform_url contains a link to the image hoisted over the cloud.

Examplehttps://w1.sndcdn.com/PP3Eb34ToNki_m.png

Image CreditsSoundClouds waveform for the track MegadethSweating Bullets by...

IndyWatch Education Feed Archiver

Go Back:30 Days | 7 Days | 2 Days | 1 Day

IndyWatch Education Feed Today.

Go Forward:1 Day | 2 Days | 7 Days | 30 Days

IndyWatch Education Feed was generated at Community Resources IndyWatch.

Resource generated at IndyWatch using aliasfeed and rawdog