LibCST/libcst
Amethyst Reese f9536b522f
Pass root path to FullyQualifiedNameProvider (#867)
This allows FullyQualifiedNameProvider to work with absolute paths,
rather than assuming all paths given will be relative to the current
directory. This enables tools like Fixit to provide a root path, and
have the FullyQualifiedNameProvider correctly scope the final results
relative to that root path.

This does require that both the root path and the given file paths
match the other as relative or absolute, due to the
`calculate_module_and_package` helper comparing file paths relative
to the root path, but this seems like a reasonable tradeoff, and
unlikely to cause a problem in normal use cases.
2023-02-22 14:36:10 -08:00
..
_nodes [parser] bail on deeply nested expressions (#718) 2022-07-04 14:45:42 +01:00
_parser Several trivial refactors (#770) 2022-09-14 14:33:45 +01:00
codegen Several trivial refactors (#770) 2022-09-14 14:33:45 +01:00
codemod [AddImportsVisitor] Docstring Check Only for the Top Element of the Body (#841) 2023-01-24 13:51:56 +00:00
helpers Pass root path to FullyQualifiedNameProvider (#867) 2023-02-22 14:36:10 -08:00
matchers Script to regenerate test fixtures (#872) 2023-02-22 12:35:23 -08:00
metadata Pass root path to FullyQualifiedNameProvider (#867) 2023-02-22 14:36:10 -08:00
testing Fix all type errors (#579) 2022-01-05 18:13:01 +00:00
tests Script to regenerate test fixtures (#872) 2023-02-22 12:35:23 -08:00
__init__.py Implement PEP-634 - Match statement (#568) 2021-12-30 10:00:51 +00:00
_add_slots.py add slots to base classes, @add_slots takes bases into account (#605) 2022-01-16 14:14:32 +00:00
_batched_visitor.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
_exceptions.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
_flatten_sentinel.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
_maybe_sentinel.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
_metadata_dependent.py Implement lazy loading mechanism for QualifiedNameProvider (#720) 2022-07-09 08:34:29 +01:00
_position.py Fix all type errors (#579) 2022-01-05 18:13:01 +00:00
_removal_sentinel.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
_tabs.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
_type_enforce.py Drop support for running libcst using a python 3.6 interpreter (#663) 2022-03-24 11:31:48 -04:00
_typed_visitor.py Several trivial refactors (#770) 2022-09-14 14:33:45 +01:00
_typed_visitor_base.py Several trivial refactors (#770) 2022-09-14 14:33:45 +01:00
_types.py Pass root path to FullyQualifiedNameProvider (#867) 2023-02-22 14:36:10 -08:00
_visitors.py Fix license headers (#560) 2021-12-28 11:55:18 +00:00
py.typed support mypy using py.typed 2019-09-16 13:49:08 -07:00
tool.py Fix the bug that the use of formatter in codemods has undetermined target Python version, resulting in hard-to-reason-with behavior (#771) 2022-09-14 14:31:36 +01:00