mbj4668 / pyang

An extensible YANG validator and converter in python
ISC License
530 stars 342 forks source link

update-sid-file does not update in place #841

Open mcr opened 1 year ago

mcr commented 1 year ago

When specifying the path to the sid file, as indicated in the example:

  $ pyang --sid-update-file toaster@2009-11-20.sid
          toaster@2009-12-28.yang --sid-extra-range count

you might think you can specify a path, like:

$ pyang --sid-update-file ../some/other/place/toaster@2009-11-20.sid

and this works for reading, but for writing, pyang always writes

        self.output_file_name = '%s@%s.sid' % (self.module_name, self.module_revision)

(line 276 of sid.py, fn process_sid_file)

whether this is a bug or a feature remains to be seen.