Compare commits

...
5 Commits
Author SHA1 Message Date
Gina Häußge fe481e12b3 Prepare release of 1.3.4 (hotfix) 2017-06-01 12:22:23 +02:00
Gina Häußge cbdf85c27a Fix crash on startup thanks to invalid default profile & auto connect
See #1942

This does NOT fix the root cause of `_default.profile` becoming an
empty file (apparently during migration from config.yaml?), however
since this particular situation was impossible to reproduce so far this
workaround for the consequences will have to suffice for now since we
want a hotfix as fast as possible for 1.3.3.
2017-06-01 12:10:12 +02:00
Gina Häußge b55c4ef5ca Preparing release of 1.3.3 2017-05-31 15:49:01 +02:00
Gina Häußge b9747d0f0e Fix typo: TRANFERING_FILE
(cherry picked from commit c4fcc59efd)
2017-05-31 11:24:44 +02:00
Gina Häußge df038e6a4d staging/maintenance is now 1.3.3rc4.dev 2017-05-24 14:50:18 +02:00
11 changed files with 80 additions and 31 deletions

No files matched your search

+2 -2
View File
@@ -22,8 +22,8 @@ maintenance 1.3.3 0a69dbeddb301d5a32827a3f0d561f875df24234 pep440-dev
fix/.* 1.3.3 0a69dbeddb301d5a32827a3f0d561f875df24234 pep440-dev
improve/.* 1.3.3 0a69dbeddb301d5a32827a3f0d561f875df24234 pep440-dev
# staging/maintenance is currently the branch for preparation of 1.3.3rc3 (if we'll need that)
staging/maintenance 1.3.3rc3 2bae87b85a53315ecc79b750f2a63f33e8a5dd94 pep440-dev
# staging/maintenance is currently the branch for preparation of 1.3.3rc4 (if we'll need that)
staging/maintenance 1.3.3rc4 ce1541e956778b732458599a21f38b6783a0c2ec pep440-dev
# every other branch is a development branch and thus gets resolved to 1.4.0-dev for now
.* 1.4.0 7f5d03d0549bcbd26f40e7e4a3297ea5204fb1cc pep440-dev
+33 -16
View File
@@ -1,35 +1,42 @@
# OctoPrint Changelog
## 1.3.3rc3 (2017-05-24)
## 1.3.4 (2017-06-01)
### Improvements
### Note for owners of Malyan M200/Monoprice Select Mini
* Some clarifications and typo fixes in the documentation
OctoPrint's firmware autodetection is now able to detect this printer. Currently when this printer is detected, the following firmware specific features will be enabled automatically:
* Always assume SD card is present (`feature.sdAlwaysAvailable`)
* Send a checksum with the command: Always (`feature.alwaysSendChecksum`)
Since the firmware is a very special kind of beast and its sources are so far unavailable, only tests with a real printer will show if those are sufficient settings for communication with this printer to fully function correctly. Thus, if you run into any issues with enabled firmware autodetection on this printer model, please add a comment in [#1762](https://github.com/foosel/OctoPrint/issues/1762) and explain what kind of communication problem you are seeing. Also make sure to include a [`serial.log`](https://github.com/foosel/OctoPrint/blob/master/CONTRIBUTING.md#where-can-i-find-those-log-files-you-keep-talking-about)!
### Bug fixes
* [#1821](https://github.com/foosel/OctoPrint/issues/1821) - Properly reset "Capture post roll images" setting in timelapse configuration when switching from "off" to "timed" timelapse mode.
* [#1934](https://github.com/foosel/OctoPrint/issues/1934) (regression) - Fix consecutive timed timelapse captures without configured post roll.
* [#1942](https://github.com/foosel/OctoPrint/issues/1942) - Fixed crash on startup in case of an invalid default printer profile combined with "auto-connect on startup" being selected and the printer available to connect to.
([Commits](https://github.com/foosel/OctoPrint/compare/1.3.3rc2...1.3.3rc3))
### More information
## 1.3.3rc2 (2017-05-17)
* [Commits](https://github.com/foosel/OctoPrint/compare/1.3.1...1.3.2)
* Release Candidates:
* None since this constitutes a hotfix release to fix an apparently very rare bug introduced with 1.3.3 that seems to be affecting a small number of users.
### Bug fixes
## 1.3.3 (2017-05-31)
* [#1917](https://github.com/foosel/OctoPrint/issues/1917) (regression) - Fix job data resetting on print job completion.
* [#1918](https://github.com/foosel/OctoPrint/issues/1918) (regression) - Fix "save as default" checkbox not being disabled when other controls are disabled.
* [#1919](https://github.com/foosel/OctoPrint/issues/1919) (regression) - Fix call to no longer existing function in Plugin Manager UI.
### Note for owners of Malyan M200/Monoprice Select Mini
([Commits](https://github.com/foosel/OctoPrint/compare/1.3.3rc1...1.3.3rc2))
OctoPrint's firmware autodetection is now able to detect this printer. Currently when this printer is detected, the following firmware specific features will be enabled automatically:
## 1.3.3rc1 (2017-05-11)
* Always assume SD card is present (`feature.sdAlwaysAvailable`)
* Send a checksum with the command: Always (`feature.alwaysSendChecksum`)
Since the firmware is a very special kind of beast and its sources are so far unavailable, only tests with a real printer will show if those are sufficient settings for communication with this printer to fully function correctly. Thus, if you run into any issues with enabled firmware autodetection on this printer model, please add a comment in [#1762](https://github.com/foosel/OctoPrint/issues/1762) and explain what kind of communication problem you are seeing. Also make sure to include a [`serial.log`](https://github.com/foosel/OctoPrint/blob/master/CONTRIBUTING.md#where-can-i-find-those-log-files-you-keep-talking-about)!
### Improvements
* [#478](https://github.com/foosel/OctoPrint/issues/478) - Made webcam stream container fixed height (with selectable aspect ratio) to prevent jumps of the controls beneath it on load.
* [#748](https://github.com/foosel/OctoPrint/issues/748) - Added delete confirmation and bulk delete for timelapses. See also the discussion in brainstorming ticket [#1807](https://github.com/foosel/OctoPrint/issues/1807).
* [#1092](https://github.com/foosel/OctoPrint/issues/1092) - Added new event to the file manager: `FileAdded`, `FileRemoved`, `FolderAdded`, `FolderRemoved`. Contrary to the `Upload` event, `FileAdded` will always fire when a file was added to storage through the file manager, not only when added through the web interface. Extended documentation accordingly.
* [#1092](https://github.com/foosel/OctoPrint/issues/1092) - Added new events to the file manager: `FileAdded`, `FileRemoved`, `FolderAdded`, `FolderRemoved`. Contrary to the `Upload` event, `FileAdded` will always fire when a file was added to storage through the file manager, not only when added through the web interface. Extended documentation accordingly.
* [#1521](https://github.com/foosel/OctoPrint/issues/1521) - Software update plugin: Display timestamp of last version cache refresh in "Advanced options" area.
* [#1734](https://github.com/foosel/OctoPrint/issues/1734) - Treat default/initial printer profile like all other printer profiles, persisting it to disk instead of `config.yaml` and allowing deletion. OctoPrint will migrate the existing default profile to the new location on first start.
* [#1734](https://github.com/foosel/OctoPrint/issues/1734) - Better communication of what actions are available for printer profiles.
@@ -76,7 +83,7 @@
* [#202](https://github.com/foosel/OctoPrint/issues/202) - Fixed an issue with the drag-n-drop area flickering if the mouse was moved too slow while dragging (see also [#1867](https://github.com/foosel/OctoPrint/pull/1867)).
* [#1671](https://github.com/foosel/OctoPrint/issues/1671) - Removed obsolete entry of no longer available filter for empty folders from file list options.
* [#1821](https://github.com/foosel/OctoPrint/issues/1821) - Fixed a wrong default value for "capture post roll images" in timelapse configuration.
* [#1821](https://github.com/foosel/OctoPrint/issues/1821) - Properly reset "Capture post roll images" setting in timelapse configuration when switching from "off" to "timed" timelapse mode.
* [#1822](https://github.com/foosel/OctoPrint/issues/1822) - Properly reset file metadata when a file is overwritten with a new version.
* [#1836](https://github.com/foosel/OctoPrint/issues/1836) - Fixed order of `PrintCancelled` and `PrintFailed` events on print cancel.
* [#1837](https://github.com/foosel/OctoPrint/issues/1837) - Fixed a race condition causing OctoPrint trying to read data from the current job on job cancel that was no longer there.
@@ -89,6 +96,10 @@
* [#1897](https://github.com/foosel/OctoPrint/issues/1897) - Removed possibility to concurrently try to perform multiple tests of the configured snapshot URL.
* [#1906](https://github.com/foosel/OctoPrint/issues/1906) - Fixed interpretation of `G92` in GCODE analysis.
* [#1907](https://github.com/foosel/OctoPrint/issues/1907) - Don't send temperature commands with tool parameter when a shared nozzle is defined.
* [#1917](https://github.com/foosel/OctoPrint/issues/1917) (regression) - Fix job data resetting on print job completion.
* [#1918](https://github.com/foosel/OctoPrint/issues/1918) (regression) - Fix "save as default" checkbox not being disabled when other controls are disabled.
* [#1919](https://github.com/foosel/OctoPrint/issues/1919) (regression) - Fix call to no longer existing function in Plugin Manager UI.
* [#1934](https://github.com/foosel/OctoPrint/issues/1934) (regression) - Fix consecutive timed timelapse captures without configured post roll.
* Fixed API key QR Code being shown (for "n/a" value) when no API key was set.
* Fixed timelapse configuration API not returning 400 status code on some bad parameters.
* Fixed a typo (see also [#1826](https://github.com/foosel/OctoPrint/pull/1826)).
@@ -100,7 +111,13 @@
* Use `pip` instead of `python setup.py develop` in `octoprint dev plugin:install` command to avoid issues on Windows.
* Docs: Fixed a wrong command in the plugin tutorial (see also [#1860](https://github.com/foosel/OctoPrint/pull/1860)).
([Commits](https://github.com/foosel/OctoPrint/compare/1.3.2...1.3.3rc1))
### More information
- [Commits](https://github.com/foosel/OctoPrint/compare/1.3.2...1.3.3)
- Release Candidates:
- [1.3.3rc1](https://github.com/foosel/OctoPrint/releases/tag/1.3.3rc1)
- [1.3.3rc2](https://github.com/foosel/OctoPrint/releases/tag/1.3.3rc2)
- [1.3.3rc3](https://github.com/foosel/OctoPrint/releases/tag/1.3.3rc3)
## 1.3.2 (2017-03-16)
+2 -1
View File
@@ -10,6 +10,7 @@ thanks to everyone who contributed!
* Aleph Objects, Inc.
* Andrew Moorby
* Arnljot Arntsen
* BEEVERYCREATIVE
* Boris Hussein
* Brad Jackson
* Brian E. Tyler
@@ -64,4 +65,4 @@ thanks to everyone who contributed!
* Timeshell.ca
* Trent Shumay
and 1086 more wonderful people pledging on the [Patreon campaign](https://patreon.com/foosel)!
and 1098 more wonderful people pledging on the [Patreon campaign](https://patreon.com/foosel)!
+1 -1
View File
@@ -366,7 +366,7 @@ class PrinterInterface(object):
* CLOSED
* ERROR
* CLOSED_WITH_ERROR
* TRANFERING_FILE
* TRANSFERING_FILE
* OFFLINE
* UNKNOWN
* NONE
+30 -2
View File
@@ -215,12 +215,18 @@ class PrinterProfileManager(object):
if self.exists("_default"):
return
if not isinstance(default_overrides, dict):
self._logger.warn("Existing default profile from settings is not a valid profile, refusing to migrate: {!r}".format(default_overrides))
return
default_overrides["id"] = "_default"
self.save(default_overrides)
settings().set(["printerProfiles", "defaultProfile"], None)
settings().save()
self._logger.info("Migrated default printer profile from settings to _default.profile: {!r}".format(default_overrides))
def _verify_default_available(self):
default_id = settings().get(["printerProfile", "default"])
if default_id is None:
@@ -228,12 +234,23 @@ class PrinterProfileManager(object):
if not self.exists(default_id):
if not self.exists("_default"):
self._logger.error("Selected default profile {} and _default do not exist, creating _default again and setting it as default".format(default_id))
if default_id == "_default":
self._logger.error("Profile _default does not exist, creating _default again and setting it as default")
else:
self._logger.error("Selected default profile {} and _default do not exist, creating _default again and setting it as default".format(default_id))
self.save(self.__class__.default, allow_overwrite=True, make_default=True)
else:
self._logger.error("Selected default profile {} does not exists, resetting to _default".format(default_id))
settings().set(["printerProfiles", "default"], "_default")
settings().save()
default_id = "_default"
profile = self.get(default_id)
if profile is None:
self._logger.error("Selected default profile {} is invalid, resetting to default values".format(default_id))
profile = copy.deepcopy(self.__class__.default)
profile["id"] = default_id
self.save(self.__class__.default, allow_overwrite=True, make_default=True)
def select(self, identifier):
if identifier is None or not self.exists(identifier):
@@ -241,7 +258,12 @@ class PrinterProfileManager(object):
return False
else:
self._current = self.get(identifier)
return True
if self._current is None:
self._logger.error("Profile {} is invalid, cannot select, falling back to default".format(identifier))
self._current = self.get_default()
return False
else:
return True
def deselect(self):
self._current = None
@@ -310,6 +332,8 @@ class PrinterProfileManager(object):
profile = self.get(default)
if profile is not None:
return profile
else:
self._logger.warn("Default profile {} is invalid, falling back to built-in defaults".format(default))
return copy.deepcopy(self.__class__.default)
@@ -344,6 +368,7 @@ class PrinterProfileManager(object):
try:
profile = self._load_from_path(path)
except InvalidProfileError:
self._logger.warn("Profile {} is invalid, skipping".format(identifier))
continue
if profile is None:
@@ -373,6 +398,9 @@ class PrinterProfileManager(object):
with open(path) as f:
profile = yaml.safe_load(f)
if profile is None or not isinstance(profile, dict):
raise InvalidProfileError("Profile is None or not a dictionary")
if self._migrate_profile(profile):
try:
self._save_to_path(path, profile, allow_overwrite=True)
+8 -5
View File
@@ -475,11 +475,14 @@ class Server(object):
# auto connect
if self._settings.getBoolean(["serial", "autoconnect"]):
(port, baudrate) = self._settings.get(["serial", "port"]), self._settings.getInt(["serial", "baudrate"])
printer_profile = printerProfileManager.get_default()
connectionOptions = printer.__class__.get_connection_options()
if port in connectionOptions["ports"]:
printer.connect(port=port, baudrate=baudrate, profile=printer_profile["id"] if "id" in printer_profile else "_default")
try:
(port, baudrate) = self._settings.get(["serial", "port"]), self._settings.getInt(["serial", "baudrate"])
printer_profile = printerProfileManager.get_default()
connectionOptions = printer.__class__.get_connection_options()
if port in connectionOptions["ports"]:
printer.connect(port=port, baudrate=baudrate, profile=printer_profile["id"] if "id" in printer_profile else "_default")
except:
self._logger.exception("Something went wrong while attempting to automatically connect to the printer")
# start up watchdogs
if self._settings.getBoolean(["feature", "pollWatched"]):
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: OctoPrint\n"
"Report-Msgid-Bugs-To: i18n@octoprint.org\n"
"POT-Creation-Date: 2017-05-24 13:21+0200\n"
"POT-Creation-Date: 2017-05-31 11:25+0200\n"
"PO-Revision-Date: 2017-05-11 13:44+0100\n"
"Last-Translator: Gina Häußge <osd@foosel.net>\n"
"Language: de\n"
Binary file not shown.
+1 -1
View File
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: OctoPrint\n"
"Report-Msgid-Bugs-To: i18n@octoprint.org\n"
"POT-Creation-Date: 2017-05-24 13:21+0200\n"
"POT-Creation-Date: 2017-05-31 11:25+0200\n"
"PO-Revision-Date: 2017-05-11 13:44+0100\n"
"Last-Translator: Gina Häußge <osd@foosel.net>\n"
"Language: de\n"
+2 -2
View File
@@ -6,9 +6,9 @@
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: OctoPrint 1.3.3rc3.dev8+gbd1d0e6\n"
"Project-Id-Version: OctoPrint 1.3.3rc4.dev2+gb9747d0\n"
"Report-Msgid-Bugs-To: i18n@octoprint.org\n"
"POT-Creation-Date: 2017-05-24 13:21+0200\n"
"POT-Creation-Date: 2017-05-31 11:25+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"