Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add draft for new find fix paths modul #347 #351

Merged
merged 4 commits into from May 24, 2024
Merged

Conversation

TobiasNx
Copy link
Collaborator

@TobiasNx TobiasNx commented May 3, 2024

See #347

@fsteeg as author of the list-fix-paths and list-fix-value wrappers could you review this new wrapper for finding the paths/keys to given value-patterns.

Copy link
Member

@dr0i dr0i left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't commit the compiled class. Always and only the source (*.java)

@TobiasNx
Copy link
Collaborator Author

TobiasNx commented May 3, 2024

Thanks @dr0i can you elaborate a little bit? For a noob like me? Where can I see if the class is compiled? And how can I keep the source?

@dr0i
Copy link
Member

dr0i commented May 6, 2024

All java source files have the file suffix java while all their compiled counterparts have class.
You can keep the source by adding and commiting it. Its name is FindFixPaths.java.

@TobiasNx
Copy link
Collaborator Author

TobiasNx commented May 6, 2024

Thanks did that. I compiled that and have run the following script with:
$ ./gradlew metafix-runner:run --args='/home/tobias/git/metafacture_workflows/find-Fix-Paths/test.flux'

"https://d-nb.info/1106253078/about/marcxml"
| open-http(accept="application/xml")
| decode-xml
| handle-marcxml
| find-fix-paths(".*ETL.*")
| print
;

it returns empty, should return:
24510.a Automating ETL processes using the domain-specific modeling approach

https://metafacture.org/playground/?flux=%22https%3A//d-nb.info/1106253078/about/marcxml%22%0A%7C+open-http%28accept%3D%22application/xml%22%29%0A%7C+decode-xml%0A%7C+handle-marcxml%0A%7C+fix%28%22nothing%28%29%22%2CrepeatedFieldsToEntities%3D%22true%22%29%0A%7C+flatten%0A%7C+stream-to-triples%0A%7C+filter-triples%28objectpattern%3D%22.%2AETL.%2A%22%29%0A%7C+template%28%22%24%7Bp%7D\t+%24%7Bo%7D%22%29%0A%7C+print%0A%3B%0A

@TobiasNx
Copy link
Collaborator Author

TobiasNx commented May 7, 2024

Thanks did that. I compiled that and have run the following script with: $ ./gradlew metafix-runner:run --args='/home/tobias/git/metafacture_workflows/find-Fix-Paths/test.flux'

"https://d-nb.info/1106253078/about/marcxml"
| open-http(accept="application/xml")
| decode-xml
| handle-marcxml
| find-fix-paths(".*ETL.*")
| print
;

it returns empty, should return: 24510.a Automating ETL processes using the domain-specific modeling approach

https://metafacture.org/playground/?flux=%22https%3A//d-nb.info/1106253078/about/marcxml%22%0A%7C+open-http%28accept%3D%22application/xml%22%29%0A%7C+decode-xml%0A%7C+handle-marcxml%0A%7C+fix%28%22nothing%28%29%22%2CrepeatedFieldsToEntities%3D%22true%22%29%0A%7C+flatten%0A%7C+stream-to-triples%0A%7C+filter-triples%28objectpattern%3D%22.%2AETL.%2A%22%29%0A%7C+template%28%22%24%7Bp%7D\t+%24%7Bo%7D%22%29%0A%7C+print%0A%3B%0A

I assume that the string for objectPattern is not passed through somehow and therefore the result is emtpy.

@TobiasNx
Copy link
Collaborator Author

TobiasNx commented May 8, 2024

I assume that the string for objectPattern is not passed through somehow and therefore the result is emtpy.

@dr0i any idea why the string is not passed through?

@TobiasNx TobiasNx requested a review from dr0i May 8, 2024 07:42
@TobiasNx TobiasNx marked this pull request as ready for review May 23, 2024 13:15
@TobiasNx TobiasNx requested review from fsteeg and dr0i and removed request for dr0i May 23, 2024 13:15
@TobiasNx
Copy link
Collaborator Author

TobiasNx commented May 23, 2024

Thanks to @dr0i this now seems to work. @fsteeg could perhaps review this.

PS: Checkstyle errors were also adjusted.

Copy link
Member

@fsteeg fsteeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool!

Just two inline suggestions (your name).

TobiasNx and others added 2 commits May 24, 2024 12:16
Co-authored-by: Fabian Steeg <steeg@hbz-nrw.de>
@TobiasNx TobiasNx requested review from dr0i and removed request for dr0i May 24, 2024 10:18
@TobiasNx TobiasNx merged commit 2d4f976 into master May 24, 2024
1 check passed
@TobiasNx TobiasNx deleted the 347-findingPathModul branch May 24, 2024 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants