#jython IRC Log (v0.9)

Index

IRC Log for 2015-11-20

Timestamps are in GMT/BST.

[0:18] * JythonLogBot (~PircBot@74.50.59.201) Quit (Ping timeout: 260 seconds)
[0:18] * JythonLogBot disconnected - trying to reconnect...
[0:18] -wolfe.freenode.net- *** Looking up your hostname...
[0:18] -wolfe.freenode.net- *** Checking Ident
[0:18] -wolfe.freenode.net- *** Couldn't look up your hostname
[0:19] -wolfe.freenode.net- *** No Ident response
[11:46] -leguin.freenode.net- *** Looking up your hostname...
[11:46] -leguin.freenode.net- *** Checking Ident
[11:46] -leguin.freenode.net- *** No Ident response
[11:46] -leguin.freenode.net- *** Couldn't look up your hostname
[11:46] * JythonLogBot (~PircBot@74.50.59.201) has joined #jython
[11:46] * Topic is 'Jython 2.7 final released: http://tinyurl.com/muqfuul | This channel is logged: http://jython.extreme.st/irclogs/ | Please update the wiki: http://wiki.python.org/jython | Jython Book: http://jythonbook.com | Podcast: http://jython.org/jythonpodcast/'
[11:46] * Set by agronholm!~agronholm@nblzone-211-20.nblnetworks.fi on Sun May 03 05:10:52 UTC 2015
[11:47] * ohumbel (5390f784@gateway/web/freenode/ip.83.144.247.132) has joined #jython
[15:08] * xemdetia (xemdetia@nat/ibm/x-peqoeowjkzjtzkhp) has joined #jython
[18:39] * lac (~quassel@c-ecc4e055.1321-1-64736c11.cust.bredbandsbolaget.se) Quit (Ping timeout: 264 seconds)
[18:40] * lac (~quassel@c-ecc4e055.1321-1-64736c11.cust.bredbandsbolaget.se) has joined #jython
[18:55] * cyraxjoe_ (~joe@CableLink205-241.telefonia.InterCable.net) has joined #jython
[18:57] * cyraxjoe (~joe@CableLink205-241.telefonia.InterCable.net) Quit (Ping timeout: 260 seconds)
[19:03] * cyraxjoe_ is now known as cyraxjoe
[19:15] * robbyoconnor (~wakawaka@guifications/user/r0bby) Quit (Quit: Konversation terminated!)
[22:11] * xemdetia (xemdetia@nat/ibm/x-peqoeowjkzjtzkhp) Quit (Ping timeout: 246 seconds)
[23:08] * Cheaterman (~cheaterma@unaffiliated/cheaterman) has joined #jython
[23:08] <Cheaterman> Hello buddies ^__^ I hope you're doing good!
[23:09] <Cheaterman> agronholm: No module named pip
[23:09] <agronholm> you can't expect to pip install stuff with the standalone
[23:09] <Cheaterman> I need sqlalchemy tho :3
[23:09] <agronholm> so install a real jython and install sqlalchemy there
[23:09] <Cheaterman> and wow you're op here
[23:09] <agronholm> I'm a Jython core developer
[23:09] <Cheaterman> But how can I force minecraft to use it?
[23:10] <Cheaterman> expects the jar to be in lib/jython.jar
[23:10] <agronholm> package it in a jar
[23:10] <agronholm> and put it in the class path
[23:10] <Cheaterman> Oh, so I install jython, then sqlalchemy on it, then I package the whole thing?
[23:10] <Cheaterman> I have maven if it helps
[23:10] <agronholm> make it so that the jar contains the sqlalchemy dir from site-packages
[23:10] <Cheaterman> I have no idea how to do this - I actually don't know how to package jython
[23:10] <agronholm> remove any .class files first
[23:11] <agronholm> cd site-packages; jar cf sqlalchemy.jar sqlalchemy
[23:11] <agronholm> thats it
[23:11] <agronholm> and remember, jar files are just renamed zip files
[23:11] <Cheaterman> Yes, that I know
[23:11] <Cheaterman> apks too
[23:11] <Cheaterman> aight, so to get started I suppose I should clone the jython git or something
[23:12] <agronholm> why?
[23:12] <agronholm> just download the installer and run it
[23:13] <Cheaterman> oh it's a jar installer
[23:13] <Cheaterman> funni
[23:13] <Cheaterman> let's go :)
[23:14] <Cheaterman> Wow very nice
[23:14] <Cheaterman> Sort of feels like a windows installer haha
[23:14] <Cheaterman> next next haha
[23:15] <Cheaterman> aight seems to work, painfully slow as usual but it works
[23:15] <Cheaterman> i should maybe upgrade my VPS
[23:15] <Cheaterman> I have about 0kiB of free RAM
[23:16] <Cheaterman> you know what I was scheduling that for tomorrow but let's just do it right now
[23:16] <Cheaterman> agronholm: it's a very lucky coincidence for me that I know you / I moved my server to minecraft / we met on SQLAlchemy / I now need Jython
[23:16] <Cheaterman> Life is awesome bliblibli ^__^ \o/
[23:17] <agronholm> sometimes things do work out that way :)
[23:17] <Cheaterman> Yes :-D
[23:18] <Cheaterman> agronholm: About the class path, is it a runtime thing? Should I basically expect "import sqlalchemy" in Python to work as soon as sqlalchemy.jar is inside the class path?
[23:18] <agronholm> yes
[23:19] <Cheaterman> (most likely corresponds to the lib/ folder of Minecraft in which I have to currently put jython.jar)
[23:19] <Cheaterman> Okay
[23:19] <Cheaterman> agronholm: the installer failed installing pip for some reason
[23:19] <Cheaterman> any way for me to do it manually?
[23:20] <Cheaterman> java.io.IOException: Cannot run program "spigot/jython/bin/jython" (in directory "spigot/jython/bin"): error=2, No such file or directory
[23:20] <Cheaterman> (while jython is there and works)
[23:20] <agronholm> jython -m ensurepip
[23:20] <Cheaterman> awesome haha
[23:21] <agronholm> but I've never seen such a failure
[23:21] <Cheaterman> maybe related to installing in some directory that's not owned by me
[23:21] <Cheaterman> i share a group with the user, and have g+w on the stuff
[23:21] <Cheaterman> but still umask 022
[23:21] <Cheaterman> ^^"
[23:21] <Cheaterman> so new files generally don't have write perm if that causes issues
[23:22] <Cheaterman> (because I have ~minecraft in which I keep the relevant stuff, and I have my own user)
[23:23] <Cheaterman> I'll file a bug if you think that's a good idea
[23:23] <Cheaterman> But it's really an edge case probably
[23:23] <agronholm> can you give instructions to reproduce it elsewhere too?
[23:23] <Cheaterman> Yes, if it's what I think
[23:23] <agronholm> if not, we can't do much
[23:23] <Cheaterman> yeah
[23:23] <Cheaterman> I know what it's like hehe
[23:24] <Cheaterman> and as long as jython -mensurepip does the job, i shouldn't have to worry too much
[23:24] <Cheaterman> "successfully"
[23:24] <Cheaterman> seems good
[23:24] <Cheaterman> that poor machine does its best to avoid swapping on its 128M of SSD
[23:24] <Cheaterman> still painfully slow
[23:24] <Cheaterman> I'm gonna order the new one immediately
[23:42] <Cheaterman> aight
[23:42] <Cheaterman> find . -iname \*.class -exec rm {} \+
[23:42] <Cheaterman> then cd ..; jar cf sqlalchemy.jar sqlalchemy
[23:43] <Cheaterman> so far so good, moved the thing in place, about to test
[23:43] <Cheaterman> More whisky too! ^___^
[23:44] <Cheaterman> agronholm: what's exactly the site module
[23:45] <Cheaterman> oh
[23:45] <Cheaterman> sys.path expects Lib/
[23:45] <Cheaterman> let's make him happi I suppose
[23:45] <Cheaterman> or not
[23:45] <agronholm> ?
[23:45] <Cheaterman> wait
[23:45] <Cheaterman> I did a bad thing
[23:48] <Cheaterman> ImportError: No module named sqlalchemy
[23:48] <Cheaterman> Hmm.
[23:48] <Cheaterman> So that wasn't my classpath after all
[23:50] <Cheaterman> worst case scenario i could take sqlalchemy folder and stick it under my plugin
[23:51] <agronholm> what is the folder structure inside your sqlalchemy jar?
[23:51] <Cheaterman> I did exactly as you asked, so it should be /sqlalchemy/whatever
[23:51] <Cheaterman> I'll check though
[23:53] <Cheaterman> sqlalchemy/orm/collections.py
[23:53] <Cheaterman> etc
[23:53] <Cheaterman> sqlalchemy/event/registry.py
[23:54] <agronholm> looks right then
[23:54] <Cheaterman> has META-INF and manifest in it
[23:54] <agronholm> and you're saying that jar is on the class path and you still can't import it?
[23:54] <Cheaterman> I'm saying I don't know what classpath is
[23:54] <Cheaterman> :S
[23:54] <agronholm> well that you need to figure out
[23:54] <Cheaterman> exactly, any easy way?
[23:55] <agronholm> I don't know how minecraft works
[23:55] <agronholm> so I don't know how it sets up its class path
[23:55] <Cheaterman> what about any other java app
[23:55] <Cheaterman> would ./ be in class path
[23:55] <agronholm> no
[23:55] <agronholm> you generally add paths to the CLASSPATH env variable
[23:55] <agronholm> either individual jars or directory/*
[23:56] <Cheaterman> Oh
[23:56] <Cheaterman> but there's also -classpath cmdline option
[23:56] <Cheaterman> so it's not even an issue
[23:56] <Cheaterman> Let's just add ~minecraft/lib to classpath with that switch
[23:56] <agronholm> that won't work
[23:56] <Cheaterman> ah
[23:57] <agronholm> it needs to end with /*
[23:57] <Cheaterman> Oh ^^
[23:57] <agronholm> to add all the jars in a directory
[23:57] <Cheaterman> I will certainly do that
[23:57] <Cheaterman> relative paths work?
[23:58] <Cheaterman> ie -classpath 'lib/*' ?
[23:58] <Cheaterman> (single quotes because expansion)
[23:58] <agronholm> I think so, but I'm not sure
[23:58] <Cheaterman> okay I won't risk it
[23:59] <Cheaterman> Funni how since my VPS holds my Irssi I can simply use /exec to see my ram usage
[23:59] <Cheaterman> (and/or how Java abuses it)

Index

These logs were automatically created by JythonLogBot_ on irc.freenode.net using a slightly modified version of the Java IRC LogBot (github).