Interesting Tags
   11 tags on

0 answers

Update product price from import excel file python project for Odoo version

I'm using Odoo version python project I want to update price from import excel file how I can do this problem anybody can help me with simple code.how to import and read excel file and update product …

0 answers

writing functional/integration tests for python

I am new to python and functional/integration tests as a whole. I know how to write unit tests, but in this case i do not need isolation for specific functions, rather i need my python script to be …

2 answers

`web.py` sessions with Apache2

Question: I am in the process of porting my web.py app from its built in server to Apache2 using mod_wsgi. All is well and the code executes, except for the sessions. Firstly, note that the ...

1 answer

Webscraping with BeautifulSoup - NYC Marathon Times

I'm trying to programatically scrape all the NYC Marathon Data found here: http://web2.nyrrc.org/cgi-bin/htmlos.cgi/2112.6.038135231510781094 into a CSV. Two issues: I can't figure out a way to ...

4 answers

Python add sequential value array to dict

For example i have dict python dict = {'a': '1', 'b': '2', 'c': '3'} and array arr = ['4', '5', '6'] I want add sequential value array to dict dict1 = {'a': '4', 'b': '5', 'c': '6'} Please …

1 answer

Schedule a repeating event in Python

I am writing a script running as daemon process. Every 12 hours, it runs some job. Is that a good practice to do the following code? I'm using Python 2.7 import sched scheduler = ...

1 answers | 8 mins ago by cli130 on Stack Overflow stackoverflow.com
0 answers

Symbol not found: ___sincos_stret

I've recently installed root on a system running Mac OS X 10.8 I've replaced my home folder title with a ~. When attempting to import ROOT while in a python interactive mode, I Traceback (most ...

0 answers

Heap snapshot Selenium webdriver python

Is there any way to get Heap Snapshot from the Selenium webdriver? I am currently using Chrome with Chrome driver. I understand that both Inspector and Selenium connects via the same port. In ...

2 answers

Sum Lists' value with corresponding index value in Python

I used a big list to represent a lot of needed values, which is really complicated to me. For example: [[[a,b,c],[d,e,f]], [[g,h,i],[j,k,l]], [[o,p,u],[r,s,t]]] And I want to combine …

2 answers | 9 mins ago by Yang Liu on Stack Overflow stackoverflow.com
2 answers

How to execute a Python function within a function and not stop the execution

I'm trying to accomplish something without using threading I'd like to execute a function within a function, but I dont want the first function's flow to stop. Its just a procedure and I don't expect …

0 answers

Error: redirect_uri_mismatch in gae django project

I am developing django non-rel gae project. I am trying to use api. My code is as below: FLOW = client.flow_from_clientsecrets( CLIENT_SECRETS, scope=[RW_SCOPE, RO_SCOPE], ...

0 answers

Can I run Python 2.7 Libraries (Impacket, Pcapy) on Django

Hi I just want to ask if its possible to run Impacket to Django, On my project I am already done on my sniffing and parsing using Impacket and Pcapy but my clients requested that the GUI will be web …

0 answers

wxFormBuilder grab text from a form python

I am trying to grab text the user inputs into a form in my GUI and store it as a string def handleThis (self, event): msgStr = "Hi! You have pressed the FIRST button" wx.MessageBox(msgStr) …

0 answers

PyQt: get the current QTreeWidget item

I presently have a QTreeWidget named 'treeWidget', and for the life of me, cannot figure out how to get the index value or the text of the selected treeWidget branch. self.treeWidget looks like: User …

1 answer

Popen and stdin to automate input to .exe

I have a simple windows executable that asks for user input and I'm trying to make a python script to automate the input. What I've done: from subprocess import Popen, PIPE p = ...

1 answers | 26 mins ago by user1091684 on Stack Overflow stackoverflow.com
1 answer

Urllib Python is not providing with the html code I see with with inspect element

I'm trying to crawl the results in this link: url = "http://topsy.com/trackback?url=http%3A%2F%2Fmashable.com%2F2014%2F08%2F27%2Faustralia-retail-evolution-lab-aopen-shopping%2F" When I inspect it …

1 answers | 35 mins ago by ybb on Stack Overflow stackoverflow.com
1 answer

python : difficulty teaming up neighbours of each cone

I have a nested list of junctions between cones. a = [0,1] b = [2,4] c = [2,0] d = [4,3] e=[a,b,c,d] I want to write a program that lists every neighbour of cone 0, every neighbour of cone 1... …

1 answers | 42 mins ago by Hannah on Stack Overflow stackoverflow.com
0 answers

How to remove a query string parameter from url using javascript?

I need help removing a query string parameter from the url. Example: /comparison?tid=326&tid=118 Let's say I want to remove tid=326 but keep tid=118 when a user clicks a remove link from my ...

0 answers

Filtered most_common() for Counter in Python

I have a counter formatted as {(f1, f2): counts}. When I run the Counter.most_common() on this I get correct results but I want to filter most_common() for some filter on f2. For example f2 = 'A' ...

2 answers

Python: return letters not in string

I was wondering if there was a method or way to return letters not in a string. Meaning: Let's say I have the word "testing". "ing" in "testing" returns true but I want to return the letters in ...

2 answers | 50 mins ago by user2456977 on Stack Overflow stackoverflow.com
0 answers

Multiple output from a single input in python

I have text file of this format MODEL 1 ATOM TER ENDMDL MODEL 2 ATOM TER ENDMDL ...and so on So, I want to copy each section starting with MODEL and end with ENDMDL into separate ...

52 mins ago by Mon on Stack Overflow stackoverflow.com
1 answer

Having trouble with classes Python

this is my assignment: SortedStringBag(initial_list) create a new sorted string bag object and give it the initial list of strings. Sort the list. This is the only time you can sort. print() print …

1 answers | 57 mins ago by Brandon Jerz on Stack Overflow stackoverflow.com
1 answer

How do I use a custom Plural-Forms in django.po?

I want to use a custom Plural-Forms scheme in my django.po for Russian, but when I change it, it does not affect the results of ungettext. I’ve found out that if I use the same translation file ...

0 answers

How can I decrypt RC4 using hex values?

I found a couple RC4 scripts online for python. I used one from http://www.joonis.de/en/code/rc4-algorithm that I simplified and am using just for decrypting files that have been encrypted with RC4 …

0 answers

Shipping Charge Using Define Function (Python)

I'm trying to program this assignment using the define function. Here is what I've done so far. Please let me know if I can do anything. There is an error to my code and I'm having difficulty ...

0 answers

Calling python script from javascript that outputs a .txt file

I need to run a python script that outputs a .txt file from javascript. The script is already done, but I am having trouble calling it from javascript. I am trying to use ajax. Here is the following …

1 answer

Python/Pygame mouse position does not update (blit function)

I'm trying to make a simple menu using Pygame but I found that whenever I use pygame.mouse.get_position, it does blit what i want but i have to keep move my mouse to make my picture keep blitting. …

1 answers | 1 hour ago by Pythy Python on Stack Overflow stackoverflow.com
1 answer

Python/Pandas: How do I select rows in one column where value iis equal to a different row in a different column?

Here is a sample of my data: In[177]:df_data[['Date', 'TeamName', 'Opponent', 'ScoreOff']].head() Out[177]: Date TeamName Opponent ScoreOff 4128 ...

2 answers

parallel generation of random forests using scikit-learn

Main question: How do I combine different randomForests in python and scikit-learn? I am currently using the randomForest package in R to generate randomforest objects using elastic map reduce. This …

2 answers

python IDLE fibonocci sequence my model doesn't work

need help with this, i tried something but it didn't work for some reason. I need some help to figure it out. def F(n): if n == 0: return 0 elif n == 1: return 1 else: return ...

2 answers | 1 hour ago by iva kukovska on Stack Overflow stackoverflow.com
15 30 50 per page
1 2 3