MCPcopy Create free account
hub / github.com/AstroPrint/AstroBox / getString

Method getString

src/octoprint/settings.py:323–332  ·  view source on GitHub ↗
(self, path)

Source from the content-addressed store, hash-verified

321 return None
322
323 def getString(self, path):
324 value = self.get(path)
325 if value is None:
326 return None
327
328 try:
329 return str(value)
330 except ValueError:
331 self._logger.warn("Could not convert %r to a valid string when getting option %r" % (value, path))
332 return None
333
334 def getFloat(self, path):
335 value = self.get(path)

Callers 1

runMethod · 0.45

Calls 1

getMethod · 0.95

Tested by

no test coverage detected