Skip to content

Updates and conflicts

How updates treat your changes

Every .cfg file OpenCreator ships is a template, subfolders included. When an update brings a new version, the updater merges it into your copy:

  • Your edits stay, unless the update changed the very same lines.
  • Your calibration stays. The SAVE_CONFIG block (input shaper, PID, meshes, skew) is never merged, only carried along.
  • Same lines changed on both sides: your file is left exactly as it is, and the merged version, with <<<<<<< markers, is put next to it as <file>.conflict. See Resolving a conflict.
  • A file you deleted is installed again as the shipped template at the next update.
  • Windows line endings still merge; the file is written back with plain line endings.

Files that aren't templates, like a file you create, are never touched by updates.

When updates run

The updater checks the opencreator-fs checkout every 60 seconds. When you update opencreator in Fluidd or Mainsail, the new configs are merged within a minute. Log: /tmp/opencreator-updater.log.

Once, each time Moonraker's update manager pulls opencreator-tunnel. Log: journalctl -u opencreator-updater.

The updater doesn't restart Klipper. After an update, restart Klipper to load the new configs. How the updater works inside is in Firmware, installer and updates.

Urgent updates

A few fixes can't wait for a hand-merged file, for example a macro one file calls and another defines. An update marked urgent takes the new template for a file that would otherwise conflict:

  • Your copy is saved beside it as <file>.mine.
  • Your SAVE_CONFIG block is put into the new file, so calibration stays.

Copy any of your own changes back from <file>.mine, then restart Klipper.

Other files the updater leaves

File Meaning
<file>.conflict An update waiting for you to merge it by hand
<file>.mine Your copy, replaced by an urgent update
<file>.before-save-fix Your file before the updater removed an extra SAVE_CONFIG block. It keeps the last block, the printer's calibration
.opencreator-updater/ The updater's own state: the last template it applied for each file (base/), the last applied commit and the last MCU firmware flashed

Resolving a conflict

When an update and your edit changed the same lines, the updater leaves your file alone and writes <file>.conflict next to it. Your printer keeps running on your version; only that file's update is waiting. Kalico and MCU firmware updates don't wait for it. The updater's log is /tmp/opencreator-updater.log on the printer.

  1. Open <file>.conflict. Each conflict shows your version (current) and the update's (latest):

    <<<<<<< current
    dock_approach_speed: 80
    =======
    dock_approach_speed: 90
    >>>>>>> latest
    
  2. Keep the lines you want, delete the other side and the three marker lines.

  3. Copy the result over the original file, delete the .conflict file, and restart Klipper.

The updater tries again when the file changes or the next update comes in. The next update merges from there. Moving your changes to your own file stops them from conflicting again.

Going back

  • One option: delete it from your own file, or put the shipped value back.
  • A whole file: the last template the updater applied is kept in .opencreator-updater/base/<file>. Copy it over your file to get the shipped version back. Deleting the file works too: the next update installs the template again.
  • A switch: switches aren't in the config files; flick them back, see How to toggle features.
  • Everything: Restore backup in the OpenCreator Installer, if you made a backup when you installed.

Keep a copy of my-printer.cfg somewhere safe. It's all you need to set a fresh install up the way you like it. A USB reinstall keeps your existing configs, and the updater merges them from there.