[Tutor] Creating a torrent file & associated tracker through a django web app

2012-11-20 Thread ashish makani
Hi Tutor folks

I am trying to achieve the following :

The user should log into a web app, select a file & the web app should
generate a .torrent file & a private
tracker(http://IP_ADDRESS:PORT_NUMBER/announce)
for that .torrent file.

Basically, i want to programmatically create a .torrent file, on the server
side.

I found two libraries mktorrent[1] & py3createtorrent [2], but i need help
with how to create a torrent from a django web app.

Any suggestions for django modules or libraries which can do this ?

Any suggestions/pointers/ideas/links will be greatly appreciated

Thanks a ton,

cheers,

ashish

   1. http://mktorrent.sourceforge.net/
   2. http://www.robertnitsch.de/projects/py3createtorrent
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] help

2012-11-20 Thread Matthew Ngaha
> Traceback (most recent call last):
>   File "Match finder GUI.py", line 87, in ?
> app = Application(root)
>   File "\Match finder GUI.py", line 23, in __init__
> self.create_widgets()
>   File "Match finder GUI.py", line 61, in create_widgets
> self.submit_bttn = Button(self, text = "Submit", command = self.reveal)
> AttributeError: Application instance has no attribute 'reveal'
>
>

i only know really basic tkinter, but i think the error is looking for
a method called reveal(). other than your __init__()  and
create_widgets() methods, i only see an update() method. I think your
update method should be named reveal?
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] pyXML i Python2.6

2012-11-20 Thread Prasad, Ramit
Sreenivasulu wrote:
> 
> Hi,
> 
> Am unable to install pyXML in Ubuntu usig python2.6
> 
> Could you please help me
> 
> Regards,
> Sreenu

Since you do not provide a link I am guessing you are referring
to the very outdated package. You use the ElementTree class or the 
reputed third party module lxml. The ElementTree class is in the 
Python 2.6 standard library at xml.etree.ElementTree.ElementTree.


You can try modifying the pyXML source (seems like a small change),
but I do not recommend this approach.
http://stackoverflow.com/questions/4953600/pyxml-on-ubuntu


~Ramit



 
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.  
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] How to load python code only after program startup?

2012-11-20 Thread eryksun
On Mon, Nov 19, 2012 at 10:43 PM, Pete O'Connell
 wrote:
> Hi I use a compositing program called Nuke which loads my custom modules on
> start up. So if I have an error in my python code somewhere, Nuke won't open
> and it throws a typical error which is easy enough to fix.
> The problem I am running into is that when others on my network are using an
> older version of Nuke, some of my code causes their older version to not
> open. For example, recently I started using gnuplot.py for graphical feed
> back which the older version of Nuke doesn't like.
> So my question is:
> What is the best way to wrap all my custom code so that it isn't read on
> startup, but rather only after I invoke a "loadMyCustomModules.py" module.

I found the following in the docs:

http://docs.thefoundry.co.uk/nuke/63/pythondevguide/startup.html

Can you add your plugins via ~/.nuke/init.py?
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] How to load python code only after program startup?

2012-11-20 Thread Steven D'Aprano

On 20/11/12 14:43, Pete O'Connell wrote:

Hi I use a compositing program called Nuke which loads my custom modules on
start up. So if I have an error in my python code somewhere, Nuke won't
open and it throws a typical error which is easy enough to fix.
The problem I am running into is that when others on my network are using
an older version of Nuke, some of my code causes their older version to not
open. For example, recently I started using gnuplot.py for graphical feed
back which the older version of Nuke doesn't like.
So my question is:



What is the best way to wrap all my custom code so that it isn't read on
startup, but rather only after I invoke a "loadMyCustomModules.py" module.


Put it in a module "loadMyCustomModules.py" instead of whatever place Nuke
expects to find it.

What is Nuke? What exactly does it do? Where does it expect to find your
modules? What you are asking is really a question about Nuke, not Python.

Can you update the other versions of Nuke? Or tell it to be more forgiving
of errors? Or less aggressive about loading things automatically?


--
Steven
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor