Skip to content
This repository was archived by the owner on Sep 9, 2025. It is now read-only.
This repository was archived by the owner on Sep 9, 2025. It is now read-only.

"Unexpected attribute syntax_type on node of type scope" in stderr #453

Description

@bm-w

We’re seeing a lot of these messages in standard-error:

Unexpected attribute syntax_type on node of type scope

These are emitted here, and stem from the fact that "syntax_type" is not included in SCOPE_ATTRS:

static SCOPE_ATTRS: Lazy<HashSet<&'static str>> =
Lazy::new(|| HashSet::from([TYPE_ATTR, IS_EXPORTED_ATTR, IS_ENDPOINT_ATTR]));

I’m not sure whether "syntax_type" should be in SCOPE_ATTRS, or the attribute is erroneously added to scope nodes in TSGs — seems to me it’s the former, but I’ll leave that up to you.

Activity

  1. hendrikvanantwerpen commented on Jul 18, 2024

    @hendrikvanantwerpen
    Contributor

    Thanks for the report! For which language are you getting these errors? And is this using a released version or the repo's main branch?

    In principle, setting syntax_type in scope nodes doesn't make much sense, but we also allow source_node on all nodes it seems, which is kind of similar.

  2. bm-w commented on Jul 18, 2024

    @bm-w
    Author

    Not sure about the source language — this came from an internal report so I’ll try to chase that down. I’m pretty sure it’s one of the languages in this repo (Java/JS/Py/TS). It’s tree-sitter-stack-graphs 0.8.1

  3. CleanCut commented on Sep 9, 2025

    @CleanCut

    The github/stack-graphs repository is no longer being maintained. As per #502, I'm closing all issues and pull requests before archiving the repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions