| Index: sitescripts/extensions/utils.py |
| =================================================================== |
| --- a/sitescripts/extensions/utils.py |
| +++ b/sitescripts/extensions/utils.py |
| @@ -202,17 +202,17 @@ |
| result = subprocess.check_output(command) |
| parser = SafeConfigParser() |
| parser.readfp(StringIO(result)) |
| return parser |
| def getDownloads(self): |
| - metadata = self.readMetadata() |
| + metadata = self.readMetadata(self.revision) |
|
Sebastian Noack
2016/11/25 13:01:56
I think this logic belongs into readMetadata(), so
Jon Sonesen
2016/11/25 13:05:01
I agree here.
Sebastian Noack
2016/11/25 13:40:29
For reference, we discussed that a little more on
|
| if metadata: |
| prefix = metadata.get('general', 'basename') |
| else: |
| prefix = os.path.basename(os.path.normpath(self.repository)) |
| prefix += '-' |
| command = ['hg', 'locate', '-R', self.downloadsRepo, '-r', 'default'] |
| for filename in subprocess.check_output(command).splitlines(): |
| @@ -311,16 +311,19 @@ |
| def getDownloadLinks(result): |
| """ |
| gets the download links for all extensions and puts them into the config |
| object |
| """ |
| for repo in Configuration.getRepositoryConfigurations(): |
| try: |
| (downloadURL, version) = _getDownloadLink(repo) |
| + if downloadURL is None: |
| + message = 'No download link found for repo: ' + repo |
|
Sebastian Noack
2016/11/25 13:01:56
Any reason you don't pass the message directly to
Jon Sonesen
2016/11/25 13:05:01
I had it in an if statement when i was testing it
|
| + raise Exception(message) |
| except: |
| traceback.print_exc() |
| continue |
| if not result.has_section(repo.repositoryName): |
| result.add_section(repo.repositoryName) |
| result.set(repo.repositoryName, 'downloadURL', downloadURL) |
| result.set(repo.repositoryName, 'version', version) |