How to make a feature for different width glyphs for the same letter to alternate in use

Hello! I was wondering how can I make a feature in order to make a font with different widths so each letter has a wide and a condensed version and with the features you make them all be wide-condensed-wide-condensed …etc when in use.
I tried to make alternate substitutions by creating two classes @wide @condensed and making them a calt feature sub @wide @wide’ by @condensed;
this worked only in one letter, the rest of the letters in the group didn’t care.

I tried two ways to set the groups.
First I had @wide with A B C and @condensed with A.ss01 B.ss01 C.ss01
It didn’t work. Instead I made @wide A B C and @condensed a b c. This time it only worked with the Aa meaning that when i wrote AAAA i got AaAa. It’s a little step.
I wonder if the calt feature will only change each one letter for the other version if they appear twice but not detecting the situation and seeing that if the letter before was a wide then the next one will have to be a condensed one no matter what letter it is.
It’s a little hard to explain but I tried my best.

Example: To give you a reference, what I’m trying to do it’s that I write GOOD MORNING and get GoOd MoRnInG.
If you could please tell me what I’m doing wrong or some other way to make the feature that would be great! Thanks!

The code is correct. How/where are you testing your feature?

Read this please:
https://www.glyphsapp.com/tutorials/features-part-3-advanced-contextual-alternates

Your case is covered at the beginning. Be sure to check for cases such interruptions of glyphs that are not part of the classes (space, punctuation).

Thank you. That was the Tutorial I was following,
For some reason I can make de feature substituting the upper case for the lower case and It works but if I try it with stylistic alternates, Glyph crashes and doesn’t work.
By now I’m only testing it on Glyphs text editor with the feature activated.

What version of Glyphs do you have? Did you send crash reports? Can you send me the .glyphs file (to support at this domain)?

Don’t forget to compile every time you want to try the feature. Maybe the classes were not set up right. Technically, it’s better to substitute stylistic sets rather than upper and lower cases.

It crashes when I hit compile, then it restarts and it works. But that’s only if i do it with the lower case. With stylistics sets crashes and doesn’t work he feature. In this case It’s all uppercase but I understand it would be better with stylistics. Trust me if it worked I would do it the proper way.
Thank you!

I have the latest 2.3 version installed.
I sent two crash reports since it shuts down when i update the features and when I compile… but for some reason when it restarts the features and the program works.
Sure I will send it right now!
Thank you!

Thank you! It worked!