summaryrefslogtreecommitdiff
path: root/src/weepinbell/utils
AgeCommit message (Collapse)Author
10 daysutils.digest: remove unused codeeltrac
11 daysall: use JF2 as a single source of truth, compile ↵eltrac
microformats/JSON-LD/<meta> to JF2 (#80) closes #75 This is a large squash commit. For details, see https://codeberg.org/eltrac/weepinbell/pulls/80
2026-10-13style: cljfmt everythingeltrac
2026-10-13wrapper: fix not downloading photo with relative urlseltrac
2026-10-13utils.url: fix not removing trailing slash of a root path URLeltrac
2026-10-11proceesor, storage: better error handling; no interrupting pipelineeltrac
- print clear stack trace using timbre when capturing exceptions - don't pass nil to url/normalize; if url/normalize gets a nil, instead of NPE, it now returns an empty string - capture exceptions in processor pipeline to keep it from dying - http.downloader now checks response status instead of blindly downloading anything
2026-10-07test, verifier, utils: fix failed testseltrac
- some namespaces tests require did not get renamed - url/extract might throw AssertionError if input contains non-HTTP(S) urls. it should not check schemes. - verifier doesn't need to filter non-HTTP(S) urls since they will return false anyway, and plus it makes localhost urls in tests fail
2026-10-07verifier, utils: fix verification failure when page contains invalid URLeltrac
- URISyntaxException was not caught in url/normalize, causing normalization failure which leads to verification failure when there is one invalid URL, even though valid URL exists - skip non-HTTP(S) urls when verifying
2026-10-07receiver, verifier, retriever, storage: URL normalizationeltrac
utils: add url utilities for accurate comparison - add url/normalize taht reconstructs URL, strips unnecessary components, reorders query string and ensures determinism - add url/url= that uses url/normalize receiver: normalize URLs before checking and putting in queue - use url= and normalize from utils.url - rename verify-request to check-request to avoid confusion with verifier.clj verifier: check if source includes target URL more accurately - implement url/extract with robinst/autolink-java, which extracts a vector a URLs from string - check if source includes target by 1. extracting all links from source body 2. normalizing all links before comparing with target link (with url= func) - refactor verify-headers -> match-content-types, with a higher order function and clearer description retriever, storage: use url= instead of = when comparing urls
2026-09-18utils.url: valid-http-url? should return false for non-string typeseltrac
2026-09-16style: format the codebaseeltrac
starting from now, every commit should be cljfmt-fixed
2026-09-14processor, verifier, webhook: tidy up log msg/level; improve code styleeltrac
processor: tidy up log msg and level; improve code style - all messages start with a lower-case letter - all webmention-related logging contains first 8-digit of its id - use WARN level when something is deleted, not INFO - use WARN level when exceptional cases happen, not ERROR - get rid of emojis in log messages utils: digest-short function for logging verifier: tidy up log messages; improve code style - use `cond` instead of nested `if`s - same message format as processor's logs webhook: tidy up log messages; send webhooks robustly - use same logging formats as processor and verifier - handle error, 4xx, 5xx status and log them - move logging inside webhook module, away from core.clj
2026-09-11feed, receiver, wrapper: replace MD5 \w SHA-256eltrac
also refactored weepinbell.utils.digest. business logic no longer depend on a concrete algorithm like SHA-256 or MD5, it's just a `digest` function whose defaults can be replaced anytime.
2026-09-11refactor(receiver, webhook, utils): replace commons validatoreltrac
used java.net to create a small validator that passes the test refactor: rename validator to url, and move other url funcs here
2026-09-11refactor(receiver, wrapper, feed): replace md5-hash dependency #9eltrac
use Java introp instead of cljc-md5, which is heavy on dependencies.