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

Remove the pinned version on solargraph dependency #49

Merged
merged 3 commits into from
Dec 2, 2022

Conversation

iftheshoefritz
Copy link
Owner

@iftheshoefritz iftheshoefritz commented Nov 11, 2022

We get constant PRs from people trying to update the version of solargraph because dependant is complaining. I'm not sure that we benefit from pinning it anymore. I think that the versions that have real problems for solargraph-rails are quite old now.

Although there is a PR for this already, we're waiting for it to be updated with the latest commits on main, I'd rather get this in asap.

@iftheshoefritz
Copy link
Owner Author

iftheshoefritz commented Nov 11, 2022

By marking items as skip:true as tests fail I can see the patterns:

  • The failing tests seem to be missing a bunch of stuff that devise adds (devise_for, devise_omniauth_callback etc)
  • .pry on every class we check (which I'm assuming is added by the Pry gem and I'm not sure should be there?)
  • ditto .descendants

I also notice that the rails7 routing specs point to rails6/routes.yml ; fix in #50

@alisnic
Copy link
Collaborator

alisnic commented Nov 11, 2022

@iftheshoefritz that's why I was so reluctant to release version requirements, I wasn't getting any consistent results. The code relies heavily on solargraph internals, and we cannot just yolo bump. To be more confident we need to spend more time in testing infra, which me personally don't have right now :(

@iftheshoefritz
Copy link
Owner Author

@alisnic I was able to fix some things that were consistently wrong in the tests with #50. I'm ok with doing the investment in the tests.

I think I'm ok with turning off the devise tests if everything else is passing.

@iftheshoefritz iftheshoefritz force-pushed the unversioned-solargraph branch 3 times, most recently from 200f048 to 2155152 Compare December 2, 2022 16:53
This is a bit of a hack, I don't know why solargraph wouldn't include
.descendants and/or whether it actually is included in any version of Rails. But
if this one change is enough to keep the tests passing I don't really care to
investigate deeply.

If other stuff fails, then we probably have a deeper problem.
Testing multiple definitions in a single spec means that if one file has a
problem, the entire test fails and we get no feedback about what might else
have failed.

Now, move the loop outside the test so that each definition file has its own
test and we can get feedback on all files at once.
@iftheshoefritz iftheshoefritz merged commit c7a2dc4 into main Dec 2, 2022
@iftheshoefritz iftheshoefritz deleted the unversioned-solargraph branch December 2, 2022 17:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants