Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

exceptions from: sfc.main_page() #259

Closed
wants to merge 2 commits into from

Conversation

dneise
Copy link
Member

@dneise dneise commented Jan 23, 2018

I was called about every hour or two the entire night with exceptions like this:

Traceback (most recent call last):
  File "/opt/conda/lib/python3.6/site-packages/custos/checks/__init__.py", line 82, in wrapped_check
    self.check(*args, **kwargs)
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/checks.py", line 38, in check
    if all([f() for f in self.checklist]):
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/checks.py", line 38, in <listcomp>
    if all([f() for f in self.checklist]):
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/debug_log_wrapper.py", line 9, in log_call_and_result
    result = wrapped(*args, **kwargs)
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/conditions.py", line 96, in is_data_run
    result = sfc.main_page().system_status
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 49, in wrapped_f
    return Retrying(*dargs, **dkw).call(f, *args, **kw)
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 212, in call
    raise attempt.get()
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 247, in get
    six.reraise(self.value[0], self.value[1], self.value[2])
  File "/opt/conda/lib/python3.6/site-packages/six.py", line 686, in reraise
    raise value
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 200, in call
    attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/retry_smart_fact_crawler.py", line 77, in main_page
    return sfc.main_page(url=url, timeout=timeout, fallback=True)
  File "/opt/conda/lib/python3.6/site-packages/smart_fact_crawler/__init__.py", line 319, in main_page
    trigger_val, trigger_unit, _ = get(table, 5, 1, default='nan nan nan').split()
ValueError: not enough values to unpack (expected 3, got 2)
2018-01-23 04:01:25,700 - custos.checks.FactIntervalCheck - ERROR - Exception while running check
Traceback (most recent call last):
  File "/opt/conda/lib/python3.6/site-packages/custos/checks/__init__.py", line 82, in wrapped_check
    self.check(*args, **kwargs)
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/checks.py", line 38, in check
    if all([f() for f in self.checklist]):
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/checks.py", line 38, in <listcomp>
    if all([f() for f in self.checklist]):
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/debug_log_wrapper.py", line 9, in log_call_and_result
    result = wrapped(*args, **kwargs)
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/conditions.py", line 96, in is_data_run
    result = sfc.main_page().system_status
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 49, in wrapped_f
    return Retrying(*dargs, **dkw).call(f, *args, **kw)
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 212, in call
    raise attempt.get()
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 247, in get
    six.reraise(self.value[0], self.value[1], self.value[2])
  File "/opt/conda/lib/python3.6/site-packages/six.py", line 686, in reraise
    raise value
  File "/opt/conda/lib/python3.6/site-packages/retrying.py", line 200, in call
    attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
  File "/opt/conda/lib/python3.6/site-packages/shifthelper/retry_smart_fact_crawler.py", line 77, in main_page
    return sfc.main_page(url=url, timeout=timeout, fallback=True)
  File "/opt/conda/lib/python3.6/site-packages/smart_fact_crawler/__init__.py", line 319, in main_page
    trigger_val, trigger_unit, _ = get(table, 5, 1, default='nan nan nan').split()
ValueError: not enough values to unpack (expected 3, got 2)

@dneise
Copy link
Member Author

dneise commented Jan 23, 2018

I was stupid, the fallback=True for the main_page is already done here:

https://github.com/fact-project/shifthelper/blob/new_sfc/shifthelper/retry_smart_fact_crawler.py#L77

@dneise
Copy link
Member Author

dneise commented Jan 23, 2018

So this PR is useless

@dneise dneise closed this Jan 23, 2018
@dneise
Copy link
Member Author

dneise commented Jan 23, 2018

moved this to an issue instead: #260

@maxnoe
Copy link
Member

maxnoe commented Jan 23, 2018

It seems that the value is present but not as expected splittable in three values. Did something change in smartfact?

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.

2 participants