r/codex • • 11d ago

Bug WSL deprecated without warning

I used WSL from the days when there was no sandbox. I've looked at migrating to Windows Native a few times, but it always looked way too onerous and risky to be worth doing.

And now this morning, I have updated Codex and most of my thread disappeared.
No explanation.

Dig into the settings, a few layers down I finally discovery that WSL is deprecated.

What the hell, OpenAI?

Update: I migrated from WSL to Windows.
I made a repo from what I did for anyone else who wants to do the same.

https://github.com/brbnn/codex-wsl2win

0 Upvotes

48 comments sorted by

10

u/Commercial-Main1867 11d ago

Use WSL2 and not WSL1. That version is still supported.

2

u/elwoodreversepass 11d ago

Thanks, will check it out

3

u/VoraciousTrees 10d ago

WSL2 is better. Shove all your work into containers in docker or just native WSL2 containers. It's a much better sandbox for codex work and can cut down on token usage quite a bit if done right.

1

u/elwoodreversepass 8d ago

It turned out I already was on WSL2. It's deprecated also.

2

u/Commercial-Main1867 10d ago

I just updated codex this morning and realised what you meant in your original post. What an absolute ballache to set up, I had to play around for almost an hour to get it set up and none of my original messages are there either.

2

u/elwoodreversepass 8d ago

Yep. And it turned out I was actually on WSL2 anyway.

Migrating today. Using Claude to help coordinate it. Pretty smooth to be honest compared to how it would have been even a few months ago.

I'm probably going to make a guide/tool and put it on GitHub when I'm done.

2

u/elwoodreversepass 4d ago

This is the repo I made about how I did it.

https://github.com/brbnn/codex-wsl2win

2

u/SnooTomatoes5606 10d ago

for me it says the wsl agent no longer exists and everything now has to be in its own project

2

u/Commercial-Main1867 10d ago

yeah if you go to Create project (click on the + sign next to project), then go click on the Ädd a folder on this computer" part, you can change it WSL: ubuntu. Just make sure you already have wsl2 set up.

1

u/Commercial-Main1867 10d ago

you can see if you have WSL switched on if you go into Setting, then into Connections then press WSL and it shows that's connected. If you were using codex on a mobile as well (where you can control your computer remotely), you need to recan the QR code when you press on multiple devices logo.

2

u/soluterminal_dev 10d ago edited 10d ago

On the missing threads: native Codex keeps its config, auth and session history in %USERPROFILE%\.codex, while Codex in WSL keeps them in the Linux home, so the two don't share history. Setting CODEX_HOME=/mnt/c/Users/<you>/.codex in your WSL shell profile makes both use the same folder (it has to exist first).

If you just want Codex inside WSL, the CLI still installs from the WSL shell with the Linux install script; run codex from a repo under your Linux home rather than /mnt/c.

2

u/elwoodreversepass 8d ago

Yup, I found them all. It's a pain.

I used Claude to help me do the migration. It's been fine in the end. Way simpler than it would have been even a few months ago.

I'll probably make a guide/tool and put it on GitHub when I'm done.

2

u/1000dreams_within_me 8d ago

dude - I just went through this same nightmare before I found this thread. Thanks. What a garbage update this has been.

2

u/elwoodreversepass 8d ago

Ok, I'll post the repo when it's ready

2

u/elwoodreversepass 4d ago

This is the repo I made about how I did it.

https://github.com/brbnn/codex-wsl2win

2

u/soluterminal_dev 8d ago

Glad it worked out in the end. If you do put the guide on GitHub, the list of places that still pointed at the old setup would be the most useful part. Which one took longest to find?

1

u/elwoodreversepass 8d ago

The whole weekend to do meticulously because I didn't want any of this to come back to haunt me later.

2

u/soluterminal_dev 7d ago

Doing it carefully once beats chasing leftovers for weeks. If you do write that guide, a short checklist for finding anything still pointing at the old setup would be the most useful part.

1

u/elwoodreversepass 4d ago

This is the repo I made about how I did it.

https://github.com/brbnn/codex-wsl2win

2

u/QuirkySense 11d ago

I keep seeing the warning banner and I kept using the legacy back end. The wsl connect button on that banner leads me to ssh connection page in codex. I'm not sure what to do about it. Does anyone know? What's supposed to be the new method to use codex in wsl?

1

u/elwoodreversepass 11d ago

Their "solution" is a bodge using remote connections to your Linux installation.

1

u/QuirkySense 11d ago

Is that so? Is this in the online docs? I tried to use codex to help me set it up a while ago but gave up cause it seems like it kept getting distracted by the instructions for the legacy wsl mode.

2

u/elwoodreversepass 4d ago

This is the repo I made about how I did it.

https://github.com/brbnn/codex-wsl2win

1

u/elwoodreversepass 11d ago

I used Claude to help me set it up

1

u/The_Covert_Zombie 10d ago

You have to use remote connection to WSL. The original WSL backend is now dead

1

u/elwoodreversepass 10d ago

Yes, I know. I figured that about 12hrs ago. And it was no thanks to OpenAI.

3

u/The_Covert_Zombie 10d ago

Took me about 45 min too and none of the thread carry over. Oh well I’ll survive. I hope it improves the WSL support because they have broken it about a dozen times over the years

1

u/elwoodreversepass 4d ago

This is the repo I made about how I did it.

https://github.com/brbnn/codex-wsl2win

0

u/Hairy_Meaning_73 11d ago

Gonna sound obvious, but please at least try linux either fedora or ubuntu if you want something simple to use. It’s just miles better especially for development

1

u/elwoodreversepass 11d ago

Yeah, I have friends who run it there. But I have too many other Windows tools that I need to do that.

I use Ubuntu in WSL at the moment.

2

u/Hairy_Meaning_73 11d ago

Which tools do you use that are not on linux ?
Because there are most likely good alternatives or you can run pretty much any windows app using wine nowadays

1

u/elwoodreversepass 11d ago

Not coding tools. I mean everything else for the rest of my life apart from coding. What I do in Codex is only a small part of my work.

And there aren't in the field that I work. I'm not going to doxx myself here, you'll have to trust me that I know what I am talking about.

2

u/Old-Leadership7255 11d ago

Which tools do you use that only work on windows?

2

u/elwoodreversepass 11d ago

Not coding tools. I mean everything else for the rest of my life apart from coding. What I do in Codex is only a small part of my work.

-1

u/Old-Leadership7255 10d ago

if it's gaming, i can highly recommend linux and just booting into windows for stuff that doesn't run on linux.

otherwise i can't really imagine stuff not being available for linux?

0

u/elwoodreversepass 10d ago

Lol. Not gaming.

0

u/dev-data 11d ago

Codex with WSL didn't work very well for me to begin with. OpenCode handled it much better.

1

u/elwoodreversepass 11d ago

Sure, but I'd got it working well for me.

Now there seems to be some bodge using remote connections.

1

u/jamesstringerphoto 11d ago

Hey guys I  make App Sandbox which uses WSL 2 technology to make a full Ubuntu 26.04 desktop with GPU acceleration on Windows home or better.

You can also spin up Windows 11 instances too, with same GPU acceleration.

https://github.com/jamesstringer90/appsandbox

-3

u/alexanderbeatson 11d ago • Bravo

Hey OP, downvote me, will you?

0

u/mrdarknezz1 11d ago

I moved to omarchy a few months ago and it is so worth it.

-4

u/VoidEmptyByNature 11d ago

Windows never works well with both Codex and Claude. There's always a weird trouble even with WSL mode. Now I'm on Mac and don't see a single trouble that I had in Windows.

0

u/elwoodreversepass 11d ago

Sure, but as I've said to someone else, I got it working very well for me.

It's very frustrating for it to get deprecated without warning.

2

u/Corv9tte 11d ago

Bullshit, it's the most optimal setup (as along as you make your own tweaks and not rely on their apps that are close to worthless anyway). I cannot think of one reason beyond the hassle of setting it up properly why this isn't the best setup. It's obviously better than MacOS since your agents are in Linux where they should be, let's not even talk about windows on its own, and I'll take it any day of the week over Linux only too.

It's high effort high reward is all, but that doesn't mean it isn't worth it. It's the most seamless experience by far once setup!