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

fixups after babashka migration and new parsing template #133

Merged
merged 5 commits into from
Apr 2, 2024

Conversation

danielhvs
Copy link
Contributor

@danielhvs danielhvs commented Apr 2, 2024

Issues

  1. Using the new template with the {{x}} format causes parsing strings to erroneous getting replaced by null instead of "" when "absent"
  2. Java exception thrown while trying to parse java.nio.file.Path as a string in triangulum.utils/remove-end fn

Fixes

  1. Coerce nils to ""
  2. transform the Path into a String before calling remove-end

@danielhvs danielhvs requested a review from rjsheperd April 2, 2024 01:28
@danielhvs
Copy link
Contributor Author

danielhvs commented Apr 2, 2024

Identified the problem by using the command below:

~/sig/pyrolyzer-8894$ clojure -M:systemd enable -r pyrolyzer-8894

@rjsheperd
Copy link
Member

Good catch, @danielhvs !

src/triangulum/utils.clj

L59-60: Please format inside of let block to create two columns.

Should look like:

(let [handlebar #"\{\{([^\}]+)\}\}"
      fmt-keys  (re-seq handlebar fmt-str)
      m         (update-vals m (fnil identity ""))
      values    (map #(m (-> % (second) (snake->kebab) (keyword))) fmt-keys)]

@danielhvs danielhvs force-pushed the dsilva-fixup-new-version branch from 41ca9e3 to 0839d21 Compare April 2, 2024 02:05
@danielhvs danielhvs force-pushed the dsilva-fixup-new-version branch from 53ad4b9 to 468bca1 Compare April 2, 2024 02:14
@danielhvs danielhvs merged commit 57d309e into main Apr 2, 2024
2 checks passed
@danielhvs danielhvs deleted the dsilva-fixup-new-version branch April 2, 2024 13:09
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.

2 participants