mattchan-tencent

Results 12 comments of mattchan-tencent
trafficstars

@rpkak Yes, if you could please open a PR to make fetching `job1` within `job2` more elegant, it would be appreciated. --- > So there are multiple ways we can...

Also, if you implement a decorator, it might be nice to increase the 500s result timeout automatically to whatever the job timeout duration is. Fetching within 500s is reasonable, but...

> I agree, I think we should definitely make reaching into parent jobs easier, something like this: > > ```python > for job in job2.dependencies: > print(job.result) > ``` This...

> 2. The decorator changes your function's signature in an implicit way that may break certain codes that access `args` and `kwargs`. Yes, actually I had problems with this. I...

One last comment for the night: I think one structural weakness of the decorator method (explicit or integrated into serialize/deserialize) is that you are pinning the return type of `job1`...

Hmm... I think this still has some problems with locality. If I wanted to change `x` from a job result to a constant, I would have to adjust the decorator...

Hi @selwin, I think I figured out a possible way to work around it. We can store the reduction job ID in the metadata, and as new child jobs are...

Answering the second question after a bit of investigation: The key bit of code is at https://github.com/rq/rq/blob/c5a1ef17345e17269085e7f72858ac9bd6faf1dd/rq/job.py#L990. In order to accept failed jobs as well, I think we need either...

@selwin Sounds good. I've PR'd it. Please let me know if it looks acceptable, or feel free to make changes. I'm new to the codebase.

@arterrey I'm a bit of a rq newbie, but I was reading the source code for something else and came across Worker.procline(). Is that what you wanted?