Re: Regarding Job Opportunity for the position Python Developer in Mc Lean, VA

2016-09-30 Thread gowri
On Friday, September 30, 2016 at 10:56:14 AM UTC-5, go...@spsolinc.com wrote:
> Hi,
> 
> Here we have an immediate opening. Location will be Mc Lean, VA.
> Please revert back to us if you are interested.
> Need good Python experience. SAS or AWS knowledge is added advantage.
> 
> Thanks,
> Gowri Shekar
> 972-983-3467

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


Regarding Job Opportunity for the position Python Developer in Mc Lean, VA

2016-09-30 Thread gowri
Hi,

Here we have an immediate opening. Location will be Mc Lean, VA.
Please revert back to us if you are interested.
Need good Python experience. SAS or AWS knowledge is added advantage.

Thanks,
Gowri Shekar
972-983-3467
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: parsing json output

2008-03-26 Thread Gowri
Hi all,

Thank you so much for all your help :) I really appreciate it. I
discovered that my problem was because of my firewall and everything
works now :)

Regards,
Gowri
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: parsing json output

2008-03-23 Thread Gowri
Hi Tim,

I'm able to get and print correctly some HTML content. I don't know
how to fix this. Need all the help I can get with this :)

Regards,
Gowri
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: parsing json output

2008-03-20 Thread Gowri
Hi Tim,

I understand it's JSON. My problem is that it just prints crazy
characters instead of the JSON data. Like I mentioned, this happens on
my windows machine which has python 2.5. On the other hand, the same
code worked perfectly great on my linux machine with python 2.3.4.
What could the problem be?

Regards,
Gowri

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


Re: parsing json output

2008-03-19 Thread Gowri
I actually have a weirder problem. The code I posted earlier prints
garbage on Windows and python 2.5 and the perfect json data on RHEL
python 2.3.4. I'm so confused and helpless. json.py doesn't seem to
help either. It says

raise ReadException, Input is not valid JSON: '%s' %
self._generator.all()

Somebody please help!
-- 
http://mail.python.org/mailman/listinfo/python-list


parsing json output

2008-03-18 Thread Gowri
Hi,

I have a service running somewhere which gives me JSON data. What I do
is this:

import urllib,urllib2
import cjson

url = 'http://cmsdoc.cern.ch/cms/test/aprom/phedex/dev/gowri/datasvc/
tbedi/requestDetails'
params = {'format':'json'}
eparams = urllib.urlencode(params)
request = urllib2.Request(url,eparams)
response = urllib2.urlopen(request)# This request is sent in HTTP
POST
print response.read()

This prints a whole bunch of nonsense as expected. I use cjson and am
unable to figure out how to print this json response and I guess if I
can do this, parsing should be straightforward? doing a
cjson.decode(str(repsonse)) does not work. In what form is this data
returned and how do I print it and later pass it on to another client
browser? Typing
http://cmsdoc.cern.ch/cms/test/aprom/phedex/dev/gowri/datasvc/tbedi/requestDetails
in my browser returns valid json data.

Regards,
Gowri
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: parsing json output

2008-03-18 Thread Gowri
Thanks for your reply Justin. But how do I do it with cjson?
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: searching an XML doc

2008-01-16 Thread Gowri
Hi Gerard,

I don't know what to say :) thank you so much for taking time to post
all of this. truly appreciate it :)
-- 
http://mail.python.org/mailman/listinfo/python-list


searching an XML doc

2008-01-15 Thread Gowri
Hello,

I've been reading about ElementTreee and ElementPath so I could use
them to find the right elements in the DOM. Unfortunately neither of
these seem to offer XPath like capabilities where I can find elements
based on tag, attribute values etc. Are there any libraries which can
give me XPath like functionality?

Thanks in advance
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: searching an XML doc

2008-01-15 Thread Gowri
On Jan 15, 3:49 pm, Diez B. Roggisch [EMAIL PROTECTED] wrote:
 Gowri schrieb:

  Hello,

  I've been reading about ElementTreee and ElementPath so I could use
  them to find the right elements in the DOM. Unfortunately neither of
  these seem to offer XPath like capabilities where I can find elements
  based on tag, attribute values etc. Are there any libraries which can
  give me XPath like functionality?

 lxml does that.

 Diez

Hi Diez

I was trying lxml out and was unable to find any examples that would
help me parse an XML file with namespaces. For example, my XML file
looks like this:

phedexData xmlns=http://a.b.com/phedex;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xsi:schemaLocation=http://a.b.com/phedex requests.xsd
!--  Low priority replication request --
request id=1234 last_update=1060199000.0
status
approvedT1_RAL_MSS/approved
approvedT2_London_ICHEP/approved
disapprovedT2_Southgrid_Bristol/disapproved
pending/
move_pending/
/status
subscription open=1 priority=0 type=replicate
items
dataset/PrimaryDS1/ProcessedDS1/Tier/dataset

block/PrimaryDS2/ProcessedDS2/Tier/block/block
/items
/subscription
/request
/phedexData

If my Xpath query is //request, it obviously would not work. Is there
some sort of namespace registration etc. that is to be done before
issuing a query? Example code would help a lot.


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


Re: converting JSON to string

2008-01-13 Thread Gowri
On Jan 12, 2:58 am, Jeroen Ruigrok van der Werven [EMAIL PROTECTED]
nomine.org wrote:
 -On [20080112 08:38], Gowri ([EMAIL PROTECTED]) wrote:

 Actually, I have one other problem after all this. I see that if I try
 to construct JSON output as above, it is of the form
 [{'isbn': u'1-56592-724-9', 'title': u'The Cathedral  the Bazaar'},
 {'isbn': u'1-56592-051-1', 'title': u'Making TeX Work'}]
 The extra 'u' seems to causing syntax error in JavaScript which is not
 able to parse this response string. Any idea how I can fix this?

 JSON does not support Unicode in the sense of allowing raw Unicode codepoints.
 Instead JSON uses a \u scheme to encode Unicode characters (a bit flawed
 to limit it to four hexadecimal digits though, it leaves the whole CJK Unified
 Ideographs Extension B out of scope.).

 I use simplejson along with lxml/ElementTree for my JSONXML needs.

 --
 Jeroen Ruigrok van der Werven asmodai(-at-)in-nomine.org / asmodai
 イェルーン ラウフロック ヴァン デル ウェルヴェンhttp://www.in-nomine.org/|http://www.rangaku.org/
 Any road leads to the end of the world...

Thanks Jeroen. That helped a lot :)
-- 
http://mail.python.org/mailman/listinfo/python-list

converting JSON to string

2008-01-11 Thread Gowri
Hello,

I actually have two questions:
1. Are there any libraries which convert XML to JSON?
2. I am currently doing the above using the DOM parser and creating a
JSON array

snippet
for node in doc.getElementsByTagName(book):
isbn = node.getAttribute(isbn)
titleNode = (node.getElementsByTagName(title)
[0]).childNodes[0]
title = titleNode.data
primarykeys.append({'isbn': isbn, 'title': title})
return primarykeys

I want to send primarykeys as a response to my client. i use
mod_python and apache. The problem is, I have not been able to figure
out how to convert my JSON output to a string.

Could someone please help me?

Thanks in advance
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: converting JSON to string

2008-01-11 Thread Gowri
Hi Adonis,

Thanks so much. Appreciate it :)
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: converting JSON to string

2008-01-11 Thread Gowri
On Jan 11, 7:21 pm, Adonis Vargas [EMAIL PROTECTED]
wrote:
 Gowri wrote:
  Hello,

  I actually have two questions:
  1. Are there any libraries which convert XML to JSON?
  2. I am currently doing the above using the DOM parser and creating a
  JSON array

  snippet
  for node in doc.getElementsByTagName(book):
  isbn = node.getAttribute(isbn)
  titleNode = (node.getElementsByTagName(title)
  [0]).childNodes[0]
  title = titleNode.data
  primarykeys.append({'isbn': isbn, 'title': title})
  return primarykeys

  I want to send primarykeys as a response to my client. i use
  mod_python and apache. The problem is, I have not been able to figure
  out how to convert my JSON output to a string.

  Could someone please help me?

  Thanks in advance

 do:

 return str(primarykeys)

 Also there are Python modules for just this. Here is the very first link
 from Google:

 http://pypi.python.org/pypi/python-json

 I have used this one personally and have been very satisfied with it.
 There is another one (CJSON?) which is similar, but written in C, for
 when performance may be an issue.

 Hope this helps.

 Adonis

Actually, I have one other problem after all this. I see that if I try
to construct JSON output as above, it is of the form
[{'isbn': u'1-56592-724-9', 'title': u'The Cathedral  the Bazaar'},
{'isbn': u'1-56592-051-1', 'title': u'Making TeX Work'}]
The extra 'u' seems to causing syntax error in JavaScript which is not
able to parse this response string. Any idea how I can fix this?
-- 
http://mail.python.org/mailman/listinfo/python-list


Python setup not working on Windows XP

2008-01-07 Thread Gowri
Hello,

I am new to Python and am trying to setup Apache to serve Python using
mod_python. I'm using a Windows XP box. here is a list of steps i
followed for the installation:

1. Installed Apache 2.2.6
2. Installed Python 2.5.1
3. Installed mod_python 3.3.1

I then included the line
LoadModule python_module modules/mod_python.so in httpd.conf

I had this one line python file (print Hello) in htdocs of Apache. i
then started Apache and it merely echoed my code print and all.

i did some reading and thought something might be wrong with my
sys.path. This is what it reads:
'C:\\WINDOWS\\system32\\python25.zip', 'C:\\Python25\\DLLs', 'C:\
\Python25\\Lib', 'C:\\Python25\\Lib\\plat-win', 'C:\\Python25\\Lib\
\lib-tk', 'C:\\Python25', 'C:\\Python25\\Lib\\site-packages'

Somebody had said this problem could be because of the .zip file at
the beginning of the path but I haven't been able to get rid of it or
solve my problem in any other way. My Apache error file has the
entries:

[Mon Jan 07 04:11:11 2008] [error] python_init: Python executable
found 'C:\\Program Files\\Apache Software Foundation\\Apache2.2\\bin\
\httpd.exe'.
[Mon Jan 07 04:11:11 2008] [error] python_init: Python path being used
'C:\\WINDOWS\\system32\\python25.zip;C:\\Python25\\Lib;C:\\Python25\
\DLLs;C:\\Python25\\Lib\\lib-tk;;C:\\Program Files\\Apache Software
Foundation\\Apache2.2\\bin'.
[Mon Jan 07 04:11:11 2008] [notice] mod_python: Creating 8 session
mutexes based on 0 max processes and 250 max threads.


Could someone please tell me what I'm doing wrong?
-- 
http://mail.python.org/mailman/listinfo/python-list