Skip to content

Commit

Permalink
bump pm java version
Browse files Browse the repository at this point in the history
  • Loading branch information
henrypinkard committed Jun 14, 2024
1 parent c348ebc commit 491b00d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
4 changes: 2 additions & 2 deletions java/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.micro-manager.pycro-manager</groupId>
<artifactId>PycroManagerJava</artifactId>
<version>0.46.8</version>
<version>0.46.9</version>
<packaging>jar</packaging>
<name>Pycro-Manager Java</name>
<description>The Java components of Pycro-Manager</description>
Expand Down Expand Up @@ -154,4 +154,4 @@
</repository>
</distributionManagement>

</project>
</project>
17 changes: 10 additions & 7 deletions pycromanager/test/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ def replace_jars(new_file_path, old_file_path, jar_names: list):
new_jar_name, new_jar_version = find_jar(new_file_path, jar_name)
old_jar_name, old_jar_version = find_jar(old_file_path, jar_name)

print('Old version:', old_jar_name, old_jar_version)
print('New version:', new_jar_name, new_jar_version)
if new_jar_name is not None:
# Only replace jar file if newly compiled file version is larger
if new_jar_version[0] > old_jar_version[0] or \
Expand Down Expand Up @@ -106,14 +108,15 @@ def install_mm():
print(f)
replace_jars(os.path.join(java_path, 'target/dependency'), os.path.join(mm_install_dir, 'plugins', 'Micro-Manager'),
['AcqEngJ', 'NDTiffStorage', 'NDViewer', 'PyJavaZ'])
# Not needed because deps of deps are already included in the JARs?
# Copy dependency jar files if present in ../../REPO_NAME/target
for repo_name in ['AcqEngJ', 'NDTiffStorage', 'NDViewer', 'PyJavaZ']:
print(f'JAR files present in {repo_name}/target:')
for f in os.listdir(os.path.join(java_path, f'../../{repo_name}/target')):
print(f)
if os.path.isdir(os.path.join(java_path, f'../../{repo_name}/target')):
replace_jars(os.path.join(java_path, f'../../{repo_name}/target'),
os.path.join(mm_install_dir, 'plugins', 'Micro-Manager'), [repo_name])
# for repo_name in ['AcqEngJ', 'NDTiffStorage', 'NDViewer', 'PyJavaZ']:
# print(f'JAR files present in {repo_name}/target:')
# for f in os.listdir(os.path.join(java_path, f'../../{repo_name}/target')):
# print(f)
# if os.path.isdir(os.path.join(java_path, f'../../{repo_name}/target')):
# replace_jars(os.path.join(java_path, f'../../{repo_name}/target'),
# os.path.join(mm_install_dir, 'plugins', 'Micro-Manager'), [repo_name])

except Exception as e:
warnings.warn(f'Failed to replace JAR files: {e}')
Expand Down

0 comments on commit 491b00d

Please sign in to comment.