diff --git a/docs/modules/bindings-specification/pages/message-passing-api.adoc b/docs/modules/bindings-specification/pages/message-passing-api.adoc index 85e48d5d..2d42efda 100644 --- a/docs/modules/bindings-specification/pages/message-passing-api.adoc +++ b/docs/modules/bindings-specification/pages/message-passing-api.adoc @@ -75,7 +75,7 @@ requestId: Int /// API version of the CLI's `--allowed-modules` flag allowedModules: Listing? -/// Regex patterns to dettermine which resources are allowed to be read. +/// Regex patterns to determine which resources are allowed to be read. /// /// API version of the CLI's `--allowed-resources` flag allowedResources: Listing? @@ -130,7 +130,7 @@ class ClientResourceReader { /// The URI scheme this reader is responsible for reading. scheme: String - /// Tells whether the path part of ths URI has a + /// Tells whether the path part of this URI has a /// [hier-part](https://datatracker.ietf.org/doc/html/rfc3986#section-3). /// /// An example of a hierarchical URI is `file:///path/to/my/file`, where @@ -148,7 +148,7 @@ class ClientModuleReader { /// The URI scheme this reader is responsible for reading. scheme: String - /// Tells whether the path part of ths URI has a + /// Tells whether the path part of this URI has a /// [hier-part](https://datatracker.ietf.org/doc/html/rfc3986#section-3). /// /// An example of a hierarchical URI is `file:///path/to/my/file`, where @@ -427,7 +427,7 @@ evaluatorId: Int /// The contents of the resource. contents: Binary? // <1> -/// The description of the error that occured when reading this resource. +/// The description of the error that occurred when reading this resource. error: String? typealias Binary = Any // <1> @@ -478,7 +478,7 @@ evaluatorId: Int /// The string contents of the module. contents: String? -/// The description of the error that occured when reading this resource. +/// The description of the error that occurred when reading this resource. error: String? ---- @@ -528,7 +528,7 @@ evaluatorId: Int /// The elements at the provided base path. pathElements: Listing? -/// The description of the error that occured when listing elements. +/// The description of the error that occurred when listing elements. error: String? class PathElement { @@ -586,7 +586,7 @@ evaluatorId: Int /// The elements at the provided base path. pathElements: Listing? -/// The description of the error that occured when listing elements. +/// The description of the error that occurred when listing elements. error: String? class PathElement { diff --git a/docs/modules/java-binding/pages/codegen.adoc b/docs/modules/java-binding/pages/codegen.adoc index cd87fd6d..a6b670cc 100644 --- a/docs/modules/java-binding/pages/codegen.adoc +++ b/docs/modules/java-binding/pages/codegen.adoc @@ -1,6 +1,6 @@ = Java Code Generator include::ROOT:partial$component-attributes.adoc[] -:uri-pkl-codgen-java-maven-module: {uri-maven-docsite}/artifact/org.pkl-lang/pkl-codegen-java +:uri-pkl-codegen-java-maven-module: {uri-maven-docsite}/artifact/org.pkl-lang/pkl-codegen-java The Java source code generator takes Pkl class definitions as an input, and generates corresponding Java classes with equally named properties. @@ -23,7 +23,7 @@ See xref:pkl-gradle:index.adoc#installation[Installation] in the Gradle plugin c [[install-library]] === Java Library -The `pkl-codegen-java` library is available {uri-pkl-codgen-java-maven-module}[from Maven Central]. +The `pkl-codegen-java` library is available {uri-pkl-codegen-java-maven-module}[from Maven Central]. It requires Java 17 or higher. ifndef::is-release-version[] diff --git a/docs/modules/language-reference/pages/index.adoc b/docs/modules/language-reference/pages/index.adoc index cf4d2aa2..42db4404 100644 --- a/docs/modules/language-reference/pages/index.adoc +++ b/docs/modules/language-reference/pages/index.adoc @@ -2573,7 +2573,7 @@ the following security checks are performed: * The target module URI is checked against the module allowlist (`--allowed-modules`). * The source and target modules' _trust levels_ are determined and compared. -For access to be granted, the source module's trust level must be higher than or equal to the target module's trust level. +For access to be granted, the source module's trust level must be greater than or equal to the target module's trust level. By default, there are five trust levels, listed from highest to lowest: . `repl:` modules (code evaluated in the REPL) @@ -3353,9 +3353,9 @@ swiftHatchlings = typedProperty.listHatchlings(new { "Poppy"; "Chirpy" }) // <8> <2> Assignment to an undeclared property in module context, amending `new Dynamic {}`. <3> `Listing` element creation, amending implicit `default`, `new Bird {}`. <4> `Listing` element creation, amending implicit `default`, `new Dynamic {}`. -<5> `Mapping` value assignment, amdending the result of applying `default` to `"Saltmarsh Sparrow"`, `new Bird { name = "Saltmarsh Sparrow" }`. +<5> `Mapping` value assignment, amending the result of applying `default` to `"Saltmarsh Sparrow"`, `new Bird { name = "Saltmarsh Sparrow" }`. <6> `Mapping` value assignment _replacing_ the parent's entry, amending the result of applying `default` to `"Saltmarsh Sparrow"`, `new Bird { name = "Saltmarsh Sparrow" }`. -<7> Admending the property default value `new Listing { new Bird { name = "Osprey" } }`; the result contains both birds. +<7> Amending the property default value `new Listing { new Bird { name = "Osprey" } }`; the result contains both birds. <8> Error: Cannot tell which parent to amend. [[let-expressions]] @@ -5475,7 +5475,7 @@ Readers are implemented as ordinary executables and use Pkl's xref:bindings-spec The xref:swift:ROOT:index.adoc[Swift] and xref:go:ROOT:index.adoc[Go] language binding libraries provide an `ExternalReaderRuntime` type to facilitate implementing external readers. External readers are configured separately for modules and resources. -They are registered by mapping their URI scheme to the executable to run and additonal arguments to pass. +They are registered by mapping their URI scheme to the executable to run and additional arguments to pass. This is done on the command line by passing `--external-resource-reader` and `--external-module-reader` flags, which may both be passed multiple times. [source,text] diff --git a/docs/modules/release-notes/pages/0.26.adoc b/docs/modules/release-notes/pages/0.26.adoc index 73e81987..92d1e740 100644 --- a/docs/modules/release-notes/pages/0.26.adoc +++ b/docs/modules/release-notes/pages/0.26.adoc @@ -12,7 +12,7 @@ This release brings Windows support, improvements to controlling how Pkl talks o The next release (0.27) is scheduled for October 10th, 2024. -Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[Github]. + +Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[GitHub]. + [small]#Pkl is hosted on https://github.com/apple/pkl[GitHub]. To get started, follow xref:pkl-cli:index.adoc#installation[Installation].# @@ -460,7 +460,7 @@ To mitigate, the package's version needs to be bumped, even if package contents == Miscellaneous [small]#🐸# -The following changes have been made that are not new features, nor breaking changes. +The following changes have been made that are neither new features nor breaking changes. * Pkl's user-agent header for HTTP requests has been tweaked to add a semicolon (https://github.com/apple/pkl/pull/221[#221]). Here is an example difference: + diff --git a/docs/modules/release-notes/pages/0.27.adoc b/docs/modules/release-notes/pages/0.27.adoc index f7ebef45..8478a410 100644 --- a/docs/modules/release-notes/pages/0.27.adoc +++ b/docs/modules/release-notes/pages/0.27.adoc @@ -12,7 +12,7 @@ This release brings improvements in typechecking of `Listing` and `Mapping`, the The next release (0.28) is scheduled for February 2025. -Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[Github]. + +Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[GitHub]. + [small]#Pkl is hosted on https://github.com/apple/pkl[GitHub]. To get started, follow xref:pkl-cli:index.adoc#installation[Installation].# @@ -121,7 +121,7 @@ A new API has been added to analyze the import graph of Pkl modules (https://git This API comes in four forms: 1. A standard library module: `pkl:analyze` -2. A CLI command: `pkl anaylze imports` +2. A CLI command: `pkl analyze imports` 3. A Java API: `org.pkl.core.Analyzer` 4. A Gradle API: `org.pkl.gradle.task.AnalyzeImportsTask` diff --git a/docs/modules/release-notes/pages/0.28.adoc b/docs/modules/release-notes/pages/0.28.adoc index e41ecaf7..4020fde5 100644 --- a/docs/modules/release-notes/pages/0.28.adoc +++ b/docs/modules/release-notes/pages/0.28.adoc @@ -10,7 +10,7 @@ Pkl {version} was released on {release-date}. + The next release (0.XX) is scheduled for ???.. -Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[Github]. + +Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[GitHub]. + [small]#Pkl is hosted on https://github.com/apple/pkl[GitHub]. To get started, follow xref:pkl-cli:index.adoc#installation[Installation].# diff --git a/docs/modules/release-notes/template.adoc b/docs/modules/release-notes/template.adoc index 726038e3..e970cdf0 100644 --- a/docs/modules/release-notes/template.adoc +++ b/docs/modules/release-notes/template.adoc @@ -12,7 +12,7 @@ XXX The next release (XXX) is scheduled for XXX (e.g., August 2, 2021). -Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[Github]. + +Please send feedback and questions to https://github.com/apple/pkl/discussions[GitHub Discussions], or submit an issue on https://github.com/apple/pkl/issues/new[GitHub]. + [small]#Pkl is hosted on https://github.com/apple/pkl[GitHub]. To get started, follow xref:pkl-cli:index.adoc#installation[Installation].# diff --git a/docs/modules/style-guide/pages/index.adoc b/docs/modules/style-guide/pages/index.adoc index 3728cdca..71b473df 100644 --- a/docs/modules/style-guide/pages/index.adoc +++ b/docs/modules/style-guide/pages/index.adoc @@ -356,7 +356,7 @@ myString = #"foo \ bar \ baz"# myString = "foo \\ bar \\ baz" ---- -NOTE: Sometimes, using custom string delimiters makes source code harder to read. For example, the `+\#+` literal reads better using escapes (`"\\#"`) than using custom string delimimters (`+##"\#"##+`). +NOTE: Sometimes, using custom string delimiters makes source code harder to read. For example, the `+\#+` literal reads better using escapes (`"\\#"`) than using custom string delimiters (`+##"\#"##+`). === Interpolation diff --git a/pkl-cli/src/main/kotlin/org/pkl/cli/commands/AnalyzeCommand.kt b/pkl-cli/src/main/kotlin/org/pkl/cli/commands/AnalyzeCommand.kt index 51b13cc0..63c44545 100644 --- a/pkl-cli/src/main/kotlin/org/pkl/cli/commands/AnalyzeCommand.kt +++ b/pkl-cli/src/main/kotlin/org/pkl/cli/commands/AnalyzeCommand.kt @@ -40,7 +40,7 @@ class AnalyzeCommand(helpLink: String) : ModulesCommand( name = "imports", helpLink = helpLink, - help = "Prints the the graph of modules imported by the input module(s)." + help = "Prints the graph of modules imported by the input module(s)." ) { private val outputPath: Path? by diff --git a/pkl-cli/src/test/kotlin/org/pkl/cli/CliEvaluatorTest.kt b/pkl-cli/src/test/kotlin/org/pkl/cli/CliEvaluatorTest.kt index 7974d856..7572c91a 100644 --- a/pkl-cli/src/test/kotlin/org/pkl/cli/CliEvaluatorTest.kt +++ b/pkl-cli/src/test/kotlin/org/pkl/cli/CliEvaluatorTest.kt @@ -1242,7 +1242,7 @@ result = someLib.x } @Test - fun `gives decent error message if certificate file is emtpy`(@TempDir tempDir: Path) { + fun `gives decent error message if certificate file is empty`(@TempDir tempDir: Path) { val emptyCerts = tempDir.writeEmptyFile("empty.pem") val err = assertThrows { evalModuleThatImportsPackage(emptyCerts) } assertThat(err).hasMessageContaining("CA certificate file `${emptyCerts.pathString}` is empty.") @@ -1313,7 +1313,7 @@ result = someLib.x val options = CliEvaluatorOptions( CliBaseOptions( - sourceModules = listOf(URI("package://localhost:1/birds@0.5.0#/catalog/Ostritch.pkl")), + sourceModules = listOf(URI("package://localhost:1/birds@0.5.0#/catalog/Ostrich.pkl")), noCache = true, httpProxy = URI(wwRuntimeInfo.httpBaseUrl), caCertificates = listOf(FileTestUtils.selfSignedCertificate), @@ -1324,7 +1324,7 @@ result = someLib.x assertThat(output) .isEqualTo( """ - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" diff --git a/pkl-commons-test/src/main/files/packages/birds@0.5.0/package/catalog/Ostritch.pkl b/pkl-commons-test/src/main/files/packages/birds@0.5.0/package/catalog/Ostrich.pkl similarity index 76% rename from pkl-commons-test/src/main/files/packages/birds@0.5.0/package/catalog/Ostritch.pkl rename to pkl-commons-test/src/main/files/packages/birds@0.5.0/package/catalog/Ostrich.pkl index 89d69f26..f440b4f9 100644 --- a/pkl-commons-test/src/main/files/packages/birds@0.5.0/package/catalog/Ostritch.pkl +++ b/pkl-commons-test/src/main/files/packages/birds@0.5.0/package/catalog/Ostrich.pkl @@ -1,6 +1,6 @@ amends "../Bird.pkl" -name = "Ostritch" +name = "Ostrich" favoriteFruit { name = "Orange" diff --git a/pkl-commons-test/src/main/kotlin/org/pkl/commons/test/PackageServer.kt b/pkl-commons-test/src/main/kotlin/org/pkl/commons/test/PackageServer.kt index 6d588fb7..869afc14 100644 --- a/pkl-commons-test/src/main/kotlin/org/pkl/commons/test/PackageServer.kt +++ b/pkl-commons-test/src/main/kotlin/org/pkl/commons/test/PackageServer.kt @@ -46,7 +46,7 @@ import org.pkl.commons.deleteRecursively */ class PackageServer : AutoCloseable { companion object { - const val BIRDS_SHA = "bfaf5281613d170a740505cc87561041f4e0cad1f0e6938bf94f7609f9a4673d" + const val BIRDS_SHA = "6f18af649b47986530cd6dc39abe17888db2701bc5381c385fb86a32fda2685e" const val FRUIT_SHA = "34a15b02346e6acb85da5bd71d8b0738a79008b38a7fc805e5869d9129ad27d2" const val FRUIT_1_1_SHA = "8d982761d182f2185e4180c82190791d9a60c721cb3393bb2e946fab90131e8c" diff --git a/pkl-commons/src/main/kotlin/org/pkl/commons/Strings.kt b/pkl-commons/src/main/kotlin/org/pkl/commons/Strings.kt index d4d8e172..0f3a687f 100644 --- a/pkl-commons/src/main/kotlin/org/pkl/commons/Strings.kt +++ b/pkl-commons/src/main/kotlin/org/pkl/commons/Strings.kt @@ -61,7 +61,7 @@ fun shlex(input: String): List { quote = null lastCloseQuoteIndex = idx } - // if not in a quote and encounter a quote charater, enter a quote + // if not in a quote and encounter a quote character, enter a quote quote == null && (char == '\'' || char == '"') -> { quote = char } diff --git a/pkl-config-java/src/main/java/org/pkl/config/java/ConfigEvaluatorBuilder.java b/pkl-config-java/src/main/java/org/pkl/config/java/ConfigEvaluatorBuilder.java index f73e9e41..e909f279 100644 --- a/pkl-config-java/src/main/java/org/pkl/config/java/ConfigEvaluatorBuilder.java +++ b/pkl-config-java/src/main/java/org/pkl/config/java/ConfigEvaluatorBuilder.java @@ -245,7 +245,7 @@ public final class ConfigEvaluatorBuilder { /** * Sets the set of URI patterns to be allowed when importing modules. * - *

This is a convenieince method that delegates to the underlying evaluator builder. + *

This is a convenience method that delegates to the underlying evaluator builder. * * @throws IllegalStateException if {@link #setSecurityManager(SecurityManager)} was also called. */ @@ -257,7 +257,7 @@ public final class ConfigEvaluatorBuilder { /** * Returns the set of patterns to be allowed when importing modules. * - *

This is a convenieince method that delegates to the underlying evaluator builder. + *

This is a convenience method that delegates to the underlying evaluator builder. */ public List getAllowedModules() { return evaluatorBuilder.getAllowedModules(); @@ -266,7 +266,7 @@ public final class ConfigEvaluatorBuilder { /** * Sets the set of URI patterns to be allowed when reading resources. * - *

This is a convenieince method that delegates to the underlying evaluator builder. + *

This is a convenience method that delegates to the underlying evaluator builder. * * @throws IllegalStateException if {@link #setSecurityManager(SecurityManager)} was also called. */ @@ -278,7 +278,7 @@ public final class ConfigEvaluatorBuilder { /** * Returns the set of patterns to be allowed when reading resources. * - *

This is a convenieince method that delegates to the underlying evaluator builder. + *

This is a convenience method that delegates to the underlying evaluator builder. */ public List getAllowedResources() { return evaluatorBuilder.getAllowedResources(); @@ -288,7 +288,7 @@ public final class ConfigEvaluatorBuilder { * Sets the root directory, which restricts access to file-based modules and resources located * under this directory. * - *

This is a convenieince method that delegates to the underlying evaluator builder. + *

This is a convenience method that delegates to the underlying evaluator builder. */ public ConfigEvaluatorBuilder setRootDir(@Nullable Path rootDir) { evaluatorBuilder.setRootDir(rootDir); @@ -298,7 +298,7 @@ public final class ConfigEvaluatorBuilder { /** * Returns the currently set root directory, if set. * - *

This is a convenieince method that delegates to the underlying evaluator builder. + *

This is a convenience method that delegates to the underlying evaluator builder. */ public @Nullable Path getRootDir() { return evaluatorBuilder.getRootDir(); diff --git a/pkl-config-java/src/test/java/org/pkl/config/java/mapper/PObjectToDataObjectTest.java b/pkl-config-java/src/test/java/org/pkl/config/java/mapper/PObjectToDataObjectTest.java index 20ab35b2..e16a1fce 100644 --- a/pkl-config-java/src/test/java/org/pkl/config/java/mapper/PObjectToDataObjectTest.java +++ b/pkl-config-java/src/test/java/org/pkl/config/java/mapper/PObjectToDataObjectTest.java @@ -41,8 +41,8 @@ public class PObjectToDataObjectTest { EnumSet.of(Hobby.SURFING, Hobby.SWIMMING), new Address("sesame street", 94105)); - private static final PersonConstructoProperties pigeon2 = - new PersonConstructoProperties( + private static final PersonConstructorProperties pigeon2 = + new PersonConstructorProperties( "pigeon", 40, EnumSet.of(Hobby.SURFING, Hobby.SWIMMING), @@ -63,7 +63,7 @@ public class PObjectToDataObjectTest { @Test public void ex1_constructor_properties() { var ex1 = module.getProperty("ex1"); - assertThat(mapper.map(ex1, PersonConstructoProperties.class)).isEqualTo(pigeon2); + assertThat(mapper.map(ex1, PersonConstructorProperties.class)).isEqualTo(pigeon2); } @Test @@ -149,14 +149,14 @@ public class PObjectToDataObjectTest { } } - static class PersonConstructoProperties { + static class PersonConstructorProperties { final String name; final int age; final Set hobbies; final Address address; @ConstructorProperties({"name", "age", "hobbies", "address"}) - PersonConstructoProperties(String name, int age, Set hobbies, Address address) { + PersonConstructorProperties(String name, int age, Set hobbies, Address address) { this.name = name; this.age = age; this.hobbies = hobbies; @@ -166,7 +166,7 @@ public class PObjectToDataObjectTest { @Override public boolean equals(@Nullable Object obj) { if (this == obj) return true; - if (!(obj instanceof PersonConstructoProperties other)) return false; + if (!(obj instanceof PersonConstructorProperties other)) return false; return name.equals(other.name) && age == other.age && hobbies.equals(other.hobbies) diff --git a/pkl-core/src/main/java/org/pkl/core/Evaluator.java b/pkl-core/src/main/java/org/pkl/core/Evaluator.java index f8107fe2..e01ff237 100644 --- a/pkl-core/src/main/java/org/pkl/core/Evaluator.java +++ b/pkl-core/src/main/java/org/pkl/core/Evaluator.java @@ -170,7 +170,7 @@ public interface Evaluator extends AutoCloseable { String evaluateExpressionString(ModuleSource moduleSource, String expression); /** - * Evalautes the module's schema, which describes the properties, methods, and classes of a + * Evaluates the module's schema, which describes the properties, methods, and classes of a * module. * * @throws PklException if an error occurs during evaluation diff --git a/pkl-core/src/main/java/org/pkl/core/NoSuchPropertyException.java b/pkl-core/src/main/java/org/pkl/core/NoSuchPropertyException.java index 19d9e929..8cc1c6c6 100644 --- a/pkl-core/src/main/java/org/pkl/core/NoSuchPropertyException.java +++ b/pkl-core/src/main/java/org/pkl/core/NoSuchPropertyException.java @@ -16,7 +16,7 @@ package org.pkl.core; /** - * Indicates that a non-existent property was requested for a {@link Composite}. To check if a + * Indicates that a nonexistent property was requested for a {@link Composite}. To check if a * property exists, use {@link Composite#hasProperty(String)}. */ public final class NoSuchPropertyException extends RuntimeException { diff --git a/pkl-core/src/main/java/org/pkl/core/ast/member/ClassNode.java b/pkl-core/src/main/java/org/pkl/core/ast/member/ClassNode.java index 255642dc..fb82e92c 100644 --- a/pkl-core/src/main/java/org/pkl/core/ast/member/ClassNode.java +++ b/pkl-core/src/main/java/org/pkl/core/ast/member/ClassNode.java @@ -106,7 +106,7 @@ public final class ClassNode extends ExpressionNode { new VmTyped( frame.materialize(), null, // initialized later by VmClass - null, // initialized later by Vmclass + null, // initialized later by VmClass prototypeMembers); } diff --git a/pkl-core/src/main/java/org/pkl/core/ast/type/TypeNode.java b/pkl-core/src/main/java/org/pkl/core/ast/type/TypeNode.java index 3c8e6b90..38f14e6f 100644 --- a/pkl-core/src/main/java/org/pkl/core/ast/type/TypeNode.java +++ b/pkl-core/src/main/java/org/pkl/core/ast/type/TypeNode.java @@ -114,7 +114,7 @@ public abstract class TypeNode extends PklNode { } /** - * Visit child type nodes; but not paramaterized types (does not visit {@code String} in {@code + * Visit child type nodes; but not parameterized types (does not visit {@code String} in {@code * Listing}). */ protected abstract boolean acceptTypeNode(TypeNodeConsumer consumer); diff --git a/pkl-core/src/main/java/org/pkl/core/module/ModuleKeys.java b/pkl-core/src/main/java/org/pkl/core/module/ModuleKeys.java index 0e664a16..a6274ea3 100644 --- a/pkl-core/src/main/java/org/pkl/core/module/ModuleKeys.java +++ b/pkl-core/src/main/java/org/pkl/core/module/ModuleKeys.java @@ -534,7 +534,7 @@ public final class ModuleKeys { conn.connect(); if (conn instanceof JarURLConnection && IoUtils.isWindows()) { // On Windows, opening a JarURLConnection prevents the jar file from being deleted, unless - // cacheing is disabled. + // caching is disabled. // See https://bugs.openjdk.org/browse/JDK-8239054 conn.setUseCaches(false); } diff --git a/pkl-core/src/main/java/org/pkl/core/packages/PackageResolvers.java b/pkl-core/src/main/java/org/pkl/core/packages/PackageResolvers.java index 7da23f45..1b71f836 100644 --- a/pkl-core/src/main/java/org/pkl/core/packages/PackageResolvers.java +++ b/pkl-core/src/main/java/org/pkl/core/packages/PackageResolvers.java @@ -333,7 +333,7 @@ final class PackageResolvers { throw fileIsADirectory(); } var entries = cachedEntries.get(packageUri); - // need to normalize here but not in `doListElments` nor `doHasElement` because + // need to normalize here but not in `doListElements` nor `doHasElement` because // `TreePathElement.getElement` does normalization already. var path = IoUtils.toNormalizedPathString(Path.of(uri.getAssetPath()).normalize()); return entries.get(path).array(); diff --git a/pkl-core/src/main/java/org/pkl/core/util/GlobResolver.java b/pkl-core/src/main/java/org/pkl/core/util/GlobResolver.java index eca25f35..4e7cefd4 100644 --- a/pkl-core/src/main/java/org/pkl/core/util/GlobResolver.java +++ b/pkl-core/src/main/java/org/pkl/core/util/GlobResolver.java @@ -434,7 +434,7 @@ public final class GlobResolver { } } - /** Split a glob pattern into the base, non-wildard parts, and the wildcard parts. */ + /** Split a glob pattern into the base, non-wildcard parts, and the wildcard parts. */ private static Pair splitGlobPatternIntoBaseAndWildcards( ReaderBase reader, String globPattern, boolean hasAbsoluteGlob) { var effectiveGlobPattern = globPattern; diff --git a/pkl-core/src/main/java/org/pkl/core/util/IoUtils.java b/pkl-core/src/main/java/org/pkl/core/util/IoUtils.java index f7a8bbd7..6f1809e8 100644 --- a/pkl-core/src/main/java/org/pkl/core/util/IoUtils.java +++ b/pkl-core/src/main/java/org/pkl/core/util/IoUtils.java @@ -483,8 +483,8 @@ public final class IoUtils { start++; } var uriPartsRemaining = uriParts.subList(start, uriParts.size()); - var basePartsRemainig = baseParts.subList(start, baseParts.size()); - if (basePartsRemainig.isEmpty()) { + var basePartsRemaining = baseParts.subList(start, baseParts.size()); + if (basePartsRemaining.isEmpty()) { return new URI( null, null, @@ -495,7 +495,7 @@ public final class IoUtils { uri.getFragment()); } var resultingPath = - "../".repeat(basePartsRemainig.size()) + String.join("/", uriPartsRemaining); + "../".repeat(basePartsRemaining.size()) + String.join("/", uriPartsRemaining); return new URI(null, null, null, -1, resultingPath, uri.getQuery(), uri.getFragment()); } catch (URISyntaxException e) { // Impossible; started from a valid URI to begin with. @@ -716,7 +716,7 @@ public final class IoUtils { * URI#resolve(URI)} */ public static URI fixTripleSlashUri(URI baseUri, URI newUri) { - // `getHost()` is erroroneously `null` when parsing triple-slash URIs. + // `getHost()` is erroneously `null` when parsing triple-slash URIs. // Ensure that they are preserved during resolution. if (baseUri.getScheme() != null && baseUri.getScheme().equalsIgnoreCase(newUri.getScheme()) diff --git a/pkl-core/src/main/java/org/pkl/core/util/json/Json.java b/pkl-core/src/main/java/org/pkl/core/util/json/Json.java index 8837e249..83714647 100644 --- a/pkl-core/src/main/java/org/pkl/core/util/json/Json.java +++ b/pkl-core/src/main/java/org/pkl/core/util/json/Json.java @@ -32,7 +32,7 @@ import org.pkl.core.util.Nullable; /** * Parser for JSON. * - *

JSON types are paresd into the following Java types: + *

JSON types are parsed into the following Java types: * * * diff --git a/pkl-core/src/main/resources/org/pkl/core/errorMessages.properties b/pkl-core/src/main/resources/org/pkl/core/errorMessages.properties index 9fa7dbf3..67734035 100644 --- a/pkl-core/src/main/resources/org/pkl/core/errorMessages.properties +++ b/pkl-core/src/main/resources/org/pkl/core/errorMessages.properties @@ -675,7 +675,7 @@ invalidGlobInvalidCharacterInCharacterClass=\ The character `{0}` is not valid in a character class. invalidGlobExtGlob=\ -Extebded globbing features are not supported. +Extended globbing features are not supported. invalidGlobNestedSubpattern=\ Sub-patterns cannot be nested. To fix, remove or escape the inner `{` character. @@ -750,7 +750,7 @@ Failed to resolve type required for rendering protobuf.\n\ Consider adding a type annotation. cannotRenderSubtypeForProtobuf=\ -Can not render subtype {0} of specified type {1} in protobuf. +Cannot render subtype {0} of specified type {1} in protobuf. cannotExportValue=\ A value of type `{0}` cannot be exported. @@ -1079,7 +1079,7 @@ Certificates can only be loaded from `jar:` or `file:` URLs, but got:\n\ cannotFindBuiltInCertificates=\ Cannot find Pkl's trusted CA certificates on the class path.\n\ -To fix this problem, add dependendy `org.pkl:pkl-certs`. +To fix this problem, add dependency `org.pkl:pkl-certs`. # suppress inspection "HttpUrlsUsage" malformedProxyAddress=\ diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/api/pcfRenderer1.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/api/pcfRenderer1.pkl index bb812640..0e505355 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/api/pcfRenderer1.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/api/pcfRenderer1.pkl @@ -15,21 +15,21 @@ parrot { new { // multiline string that is a property within an element lastName = """ - Flinstone + Flintstone - Flinstone + Flintstone """ """ - Flinstone + Flintstone - Flinstone + Flintstone """ } // multiline string that is an element """ - Flistone + Flintstone - Flistone + Flintstone """ } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/classes/class3.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/classes/class3.pkl index 39260feb..230e53ce 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/classes/class3.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/classes/class3.pkl @@ -8,5 +8,5 @@ class Person { person = new Person { name = "Pigeon" // typo - adress = "Howdy St." + address_ = "Howdy St." } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/listings/listing5.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/listings/listing5.pkl index 2d910213..826bf170 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/listings/listing5.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/listings/listing5.pkl @@ -26,14 +26,14 @@ examples { module.catch(() -> l[0]) } - ["type check: local paramaterized property type, unparamaterized new with explicit parent"] { + ["type check: local parameterized property type, unparameterized new with explicit parent"] { local m: Listing = new Listing { 1 } module.catch(() -> m[0]) } - ["type check: local unparameterized property type, paramaterized new with explicit parent"] { + ["type check: local unparameterized property type, parameterized new with explicit parent"] { local m: Listing = new Listing { 1 } @@ -105,7 +105,7 @@ examples { "Ba" // fails `length.isOdd` "bar" // fails `this == capitalize()` } - // type check String(length.isOdd) should be propagated to the listing via a paramater type + // type check String(length.isOdd) should be propagated to the listing via a parameter type // annotation local function func1(listing: Listing) = listing // type check String(length.isOdd) should be propagated to the listing via a return type diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/listings/typeCheck.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/listings/typeCheck.pkl index 95935a01..d8c56d81 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/listings/typeCheck.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/listings/typeCheck.pkl @@ -35,7 +35,7 @@ local x7 = new Listing { } local x8 = new Listing { - throw("element unneccessarily evaluated") + throw("element unnecessarily evaluated") } res5 = x4.length == 1 diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead8.error.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead8.error.pkl index 8c054e45..fe00d8c1 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead8.error.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead8.error.pkl @@ -1 +1 @@ -res = import("package://localhost:0/badImportsWithinPackage@1.0.0#/unknownDependencyReaad.pkl") +res = import("package://localhost:0/badImportsWithinPackage@1.0.0#/unknownDependencyRead.pkl") diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead9.error.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead9.error.pkl index 93f855a7..6c43b560 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead9.error.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/badRead9.error.pkl @@ -1 +1 @@ -res = import("package://localhost:0/badImportsWithinPackage@1.0.0#/invalidPathReaad.pkl") +res = import("package://localhost:0/badImportsWithinPackage@1.0.0#/invalidPathRead.pkl") diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages1.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages1.pkl index 5aa4ac52..61d1d34a 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages1.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages1.pkl @@ -13,14 +13,14 @@ examples { } } import("package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl") - import("package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl") + import("package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl") } ["importing while specifying checksum"] { - import("package://localhost:0/birds@0.5.0::sha256:bfaf5281613d170a740505cc87561041f4e0cad1f0e6938bf94f7609f9a4673d#/catalog/Swallow.pkl") + import("package://localhost:0/birds@0.5.0::sha256:6f18af649b47986530cd6dc39abe17888db2701bc5381c385fb86a32fda2685e#/catalog/Swallow.pkl") } ["reads"] { read("package://localhost:0/birds@0.5.0#/Bird.pkl") read("package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl") - read("package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl") + read("package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl") } } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages2.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages2.pkl index 8d9f614c..0a479a3d 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages2.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/packages/packages2.pkl @@ -20,6 +20,6 @@ examples { import("package://localhost:0/birds@0.5.0#/allFruit.pkl").fruitFiles } ["glob import while specifying checksum"] { - import*("package://localhost:0/birds@0.5.0::sha256:bfaf5281613d170a740505cc87561041f4e0cad1f0e6938bf94f7609f9a4673d#/catalog/*.pkl") + import*("package://localhost:0/birds@0.5.0::sha256:6f18af649b47986530cd6dc39abe17888db2701bc5381c385fb86a32fda2685e#/catalog/*.pkl") } } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/input/projects/project1/basic.pkl b/pkl-core/src/test/files/LanguageSnippetTests/input/projects/project1/basic.pkl index 8d40921b..497c5285 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/input/projects/project1/basic.pkl +++ b/pkl-core/src/test/files/LanguageSnippetTests/input/projects/project1/basic.pkl @@ -1,11 +1,11 @@ amends ".../snippetTest.pkl" -import "@birds/catalog/Ostritch.pkl" +import "@birds/catalog/Ostrich.pkl" import "@birds/catalog/Swallow.pkl" examples { ["import package"] { - Ostritch + Ostrich Swallow } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/api/pcfRenderer1.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/api/pcfRenderer1.pcf index 11e2f0e5..06caa3ca 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/api/pcfRenderer1.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/api/pcfRenderer1.pcf @@ -11,19 +11,19 @@ barnOwl { parrot { new { lastName = """ - Flinstone + Flintstone - Flinstone + Flintstone """ """ - Flinstone + Flintstone - Flinstone + Flintstone """ } """ - Flistone + Flintstone - Flistone + Flintstone """ } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/api/protobuf.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/api/protobuf.pcf index 0ec14b45..e4a45c9b 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/api/protobuf.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/api/protobuf.pcf @@ -199,7 +199,7 @@ examples { foo: "renders" } """ - "Can not render subtype protobuf#Foo of specified type protobuf#Bar in protobuf." + "Cannot render subtype protobuf#Foo of specified type protobuf#Bar in protobuf." """ myFoo: { foo: "renders" diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/basic/importGlob.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/basic/importGlob.pcf index 5e82fd04..dd4d7d98 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/basic/importGlob.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/basic/importGlob.pcf @@ -84,8 +84,8 @@ examples { } ["package"] { new { - ["package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl"] { - name = "Ostritch" + ["package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -101,7 +101,7 @@ examples { "package://localhost:0/birds@0.5.0#/Bird.pkl" "package://localhost:0/birds@0.5.0#/allFruit.pkl" "package://localhost:0/birds@0.5.0#/catalog.pkl" - "package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + "package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" "package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" "package://localhost:0/birds@0.5.0#/some/dir/Bird.pkl" } @@ -116,8 +116,8 @@ examples { } ["package glob and up one level"] { new { - ["package://localhost:0/birds@0.5.0#/catalog/../catalog/Ostritch.pkl"] { - name = "Ostritch" + ["package://localhost:0/birds@0.5.0#/catalog/../catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/basic/readGlob.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/basic/readGlob.pcf index ade69180..c38b647a 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/basic/readGlob.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/basic/readGlob.pcf @@ -156,19 +156,19 @@ examples { """ base64 = "bW9kdWxlIGJpcmRzLmNhdGFsb2cKCmNhdGFsb2cgPSBpbXBvcnQqKCJjYXRhbG9nLyoucGtsIikKY2F0YWxvZ0ZpbGVzID0gcmVhZCooImNhdGFsb2cvKi5wa2wiKQo=" } - ["package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl"] { - uri = "package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl"] { + uri = "package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl"] { uri = "package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/classes/class3.err b/pkl-core/src/test/files/LanguageSnippetTests/output/classes/class3.err index 93dca147..9e7c7ffe 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/classes/class3.err +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/classes/class3.err @@ -1,8 +1,8 @@ –– Pkl Error –– -Cannot find property `adress` in object of type `class3#Person`. +Cannot find property `address_` in object of type `class3#Person`. -xx | adress = "Howdy St." - ^^^^^^ +xx | address_ = "Howdy St." + ^^^^^^^^ at class3#person (file:///$snippetsDir/input/classes/class3.pkl) Did you mean any of the following? diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/listings/listing5.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/listings/listing5.pcf index 1fe6bf38..faa89df5 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/listings/listing5.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/listings/listing5.pcf @@ -10,10 +10,10 @@ examples { ["type check: local new with inferred parent"] { "Expected value of type `String`, but got type `Int`. Value: 1" } - ["type check: local paramaterized property type, unparamaterized new with explicit parent"] { + ["type check: local parameterized property type, unparameterized new with explicit parent"] { "Expected value of type `String`, but got type `Int`. Value: 1" } - ["type check: local unparameterized property type, paramaterized new with explicit parent"] { + ["type check: local unparameterized property type, parameterized new with explicit parent"] { "Expected value of type `String`, but got type `Int`. Value: 1" } ["amending listings does not require type checks on amending object members"] { diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead8.err b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead8.err index 4a6140e0..ee02727b 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead8.err +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead8.err @@ -1,9 +1,9 @@ –– Pkl Error –– -Cannot find module `package://localhost:0/badImportsWithinPackage@1.0.0#/unknownDependencyReaad.pkl`. +Cannot find dependency named `notapackage`, because it was not declared in package `package://localhost:0/badImportsWithinPackage@1.0.0`. -x | res = import("package://localhost:0/badImportsWithinPackage@1.0.0#/unknownDependencyReaad.pkl") - ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -at badRead8.error#res (file:///$snippetsDir/input/packages/badRead8.error.pkl) +x | res = read("@notapackage/Foo.txt") + ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +at unknownDependencyRead#res (package://localhost:0/badImportsWithinPackage@1.0.0#/unknownDependencyRead.pkl) xxx | text = renderer.renderDocument(value) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead9.err b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead9.err index ece9a711..fa3b6cba 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead9.err +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/badRead9.err @@ -1,9 +1,9 @@ –– Pkl Error –– -Cannot find module `package://localhost:0/badImportsWithinPackage@1.0.0#/invalidPathReaad.pkl`. +I/O error reading resource `package://localhost:0/badImportsWithinPackage@1.0.0#/not/a/valid/path.txt`. -x | res = import("package://localhost:0/badImportsWithinPackage@1.0.0#/invalidPathReaad.pkl") - ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -at badRead9.error#res (file:///$snippetsDir/input/packages/badRead9.error.pkl) +x | res = read("not/a/valid/path.txt") + ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +at invalidPathRead#res (package://localhost:0/badImportsWithinPackage@1.0.0#/invalidPathRead.pkl) xxx | text = renderer.renderDocument(value) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages1.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages1.pcf index 370c3456..ca1d8c68 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages1.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages1.pcf @@ -13,7 +13,7 @@ examples { } } new { - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -57,18 +57,18 @@ examples { base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCmltcG9ydCAiQGZydWl0aWVzL2NhdGFsb2cvYXBwbGUucGtsIgoKbmFtZSA9ICJTd2FsbG93IgoKZmF2b3JpdGVGcnVpdCA9IGFwcGxlCg==" } new { - uri = "package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + uri = "package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } } } diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages2.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages2.pcf index 3c6ec7ee..012f5793 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages2.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/packages/packages2.pcf @@ -1,8 +1,8 @@ examples { ["glob import"] { new { - ["package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl"] { - name = "Ostritch" + ["package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -17,8 +17,8 @@ examples { } ["glob import within package"] { new { - ["catalog/Ostritch.pkl"] { - name = "Ostritch" + ["catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -40,19 +40,19 @@ examples { } ["glob read"] { new { - ["package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl"] { - uri = "package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl"] { + uri = "package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl"] { uri = "package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" @@ -72,19 +72,19 @@ examples { } ["glob read within package"] { new { - ["catalog/Ostritch.pkl"] { - uri = "package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["catalog/Ostrich.pkl"] { + uri = "package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["catalog/Swallow.pkl"] { uri = "package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" @@ -118,13 +118,13 @@ examples { } ["glob import while specifying checksum"] { new { - ["package://localhost:0/birds@0.5.0::sha256:bfaf5281613d170a740505cc87561041f4e0cad1f0e6938bf94f7609f9a4673d#/catalog/Ostritch.pkl"] { - name = "Ostritch" + ["package://localhost:0/birds@0.5.0::sha256:6f18af649b47986530cd6dc39abe17888db2701bc5381c385fb86a32fda2685e#/catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } } - ["package://localhost:0/birds@0.5.0::sha256:bfaf5281613d170a740505cc87561041f4e0cad1f0e6938bf94f7609f9a4673d#/catalog/Swallow.pkl"] { + ["package://localhost:0/birds@0.5.0::sha256:6f18af649b47986530cd6dc39abe17888db2701bc5381c385fb86a32fda2685e#/catalog/Swallow.pkl"] { name = "Swallow" favoriteFruit { name = "Apple" diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/basic.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/basic.pcf index dd28472f..44be0a5d 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/basic.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/basic.pcf @@ -16,7 +16,7 @@ facts { examples { ["import package"] { new { - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -40,11 +40,11 @@ examples { new { uri = "projectpackage://localhost:0/birds@0.5.0#/catalog" text = """ - Ostritch.pkl + Ostrich.pkl Swallow.pkl """ - base64 = "T3N0cml0Y2gucGtsClN3YWxsb3cucGtsCg==" + base64 = "T3N0cmljaC5wa2wKU3dhbGxvdy5wa2wK" } new { uri = "projectpackage://localhost:0/birds@0.5.0#/" diff --git a/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/globbing.pcf b/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/globbing.pcf index 3f000af6..bf425325 100644 --- a/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/globbing.pcf +++ b/pkl-core/src/test/files/LanguageSnippetTests/output/projects/project1/globbing.pcf @@ -1,8 +1,8 @@ examples { ["glob-import within package"] { new { - ["catalog/Ostritch.pkl"] { - name = "Ostritch" + ["catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -17,8 +17,8 @@ examples { } ["glob-import absolute package uri"] { new { - ["package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl"] { - name = "Ostritch" + ["package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl"] { + name = "Ostrich" favoriteFruit { name = "Orange" } @@ -44,25 +44,25 @@ examples { } } ["glob-import using dependency notation"] { - Set("@birds/catalog/Ostritch.pkl", "@birds/catalog/Swallow.pkl") + Set("@birds/catalog/Ostrich.pkl", "@birds/catalog/Swallow.pkl") Set("@birds/Bird.pkl", "@birds/allFruit.pkl", "@birds/catalog.pkl") - Set("@birds/Bird.pkl", "@birds/allFruit.pkl", "@birds/catalog.pkl", "@birds/catalog/Ostritch.pkl", "@birds/catalog/Swallow.pkl", "@birds/some/dir/Bird.pkl") + Set("@birds/Bird.pkl", "@birds/allFruit.pkl", "@birds/catalog.pkl", "@birds/catalog/Ostrich.pkl", "@birds/catalog/Swallow.pkl", "@birds/some/dir/Bird.pkl") } ["glob-read using dependency notation"] { new { - ["@birds/catalog/Ostritch.pkl"] { - uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["@birds/catalog/Ostrich.pkl"] { + uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["@birds/catalog/Swallow.pkl"] { uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" @@ -154,19 +154,19 @@ examples { """ base64 = "bW9kdWxlIGJpcmRzLmNhdGFsb2cKCmNhdGFsb2cgPSBpbXBvcnQqKCJjYXRhbG9nLyoucGtsIikKY2F0YWxvZ0ZpbGVzID0gcmVhZCooImNhdGFsb2cvKi5wa2wiKQo=" } - ["@birds/catalog/Ostritch.pkl"] { - uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["@birds/catalog/Ostrich.pkl"] { + uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["@birds/catalog/Swallow.pkl"] { uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" @@ -200,19 +200,19 @@ examples { } ["glob-read within package"] { new { - ["catalog/Ostritch.pkl"] { - uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["catalog/Ostrich.pkl"] { + uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["catalog/Swallow.pkl"] { uri = "projectpackage://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" @@ -232,19 +232,19 @@ examples { } ["glob-read absolute package uri"] { new { - ["package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl"] { - uri = "package://localhost:0/birds@0.5.0#/catalog/Ostritch.pkl" + ["package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl"] { + uri = "package://localhost:0/birds@0.5.0#/catalog/Ostrich.pkl" text = """ amends "../Bird.pkl" - name = "Ostritch" + name = "Ostrich" favoriteFruit { name = "Orange" } """ - base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cml0Y2giCgpmYXZvcml0ZUZydWl0IHsKICBuYW1lID0gIk9yYW5nZSIKfQo=" + base64 = "YW1lbmRzICIuLi9CaXJkLnBrbCIKCm5hbWUgPSAiT3N0cmljaCIKCmZhdm9yaXRlRnJ1aXQgewogIG5hbWUgPSAiT3JhbmdlIgp9Cg==" } ["package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl"] { uri = "package://localhost:0/birds@0.5.0#/catalog/Swallow.pkl" diff --git a/pkl-core/src/test/kotlin/org/pkl/core/EvaluatorTest.kt b/pkl-core/src/test/kotlin/org/pkl/core/EvaluatorTest.kt index f3c2b408..bc6891ff 100644 --- a/pkl-core/src/test/kotlin/org/pkl/core/EvaluatorTest.kt +++ b/pkl-core/src/test/kotlin/org/pkl/core/EvaluatorTest.kt @@ -407,7 +407,7 @@ class EvaluatorTest { .trimIndent() } else """ - birds = import("@birds/catalog/Ostritch.pkl") + birds = import("@birds/catalog/Ostrich.pkl") """ .trimIndent() diff --git a/pkl-core/src/test/kotlin/org/pkl/core/packages/PackageResolversTest.kt b/pkl-core/src/test/kotlin/org/pkl/core/packages/PackageResolversTest.kt index 34f5aab1..550c7220 100644 --- a/pkl-core/src/test/kotlin/org/pkl/core/packages/PackageResolversTest.kt +++ b/pkl-core/src/test/kotlin/org/pkl/core/packages/PackageResolversTest.kt @@ -152,7 +152,7 @@ class PackageResolversTest { assertThat(elements) .isEqualTo( setOf( - PathElement("Ostritch.pkl", false), + PathElement("Ostrich.pkl", false), PathElement("Swallow.pkl", false), ) ) diff --git a/pkl-doc/src/test/files/DocGeneratorTest/output/localhost(3a)0/birds/0.5.0/index.html b/pkl-doc/src/test/files/DocGeneratorTest/output/localhost(3a)0/birds/0.5.0/index.html index 33ed09bd..56ee5113 100644 --- a/pkl-doc/src/test/files/DocGeneratorTest/output/localhost(3a)0/birds/0.5.0/index.html +++ b/pkl-doc/src/test/files/DocGeneratorTest/output/localhost(3a)0/birds/0.5.0/index.html @@ -39,7 +39,7 @@
Dependencies:
fruit:1.0.5
Checksum:
-
bfaf5281613d170a740505cc87561041f4e0cad1f0e6938bf94f7609f9a4673d
+
6f18af649b47986530cd6dc39abe17888db2701bc5381c385fb86a32fda2685e
diff --git a/pkl-executor/pkl-executor.gradle.kts b/pkl-executor/pkl-executor.gradle.kts index 79c7dd34..05583f19 100644 --- a/pkl-executor/pkl-executor.gradle.kts +++ b/pkl-executor/pkl-executor.gradle.kts @@ -74,7 +74,7 @@ val prepareHistoricalDistributions by val distributionDir = outputDir.get().asFile.toPath().also(Files::createDirectories) for (file in pklHistoricalDistributions.files) { val target = distributionDir.resolve(file.name) - // Create normal files on Windows, symlink on macOS/linux (need admin priveleges to create + // Create normal files on Windows, symlink on macOS/linux (need admin privileges to create // symlinks on Windows) if (buildInfo.os.isWindows) { if (!Files.isRegularFile(target, LinkOption.NOFOLLOW_LINKS)) { diff --git a/pkl-executor/src/main/java/org/pkl/executor/EmbeddedExecutor.java b/pkl-executor/src/main/java/org/pkl/executor/EmbeddedExecutor.java index 5eb84682..e7d67f88 100644 --- a/pkl-executor/src/main/java/org/pkl/executor/EmbeddedExecutor.java +++ b/pkl-executor/src/main/java/org/pkl/executor/EmbeddedExecutor.java @@ -267,7 +267,7 @@ final class EmbeddedExecutor implements Executor { if (clazz == null) { if (name.startsWith("org.pkl.executor.spi.")) { try { - // give pkl-executor a chance to load the SPI clasa + // give pkl-executor a chance to load the SPI class clazz = pklExecutorClassLoader.loadClass(name); } catch (ClassNotFoundException ignored) { // The SPI class exists in this distribution but not in pkl-executor, diff --git a/stdlib/EvaluatorSettings.pkl b/stdlib/EvaluatorSettings.pkl index f8c29e7e..baf36ef1 100644 --- a/stdlib/EvaluatorSettings.pkl +++ b/stdlib/EvaluatorSettings.pkl @@ -172,7 +172,7 @@ class ExternalReader { /// On macOS, Linux, and Windows platforms, this may be: /// /// * An absolute path - /// * A relative path (to the currrent working directory) + /// * A relative path (to the current working directory) /// * The name of the executable, to be resolved against the `PATH` environment variable executable: String diff --git a/stdlib/analyze.pkl b/stdlib/analyze.pkl index 8cbe3f84..eedd8bc9 100644 --- a/stdlib/analyze.pkl +++ b/stdlib/analyze.pkl @@ -52,7 +52,7 @@ class ImportGraph { /// /// Dependency-notation imports, such as `"@myPackage/myModule.pkl"`, are represented as /// in-language URIs with scheme `projectpackage:`. - /// In the case of local project dependenecies, they will be local URIs resolved from the project + /// In the case of local project dependencies, they will be local URIs resolved from the project /// file URI (in normal cases, `file:` URIs). resolvedImports: Map(keys == imports.keys) }