Skip to content

Instantly share code, notes, and snippets.

@Tarliton
Tarliton / async_sqlalchemy_thread.py
Last active February 26, 2023 13:07
asyncio with a thread executor and sqlalchemy
import asyncio
import base64
import os
import random
from sqlalchemy import Column, Integer, String
from sqlalchemy import create_engine
from sqlalchemy.orm import scoped_session, sessionmaker, declarative_base
# SQLAlchemy==2.0.4
"""pywin32 native dialog demo
Explanation here: http://auralbits.blogspot.com/2014/02/a-native-win32-application-in-python.html #noqa
The core of this demo comes from the pywin32 win32gui_dialog demo:
http://pywin32.hg.sourceforge.net/hgweb/pywin32/pywin32/file/tip/win32/Demos/win32gui_dialog.py # noqa
"""
var net = require('net')
// , listener = net.createServer()
, irc = require('irc')
, sys = require('sys')
, dns = require('dns')
, Buffer = require('buffer').Buffer
client = new irc.Client(
'irc.freenode.net'
, 'nodedcc'
, {channels: ['#node.js.bots']}