Skip to content

Commit b833c07

Browse files
committed
pre-commit upgrade codespell and fix spelling
1 parent b48de4e commit b833c07

File tree

39 files changed

+100
-80
lines changed

39 files changed

+100
-80
lines changed

.github/linters/codespell.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ aqcuire
3535
aqcuired
3636
aquire
3737
aquiring
38+
assertin
3839
assiciate
3940
assigne
4041
assoication
@@ -65,6 +66,7 @@ bject
6566
boardcast
6667
bootstraper
6768
bu
69+
callin
6870
cant
6971
capabilites
7072
capablity
@@ -73,6 +75,7 @@ carrefully
7375
cavaet
7476
chaing
7577
checkd
78+
checkin
7679
childs
7780
choosen
7881
chould
@@ -165,6 +168,7 @@ disover
165168
dissapper
166169
dissassociated
167170
divice
171+
dockin
168172
doesn'
169173
doesnot
170174
doesnt
@@ -195,6 +199,7 @@ excption
195199
excute
196200
execept
197201
execption
202+
exects
198203
execut
199204
executeable
200205
exeeded
@@ -211,6 +216,7 @@ faield
211216
faild
212217
failes
213218
falied
219+
fals
214220
fasion
215221
feild
216222
filenname
@@ -237,6 +243,7 @@ hanling
237243
happend
238244
hasing
239245
hasnt
246+
havin
240247
hda
241248
hostanme
242249
hould
@@ -325,6 +332,7 @@ nin
325332
nodel
326333
nome
327334
noone
335+
notin
328336
nowe
329337
numbe
330338
numer
@@ -339,6 +347,7 @@ opeation
339347
optin
340348
orginal
341349
otherwse
350+
ources
342351
outter
343352
overriden
344353
overwritting
@@ -417,6 +426,7 @@ returing
417426
re-use
418427
rever
419428
rocessor
429+
roperty
420430
runing
421431
runnign
422432
sate
@@ -479,6 +489,7 @@ therefor
479489
theres
480490
theses
481491
thi
492+
thirdparty
482493
thorugh
483494
throught
484495
ths

.pre-commit-config.yaml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,22 @@ repos:
6363
args: [--markdown-linebreak-ext=md]
6464
exclude: ^services/console-proxy/rdpconsole/src/test/doc/freerdp-debug-log\.txt$
6565
- repo: https://github.com/codespell-project/codespell
66-
rev: v2.2.6
66+
rev: v2.3.0
6767
hooks:
6868
- id: codespell
6969
name: run codespell
7070
description: Check spelling with codespell
7171
args: [--ignore-words=.github/linters/codespell.txt]
72-
exclude: ^ui/package\.json$|^ui/package-lock\.json$|^ui/public/js/less\.min\.js$|^ui/public/locales/.*[^n].*\.json$
72+
exclude: |
73+
(?x)^(
74+
systemvm/agent/noVNC/app/locale/.*\.json|
75+
systemvm/agent/noVNC/po/.*|
76+
tools/eclipse/eclipse.epf|
77+
ui/package\.json|
78+
ui/package-lock\.json|
79+
ui/public/js/less\.min\.js|
80+
ui/public/locales/.*[^n].*\.json
81+
)$
7382
- repo: https://github.com/pycqa/flake8
7483
rev: 7.0.0
7584
hooks:

api/src/main/java/com/cloud/storage/Storage.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ public static enum FileSystem {
131131
public static enum TemplateType {
132132
ROUTING, // Router template
133133
SYSTEM, /* routing, system vm template */
134-
BUILTIN, /* buildin template */
134+
BUILTIN, /* builtin template */
135135
PERHOST, /* every host has this template, don't need to install it in secondary storage */
136136
USER, /* User supplied template/iso */
137137
VNF, /* VNFs (virtual network functions) template */

core/src/main/java/com/cloud/storage/resource/StorageProcessor.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
import org.apache.cloudstack.agent.directdownload.DirectDownloadCommand;
2323
import org.apache.cloudstack.storage.command.AttachCommand;
24-
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
24+
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
2525
import org.apache.cloudstack.storage.command.CopyCommand;
2626
import org.apache.cloudstack.storage.command.CreateObjectCommand;
2727
import org.apache.cloudstack.storage.command.DeleteCommand;
@@ -82,7 +82,7 @@ public interface StorageProcessor {
8282

8383
Answer copyVolumeFromPrimaryToPrimary(CopyCommand cmd);
8484

85-
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd);
85+
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd);
8686

8787
public Answer syncVolumePath(SyncVolumePathCommand cmd);
8888
}

core/src/main/java/com/cloud/storage/resource/StorageSubsystemCommandHandlerBase.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
import org.apache.cloudstack.agent.directdownload.DirectDownloadCommand;
2323
import org.apache.cloudstack.storage.command.AttachCommand;
24-
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
24+
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
2525
import org.apache.cloudstack.storage.command.CopyCommand;
2626
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
2727
import org.apache.cloudstack.storage.command.CreateObjectCommand;
@@ -79,8 +79,8 @@ public Answer handleStorageCommands(StorageSubSystemCommand command) {
7979
return processor.resignature((ResignatureCommand) command);
8080
} else if (command instanceof DirectDownloadCommand) {
8181
return processor.handleDownloadTemplateToPrimaryStorage((DirectDownloadCommand) command);
82-
} else if (command instanceof CheckDataStoreStoragePolicyComplainceCommand) {
83-
return processor.checkDataStoreStoragePolicyCompliance((CheckDataStoreStoragePolicyComplainceCommand) command);
82+
} else if (command instanceof CheckDataStoreStoragePolicyComplianceCommand) {
83+
return processor.checkDataStoreStoragePolicyCompliance((CheckDataStoreStoragePolicyComplianceCommand) command);
8484
} else if (command instanceof SyncVolumePathCommand) {
8585
return processor.syncVolumePath((SyncVolumePathCommand) command);
8686
} else if (command instanceof QuerySnapshotZoneCopyCommand) {
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@
2121

2222
import com.cloud.agent.api.to.StorageFilerTO;
2323

24-
public class CheckDataStoreStoragePolicyComplainceCommand extends StorageSubSystemCommand {
24+
public class CheckDataStoreStoragePolicyComplianceCommand extends StorageSubSystemCommand {
2525

2626
String storagePolicyId;
2727
private StorageFilerTO storagePool;
2828

29-
public CheckDataStoreStoragePolicyComplainceCommand(String storagePolicyId, StorageFilerTO storagePool) {
29+
public CheckDataStoreStoragePolicyComplianceCommand(String storagePolicyId, StorageFilerTO storagePool) {
3030
super();
3131

3232
this.storagePolicyId = storagePolicyId;

engine/components-api/src/main/java/com/cloud/storage/StorageManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ public interface StorageManager extends StorageService {
216216

217217
/**
218218
* should we execute in sequence not involving any storages?
219-
* @return tru if commands should execute in sequence
219+
* @return true if commands should execute in sequence
220220
*/
221221
static boolean shouldExecuteInSequenceOnVmware() {
222222
return shouldExecuteInSequenceOnVmware(null, null);

engine/components-api/src/main/java/com/cloud/vm/snapshot/VMSnapshotManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public interface VMSnapshotManager extends VMSnapshotService, Manager {
4242
boolean deleteAllVMSnapshots(long id, VMSnapshot.Type type);
4343

4444
/**
45-
* Sync VM snapshot state when VM snapshot in reverting or snapshoting or expunging state
45+
* Sync VM snapshot state when VM snapshot in reverting or snapshotting or expunging state
4646
* Used for fullsync after agent connects
4747
*
4848
* @param vm, the VM in question

engine/storage/src/main/java/org/apache/cloudstack/storage/allocator/AbstractStoragePoolAllocator.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ protected boolean filter(ExcludeList avoid, StoragePool pool, DiskProfile dskCh,
348348
return false;
349349
}
350350
} catch (StorageUnavailableException e) {
351-
logger.warn(String.format("Could not verify storage policy complaince against storage pool %s due to exception %s", pool.getUuid(), e.getMessage()));
351+
logger.warn(String.format("Could not verify storage policy compliance against storage pool %s due to exception %s", pool.getUuid(), e.getMessage()));
352352
return false;
353353
}
354354
}

plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotInfo;
5151
import org.apache.cloudstack.storage.command.AttachAnswer;
5252
import org.apache.cloudstack.storage.command.AttachCommand;
53-
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
53+
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
5454
import org.apache.cloudstack.storage.command.CopyCmdAnswer;
5555
import org.apache.cloudstack.storage.command.CopyCommand;
5656
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
@@ -2603,8 +2603,8 @@ protected boolean isEnoughSpaceForDownloadTemplateOnTemporaryLocation(Long templ
26032603
}
26042604

26052605
@Override
2606-
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd) {
2607-
logger.info("'CheckDataStoreStoragePolicyComplainceCommand' not currently applicable for KVMStorageProcessor");
2606+
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd) {
2607+
logger.info("'CheckDataStoreStoragePolicyComplianceCommand' not currently applicable for KVMStorageProcessor");
26082608
return new Answer(cmd,false,"Not currently applicable for KVMStorageProcessor");
26092609
}
26102610

0 commit comments

Comments
 (0)