V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  fanhaipeng0403  ›  全部回复第 12 页 / 共 27 页
回复总数  540
1 ... 8  9  10  11  12  13  14  15  16  17 ... 27  
2019-01-09 13:12:00 +08:00
回复了 whodareswins 创建的主题 程序员 想了半天才决定发,这是我的年终总结
你这一年过的真不容易啊
2019-01-09 13:02:07 +08:00
回复了 akmonde 创建的主题 Python celery 时间不同步求破,导致 soft_time_limit 失效 [V 币感谢]
设置个环境变量 export TZ = = 'Asia/Shanghai'

为啥不直接升到 4
2019-01-08 17:03:43 +08:00
回复了 duzhonglin 创建的主题 Python Python 不同文件变量调用
legb ?
2019-01-07 14:44:04 +08:00
回复了 JohnLou 创建的主题 问与答 大龄单身怎么办,有点忧伤。
@66beta 匿不了。v2ex 留言删不掉了
2019-01-07 14:43:22 +08:00
回复了 JohnLou 创建的主题 问与答 大龄单身怎么办,有点忧伤。
26, 大 nmb
我都 28 了~

我不想这事
2019-01-07 11:48:58 +08:00
回复了 Coder1991 创建的主题 职场话题 得了这个病,怎么继续做程序员?
没人在乎这个,你就说久坐起来活动下,别人也无话可说。
前排与大佬合影
2019-01-06 15:42:23 +08:00
回复了 hxse 创建的主题 Python 请问 Python 中的 -> 是什么意思
type hint
2019-01-06 15:40:15 +08:00
回复了 tqknight 创建的主题 Python apply_async 多进程异步调用,子任务不执行,居然没找到原因
2019-01-06 15:40:10 +08:00
回复了 tqknight 创建的主题 Python apply_async 多进程异步调用,子任务不执行,居然没找到原因
Note that with asynchronous programming you don't need to manually deal with result queues - apply_async returns a AsyncResult instance which can be used to get the result: result.get(). This uses an underlying result (out-) queue and so you simply need to return in your target function. Also if you use result.get() and you passed a Queue instance as an argument to the target function it will raise a RuntimeError
2019-01-05 21:08:12 +08:00
回复了 simoncos 创建的主题 Python Python 功能点实现:函数级/代码块级计时器
@simoncos 可能没啥用 哈哈
2019-01-05 21:07:58 +08:00
回复了 simoncos 创建的主题 Python Python 功能点实现:函数级/代码块级计时器
2019-01-05 21:06:04 +08:00
回复了 simoncos 创建的主题 Python Python 功能点实现:函数级/代码块级计时器
卧槽 我刚写了个类似的文章~
2019-01-05 01:18:14 +08:00
回复了 smallgoogle 创建的主题 Python Linux 下 multiprocessing 的结束子进程问题
```
class CountdownTask:
def __init__(self):
self._running = True

def terminate(self):
self._running = False

def run(self, n):
while self._running and n > 0:
print('T-minus', n)
n -= 1
time.sleep(5)

c = CountdownTask()
t = Thread(target=c.run, args=(10,))
t.start()
c.terminate() # Signal termination
t.join() # Wait for actual termination (if needed)
```
2019-01-05 01:17:40 +08:00
回复了 smallgoogle 创建的主题 Python Linux 下 multiprocessing 的结束子进程问题
t.daeman =true
老大做完,小弟就不做了

t.join()
老大等小弟做完继续在做


class CountdownTask:
def __init__(self):
self._running = True

def terminate(self):
self._running = False

def run(self, n):
while self._running and n > 0:
print('T-minus', n)
n -= 1
time.sleep(5)

c = CountdownTask()
t = multiprocessing.Process(target=c.run, args=(10,))
t.start()
c.terminate() # Signal termination
t.join() # Wait for actual termination (if needed)
老大给小弟给信号



不知道理解的对不对、、、
ipython manage.py shell

%debug
2019-01-04 15:52:44 +08:00
回复了 zhangqilin 创建的主题 职场话题 后端工作 1 年 2 个月感慨
@liprais 不大么~
1 ... 8  9  10  11  12  13  14  15  16  17 ... 27  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2737 人在线   最高记录 6543   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 48ms · UTC 14:43 · PVG 22:43 · LAX 07:43 · JFK 10:43
Developed with CodeLauncher
♥ Do have faith in what you're doing.