Posts

Showing posts from January, 2023

Solving [SSL: WRONG_SIGNATURE_TYPE] wrong signature type when Scraping Websites

So, recently I worked on a project where I was required to collect all available course information at a targeted university website. You know the drill. I started to import requests and BeautifulSoup and was about to pass the target URL into the requests.get(). I thought it was going to be smooth and easy as it used to be. Unfortunately, an error came up and prevented the scraping to be running.  This was the error: [SSL: WRONG_SIGNATURE_TYPE] wrong signature type So what I did (as always) was started surfing StackOverflow. Without taking much time, I found this post . Here's the workaround, just add the TLSAdapter class (as shown below) and you're good to go. So, instead of using requests.get() directly, it is suggested to make use of the session in order to incorporate the TLSAdapter() prior to reaching the target URL. Credit goes to pyOliv . Hope it helps you too.

Peran QRIS dalam Memajukan UMKM Indonesia

Image
Berdasarkan 2019 Southeast Asia E-Money Market Report yang disusun oleh Standard and Poor's (S&P) Global Market Intelligence , transaksi uang elektronik di wilayah Asia Tenggara meningkat hingga lebih dari 31 persen pada 2018. Indonesia, bersama Filipina, menjadi negara terdepan yang menunjukkan potensi pertumbuhan terbesar untuk produk dompet elektronik non-bank ( non-bank e-wallets ) [1]. Temuan ini termanifestasi dalam peningkatan jumlah transaksi non-tunai ( cashless transaction ) di Indonesia yang mencapai lebih dari 2 miliar transaksi pada 2018. Bahkan berdasarkan temuan salah satu perusahaan riset pemasaran independen, Ipsos Indonesia , menyebutkan bahwa 47% konsumen yang menjadi responden memiliki lebih dari dua jenis dompet digital [2]. Merespon tren tersebut, Bank Indonesia selaku Bank Sentral meluncurkan QRIS pada 17 Agustus 2019 dengan mengusung misi besar: menjamin kemudahan, kecepatan, dan keamanan transaksi pembayaran di Indonesia.  Peluncuran ini kian terasa te...

Adding a Dashed Connector in Draw.io

Image
So, over the past two months, I was assigned to create use-case diagrams. I found a handy tool for this purpose i.e.,  draw.io . I never touched this type of diagram in my entire professional career. I learnt how to draw ones when I was in college, sure. But spending most of my time to date as a programmer or data engineer, I never got the chance to actually create one. It was clear that when I got this assignment, I was spending a substantial amount of time just figuring out how to include a dashed connecter  (typically for representing "include" or "extend"). The funny thing is I could not find any clue of how to do this in their blog . So, here's how. Step 0: Initiation Suppose we have two cases: case 1 and case 2 ( I know it was a genuine mistake to name the two cases as use case 1 and use case 2 as shown below. Heck, I'm too lazy to update the pictures, so from now on we will assume the name of the cases are case 1 and case 2, respectively). We want to...

Adding Months to Current Date? Use relativedelta()

Image
After minutes of surfing in the ocean of Stackoverflow, find this trick to add months to the current date (dealing with date is painful already in any language, at least to me personally). Use relativedelta() from dateutil library. and the result shows: Check out the date after adding two months. Voila! Just like that. Credit: https://stackoverflow.com/questions/4130922/how-to-increment-datetime-by-custom-months-in-python-without-using-library