Skip to content

Conversation

nad2000
Copy link
Contributor

@nad2000 nad2000 commented Jun 14, 2018

a simple solution to solve the issues #58 and #61.
perhaps the rest of options would be helpful to supply with type too...

nad2000 added 2 commits June 14, 2018 15:59
a simple solution to solve the issue.
perhaps the rest of options would be helpful to supply with type too..
@codecov
Copy link

codecov bot commented Jun 14, 2018

Codecov Report

Merging #62 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #62   +/-   ##
=======================================
  Coverage   99.64%   99.64%           
=======================================
  Files           6        6           
  Lines         283      283           
  Branches       24       24           
=======================================
  Hits          282      282           
  Partials        1        1
Impacted Files Coverage Δ
src/flask_rq2/cli.py 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0afd162...0467a87. Read the comment docs.

@andreyfedoseev
Copy link

@jezdez what's necessary to merge this PR? It seems to fix the problem with setting the poll interval value.

@@ -118,8 +118,8 @@ def info(rq, ctx, path, interval, raw, only_queues, only_workers, by_queue,
@click.option('--name', '-n', help='Specify a different name')
@click.option('--path', '-P', default='.', help='Specify the import path.')
@click.option('--results-ttl', help='Default results timeout to be used')

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice to also update this option with type=int and maybe a default.

Been noticing this error when providing a value or a similar error (instead of str complains about None) without providing a value.

  File \"/usr/lib/python3.6/site-packages/rq/worker.py\", line 803, in perform_job
    started_job_registry=started_job_registry)
  File \"/usr/lib/python3.6/site-packages/rq/worker.py\", line 766, in handle_job_success
    finished_job_registry.add(job, result_ttl, pipeline)
  File \"/usr/lib/python3.6/site-packages/rq/registry.py\", line 43, in add
    score = ttl if ttl < 0 else current_timestamp() + ttl
TypeError: '<' not supported between instances of 'str' and 'int'
", "exc_info": "Traceback (most recent call last):
  File \"/usr/lib/python3.6/site-packages/rq/worker.py\", line 803, in perform_job
    started_job_registry=started_job_registry)
  File \"/usr/lib/python3.6/site-packages/rq/worker.py\", line 766, in handle_job_success
    finished_job_registry.add(job, result_ttl, pipeline)
  File \"/usr/lib/python3.6/site-packages/rq/registry.py\", line 43, in add
    score = ttl if ttl < 0 else current_timestamp() + ttl
TypeError: '<' not supported between instances of 'str' and 'int'

@jezdez jezdez merged commit 0420837 into rq:master Sep 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants