… File "__main__", line 4, in __main__.add_column Failed example…********************************************************************** File "__main__", line 7, in __main__.add_column Failed example… Discussion Thread by LateNiteTippin in Software Development
8 Years Ago
… File "__main__", line 4, in __main__.add_column Failed example…********************************************************************** File "__main__", line 7, in __main__.add_column Failed example… Discussion Thread by LateNiteTippin in Software Development
… File "__main__", line 4, in __main__.add_column Failed example…********************************************************************** File "__main__", line 7, in __main__.add_column Failed example… Reply by jlm699
8 Years Ago
… File "__main__", line 4, in __main__.add_column Failed example…********************************************************************** File "__main__", line 7, in __main__.add_column Failed example… Discussion Thread by LateNiteTippin in Software Development
… File "__main__", line 4, in __main__.add_column Failed example…********************************************************************** File "__main__", line 7, in __main__.add_column Failed example… Reply by LateNiteTippin
8 Years Ago
….predmety is as folloving: [<__main__.Cpredmet instance at 0x010F5260>…;, <__main__.Cpredmet instance at 0x010F5210>…;, <__main__.Cpredmet instance at 0x010F5238>… Discussion Thread by vlady in Software Development
5 Years Ago
…run_testcase() if __name__=="__main__": logger=Logger() logger…capture]) if __name__=="__main__": logger=Logger() … wrapper if __name__=="__main__": logger=Logger()… Discussion Thread by falek.marcin in Software Development
5 Years Ago
… results: 2 <class '__main__.bu(4)'> 10 <…;class '__main__.bu(2)'> actual results…: 2 <class '__main__.bu(4)'> 2 <…;class '__main__.bu(4)'> the problem… Discussion Thread by DarkPikachu in Software Development
3 Years Ago
….stdout # restore sys.stderr # cleanup __main__ # cleanup[1] random # cleanup[1… named posix (conditional import by __main__) W: no module named pwd….Handler (top-level import by __main__) W: no module named clr… Discussion Thread by sbaw in Software Development
2 Years Ago
…function. if __name__ == '__main__': main() Okay, so …. if __name__ == '__main__': main() Is this required… function. if __name__ == '__main__': main() printName() printNames() … Discussion Thread by Slavi in Software Development
2 Years Ago
…function. if __name__ == '__main__': main() Okay, so …. if __name__ == '__main__': main() Is this required… function. if __name__ == '__main__': main() printName() printNames() … Discussion Thread by Slavi in Software Development
…, this variable has the value `'__main__'` and in the second case… intended meaning of if __name__ == '__main__': do_stuff() is if we_are_executed_as_a_script_and_not_as_a_module(): do_stuff… Reply by Gribouillis
2 Years Ago
…function. if __name__ == '__main__': main() Okay, so …. if __name__ == '__main__': main() Is this required… function. if __name__ == '__main__': main() printName() printNames() … Discussion Thread by Slavi in Software Development
Use of `if __name__ == '__main__':` # use it for testing function1() # … or be an importable module # __main__ is the namespace of the… as a module if __name__ == '__main__': function1() Reply by vegaseat
2 Years Ago
… list(set(possibleItems)) if __name__ == '__main__': print('Text Adventure Demo!') print… Discussion Thread by Sean___ in Programming
2 Months Ago
… list(set(possibleItems)) if __name__ == '__main__': print('Text Adventure Demo!') print… Discussion Thread by Sean___ in Programming
It looks quite simple. You need to add an attribute to dungeon items, such as `GoldValue: 25,`. From the character's point of view, you can invent a new variable similar to location or inventory, such as `purse = 18` which means that you have 18 gold … Reply by Gribouillis
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
Hi, it's been a long time since I last used wxpython, but I think it should be something like for i, seq in enumerate(data): for j, v in enumerate(seq): self.SetCellValue(i, j, v) You should find good examples in… Reply by Gribouillis
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
Hi. Thx for your reply. I try this but not woking, I got error message "TypeError: String or Unicode type required". Also i alredy chek Mouse vs Python, but could not find any advance stuff, only basic, or I just dont know how to lok for … Reply by Nemius
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
Can you post the whole exception traceback that gets printed instead of only TypeError: String or Unicode type required" ? Reply by Gribouillis
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
Yeah, sure. Traceback (most recent call last): File "C:/Users/*****/PycharmProjects/MySQL Setup TE/main.py", line 131, in <module> frame = GlavniProzor() File "C:/Users/*****/PycharmProjects/MySQL … Reply by Nemius
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
The error means that you tried to insert in a grid cell a value `v` which type is not `str` or `unicode`, and the `Grid` type doesn't accept that. We can get more information about what this value was by using for i, seq in enumerate(data):… Reply by Gribouillis
2 Months Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
I got this mesage. Traceback (most recent call last): File "C:/Users/*****/PycharmProjects/MySQL Setup TE/main.py", line 134, in <module> frame = GlavniProzor() File "C:/Users/*****/PycharmProjects/MySQL … Reply by Nemius
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
The 7L comes because you are using python 2 instead of python 3, which I disapprove, but it is your choice, and there are two integer types in python 2, namely `int` and `long`, so 7L is a long because the module you used to read the database returns long … Reply by Gribouillis
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Software Development
It work. Man, i just canot say how i grateful I am. Yeah i start whit python 2.7 and stil learning. Maybe that is what giving me the most problems, Python have to many versions, and everybody working whit different version. Anyway, thank you so much … Reply by Nemius
1 Month Ago
so I'm working on a class for a vector which I want to hash like a tuple, and to do so, a vector instance needs acess to it's properties. here's the constructor for the performative properties I'm using, and the vector class: def newProp():… Discussion Thread by DarkPikachu in Software Development
…() print(hash(v)) if __name__ == '__main__': main() I'm sure you… Reply by Gribouillis
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
For problem 1, I think you could remove the 'data' argument in def OnCellChange(self, evt, data): ... For problem 2, you need to compute the `row` value that you want to insert, for exemple def appendRow(self): row = … Reply by Gribouillis
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
Thank you. As for first problem, its more complex than I thout it is. So I will need to start from scratch. For second problem, i try to add row = self.GetNumberRows() +1 but got error: _grid.GridTableMessage_swiginit(self,_grid.… Reply by Nemius
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
The error message won't suffice, can you post the whole exception traceback printed by python ? Reply by Gribouillis
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
Sure. Traceback (most recent call last): File "C:/Users/******/PycharmProjects/MySQL Setup TE/backpu.py", line 183, in onKeyDown self.appendRow() File "C:/Users/******/PycharmProjects/MySQL Setup TE/backpu.py&… Reply by Nemius
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
Try `self.GetTable()` instead of `self` as first argument when you call `gridlib.GridTableMessage()`. Reply by Gribouillis
1 Month Ago
…(self) #Run if __name__ == "__main__": app = wx.App() frame… Discussion Thread by Nemius in Programming
Thx. I try that, but now add 2 rows, not 1, but do not show any error. Reply by Nemius
1 Month Ago
Hello! Can you give me an example of Button widget in Kivy language? I can creat the button but don't know how to use it's callback. I mean how can i set a command for the Button in Kivy? Discussion Thread by Niloofar24 in Software Development
… is no if __name__ == "__main__": window.run() *statement. I… Reply by M_12
2 Weeks Ago