Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Python IRCP Library

Project Description

Quick Start

import zirc, ssl

class Bot(zirc.Client):
    def __init__(self):
        self.connection = zirc.Socket(wrapper=ssl.wrap_socket)
        self.config = zirc.IRCConfig(host="irc.freenode.net",
            port=6697,
            nickname="zirctest",
            ident="bot",
            realname="test bot",
            channels=["##chat"],
            caps=zirc.Caps(zirc.Sasl(username="username", password="password")))

        self.connect(self.config)
        self.start()

    def on_privmsg(bot, event, irc):
        irc.reply(event, "It works!")
        #Or alternatively:
        #irc.privmsg(event.target, "It works!")

Bot()

This library implements the IRC protocol, it’s an event-driven IRC Protocol framework.

Installation

PyPi

sudo pip install zirc
sudo pip3 install zirc

Github

sudo pip install git+https://github.com/itslukej/zirc.git
sudo pip3 install git+https://github.com/itslukej/zirc.git

Github will contain the latest bug fixes and improvements but sometimes also “bad quality” code.

Features

  • Automatic PING/PONG between the server
  • IRC Message parsing
  • A simple set up and connection method
  • Easy installation
  • Easy CTCP Set-up

IPv6

To use IPv6 with zirc.Socket, you can use the family socket.AF_INET6:

import socket

self.connection = zirc.Socket(family=socket.AF_INET6)

Proxy

Initialize zirc.Socket with argument socket_class:

self.connection = zirc.Socket(socket_class=zirc.Proxy(host="localhost", port=1080, protocol=zirc.SOCKS5))

Ideas

  • Multiple connection support

TODO

  • More documentation

Contributing

Talk to us on #zirc at Freenode

Please discuss code changes that significantly affect client use of the library before merging to the master branch. Change the version in setup.py ahead if the change should be uploaded to PyPi.

Release History

Release History

This version
History Node

1.2.8

History Node

1.2.7

History Node

1.2.6

History Node

1.2.4

History Node

1.2.3

History Node

1.2.2

History Node

1.2.1

History Node

1.2.0

History Node

1.1.0

History Node

1.0.2

History Node

1.0.0

History Node

0.0.1

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
zirc-1.2.8-py2-none-any.whl (19.1 kB) Copy SHA256 Checksum SHA256 py2 Wheel Jul 15, 2017
zirc-1.2.8-py3-none-any.whl (19.0 kB) Copy SHA256 Checksum SHA256 py3 Wheel Jul 15, 2017
zirc-1.2.8.tar.gz (25.9 kB) Copy SHA256 Checksum SHA256 Source Jul 15, 2017

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting