Skip to content

Commit 10d053c

Browse files
Small sorbet fix
1 parent 8d114d5 commit 10d053c

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,6 @@ To reduce the impact of those limitations, Packwerk is designed to avoid false p
8282
- Method calls and objects passed around the application are completely ignored. Packwerk only cares about static constant references. That said, if you want Packwerk to analyze parameters of a method, you can use [Sorbet](https://sorbet.org/) to define a type signature. Sorbet signatures are pure Ruby code and use constants to express types, and Packwerk understands that.
8383
- Support for custom Zeitwerk configuration is limited. If [custom ActiveSupport inflections](https://guides.rubyonrails.org/autoloading_and_reloading_constants.html#customizing-inflections) are used, Packwerk will understand that and everything is fine. However, if Zeitwerk is directly configured with [custom Zeitwerk inflections](https://github.com/fxn/zeitwerk#inflection) or to [collapse directories](https://github.com/fxn/zeitwerk#collapsing-directories), _Packwerk will get confused and produce false positives_.
8484

85-
TODO: Remove this
86-
8785
## Contributing
8886

8987
Bug reports and pull requests are welcome on GitHub at https://github.com/Shopify/packwerk.

test/support/rails_application_fixture_helper.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ def set_load_paths_for_external_packages_template
7373

7474
def create_new_engine_at_path(path)
7575
Class.new(Rails::Engine) do
76-
T.unsafe(self).define_method(:root) do
76+
T.bind(self, Class)
77+
define_method(:root) do
7778
path
7879
end
7980
end

0 commit comments

Comments
 (0)