W.B Storytime

Contributing on open source and a synced client

I'm a member of the WTForms organization that works and maintains the ever popular WTForms in Python land. Most of the use for these forms ends up being in data validation and some rendering to be used on the web in frameworks like Django and Flask.

It is awesome volunteering and helping when I can, mostly addressing some "issues" or rather questions some people might have as to how to use some parts or how to do XYZ. When I have some more time, I've been working on moving some of their tests over to Pytest and getting ready for the soon to be dead but not quite dead yet Python2.7. Oh joy! 

So far I've been meaning to refactor and improve one of the Field validators but haven't had the time to. I'm definitely starting to see how much time maintaining a popular project can become and I'm going to give a nice shoutout to all those motivated developers hacking away making a project better with their contributions. So keep up the great work!

In other news, I finally got my parity client synced up to present time! Its only a sleek 140+ GB chain. The first couple of years of transactions on Ethereum were small and then theres a massive ramp up in transactions and activity as seen by the explosion in chain size. I'm going to see what's possible now that I'm running a full client. Should be very interesting. 

~update : haven't contributed much as I've been swamped with work...

Back into crypto

Been spending more time in the crypto space again. I just spun up a DO droplet to become an Ethereum node. I'm currently using the Parity client and ran into some weird issues with the RPC when synced via 'warp'. Now I'm back on the '--no-warp' flag and downloading 40+GB worth of transactions. Still waiting for it to sync, its been roughly 2 days now.

I'm planning on setting up my own API to be able to query the chain more efficiently. The Infura api is limited by design and lacks some of the standard ETH RPC methods. Might be a fun little reason to get to play with more Rust and Ethereum.

Amigo Courier & Rust

I was born and grew up for roughly half my life (at time of publication) in Guayaquil, Ecuador. There are many unique and wonderful things about Ecuador and its people, but there are far more things which are bad or downright terrible. A number of common everyday things in the U.S are considered non-existing or luxury goods. The concept of "mail" which goes back a millenia or more doesn't really exist there. Commerce is restricted due to lack of infrastructure or the government seeking to control it and tax it.

A common thing for those living outside the U.S is not having access to the myriad number of goods that are readily accesible at the mall, a super-store like Walmart, or even e-commerce. The prices are multiples of what they are in the U.S or they simply don't exist. The question then is, how is it that people get access to these goods then? They essentially wait till a friend or relative is traveling to western Europe or the U.S and purchase things through them. 

I'm still left in awe when I have relatives visiting, all their pent-up demand for shopping is ready to let loose like an overflowing dam. While to me it is "just a boring Walmart" to them it is a wonderful store with extremely low prices and all kinds of products that they have never seen. In some international hubs like Miami, I've seen 100 lb women dragging hundreds of pounds worth of just purchased items in suitcases as they make their way across outlet malls.

To that end, I've launched a simple landing page to see what can be done about this and have a "lean startup" proof of concept here. I've been trying to jump in to using Rust and specifically one of their bigger frameworks called Rocket, so this is the simple site:

Amigo Courier

I've already received some number of signups which is interesting as I've done very little to advertise the page. I've posted in a couple reddit sub-threads for Ecuador, an expat-forum, and ran a $5 ad-campaign in Facebook. The FB ads are an interesting thing to see, I just slapped a random image and some text into what appears to be a nicely formatted ad but I don't think its all that good. I'm going to make another and see how it performs in comparison.

All in all, super excited about playing with Rust and seeing how far this proof of concept goes.

Bulma makeover

Last day or so I ended up revamping this simple site. I was messing around with the blog a week or so ago and ended up placing a script tag in the wrong place. Typical JS-land oversight caused the sight to not load properly, but once it was cached it rendered just fine. This led to me believing everything was good when in fact things were broken. I would have never have noticed it until a nice stranger sent me the heads up. Besides the random act of kindness, I'm still weirded out that I had a greater than 0 viewership for this site.

As for the revamping, I was using bootstrap but moved over to Bulma instead. I'm pretty happy with the transition and the result. I was able to go from a heavy 450kb to a speedy 29kb in size. Font awesome ended up taking a considerable amount of that, so I just went without it.

I'm getting tired of heavy pages and I'm trying to keep things to a minimum here. I could definitely improve performance even more, maybe add Cloudflare as a CDN, but for now its fast enough. As it stands the css/js files are already being served by cloudflare.  

Happy Day of Rebellion

I have definitely not kept up in posting frequently, so its time to stop the laziness! I've been busy working on a white labeling of sorts of an event management/ticketing software Γ  la Eventbrite, Vendini, and others.

I saw a very popular open source project called Attendize which does a great job and presents many if not all the features the aforementioned companies offer.

So of course I planned a "couple" of weeks to ship a project this size with similar features and have it be fully tested, easy right? Well lo and behold the project's time estimate is all wrong and I'm here roughly a month later still cranking away.

The stack roughly is:

  • Flask
  • Python3.7πŸŽ‰πŸŽ‰
  • AWS S3 and Lambda
  • Postgres
  • ReactπŸŽ‰πŸŽ‰
  • Pytest and Jest for tests
  • TravisCI for....CI

Its been an interesting ride so far. For sure my first go around with Jest for some unit testing on JS land. Though its got a ways to go before its as robust as Pytest and some of the batteries that come with Python. 

This has also been a great excuse for me to get to work with Functions As A Service, this new thing trendily with its acronym FaaS. I was able to offload the common use case of resizing the user uploaded images to it as opposed to having a mix of redis + workers on the side somewhere.

One quick tip for Lambda's are to make quick use of print statements to watch the logs from the AWS side as debugging can be quite an issue. Also, if you're hitting your head as to why a function call that should be working and is not go ahead and check on the allotted memory usage per function call. I ran into this issue where some larger images were being passed in and the function would just stop execution upon hitting its low memory limits.

Besides that, Happy Fourth! Its been quite a ways since we rebelled against the British monarchy back in 1776! Shout out to the armed forces like the Marines (and the other branches of course), founded on 1775, in fighting off those red coats!