Junie CLI Agent Not Starting

I just ran into this lame issue with Junie. The system cannot find the batch label specified - after_channel_oneshot.

Ok – so how did I get this? It’s super simple. I tried installing it via the command they give on their website: https://junie.jetbrains.com/

This is the command they give:
powershell -NoProfile -ExecutionPolicy Bypass -Command "iex (irm 'https://junie.jetbrains.com/install.ps1')"
After running that command, you restart powershell and junie and it works, normally. This time it wasn’t. I went through a load of debugging steps. Deleting caches, deleting other bats, etc… But the one thing that actually helped came from this StackOverflow post. The Line endings were wrong.

So – how to fix? I downloaded the install.ps1 file directly and converted the line endings to CRLF. I opened it in Notepad++ and used Edit > EOL Conversion > Windows (CR LF)

Then I ran powershell -ExecutionPolicy Bypass -File .\install.ps1 directly. BAM! It works. No more mad mad.

Kilo AI CLI Coding Agent

I’ve been working with Kilo CLI for the last day. So, this is first impressions. This is coming from working with Codex CLI for a few months. The following post comes from this experience. In this case I’m using GPT-5.5 medium in both Kilo and Codex.

The Kilo AI CLI has some cool features. I really appreciate the ability to connect with your existing provider. I like the auto-model routing. The interface is pretty cool, with a lot of themes to choose from. There is a persistent status section in the CLI that shows usage, context available, tokens used, modified files. It’s really cool.

However, I’ve consistently run into issues since attempting to use Kilo. And it’s not with the interface or the functionality of the software. It’s with the underlying tooling. Something about Kilo causes the LLM to do things that I don’t want it to do. Here’s an excerpt from my AGENTS.md file.

When the user pastes review feedback, follow the Review Feedback section below. Treat the feedback as a claim to verify, explain the conclusion, recommend the smallest correct fix, and ask before implementing unless the user explicitly asks for changes.
...
## Review Feedback

When addressing merge request or code review feedback, treat each comment as a claim to verify, not as an instruction to apply automatically.

- First confirm whether the reported problem is real by reading the relevant code paths and, when practical, reproducing or reasoning through the behavior.
- Validate suggested solutions before implementing them; they may be incomplete, too broad, or aimed at the wrong boundary.
- If the issue is valid, choose the smallest correct fix that changes the fewest lines and preserves existing intended behavior.
- If the issue is not valid, explain why with concrete code references or behavior.
- If a minimal fix could hide an inconsistent state, distinguish the legitimate case from the suspicious case and handle each explicitly.

That’s pretty clear about what I expect. My expectation is no changes unless it’s verified with me. Or unless I tell the agent to explicitly fix it. Over the last day I’ve given feedback to the agent and it continues to ignore my instructions, opting instead to make a change without verifying it with me. That’s frustrating.

Kilo Modes

Kilo comes with several modes out of the box. There’s a Code mode, a Plan mode, an Ask mode, a Debug mode, and an Orchestrator mode. Now, this frustration could be my fault for using the tool wrong. I started in “Code mode”. Perhaps, code mode, means that Kilo is going to strongly tell the LLM to write code, even if it contradicts my instructions. It could be my fault for not starting in ASK mode and then flipping to CODE mode. But… seriously. I’m not going to sit here switching modes all day when I expect the tool to be smart enough to follow instructions. If the tool is in code mode, and the instructions are “ask before coding” then the tool should ask. The mode should be inferred from the prompt. If the prompt is a question, then assume an answer is wanted. If the prompt is, fix this issue, then assume that a combination of debug+code is wanted. If the prompt is, implement this feature, then assume orchestrator+code is likely wanted.

Maybe that’s just me. But switching between modes seems like busy work for me.

Kilo Tooling

I have RTK set up on my machine and integrated into my AI agents. The tool exists as rtk and is callable by the AI agents. However, the code I was writing was in php and I don’t have php installed on my system. I do have it running in a container running on my system though. I have explicit instructions in my AGENTS.md file telling the Agent to look at local machine notes. My local machine notes tell the Agent all about how this current system uses Fedora and Podman for containers.

Today, Kilo failed hard on a few things:
– It did not use rtk. It attempted to use rtk php and when that failed it assumed rtk did not exist and didn’t use it anymore.
– It did not read my local notes. And because it did not read my local notes (despite being told to in the AGENTS file) it failed to validate my code using php
– It tried to use docker multiple times even though the local notes tell it to use podman

Working Verdict

I really like the concept of Kilo. Super cool interface, super cool themes, super cool status window, an auto-model selector. Kilo has a lot of good stuff going for it.

I’ve worked with Kilo and attempted to use it. It’s been an incredibly frustrating experience. Kilo is not reliable and it doesn’t listen.

Despite all the cool, and the hype, when the rubber meets the road Kilo is not up to snuff. Kilo is not up to snuff because Kilo ignores explicit directions.

My plan is to use Pi.dev. I’ve heard that it will work with the Kilo gateway. I probably won’t come back to Kilo, but who knows, they might update the tool to be more reliable. If they do, I’ll try it again.

Truenas SCALE MineOS Server Not Starting

This post is to serve basically as long term memory for me. I keep forgetting how to do this, and the original post I used to refer to is gone. (Well, at the time of this writing it is). That said, WaybackMachine is awesome and I was able to access the archived original post there.

However, for ease, I’m just going to repeat the steps here because it’s easy enough to do.

Install the right Java Version

As of this writing, the TrueNAS Scale MineOS App, does not come with Java 21 pre-installed. Every time the MineOS App is updated, Java 21 is blown away. So, you have to re-install it in the MineOS App Container.

Step 1 – Access the MineOS App Shell

Accessing the TrueNAS Scale MineOS shell

Step 2 – Run apt update

Step 3 – Run apt install openjdk-21-jdk

Start The Servers

Ok – now that you’ve updated the java version, you can go in and start your MineOS servers.

  1. Visit the Server page
  2. Select the correct profile from the Server Actions box. (i.e. 1.21.4)
  3. Select the correct runnable jar from the Java Settings box (i.e. minecraft_server.1.21.4.jar)
  4. Push the big green Start button
  5. Wait a bit and you should see the Server status checkbox flip from a red “Down” to a green “Up”

Here’s a couple screenies to help you get your bearings.

PHPStorm Classic Mode

So, one of the most annoying things IN MY LIFE has been when JetBrains started adding all of this random AI Assistant autocompletes to their IDE’s. I know I’m not alone, because there are even tickets like this one, How to Shut Off All this AI Crap?.

It’s not that I’m anti-AI – I’m anti-Intrusion. When I’m driving the car, I get to drive the car, not the AI Assistant. Unfortunately, the way JetBrains is adding AI into it’s editor feels very intrusive. And, also unfortunately, it’s a slog to go through all of the IDE settings to try and find every single little thing that needs to be turned off.

Luckily, you don’t need to! JetBrains has added some files that will allow you to selectively use AI tools. My favorite is dropping a .noai file in your project root. It’s easy to do, navigate to your project root in Powershell and run touch .noai. That’s it, all you need is an empty file to disable all the AI stuff in PHPStorm.

Now you can get back to PHPStorm Classic mode. LFG? Molten Core? … oops wrong classic mode.

But what about Junie?

That’s a valid question. Like I said, I’m not anti-AI. I actually like the coding agents, I’ve found them extremely helpful in certain circumstances. So, I wondered, will .noai disable all coding agents? Nope! It won’t. As of this writing .noai will disable the AI Assistant features in the IDE – but you can still use the Junie agent window. I don’t know if that’s an oversight or not, I actually recently heard that the Junie agent window is going away as they consolidate underneath the AI Assistant chat window.

The Better Junie Option (imo)

The better option, in my opinion, is to just use the Junie CLI. It’s currently in beta, and appears very usable from my testing. It’s integrated with your current JetBrains AI pricing model, so if you pay to use Junie within your IDE, then you are paying to use the CLI tool as well. I’ve found that I can open my own custom terminal, or use the built in IDE terminal, and open Junie via CLI. This gives me the best of both worlds, a powerful IDE and a powerful coding agent. I can use both when I want.

Not Quite .noai

Despite .noai working in most circumstances, I’m noticing little bits of AI crop back up. For example, inline Code Completion. I’m wanting classic intellisense, but JetBrains is giving me inline completion using cloud and local models. I had expected this to not happen, and indeed thought it wasn’t happening. But today, as I’m coding, I noticed phpstorm giving me ghosted AI completion hints. So, I navigated to phpstorm settings Editor > General > Code Completion > Inline and unchecked the Enable inline completion using language models: option.

.noai seems to have no effect on this setting

RocketChat server not running. Cancelling

As you might know, I’ve set up a RocketChat server recently on Digital Ocean. So far it’s been working great. An update every once and a while is all it needs.

However, yesterday, I attempted an update that failed. From then on every attempted update resulted in “RocketChat server not running. Cancelling”. This was very frutrating.

First, a few commands to try that might help:

  1. systemctl restart rocketchat.service – This will start your RocketChat server in case it is stopped.
  2. systemctl status rocketchat.service – Use this command to check the results of the previous command. Typically this will report that the service is “Active” if the previous command was successful.

In my case, the second command resulted in a “failed” state. The command itself gave me some information as to what the failure was, but not a lot of context as to what caused the failure. However, it did show me the process that it attempted to run. It said, ExecStart=/opt/nvm/versions/node/v14.19.3/bin/node /opt/Rocket.Chat/main.js (code=exited, status=1/FAILURE).

Alright! We’re getting somewhere. With that I was able to figure out what command failed and where that command was run. I navigated directly to the /opt/Rocket.Chat directory which was where the failure was occurring. From here I ran node main.js. The results of this command were much more helpful. They told me this, Error: Cannot find module '@meteorjs/reify/lib/runtime'. That looks like an issue with npm dependencies.

So, I poked around the Rocket.Chat directory structure and looked for dependencies for the Rocket.Chat server. I found what I was looking for in the /opt/Rocket.Chat/programs/server directory.

From this directory I ran two commands

  1. npm install
  2. npm ci

Afterwards I attempted to start the RocketChat server again using the systemctl restart rocketchat.service command. I checked it with systemctl status rocketchat.service and found that it was working now! RocketChat was back to running normally. The problem with “RocketChat server not running. Cancelling” was gone!

Getting Started with Rocket Chat Using Digital Ocean Backing

Note – RocketChat is making moves to severely limit their PAAS offering. They have baked in a bunch of limitations in the codebase and now claim that if you self-host you are using their “free version” ?


RocketChat (https://rocket.chat) is a chatting tool similar to MatterMost and Slack. It offers a self-managed community edition as well as some paid plans and is in active development. I’m just learning how to use it, so I’m planning on documenting my journey here.

I installed and set up RocketChat installed in a matter of minutes. The QuickStart guide, though short, includes most of what you need to get up and running.

To get started with your RocketChat instance on DigitalOcean you need to:

  1. Create a DigitalOcean account
  2. Install RocketChat
  3. Create an A Record that points to your Digital Ocean Droplet. *
  4. Setup your Let’s Encrypt certificate.
    rocketchatctl configure --lets-encrypt --root-url=YOUR_DOMAIN --letsencrypt-email=YOUR_EMAIL
  5. Update your RocketChat installation. Run the following commands from your droplet command line interface.
    1. Run sudo rocketchatctl upgrade-rocketchatctl
    2. Run sudo rocketchatctl update

* I use Cloudflare to host my DNS. In this case I had to disable the proxying on the A Record in order to allow RocketChat to work correctly.

Now visit your site (you should not run into any problems) and create your administration account.

One Note

From time to time the Rocket Chat server responds with “Bad Gateway”. I’m not sure exactly why. However, a DigitalOcean droplet can be restarted by using the reboot command from the command line interface.

Git Commits for the Current Branch

I had need to get a list of a simple list of all commits for the Current branch. This approach was simple enough and gave me what I wanted. I modified it to just use HEAD so that I can easily run it against the current branch.

git shortlog --no-merges --graph --abbrev-commit master..HEAD

This came from Alex who posted it on StackOverflow here: https://stackoverflow.com/a/61284456/296889

Validate the Hash or Checksum of a Downloaded File

Every once and a while I want to validate the hash of a downloaded file. Most of the time these are MD5 hashes, but I’ve seen SHA as well.

Windows actually has a couple built in ways of generating the hash of a file. You can use certutil or, in powershell you can use get-filehash.

With Certutil

To verify a checksum with certutil use the following command: certutil -hashfile {FILENAME} {ALGORITHM} replace the FILENAME and ALGORITHM with your choices.

With get-filehash

This is my preferred method. No reason, maybe I like the order of arguments better?

Use get-filehash -algorithm {ALGORITHM} {FILENAME}.

That’s it!

Clean up Previously Merged Git Branches

First things first, I tend to build up a lot of local branches. No, I don’t pro-actively remove them from my machine. (Who does that extremely smart thing? ?) At work we use GitHub and Windows. As such I use posh-git to perform almost all my git interactions (you should too cause it’s ?).

Our current process is:

  1. Create Feature Branch
  2. Create Pull Request
  3. Squash and Merge Pull Request
  4. Delete Feature Branch from Remote

Any developer can have any number of feature branches out at a time waiting to be merged.  As we are using a “Squash and Merge” process our branches are not *actually merged*. We delete the original branch after the squash.

But that doesn’t really matter to you. Come to think of it, it doesn’t really matter to future me. What does matter is, how can I remove local git branches that aren’t on the git remote anymore? (Remote meaning GitHub, Gitlab, Bitbucket, etc…). No, we aren’t talking about the remote tracking branches that are removed by pruning. Otherwise, one could just prune, no?

I continuously search for this, so I’m documenting it here so I NEVER HAVE TO SEARCH EVER AGAIN ?

First of all, the answer to the question comes from this question on StackOverflow.

git checkout master; git remote update origin --prune; git branch -vv | Select-String -Pattern ": gone]" | % { $_.toString().Trim().Split(" ")[0]} | % {git branch -d $_}

If you are in a position where you Squash & Merge then you will need to replace the git branch -d with git branch -D. This will successfully remove all “:gone” branches from your local machine.

If you are using linux, and not powershell, you can use the following command taken from the same question on StackOverflow.

git branch -r | awk '{print $1}' | egrep -v -f /dev/fd/0 <(git branch -vv | grep origin) | awk '{print $1}' | xargs git branch -d

But Why?!

Any git branch you have checked out essentially has three branches.
1. The remote branch on GitHub
2. The remote tracking branch on your machine
3. The local branch you do your work on.

When we push a feature branch live (merge a pull request) we delete the “remote branch on GitHub” (#1 above).

When we run `git fetch origin –prune` we remove the remote tracking branch (taking care of #2) above.

However, taking care of #3 above often requires manual clean up. That’s where the piped command above comes into play, it takes care of cleaning up branch #3.

Include Surrounding Lines with Grep

I find it extremely useful to include surrounding lines when I’m searching through log files or whatnot for a string of text. It certainly helps provide some context as to what I’m looking at.

However, I constantly forget the flag for including surrounding lines. So I’m posting it here so that, at least when I forget, I know where to find it ?

The flag is -C. I suppose it should be easy to remember since I want “Context” and “Context” begins with “C”. ?

Below is a quick example for just in case you want the whole command or you enjoy copying and pasting all the things – hey… no judgement here.

grep -C 5 "[5aa027aeb0ebb]" my_special_log.log