mirror of
https://github.com/ansible/awx.git
synced 2024-11-01 08:21:15 +03:00
Change 'can not' to cannot (by request)
This commit is contained in:
parent
c06d4eaa08
commit
1e9a0e5814
@ -1639,7 +1639,7 @@ class InventorySourceSerializer(UnifiedJobTemplateSerializer, InventorySourceOpt
|
||||
|
||||
def validate_source_project(self, value):
|
||||
if value and value.scm_type == '':
|
||||
raise serializers.ValidationError(_("Can not use manual project for SCM-based inventory."))
|
||||
raise serializers.ValidationError(_("Cannot use manual project for SCM-based inventory."))
|
||||
return value
|
||||
|
||||
def validate_source(self, value):
|
||||
@ -3420,7 +3420,7 @@ class ScheduleSerializer(BaseSerializer):
|
||||
if type(value) == InventorySource and value.source not in SCHEDULEABLE_PROVIDERS:
|
||||
raise serializers.ValidationError(_('Inventory Source must be a cloud resource.'))
|
||||
elif type(value) == Project and value.scm_type == '':
|
||||
raise serializers.ValidationError(_('Manual Project can not have a schedule set.'))
|
||||
raise serializers.ValidationError(_('Manual Project cannot have a schedule set.'))
|
||||
elif type(value) == InventorySource and value.source == 'scm' and value.update_on_project_update:
|
||||
raise serializers.ValidationError(_(
|
||||
'Inventory sources with `update_on_project_update` cannot be scheduled. '
|
||||
|
@ -112,7 +112,7 @@ class AnsibleInventoryLoader(object):
|
||||
self.method = 'ansible-inventory backport'
|
||||
|
||||
if not os.path.exists(abs_module_path):
|
||||
raise ImproperlyConfigured('Can not find inventory module')
|
||||
raise ImproperlyConfigured('Cannot find inventory module')
|
||||
logger.debug('Using backported ansible-inventory module: {}'.format(abs_module_path))
|
||||
return [abs_module_path, '-i', self.source]
|
||||
|
||||
@ -128,7 +128,7 @@ class AnsibleInventoryLoader(object):
|
||||
kwargs['proot_temp_dir'] = self.source_dir
|
||||
cwd = self.source_dir
|
||||
else:
|
||||
# we can not safely store tmp data in source dir or trust script contents
|
||||
# we cannot safely store tmp data in source dir or trust script contents
|
||||
if env['AWX_PRIVATE_DATA_DIR']:
|
||||
# If this is non-blank, file credentials are being used and we need access
|
||||
private_data_dir = functioning_dir(env['AWX_PRIVATE_DATA_DIR'])
|
||||
|
@ -1772,7 +1772,7 @@ class RunInventoryUpdate(BaseTask):
|
||||
if str(env_k) not in env and str(env_k) not in settings.INV_ENV_VARIABLE_BLACKLIST:
|
||||
env[str(env_k)] = unicode(inventory_update.source_vars_dict[env_k])
|
||||
elif inventory_update.source == 'file':
|
||||
raise NotImplementedError('Can not update file sources through the task system.')
|
||||
raise NotImplementedError('Cannot update file sources through the task system.')
|
||||
# add private_data_files
|
||||
env['AWX_PRIVATE_DATA_DIR'] = kwargs.get('private_data_dir', '')
|
||||
return env
|
||||
|
Loading…
Reference in New Issue
Block a user