ember-cli-conditional-compile icon indicating copy to clipboard operation
ember-cli-conditional-compile copied to clipboard

Ember 4.x compatibility and other fixes

Open halfbyte opened this issue 2 years ago • 6 comments

This is more an inquiry than a bug report, please let me know if I should write an email to someone instead.

We've been using our own fork of this for a while at Focusrite-Novation and are somewhat dependent on it. The changes we made to our fork so far are:

  • Enable us to override the environment (As we have multiple environments and dev/test/prod is not enough for us)
  • Fix #59 by replacing files with almost empty (/**/) files instead of removing them from the tree. I haven't checked yet if the underlying bug is fixed in ember-cli so maybe this isn't needed anymore.

Over the course of this week I have started to investigate what it would take to make this work on Ember 4.x - It is mainly small things apart from the completely changed API for compiler plugins. Also, the test suite still uses the old test syntax and is currently failing anyway.

I have a branch at my fork that has a green test suite but it has a ton of changes to the dependencies and is quite safely not compatible to older ember versions - I've ran ember-cli-update against it and used a slightly modified version of the generated ember-try config that tests this against modern Ember versions and ignores the terser vs. uglify issue.

This fork does not include the additional changes mentioned above.

I am happy to open up a PR for both the modernisation and the other changes if it would make sense. Feel free to look at my fork and tell me if maybe you would want to update it in more granular steps if possible. The fork was just a way for me to force myself through the bunch of issues I encountered on my way to get green tests,

We would be really happy if we could switch back to the canonical npm module in the future and we would be willing to spend additional time on future maintenance if needed.

halfbyte avatar Apr 08 '22 19:04 halfbyte

Okay, I guess no answer is also sort of an answer in this context.

No worries, I am not trying to put pressure on anyone here, just acknowledging the status quo. I know how difficult the maintainer situation in general in Ember land is right now.

If you are in need of 4.x compatibility, please check and test my fork and let me know if things break for you. Eventually I might publish that as a separate package if this here turns out to be truly abandoned.

halfbyte avatar May 16 '22 12:05 halfbyte

Hey @halfbyte! The original maintainer got enticed by the dark side (Rails) so I don't think you'll see him around here any more. I do have merge and release permissions myself though and I'm still interested in seeing this project move forward.

Adding 4.x compatibility is great but it'd be great if you could keep 3.x support too (I'm still on 3.x).

Seems like the first priority should be getting the test suite passing. After that, if you could break up your changes into bite-sized pieces that would be great (or half-bytes).

calvinlough avatar May 17 '22 01:05 calvinlough

Hey @calvinlough thanks for your answer, it's good to have someone to talk to!

Couple of questions before I can start:

  • Would you be okay to move from Travis to GH actions so that we can be relatively close to the ember addon blueprint and also use a more future proof platform?
  • Definitely will keep 3.x compatibility. All changes I did so far do work with the last two 3.x LTS versions. Does [this ember-try config] look useful to you? (We can of course discuss the finer details in a PR).

halfbyte avatar May 17 '22 11:05 halfbyte

Yep, GH actions sounds great. When you say [this ember-try config] did you intend to put a link in there?

calvinlough avatar May 17 '22 12:05 calvinlough

@calvinlough Haha, of course. To be fair, after reviewing it, it's probably more succinctly summarised as: Cutoff at 3.15 (I think 3.15 is where the new functional API we would need for 4.x was introduced) and let ember try figure out the rest.

halfbyte avatar May 17 '22 12:05 halfbyte

Sounds great

calvinlough avatar May 17 '22 12:05 calvinlough