ULOG 004 - Code freeze

in #ulog6 years ago

I'm starting to find it hard to write a daily #ulog, on weekdays, every day is like a copy/paste from the previous day lol. As the World Cup kick-off is happening tomorrow night, my company is now under code-freeze. We cannot deploy new features or changes unless they are fixes for critical issues. Tomorrow, some of us will not be coming to work, taking on some sleep time in order to work on their night shifts. My turn will be starting this Saturday with a shift starting at 3 am.

I will try to wake up one hour earlier every day from tomorrow, that is if I manage to sleep early tonight, it's not going to be easy for me as I'm more of a night owl. The alternate solution would be to stay awake overnight on Saturday and sleep during the day.

How does a bot look like?

So I'm a developer per trade, my life is surrounded by programming code and application logs 🤣. For those curious about what a bot looks like, here is a little preview of its code. This is a small piece of code from @teamvn, the community bot I'm building for the Vietnamese community. This piece of code is using @steemsql service from @arcange that has indexed the content of the Steem blockchain into a SQL Server database allowing me to make complex search queries more easily and faster than if I had to read the blockchain directly. It is a paid service (10 SBD per month) but it's worth every cents as it makes my life so much easier.

Screen Shot 2018-06-13 at 6.06.09 pm.png

This piece of code, queries Steem SQL and requests the most recent post of each member of the bot's upvote list. For each of those posts, it will check whether or not it meets the minimum of 200 words and start checking if it has been previously voted on.

Sneak peak at a witness server

I'm currently testing a new setup for a witness node and a seed node. This new setup will allow me to continue running a witness node and also launch a seed node (that will broadcast blocks to other witness servers) without burning my bank account while I'm climbing up the witness ranks. If you want to support me, head to the link below, scroll down, in the first text input, type my name quochuy and click on the Vote button, my name will appear below the text input.

DO NOT click on anything else.

Screen Shot 2018-06-13 at 6.29.07 pm.png

Ever wondered how a witness server looks like under the hood? Well, I can't show you the whole code for the software and all the stuffs running on the server, but this is what Steemd, the software that does the witnessing work, outputs when it is running, receiving blocks and generating them.

Screen Shot 2018-06-13 at 6.19.16 pm.png

In the screenshot above, what you are seeing are events received by my witness server, they are mainly the reception of blocks signed by other witnesses (most of them from the top 20) that Steemd has to add to its local copy of the Steem blockchain.

So each line is for one block. The information that is of interest is on the right handside, for example:
Got 30 transactions on block 23280739 by ausbitbank

That line tells me that I have received one block from @ausbitbank, the block is identified by the number 23280739 and contains 30 transactions (posts, comments, upvotes, transfers etc...) from other Steemians. And if you want to see what is inside that specific block, check this link from SteemDB:
https://steemdb.com/block/23280739

Screen Shot 2018-06-13 at 6.24.00 pm.png

That's it, a little glimpse onto the technical aspect of my life 😆. See you tomorrow if I'm not running out of ideas


Related content


 Do more on Steem
quochuy.jpgOn Steem, Witnesses are playing the important role of providing a performant and safe network for all of us. You have the power to choose 30 trusty witnesses to package transactions and sign the blocks that will go in the Steem blockchain. Vote for me via SteemConnect to help me do more useful projects for the community.
Join me on Homesteaders Online's Discord
If you are Australian (even abroad), join #teamaustralia!

Credits

  • The image at the top has been generated with the Canva app using my own photo.

Protect your money against Phishing Scam!

Cryptos accounts are the target of international scammers because they want your hard earned money!

Those people are very clever and in a moment of inattention, you've given them your login and password!

I've created a Chrome extension that can help you detecting scam links!

Install Steemed Phish Chrome desktop browser extension now!

Password and Private Keys security

You all know that your Steem password is the access to all your STEEM, SBD, posting, transferring, everything... right?
So, please, follow those simple steps and keep yourself safe:

  1. Apart from the initial setup of your account, NEVER use your password ANYWHERE, if stolen, it will give full control to your Steem account.
  2. Backup your password and keep it somewhere safe. Use a password manager like Lastpass, print it on paper and put it in a safe (no kidding). If you forget your password, no one can help you out.
  3. To login for creating content and curating, use your Private Posting Key
  4. To make transfers and account operations, use your Private Active Key
  5. To encrypt and decrypt memos, use your Private Memo Key
Sort:  

Wow, this post is interesting, I enjoy reading it. You should write more article like this, its gave me a valuable insight into bot activity

Hey. Thanks mate.
I will break down the bot’s code into one ore more posts

Congratulations! Your post has been selected as a daily Steemit truffle! It is listed on rank 5 of all contributions awarded today. You can find the TOP DAILY TRUFFLE PICKS HERE.

I upvoted your contribution because to my mind your post is at least 32 SBD worth and should receive 130 votes. It's now up to the lovely Steemit community to make this come true.

I am TrufflePig, an Artificial Intelligence Bot that helps minnows and content curators using Machine Learning. If you are curious how I select content, you can find an explanation here!

Have a nice day and sincerely yours,
trufflepig
TrufflePig

@quochuy, don't you feel like Keanu Reeves in the movie "The Matrix" with all these codes.

Oh yea, I see a blonde girl in red dress all the time!

@quochuy - what about photography post? Sometimes you don’t need 200 words. The bot automatically denies those entries. Although I enjoy the bot’s response.

😊
The admin team has agreed for 200 words regardless of if it is a blog, photo or video. Steemit is not a photo album or a video repository, it is a blogging platform where you can attach photos and videos. If we want to add value to the Steem blockchain then we need to make things better. When you attach a photo, you can tell many things about it so the viewer knows more about the photo, the story behind it or even about your style and yourself. For example, these are some things you can add to a photo:

  • tell us about the location where you took it, what you were doing there on the day
  • tell us why you took a photo of that subject, what you felt when you saw it
  • tell us about how you decided to compose the photograph
  • etc...

Here is an example of mine:
https://steemit.com/photography/@quochuy/iphone-macro-photography-verbena-bonariensis-aka-purpletop-vervain