Uploaded image for project: 'Hue'
  1. Hue
  2. HUE-1559

[core] app registry should truncate and overwrite

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.5.0
    • Fix Version/s: 3.0.0
    • Component/s: core.backend
    • Labels:
      None

      Description

      Currently, Hue creates a new file whenever it needs to update its app registry:

      def save(self):
          """Save and write out the registry"""
          assert self._initialized, "Registry not yet initialized"
      
          tmp_path = self._reg_path + '.new'
          self._write(tmp_path)
          os.rename(tmp_path, self._reg_path)
          LOG.info('=== Saved registry at %s' % (self._reg_path,))
      

      It should not create a new file, but truncate and overwrite the previous file so that symbolic links are preserved.

        Attachments

          Activity

            People

            • Assignee:
              abe Abraham Elmahrek
              Reporter:
              abe Abraham Elmahrek
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: