Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/copilot-instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ When writing documentation that includes Java or Python code examples:
- **Style & Formatting**: Java code follows Google style with project overrides from `.config/checkstyle_neqsim.xml` and formatter profiles (`.config/neqsim_formatter.xml`); keep indentation at two spaces and respect existing comment minimalism.
- **Code Formatting (Spotless) - MANDATORY**: AI-generated Java is NOT auto-formatted. After creating or editing ANY `.java` file, run `./mvnw spotless:apply` (Windows: `mvnw.cmd spotless:apply`) to reformat to the project style, then `git add` the changes before committing. CI runs `./mvnw spotless:check` and FAILS the build on any unformatted file. Do not rely on local pre-commit hooks being installed, and NEVER bypass the gate with `git commit --no-verify`.
- **Serialization & Copying**: Many equipment classes rely on Java serialization (`ProcessEquipmentBaseClass.copy()`); avoid introducing non-serializable fields or mark them `transient` to preserve cloning. SpotBugs enforces this via the SE_BAD_FIELD rule. When adding fields to any `Serializable` class (equipment, measurement devices, mechanical design, thermo phases), use the correct modifier order: `private transient Type field;` or `private final transient Type field;`. Common non-serializable types that need `transient`: `Function`, `BiConsumer`, `Consumer`, `Thread`, JDBC `Connection`/`Statement`, Apache Commons Math interpolators, and any inner class that doesn't implement `Serializable`. The `ProcessLogic` interface extends `Serializable`.
- **External Dependencies**: Core math depends on EJML, Commons Math, JAMA, and MTJ; check numerical stability when swapping linear algebra routines, and keep JSON/YAML handling aligned with gson/jackson versions pinned in pom.xml.
- **External Dependencies**: Core math depends on ojAlgo, Commons Math, JAMA, and MTJ; check numerical stability when swapping linear algebra routines, and keep JSON/YAML handling aligned with gson/jackson versions pinned in pom.xml.
- **Java 8 Compatibility (MANDATORY)**: See the critical section at the top of this document. All code MUST compile with Java 8. The CI build will FAIL if you use Java 9+ features like `String.repeat()`, `var`, `List.of()`, etc.
- **Sample Flow**:

Expand Down
5 changes: 0 additions & 5 deletions .github/workflows/publish_to_maven_central.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,6 @@ jobs:
gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE
cache: 'maven'
# Clean Maven cache for critical dependencies to avoid stale class issues
- name: Clean dependency cache for EJML
run: |
rm -rf ~/.m2/repository/org/ejml
echo "Cleaned EJML from Maven cache to ensure fresh download"
# --- Java 8 artifact ---
- name: Publish package (Java 8)
run: ./mvnw -f pomJava8.xml -P release --batch-mode clean deploy -Dmaven.deploy.skip=true -DskipTests -Djacoco.skip=true -Drevision=${{ steps.release_version.outputs.version }} -ntp
Expand Down
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,9 @@
<version>3.6.1</version>
</dependency>
<dependency>
<groupId>org.ejml</groupId>
<artifactId>ejml-all</artifactId>
<version>0.45.1</version>
<groupId>org.ojalgo</groupId>
<artifactId>ojalgo</artifactId>
<version>52.0.0</version>
</dependency>
<dependency>
<groupId>gov.nist.math</groupId>
Expand Down
6 changes: 3 additions & 3 deletions pomJava8.xml
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@
<version>3.6.1</version>
</dependency>
<dependency>
<groupId>org.ejml</groupId>
<artifactId>ejml-all</artifactId>
<version>0.41</version> <!-- Last version supporting java 8-->
<groupId>org.ojalgo</groupId>
<artifactId>ojalgo</artifactId>
<version>52.0.0</version>
</dependency>
<dependency>
<groupId>gov.nist.math</groupId>
Expand Down

Large diffs are not rendered by default.

Loading
Loading