[ann] pypi2u - Get notified on new version of packages

2014-04-17 Thread Miki Tebeka
Greetings,

http://pypi2u.appspot.com/ is a simple service that notifies you on new 
versions of packages you're interested in.

You can view the code, fill bugs and suggest ideas at 
https://bitbucket.org/tebeka/pypi2u

Hope you find it useful,
--
Miki
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: subprocess help

2014-04-17 Thread Влатко Станковиќ
>
>
>
> -- Forwarded message --
>> From: Steven D'Aprano 
>> To: python-list@python.org
>> Cc:
>> Date: 16 Apr 2014 12:06:16 GMT
>> Subject: Re: subprocess help
>> On Wed, 16 Apr 2014 12:47:03 +0200, Влатко Станковиќ wrote:
>> > Hello,
>> > I'm having some sort of 'problem' when using subprocess calls. This is
>> > the code snipet that i am using:
>> >
>> > capture_server1 = '''xvfb-run --auto-servernum ... '''
>> > server1_download = subprocess.Popen(shlex.split(capture_server1),
>> > stdin=subprocess.PIPE,
>> > stdout=subprocess.PIPE,
>> > stderr=subprocess.PIPE)
>> >
>> > out_s1, err_s1 = server1_download.communicate()
>> > time.sleep(2)
>> What's the difference between the server1 code (shown above) and the
>> server2 code (not shown, but identical as far as I can tell)?
>> You have to identify what files are remaining open. What does the xvfb-
>> run process do? What are the rest of the arguments?
>> My guess is that, depending on the arguments, sometimes xvfb-run leaves
>> files open even after the process terminates. You should monitor the open
>> files with lsof which is available on most Linux systems. I don't know
>> how to do that on other operating systems.
>> My guess is that, depending on the arguments, sometimes xvfb-run leaves
>> files open even after the process terminates. You should monitor the open
>> files with lsof which is available on most Linux systems. I don't know
>> how to do that on other operating systems.
>> --
>> Steven
>
>
>  --

https://mail.python.org/mailman/listinfo/python-list


 xvfb-run accepts some parameters and calls CutyCapt with parameters for it
The command is this:

xvfb-run --auto-servernum --server-num=55 --server-args "-screen 0,
> 1024x768x24" {0} --url="{1}" --private-browsing=on --out={2}


So server1, opens a process with CutyCapt which points to server1
address/url, does its thing and saves the result in out
Server2 in the other hand has a different address/url, different
server-num, and different out

As a workarround i've added close_fds=True, preexec_fn=os.setsid, and
after communicate(), i am doing os.killpg(server1.pid, signal.SIGUSR1)

Although i am not sure if this will work 100% because i have to wait X days
until something crashes

Any ideas are welcomed

P.S. After adding os.killpg, lsof and ps aux dont show more than 4 or 5
xvfb and cutycapt processes while running

Thanks and Regards
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: problem in event handling on change of variable value.

2014-04-17 Thread Bernd . Moennicke
hello sirjee,

i have read You solution for handling of events from CANoe in python.

I've implemented and its work correctly when I waiting in a msgbox (0, 
"Finished the Test", "Info", 16).
I will implement it in a loop with a sleep time. The standard python 
function of the sleep blocks the actual task and the event handling dosn't 
work.

Now I search for a solution to start the event class in a extra task with 
treahding.Thread. 

I've write a simple claas for testing of this:

class Tester (threading.Thread):

def __init__ (self, variable):
threading.Thread.__init__ (self)
self.__debug = True
self.__env_event = None

self.__appl = win32com.client.Dispatch 
('CANoe.Application')
self.__env = self.__appl.Environment
self.__var_name = variable
self.__var = self.__env.GetVariable (variable)

def run (self):
if self.__var != None:
self.__env_event = win32com.client.WithEvents 
(self.__var, Tester)
print 'run'
i = 0
while True:
pass
time.sleep (10)
print i
i = i + 1

def OnChange (self, value):
if self._debug: print ('VariableEvents:OnChange now called 
with %s' %value)

a = Tester ('dummy')
a.start ()

The run() dosn't work. I can't register the COM event. Have You a solution 
for this?
The claas tester works without self.__env_event = 
win32com.client.WithEvents (self.__var, Tester).

Regards,
Bernd
-- 
https://mail.python.org/mailman/listinfo/python-list


networking question: 2-way messaging w/o wireless modem config?

2014-04-17 Thread haiticare2011
I have a Raspberry Pi board with a wireless usb modem on it.
I wish to be able to message 2-way with the board from 
across the internet, without having to open ports on the wireless modem. Is 
there
 a way to do this? I have been looking at udp, but imagine that a udp packet is 
allowed in, but not out?
The amount of data transmission I want is very small, maybe lt 30 bytes. 
So a client http request could include this data?
I have been looking at messaging systems like MQTT as well, but don't know if 
they require opening a port in the typical modem-router.

Any ideas appreciated!
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: networking question: 2-way messaging w/o wireless modem config?

2014-04-17 Thread Mark H Harris

On 4/17/14 11:20 AM, haiticare2...@gmail.com wrote:

I have a Raspberry Pi board with a wireless usb modem on it.
I wish to be able to message 2-way with the board from
across the internet, without having to open ports on the wireless modem. Is 
there
  a way to do this? I have been looking at udp, but imagine that a udp packet is
allowed in, but not out?
The amount of data transmission I want is very small, maybe lt 30 bytes.


The answer depends on how you setup your wireless modem | router. There 
are many ways to set this up depending on your project goals. If you're 
trying to setup a sniffer (well, just don't do that, its not nice).


If you were trying to setup a micro server on my network (for instance), 
well, you couln't, because I don't permit the outgoing connection 
without authorization and port (actually, same is true for incoming 
connections. I would have to setup auth and port for you to connect your 
Pi as a micro server on my wireless network. Most public access points 
are blocked (peer to peer) too (if they're smart).


For legitimate non trivial setups (not experiments) you want to control 
the connection with auth and ports.


A word of caution about udp. If the data you are sending is contained in 
one datagram (one packet), then no problem; however, if you are sending 
multiple packets over the WAN it can be a big problem because the upd 
in|out does not guarantee correct packet ordering.


Is there a python question in here somewhere?

marcus

--
https://mail.python.org/mailman/listinfo/python-list


Soap list and soap users on this list

2014-04-17 Thread Joseph L. Casale
Seems the soap list is a little quiet and the moderator is mia regardless.

Are there many soap users on this list familiar with Spyne or does anyone
know the most optimal place to post such questions?

Thanks!
jlc
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: Soap list and soap users on this list

2014-04-17 Thread Chris Angelico
On Fri, Apr 18, 2014 at 3:58 AM, Joseph L. Casale
 wrote:
> Seems the soap list is a little quiet and the moderator is mia regardless.
>
> Are there many soap users on this list familiar with Spyne or does anyone
> know the most optimal place to post such questions?

I've used SOAP, but not with Python. (I've also used soap, but never
with any form of python. Snakes can stay dirty for all I care.)
Wouldn't really call myself a "soap user", tbh. Is your question
regarding anything at all Python, or are you just looking for helpful
nerds? :)

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list


RE: Soap list and soap users on this list

2014-04-17 Thread Joseph L. Casale
> Is your question
> regarding anything at all Python, or are you just looking for helpful
> nerds? :)

Hi Chris,
Thanks for responding. I've been looking at Spyne to produce a service that
can accept a request formatted as follows:


http://..."; xmlns:xsi=http:/..." 
xmlns:xsd="http://...";>


  
  
  

  


Where I am interested in the ID attribute of the attr tag as well as _all_ the
varying xml within the data tags.

The docs are good, but a bit thin on more intricate examples. Maybe your 
previous
soap experience might lead you to a tip that would eternally in debt me to 
you:) I
have only ever done the most simplest work with soap and or ajax and hence got
away with not knowing much...

Thanks again for your help!
jlc
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: Soap list and soap users on this list

2014-04-17 Thread Mark H Harris

On 4/17/14 12:58 PM, Joseph L. Casale wrote:

Seems the soap list is a little quiet and the moderator is mia regardless.

Are there many soap users on this list familiar with Spyne or does anyone
know the most optimal place to post such questions?


Read first.


You can try :

>  http://spyne.io/docs/2.10/

>  https://pythonhosted.org/Soapbox/


google is our friend. There are lots of links in the above, tutorials, &c.

Also, you might do some additional searching on PyPI... lots of SOAP 
packages (simple object access protocol).  Spyne uses SOAP.



marcus
--
https://mail.python.org/mailman/listinfo/python-list


RE: Soap list and soap users on this list

2014-04-17 Thread Joseph L. Casale
>Read first.
>
>
>You can try :
>
> >  http://spyne.io/docs/2.10/
>
> >  https://pythonhosted.org/Soapbox/

Thanks Marcus,
I assure you I have been reading but missed soapbox, I'll keep hacking away, 
thanks for the pointer.

jlc
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: networking question: 2-way messaging w/o wireless modem config?

2014-04-17 Thread haiticare2011
On Thursday, April 17, 2014 12:38:46 PM UTC-4, Mark H. Harris wrote:
> On 4/17/14 11:20 AM, hxaiticzzare2...@gmail.com wrote:
> 
> > I have a Raspberry Pi board with a wireless usb modem on it.
> 
> > I wish to be able to message 2-way with the board from
> 
> > across the internet, without having to open ports on the wireless modem. Is 
> > there
> 
> >   a way to do this? I have been looking at udp, but imagine that a udp 
> > packet is
> 
> > allowed in, but not out?
> 
> > The amount of data transmission I want is very small, maybe lt 30 bytes.
> 
> 
> 
> The answer depends on how you setup your wireless modem | router. There 
> 
> are many ways to set this up depending on your project goals. If you're 
> 
> trying to setup a sniffer (well, just don't do that, its not nice).
> 
> 
> 
> If you were trying to setup a micro server on my network (for instance), 
> 
> well, you couln't, because I don't permit the outgoing connection 
> 
> without authorization and port (actually, same is true for incoming 
> 
> connections. I would have to setup auth and port for you to connect your 
> 
> Pi as a micro server on my wireless network. Most public access points 
> 
> are blocked (peer to peer) too (if they're smart).
> 
> 
> 
> For legitimate non trivial setups (not experiments) you want to control 
> 
> the connection with auth and ports.
> 
> 
> 
> A word of caution about udp. If the data you are sending is contained in 
> 
> one datagram (one packet), then no problem; however, if you are sending 
> 
> multiple packets over the WAN it can be a big problem because the upd 
> 
> in|out does not guarantee correct packet ordering.
> 
> 
> 
> Is there a python question in here somewhere?
> 
> 
> 
> marcus

Thanks - I am just trying to design a consumer product where the consumer
does not have to fiddle with their modem, ie, plug'n'play. Usually, with 
consumer modems, you can do http client activity. (just connect another PC to 
the local network.) So I guess I could iniate a http request from the Pi. I
 just wondered if there were other protocols that would allow me to just
 communicate with the Pi.

As far as sniffers etc., I adhere to a complete personal honesty - that's my
 policy, as anything else just won't do. I hope to program the item in Python, 
though I'm wondering if C is better for network programming.

Thanks for help.
jb
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: networking question: 2-way messaging w/o wireless modem config?

2014-04-17 Thread Chris Angelico
On Fri, Apr 18, 2014 at 12:56 PM,   wrote:
> As far as sniffers etc., I adhere to a complete personal honesty - that's my
>  policy, as anything else just won't do. I hope to program the item in Python,
> though I'm wondering if C is better for network programming.

Not at all. I'd definitely recommend doing networking code in Python.
You can do basic TCP/IP sockets pretty much the same way in every
language, but with high level languages like Python, you get extra
facilities that C won't give - most notably, the urllib.request module
[1]. Same goes for quite a few other high level protocols. Take the
easy way out!

ChrisA

[1] https://docs.python.org/3/library/urllib.request.html
-- 
https://mail.python.org/mailman/listinfo/python-list