Skip to content
This repository was archived by the owner on Nov 13, 2022. It is now read-only.

Fix support for Atom 1.37 (and maybe a few older versions) #36

Merged
merged 6 commits into from
Jun 2, 2019

Conversation

rixo
Copy link
Contributor

@rixo rixo commented May 19, 2019

I've recently upgraded to Atom 1.37 (from 1.26) and it broke recent files finder.

The cause is a mandatory arg that has recently been added to the constructor of FuzzyFinderView you're extending: atom/fuzzy-finder@6fbfe35#diff-e0ee5d9b066d4ea2a281ddaf5be6993eR26

I looked into fuzzy-finder's code to see how it gets its metricsReporter and it turns out it is a service it consumes. So I could replicate into this project and it fixed my error.

I'm not too sure that my fix is semantically correct since I don't know anything about metricsReporter. And I'm not too strong on the Coffee side. But I'd really like recent files finder to continue working in recent Atoms, so here's a PR that you can at least use for reference.

Copy link
Owner

@viddo viddo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi there!
Ouch, good catch! I guess I have not had to use my this in a while myself so had not noticed.

In addition to the inline suggestion (re: getMetricsReporter), can you remove the consumeMetricsReporter function and package.json entry? I think it's better if this plugin don't pollute their metrics with wrong data, and I don't think we're required to consume that service, right?

Thanks for the pull-request!

@rixo
Copy link
Contributor Author

rixo commented May 24, 2019

I must confess I fail to appreciate the ins and outs of these metrics... But you must be right, we can't do harm if we do nothing.

So I added a noop proxy and cleaned things a bit following this change.

Sorry for butchering the commit history.

@viddo viddo merged commit 770682b into viddo:master Jun 2, 2019
@viddo
Copy link
Owner

viddo commented Jun 2, 2019

No worries, thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants