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

Fix Hypercert error #88

Open
davidgasquez opened this issue Jul 2, 2024 · 3 comments
Open

Fix Hypercert error #88

davidgasquez opened this issue Jul 2, 2024 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@davidgasquez
Copy link
Owner

Seems the hypercerts endpoint changed.

dagster._core.errors.DagsterExecutionStepExecutionError: Error occurred while executing op "raw_hypercert_claims"::

tenacity.RetryError: RetryError[<Future at 0x7f2db20f6010 state=finished raised HTTPError>]

Stack Trace:
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/dagster/_core/execution/plan/utils.py", line 54, in op_execution_error_boundary
    yield
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/dagster/_utils/__init__.py", line 468, in iterate_with_context
    next_output = next(iterator)
                  ^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/dagster/_core/execution/plan/compute_generator.py", line 141, in _coerce_op_compute_fn_to_iterator
    result = invoke_compute_fn(
             ^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/dagster/_core/execution/plan/compute_generator.py", line 129, in invoke_compute_fn
    return fn(context, **args_to_pass) if context_arg_provided else fn(**args_to_pass)
                                                                    ^^^^^^^^^^^^^^^^^^
  File "/home/runner/work/gitcoin-grants-data-portal/gitcoin-grants-data-portal/ggdp/assets/other.py", line 190, in raw_hypercert_claims
    result = get_hypercerts(HYPERCERTS_ENDPOINT, window_creators)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/tenacity/__init__.py", line 336, in wrapped_f
    return copy(f, *args, **kw)
           ^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/tenacity/__init__.py", line 475, in __call__
    do = self.iter(retry_state=retry_state)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/tenacity/__init__.py", line 376, in iter
    result = action(retry_state)
             ^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/tenacity/__init__.py", line 419, in exc_check
    raise retry_exc from fut.exception()

The above exception was caused by the following exception:
requests.exceptions.HTTPError: 410 Client Error: Gone for url: https://api.thegraph.com/subgraphs/name/hypercerts-admin/hypercerts-optimism-mainnet

Stack Trace:
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/tenacity/__init__.py", line 478, in __call__
    result = fn(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^
  File "/home/runner/work/gitcoin-grants-data-portal/gitcoin-grants-data-portal/ggdp/assets/other.py", line 171, in get_hypercerts
    response.raise_for_status()
  File "/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/requests/models.py", line 1024, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
@davidgasquez davidgasquez added the bug Something isn't working label Jul 2, 2024
@davidgasquez davidgasquez self-assigned this Jul 2, 2024
@davidgasquez
Copy link
Owner Author

@DistributedDoge, seems the endpoint has been removed.

https://thegraph.com/hosted-service/subgraph/hypercerts-admin/hypercerts-optimism-mainnet

Getting this message from their GraphiQL.

This endpoint has been removed. If you are the owner of this subgraph you can upgrade it by going here: https://thegraph.com/hosted-service. If you have any questions, reach out to support@thegraph.zendesk.com. Learn more about why this happening here: https://thegraph.com/docs/en/sunrise/#upgrading-subgraphs-to-the-graph-network

Any ideas/thoughts?

davidgasquez added a commit that referenced this issue Jul 2, 2024
Disabled hypercert_claims SQL model and raw_hypercert_claims asset function due to issue [#88](#88). Commented out the `id` field in the SQL model.
@DistributedDoge
Copy link
Collaborator

DistributedDoge commented Jul 2, 2024

Problem is The Graph rolled-out protocol wide upgrade where every subgraph either migrates to hosted service or stops working. I believe this migration has to be done by subgraph author, not by us as consumers.

https://thegraph.com/blog/sunbeam-upgrade-window/

The good news is that all hypercerts are created by a single contract which emits after every mint so using Covalent or RPC-node we can get the same information directly from on-chain events.

@davidgasquez
Copy link
Owner Author

Thanks for digging and sharing the details! 🔍

I wasn't aware at all of these changes going on at The Graph.

Relying on Covalent sounds good! For now, I've disabled them as they were blocking all other assets.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants