Search Results
|
Post |
Author |
Forum |
Replies |
Views |
Posted
[asc]
|
|
|
Thread: import argv
Post: RE: import argv
What the problem just to look into argv with print function?
print(argv) |
|
fishhook |
General Coding Help |
3 |
5,898 |
Nov-11-2019, 07:52 AM |
|
|
Thread: authentication required error with urlopen
Post: RE: authentication required error with urlopen
It seems you connect to the Internet via a proxy server. Your browser is set to work with the proxy but your program is not. |
|
fishhook |
General Coding Help |
2 |
2,731 |
Sep-06-2019, 06:27 AM |
|
|
Thread: Posting html values to views/models in Django
Post: RE: Posting html values to views/models in Django
Just go through the tutorial on Django's web site. |
|
fishhook |
Web Scraping & Web Development |
1 |
2,157 |
Sep-04-2019, 01:44 PM |
|
|
Thread: modifying what a module defines
Post: RE: modifying what a module defines
if option == "1":
print("\nOkay, you have decided to work WITHOUT THE EUREKAPRINTER.\n\n")
if option == "2":
import eurekaprinter
print("\nOkay, you have decided to work WITH THE EUREKA... |
|
fishhook |
General Coding Help |
8 |
2,841 |
Aug-26-2019, 06:29 AM |
|
|
Thread: i keep getting unordered output when using dictionaries
Post: RE: i keep getting unordered output when using dic...
I would highly recommend not building your algorithms based on the assumption of dictionary order. |
|
fishhook |
General Coding Help |
4 |
2,348 |
Aug-23-2019, 01:01 PM |
|
|
Thread: i keep getting unordered output when using dictionaries
Post: RE: i keep getting unordered output when using dic...
Dictionaries do not keep the order. If you really need to keep order use OrderedDict instead. |
|
fishhook |
General Coding Help |
4 |
2,348 |
Aug-23-2019, 10:02 AM |
|
|
Thread: BeautifulSoup: Error while extracting a value from an HTML table
Post: RE: BeautifulSoup: Error while extracting a value ...
Quote:shares = soup.find('td', {'Shares outstanding'}).contents
I am sorry, but I didn't manage to find in BS::find documentation an argument of type set([]). Can you show me it? |
|
fishhook |
Web Scraping & Web Development |
3 |
3,220 |
Aug-23-2019, 06:45 AM |
|
|
Thread: modifying what a module defines
Post: RE: modifying what a module defines
modules are just regular python's objects, you can set and get attributes via setattr/getattr functions |
|
fishhook |
General Coding Help |
8 |
2,841 |
Aug-23-2019, 06:39 AM |
|
|
Thread: Writing my first Django app
Post: RE: Writing my first Django app
class __str__(self):
return self.choice_textClass definition is not suitable here, you probably wanted to write def instead. |
|
fishhook |
Web Scraping & Web Development |
4 |
3,373 |
Aug-22-2019, 06:25 AM |
|
|
Thread: Writing my first Django app
Post: RE: Writing my first Django app
Make sure you didn't mix TABS and SPACES.
Show your whole module. |
|
fishhook |
Web Scraping & Web Development |
4 |
3,373 |
Aug-21-2019, 06:33 AM |
|
|
Thread: Convert a mongo db scrip to python equivalent
Post: RE: Convert a mongo db scrip to python equivalent
First of all which library do you use for MongoDB in your program? |
|
fishhook |
General Coding Help |
1 |
2,184 |
Aug-20-2019, 02:28 PM |
|
|
Thread: Repr() function
Post: RE: Repr() function
Quote:Return a string containing a printable representation of an object. For many types, this function makes an attempt to return a string that would yield an object with the same value when passed t... |
|
fishhook |
General Coding Help |
3 |
3,358 |
Aug-19-2019, 01:50 PM |
|
|
Thread: scheduled job only runs once
Post: RE: scheduled job only runs once
(Aug-19-2019, 06:55 AM)Stan2292 Wrote: would love to know the alternative... other than execfile of course...importlib.reload(packagename) |
|
fishhook |
General Coding Help |
4 |
2,861 |
Aug-19-2019, 08:18 AM |
|
|
Thread: Breaking subprocess loop from parent process
Post: RE: Breaking subprocess loop from parent process
Use signals instead of sending a text to stdin.
https://docs.python.org/2/library/subpro...end_signal |
|
fishhook |
General Coding Help |
3 |
3,861 |
Aug-19-2019, 06:59 AM |
|
|
Thread: scheduled job only runs once
Post: RE: scheduled job only runs once
Quote:why?
def job():
import asdf_1 All that you code do is importing module. Python's modules are imported only once per process. |
|
fishhook |
General Coding Help |
4 |
2,861 |
Aug-19-2019, 06:53 AM |
|
|
Thread: assignments of function references
Post: RE: assignments of function references
(Aug-15-2019, 12:42 AM)Skaperen Wrote: can i do:
def myfunc():
print('my_func')
class foo:
foo.func = myfunc
foo.func()?
yes, you can
def myfunc():
print('my_func')
class foo:
pa... |
|
fishhook |
General Coding Help |
3 |
2,356 |
Aug-15-2019, 11:12 AM |
|
|
Thread: Object exchange from django app to client app and vide versa
Post: RE: Object exchange from django app to client app ...
Read something about AJAX and JSON. It will be useful to study REST as well. |
|
fishhook |
General Coding Help |
1 |
1,965 |
Aug-15-2019, 06:03 AM |
|
|
Thread: modifying variables in local or global space
Post: RE: modifying variables in local or global space
(Aug-14-2019, 03:55 AM)Skaperen Wrote: you can't modify variables in local space using they dictionary you get from locals()
but.... I can
>>> l=locals()
>>> l["foo"] = "bar"
>... |
|
fishhook |
General Coding Help |
2 |
2,208 |
Aug-14-2019, 06:12 AM |
|
|
Thread: Operations on indexed variables in loop
Post: RE: Operations on indexed variables in loop
(Aug-14-2019, 05:36 AM)Fibulavie Wrote: Any idea what's wrong in here?
All is wrong. You don't need to create a lot of the same variables, just use lists or dictionaries instead. Every book I read e... |
|
fishhook |
General Coding Help |
1 |
1,933 |
Aug-14-2019, 06:07 AM |
|
|
Thread: HTML Styling Not Working
Post: RE: HTML Styling Not Working
You can find if your client supports a particular css feature here |
|
fishhook |
Web Scraping & Web Development |
1 |
2,228 |
Aug-13-2019, 06:26 AM |