Chris Padilla/Blog
My passion project! Posts spanning music, art, software, books, and more. Equal parts journal, sketchbook, mixtape, dev diary, and commonplace book.
- You may need to
pip install mysqlclientso that the ORM can pick up your mysql config. - You may also need to download mysql through homebrew.
- Lastly, I think it's helpful to have the MySQL workbench GUI.
- Tolkein's Fellowship of the Ring is going to take me a while, y'all. π So far so good, though. It's very cozy β lots of words dedicated to eating supper.
- Form & Essence: A Guide to Practicing Truth I took an arts admin class with Matt back at UT. Matt is such an amazing embodiment of the servant leader, and this book feels like I'm getting to take the best bits of his class all over again.
- I have a few words written through the Books tag on my blog. My favorite this month: Software is Measurably Valuable Creation
- My friend Thomas Kurtz gave a beautiful recital in Austin! No sound online yet, but all of his recordings are gorgeous.
- The Black Box by aivi & surasshu. An old favorite. I love the mix of classical and chiptune by the composers of Stephen Universe.
- Lumi by Snail's House. Kawaii Future Bass at it's finest.
- Brasilian Skies by Masayoshi Takanaka. The king of City Pop never disappoints. I admit that Star Wars Samba is a favorite track.
- New Ted Lasso is pretty good! The Apple product placement is strong this season. π±
- We're trying out a few others - Shrinking and The Big Door Prize. So far so good!
Barre Chord Improv
Been LOVING this new instrument!
Creative Legacy
Doing creative work gets pitched as this "Exertion of the ego" or "One bold director's vision." Iwata himself said "Creativity, after all, is an expression of the ego."
Allow me to be over 30 and bust out the phrase "But, the older I get...":
The older I get, the more I feel inspired by being tied to a lineage. The more it feels ennobling to be a part of a larger legacy of craft, expression, and plane ol' messing around.
It happens anytime I go to an art museum... like this weekend! We're all moved by an artists' ability to draw expressive strokes on a page, paint a bowl, or carve figurines.
Take that in any creative dimension you want. I have a few more:
Every time I sit down to code, I feel my spirit jumping down into the trenches with many folks I admire. Those spirits that developed video games in the 80s and 90s in Japan, or those developers who programmed the websites I visited as a kid. Or my favorite: my dad β who was always tinkering with custom built PC's while I was growing up.
As a musician, well, there are multiple!! I sat with Bach and Yo-yo Ma while learning the first cello suite on bari sax. (An offensive idea to some, I'm sure, but wildly fun for me!) When I play piano, a range of jazz musicians, classical pianists, and composers sit at the bench next to me.
Lately, my favorite is thinking of Walt Stanchfield, who would "spend an inordinate amount of time at the piano" only to go on and sketch tirelessly. A very personal fit for me, who also is spending his days sketching and banging at the keyboard.
On a grander scale, all of that connects us with generations spanning humanity of people who added flare to simple items and decorated their time with song.
Here's W. A. Matheau's essay on originality:
...You realize that what is "original" essentially rearranges the familiar: the same ancient notes and gestures done over again in meaningful new ways. You realize that only the fingerprints are yours, and that this was true for Beethoven and his fingerprints, and Bird and his. You see how everyone is on the same pilgrimage, and how there is no racing on such a road as this. You desire on thing only: To be a conscientious traveler.
Phew! What a relief! No need to be original. Just authentic. Instead, we're all unique intersections of influences.
While that leads to different sensitivities and different eyes for beauty, we're all united in one way or another to our lineages. And we are continuing the conversation for generations by contributing in the first place.
My voice may not be entirely unique. Instead, I think it's more noble to be the vessel through which so many traditions and eyes for beauty in the world continue on. In that way, we all live on.
New Album β Forest π³
An adventure into the wooded grove π²π
Playing with a few sounds from Ocarina of Time and Chrono Trigger!
Purchase on π€ Bandcamp and Listen on π Spotify or any of your favorite streaming services!
How C# Compiles
I'm taking time to dig into a more enterprise level language. For me, it's a good opportunity to learn from technology that was built to scale so that my work in other languages can be informed by that long term scalability.
Here are some concepts that are important to know before diving into the language:
Compiling
Major C family languages C and C++ are also compiled, but they compile directly to machine code. So there's a limit to what machines the programs can be run on β compiling to windows means no linux support.
C# is compiled, but instead of compiling to machine code, it's brought down to IL code (Intermediate Language.) This actually borrows from Java, famous for the tagline "write once, run anywhere!"
The IL code can then be run on any machine with a the Common Language Runtime (CLR) installed. The CLR will take the IL code and compile it to machine code from there. For C#, the CLR is part of the .NET framework, so any apps developed through .NET have this same flexibility of running on multiple platforms.
JavaScript in the browser is actually an interpreted language. The code is given to browser that take the instructions and executes at runtime.1 Node would be a closer comparison since its compiled. It's passed through the V8 engine which compiles Node code to machine code.
Practice or Play
I hear variations on this quote every now and then. Here's Scott Adam's version of it:
"Practice involves putting your consciousness in suspended animation. Practicing is not living."1
A jarring idea for someone who spends time doing what looks like "practice" on first glance. It goes for all domains β software, music, art, writing, or otherwise.
I thought about my time in school and think about how, largely, your time is spent "practicing" for adulthood. Why did that feel different? Why was there nothing but abundance and joy during that time?
One of my favorite essays from Julia Cameron's "The Artist's Way" has an answer:
βIt must take so much discipline to be an artist,β we are often told by well-meaning people who are not artists but wish they were. What a temptation. What a seduction. Theyβre inviting us to preen before an admiring audience, to act out the image that is so heroic and Spartanβand false...
True, our artist may rise at dawn to greet the typewriter or easel in the morning stillness. But this event has more to do with a childβs love of secret adventure than with ironclad discipline. What other people may view as discipline is actually a play date that we make with our artist child: βIβll meet you at 6:00 A.M. and weβll goof around with that script, painting, sculpture β¦β
Largely when we're kids, we're playing. Kids aren't overly concerned about their futures or the results of where their work will get them. It's just for the joy of exploration and taking on an interesting challenge!
Matt also has a great antidote to this in Form & Essence β it's the difference between doing and being. Are you aiming to get tasks done? Reach a certain destination? Or are you simply being a musician, being an engineer, being an artist.
The difference between practicing and living is the posture. Are you overly worried about results and reaching a continually elusive future, or are you playing?
Julia Cameron again:
Remember that art is process. The process is supposed to be fun. For our purposes, βthe journey is always the only arrivalβ may be interpreted to mean that our creative work is actually our creativity itself at play in the field of time. At the heart of this play is the mystery of joy.
Barley and Board
Faber - Ceremony for Peace
The Faber books have a knack for really stately pieces π
Sorry for the fake out at the end. π Best experienced in a loop!
Connecting SQL with Python
A great deal of data flexibility is made available through MongoDB's aggregations.
When it comes to SQL, that same ability to query and combine data is a first-class process by nature of the language itself.
Combine that with a scripting language like python, and the possibilities continue to open up!
Here are the basics to getting started with passing SQL queries in from Python.
Setting Up
A bit of installing needs to be done first:
To setup mysql on the command line after install, you'll want to login with this command:
$ mysql -u root -pLeaving the password flag blank by default on first login, though this can be changed later.
SQLAlchemy & MySQL Workbench
SQLAlchemy will be the ORM of choice for this post. There are other great options, though I personally chose this because it has first class support in the Pandas method DataFrame.to_sql().
The nice thing about using an ORM is you have access to methods that simplify queries down to a single call.
#Equivalent to 'SELECT * FROM schools'
query = db.select([schools])Sometimes, though, you have to open up the hood and write more intricate queries yourself.
Writing the Script
Ok! The fun part begins!
In an environment variable, set your connection url:
mysql+mysqldb://root:PASSWORD@localhost/DBNAMEAbove I've already created a DB, so I'm skipping that step here. You can programmatically do this through Python and the steps looking similar to create_db_connection below.
We'll pass that url into our create_db_connection method:
from sqlalchemy import create_engine
from sqlalchemy.sql import text
from sqlalchemy.orm import Session
def create_db_connection(url):
connection = None
try:
connection = create_engine(url)
print("MySQL Database Connection Successful π")
except Error as err:
print(f"Error: '{err}'")
return connectionWhile we're at it, let's write our method for executing a query and reading a result:
def execute_query(connection, query):
try:
with connection.connect() as session:
session.execute(query)
print('Query Successful')
except Error as err:
print(f"Error: '{err}")
def read_query(connection, query):
result = None
try:
with connection.connect() as session:
result = session.execute(query)
return result
except Error as err:
print(f"Error: '{err}'")If you'd like to pass in values dynamically, you can use the text module. Here's an example form this article:
from sqlalchemy.sql import text
with engine.connect() as con:
data = ( { "id": 1, "title": "The Hobbit", "primary_author": "Tolkien" },
{ "id": 2, "title": "The Silmarillion", "primary_author": "Tolkien" },
)
statement = text("""INSERT INTO book(id, title, primary_author) VALUES(:id, :title, :primary_author)""")
for line in data:
con.execute(statement, **line)For us, though, a raw string works just as well:
pop_client = """
INSERT INTO client VALUES
(101, 'Starbucks', '123 Cool St., Dallas TX', 'Fast Food'),
(102, 'Cava', '27 Yum Dr., Austin TX', 'Lunch'),
(103, 'Flavor Town', '20 W Good Food Lane, Houston TX', 'Dine In'),
"""One reason to use MySQL workbench here is that it's WAY easier to debug through their console than to do it within our Python program. So, as you're writing queries, I would recommend giving them a whirl in the GUI first.
After confirming the above insert works in the GUI, you can clear it by truncating the table:
TRUNCATE TABLE clientFrom here, it's as easy as calling our methods:
connection = create_db_connection(url)
q1 = text("""
SELECT *
FROM client;
""")
execute_query(connection, pop_client)
results_first = read_query(connection, q1)
for row in results_first:
print(row)Reading and writing, done! From here, the only limits are your SQL savvy and your python chops.
AI as a Synthesis Tool
True artists create in the genre of their time. Sooooo I'm going to write about AI!
Some of the AI demos are pretty impressive!
What I've seen though, mostly, feels like playing those old point-and-click adventure games. You have to keep trying different solutions to a puzzle just to make the game happy. Similar is true with having AI generate content for you.
It's a tool, but it's not quite the "steal your job" kind of automation that's been expected. At least, from a knowledge-work perspective.
Josh Comeau makes a great point at this juncture about tasks v jobs:
My personal belief is that for the most part, working professionals will find ways to integrate this technology into their workflows, increasing their productivity and value. Certain tasks might be delegated to an AI, but not many jobs.
I appreciate that GitHub's AI product is named "Copilot." It seems more fitting and true to the nature of most AI tools. It's not going to do the job for you, but it's a means of getting an idea started or synthesizing information.
Dave and Chris speak to this point on ShopTalk Show (also, my source for Josh's article!) AI seems to be good at synthesizing and expanding on certain points. Generating reports, namely, or summarizing notes.
But, in that sense, blog articles that are only a Google search away can accomplish a similar task.
So maybe that's it. AI is largely a synthesis tool that is only one step removed from the Google "I'm feeling lucky" button of old.
But it still takes a human being to understand context, style, form, and to solve the innumerable problems that take more than a few Google searches.
Does that takeaway from how impressivene or usefull AI is as a tool? I don't think so. AI still unloads the initial effort of sifting through content.
If anything, the fact that AI is not quite a quantum leap in productivity is a testament to how AMAZING our current resources are.
The Haps - April 2023
The sun is coming back out and I am loving it! βοΈ
Blogging & Dev
Fun month of blogging! I'm wrapping it up on researching JavaScript testing and am switching over to SQL.
Tailwind redesign is still kicking at work! We got docker up and running, too! π³
Meetups are great! I had a blast again at React Dallas! If you're in the area, come on out! It's such a great group of folks. β
You can catch up with my tech projects through the Tech tag on my blog.
Music
I released Whiteout this month! Snuck it in right as it started warming up outside.
On a trip up to UNT, I got to wander around my old stomping grounds at the College of Music. It was so rejuvenating to be up there. I lovingly wax nostalgic on the place as "my own Disney World for Music."
I did a few piano recordings while I was there, too! The Bach Prelude in C is my favorite, such a dreamy piece...
You can see what I've shared so far through the Music tag on my blog. I'm also sharing recordings on Instagram.
Drawing
I finished my second AND third sketch books this month! π Dried out my first fine liner! π I'm crossing right through those artistic rights of passage.
I'm just about wrapping up Drawabox with lots of studies on animals. I'm currently on the hunt for resources for studying the human figure next.
You can see what I've made so far through the Art tag on my blog. I'm also sharing drawings on Instagram.
Words and Sounds
π
π§
πΊ
Life
Really grateful for some sunshine and warmth! The end of winter is always pretty tough, and this one felt extra long here in Dallas.
It's mostly been heads down for Miranda and I. My favorite nights this month have been the couple where we've put on some music and drawn together.
The best vibe was when we drew camels and snails while listening to Arooj Aftab! π π«
π
Animal Construction
My favorite studies on animal construction! Lots of sturdy looking body with noodley legs! π
All part of the Drawabox module on animals.
Faber - Wild Flowers
Many Pots Boiling
Focus is a really big deal.
Minimalism is a movement to live with only what's essential, Essentialism and The One Thing, and 4,000 Weeks are books about honing in on only what's most important. Speaking as a former musician, there are even cultural precedents to go all in on whatever you are most passionate about.
But bouncing around and chasing lots of interests is way more fun!
W.A. Mathieu writes beautifully on this in The Listening Book:
It is valuable to have many pots on many burners, and to keep track of the pots and the fires under them. This means that it is good to nurture diverse musical interests with well-defined, coherent projects in which to develop them... On any given day, go for whatever is cooking bestβstir that pot. One's interest boils and cools unpredictably. Don't hassle it. Be responsive to your muse, not controlling. Do what she says. Coherence will come over time.
Call it productive procrastination, if you'd like.
It's what keeps your spirit creating. The important thing in making things is not really the product, it's the process. With too much focus, the process can become heavy. With variety, there's likely always something you'll want to chase after in another craft when the current one simmers down.
For Bowie, it was a dance between painting and songwriting. For me personally, well, I have a lot of options! Drawing, piano, guitar, coding, blogging, writing music. They feed each other beautifully.
If you have one big thing, great! I hope you find time for a bit of exploration, too. Magic happens, there!
The Blue of Distance
I think often about Rebecca Solnit's essay "The Blue of Distance". The full piece is linked there, and deserves a dedicated read for the beautiful illustrations on her theme. The core message is this:
We treat desire as a problem to be solved, address what desire is for and focus on that something and how to acquire it rather than on the nature and the sensation of desire, though often it is the distance between us and the object of desire that fills the space in between with the blue of longing. I wonder sometimes whether with a slight adjustment of perspective it could be cherished as a sensation on its own terms, since it is as inherent to the human condition as blue is to distance? If you can look across the distance without wanting to close it up, if you can own your longing in the same way that you own the beauty of that blue that can never be possessed? For something of this longing will, like the blue of distance, only be relocated, not assuaged, by acquisition and arrival, just as the mountains cease to be blue when you arrive among them and the blue instead tints the next beyond. Somewhere in this is the mystery of why tragedies are more beautiful than comedies and why we take a huge pleasure in the sadness of certain songs and stories. Something is always far away.
Any creative practice is made all the more fulfilling because of this effect. What James P. Carse would call an infinite game, music and illustration and software and writing are all fulfilling because the horizon is always moving. There's not necessarily a mountain to climb so much as there are valleys to explore.
Funnily enough, it's easy to get caught up in reaching the destination anyway. Wanting to finish an album, wanting to be able to draw with a certain technique and style. That's not even considering the external factors - wanting to make X amount of money, have X followers.
After "having arrived" at a few intended destinations, I can wholeheartedly confirm that it's "being en route" that is life-giving.
Matt Hinsley in Form & Essence writes about "The Law of Dynamicism" The idea is that we are always stepping towards the horizon. Matt encapsulates how that distance energizes the work at hand:
I am working right now to write this book... In an earlier time I might have said something like, 'I can't wait to finish this book.'... But the reality is...that reality is. I will be then as I am now. Wherever I go, there I am. Today is my perfect day because I am thinking, learning, feeling, breathing, communicating, deepening. When this book is done, there will be another to write, or perhaps a different sort of adventure altogether. But what that is, is insignificant. It will be only another marker along the path in my lifetime of glorious dynamic consciousness.
Ren'Py v Making a Game with React
Have you ever wanted to make a game? Is it a visual novel?! You could do what I did and use web tech to build the game from scratch. OR you could use Ren'py!
We made AC New Muder in React, Node, and Sanity. I learned a TON, and I'm a better developer for having done it!
But, I am tempted to daydream about what it would have been like to lean on an actual game making tool.
As far as I can tell, you barely even need to know Python to get started! Here's what a script looks like from the docs:
define s = Character('Sylvie', color="#c8ffc8")
define m = Character('Me', color="#c8c8ff")
label start:
s "Hi there! How was class?"
m "Good..."
"I can't bring myself to admit that it all went in one ear and out the other."
s "Are you going home now? Wanna walk back with me?"
m "Sure!"We actually considered using this at the start. What stopped us ultimately though was flexibility. I think an interactive map, item storage, and health were not a part of the scope of a tool like this.
AND, we wanted it to be on the web!! Ren'py has great Windows support, potentially less Mac support. For our case: having to download a game like this, launching it on Steam β that would be complicated since our game is based on Nintendo's characters. We wanted an early 2000's flash games feel. We both have a VERY soft spot for those games!
So, it's nice to dream. Maybe next time! But I'm really grateful we used the web platform.








