tree-sitter/py-tree-sitter

Release Python GIL when possible

Ouverte

#111 ouverte le 23 mai 2022

 (10 commentaires) (2 réactions) (0 personne assignée)C (193 forks)github user discovery
help wanted

Métriques du dépôt

Stars
 (1 490 étoiles)
Métriques de merge PR
 (Merge moyen 4j 14h) (7 PRs mergées en 30 j)

Description

I'm looking to search several million source files using the tree-sitter query interface. I'd love to use a thread pool in Python for this. Would it be possible to make a thread-safe Query.captures method that released the GIL?

I tried doing it in https://github.com/grantjenks/py-tree-sitter-languages but couldn't figure it out this evening (not sure it's possible with the current interface).

Guide contributeur