<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hi, Dan,<br>
    before answering I'll describe the situation a bit.<br>
    <br>
    there was a question today, if I know about pg8000 or psycopg2ct.<br>
     <br>
    As for pg8000, pure python should be slower than ctypes, anyway, so
    I don't think these two should be compared.<br>
    <br>
    But at the time of making pypq, I did not know about psycopg2ct. A
    couple of weeks ago there was no mention of it on the pypy psycopg2
    compatibility page, and yesterday (when I decided to make pypq) I
    did not find it while googling the topic. Though if I did know that,
    I wouldn't write my own implementation. <br>
    <br>
    Luckily, it took me only one day of coding, and therefore there are
    two key differences:<br>
    - pypq is a lot simpler. You can look at the code of both to see
    that<br>
    - pypq does not try to be psycopg2, only a couple of functions from
    there for django compatibility<br>
    <br>
    As soon as there is another project of this kind, I'm not sure if
    I'll go on with this. For production usage, pypq needs at least a
    complete test coverage, so DO NOT USE it in production, it is very
    alpha.<br>
    <br>
    About your questions, Dan:<br>
    <br>
    - this is not a replacement for psycopg2, as psycopg2ct is, but
    instead a dbapi2-compliant driver, which looks almost the same as
    psycopg2, cause they share the API. Making it a replacement was not
    a concern<br>
    <br>
    - i did not profile the code, just tested the results on my sites
    visually, and on cpython 2.7, I got roughly the same speeds as with
    psycopg2. It should be pretty fast, but if there is a bottleneck,
    the code is pretty simple to explore and fix. What I can think of
    now is processing very large result sets might be slow, cause for
    every cell there is a type cast going on, especially for complex
    types like datetime.timedelta. See datatypes.py for details.<br>
    <br>
    But still, the fact, that a working postgres driver for python could
    be written in a day, is awesome :) So as long as the code is simple,
    it could be an alternative.<br>
    <br>
    Regards,<br>
    Igor.<br>
    <br>
    On 10/04/2011 05:45 PM, Dan Loewenherz wrote:
    <blockquote
cite="mid:CAOKWLrHcvuEpeQ0P_U8a4DyTweVAP1AMEva=qzd=Hsgt1kGi6g@mail.gmail.com"
      type="cite">Hi Igor,
      <div><br>
      </div>
      <div>This is awesome.
        <div>
          <div><br>
          </div>
          <div>Quick questions: What is the feature parity with
            psycopg2? Are there any large components that aren't up to
            speed and need working on?</div>
          <div><br>
          </div>
          <div>Thanks!</div>
          <div>Dan</div>
          <div><br clear="all">
            <span style="border-collapse:collapse">
              <div style="font-family:arial, sans-serif"><span
                  style="font-size:13px"><font face="arial, helvetica,
                    sans-serif" size="1"><font color="#cc0000">mobile</font> <a
                      moz-do-not-send="true" value="+17862011161"
                      style="color:rgb(42, 93, 176)">786-201-1161</a> | </font><span
                    style="font-family:arial, helvetica,
                    sans-serif;font-size:x-small"><font color="#cc0000">web</font> <a
                      moz-do-not-send="true" href="http://dlo.me/"
                      style="color:rgb(42, 93, 176)" target="_blank">http://dlo.me/</a> | </span><span
                    style="font-family:arial, helvetica,
                    sans-serif;font-size:x-small"><font color="#cc0000">twitter</font> <a
                      moz-do-not-send="true"
                      href="http://twitter.com/dwlz"
                      style="color:rgb(42, 93, 176)" target="_blank">@dwlz</a></span></span></div>
            </span><br>
            <div class="gmail_quote">On Tue, Oct 4, 2011 at 3:07 AM,
              Igor Katson <span dir="ltr">&lt;<a moz-do-not-send="true"
                  href="mailto:igor.katson@gmail.com">igor.katson@gmail.com</a>&gt;</span>
              wrote:<br>
              <blockquote class="gmail_quote" style="margin:0 0 0
                .8ex;border-left:1px #ccc solid;padding-left:1ex;">
                <div bgcolor="#FFFFFF" text="#000000"> Hi, pypy
                  developers.<br>
                  <br>
                  check out pypq, a dbapi 2 PostgreSQL driver working
                  with pypy  <a moz-do-not-send="true"
                    href="http://pypi.python.org/pypi/pypq"
                    target="_blank">http://pypi.python.org/pypi/pypq</a><br>
                  <br>
                  I've made it to test how will my existing django sites
                  work with pypy<br>
                  <br>
                  I will be glad for any help.<br>
                  Feel free to contact me if you want to participate.<br>
                </div>
                <br>
                _______________________________________________<br>
                pypy-dev mailing list<br>
                <a moz-do-not-send="true"
                  href="mailto:pypy-dev@python.org">pypy-dev@python.org</a><br>
                <a moz-do-not-send="true"
                  href="http://mail.python.org/mailman/listinfo/pypy-dev"
                  target="_blank">http://mail.python.org/mailman/listinfo/pypy-dev</a><br>
                <br>
              </blockquote>
            </div>
            <br>
          </div>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>