Commit graph

58 commits

Author SHA1 Message Date
Dessalines
9367cbdb00
Upgrading from postgres 15 -> 16-alpine. ()
- Includes an upgrade script.
- Fixes 
2024-02-07 11:21:02 +01:00
Dessalines
3647a46e86
Remove ansible tagging. ()
- See https://github.com/LemmyNet/lemmy-ansible/issues/215
2024-01-31 10:46:13 +01:00
a09027c4c0
Silence warnings from ts-rs ()
* Silence warnings from ts-rs

https://github.com/Aleph-Alpha/ts-rs/issues/108

* fmt
2024-01-29 09:22:53 -05:00
Dessalines
eb0dc2fda4
Moving from yarn to pnpm. ()
* Moving from yarn to pnpm.

* Prettier check.
2024-01-29 11:38:39 +01:00
dullbananas
759f6d8a9a
Better query plan viewing experience ()
* stuff

* stuff including batch_upsert function

* stuff

* do things

* stuff

* different timestamps

* stuff

* Revert changes to comment.rs

* Update comment.rs

* Update comment.rs

* Update post_view.rs

* Update utils.rs

* Update up.sql

* Update up.sql

* Update down.sql

* Update up.sql

* Update main.rs

* use anyhow macro

* replace get(0) with first()

* as_slice

* Update series.rs

* Update db_perf.sh

* Update and rename crates/db_schema/src/utils/series.rs to crates/db_perf/src/series.rs

* Update utils.rs

* Update main.rs

* Update main.rs

* Update .woodpecker.yml

* fmt main.rs

* Update .woodpecker.yml

* Instance::delete at end

* Update main.rs

* Update Cargo.toml

---------

Co-authored-by: Nutomic <me@nutomic.com>
2024-01-24 10:22:33 -05:00
Dessalines
70530a8ad2
Optimizing sql format check. ()
* Optimizing sql format check.

* Fixing format testing.

* Fixing format testing 2.
2023-12-14 11:35:52 -05:00
a790a24c4d
Revert debug auth ()
* Revert "Some changes to help debug auth problems on lemmy.ml ()"

This reverts commit 16ac893e15.

* Rename auth cookie back to jwt
2023-12-05 11:22:08 -05:00
16ac893e15
Some changes to help debug auth problems on lemmy.ml ()
* Some changes to help debug auth problems on lemmy.ml

* fix

* clippy
2023-12-01 09:18:29 -05:00
dullbananas
30f7135f32
Use rust 1.74.0 in CI and move clippy lints to Cargo.toml ()
* ci rust 1.74.0

* do it

* Update .woodpecker.yml

* Update Cargo.toml

* Update lint.sh

* Update lib.rs

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-11-21 08:51:22 -05:00
Dessalines
8deb4e5752
Convert more responses to SuccessResponse. Fixes ()
* Convert more responses to SuccessResponse. Fixes 

* Upgrading lemmy-js-client.
2023-10-19 13:21:05 -04:00
Anon
fe3ebea95a
Add logging for pictrs uploads ()
* Add logging for pictrs uploads

* cleanup
2023-09-06 09:13:30 -04:00
Dessalines
be1389420b
Adding SQL format checking via pg_format / pgFormatter ()
* SQL format checking, 1.

* SQL format checking, 2.

* SQL format checking, 3.

* SQL format checking, 4.

* SQL format checking, 5.

* Running pg_format

* Getting rid of comment.

* Upping pg_format version.

* Using git ls-files for sql format check.

* Fixing sql lints.

* Addressing PR comments.
2023-08-02 12:44:51 -04:00
cetra3
9256895635
Cache & Optimize Woodpecker CI ()
* Try using drone cache plugin

* Try another path

* Include volume

* Fix formatting

* Include fmt

* Exclude cargo dir from prettier

* Don't override cargo

* Just do check

* Add cache key

* Use different cache plugin

* Add clippy

* Try minio

* Add quotes

* Try adding secrets

* Try again

* Again

* Use correct secret formation

* Add back clippy

* Use secret for the root bucket name

* Try drone cache instead

* Add region

* Add path-style option

* Include cargo clippy

* Include everything again

* Fix formatting

* Don't run clippy twice

* Add `allow` statements for tests to pass

* Adjust endpoint to be a secret

* Fix prettier

* Merge & fix tests

* Try to restart the woodpecker test

* Change the ENV var name

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-07-17 11:04:14 -04:00
Dessalines
164f4b93d9
Make lemmy_api_common wasm-compatible ()
* Fixing lemmy_api_common optionals

* Adding taplo for .toml files.

* Versioning taplo in woodpecker.

* Addressing PR comments.
2023-07-14 10:45:18 +02:00
dullbananas
7d3894d5dd
Automatically manage database when running scripts/test.sh ()
* Update .gitignore

* Create start-dev-db.sh

* Rename start-dev-db.sh to start_dev_db.sh

* Update .gitignore

* Update start_dev_db.sh

* Update start_dev_db.sh

* Update start_dev_db.sh

* Update start_dev_db.sh

* h

* Update test.sh

* Update start_dev_db.sh

* made it work

* Make test.sh work when run from scripts dir
2023-06-30 09:50:30 +02:00
Dessalines
6c64cb5233
Fixing release script. ()
* Fixing release script.

* Version 0.18.1-rc.2

* Removing cargo update from release script.

* Fixing topdir location.
2023-06-29 16:17:59 +02:00
dullbananas
bef76630c5
Remove redundant calls to Iterator::collect ()
* Remove redundant calls to `Iterator::collect`

* Update mentions.rs

* Add clippy lints and run fmt

* CI ran on the wrong commit again 
2023-06-28 11:19:26 +02:00
e4b739320c
Run cargo update as part of release script ()
To get newest dependency patches and get rid of yanked deps

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-27 08:59:58 -04:00
Dessalines
98482b1564
Fixing the release script. ()
* Fixing the release script.

* Updating the submodules.
2023-06-27 10:28:56 +02:00
cetra3
9406c3ad2b
Adjust the config check to be a separate faster to compile binary () 2023-06-26 06:23:21 -04:00
Patrick Roe
87aa0acaf1
Align default DB password with documentation () 2023-06-13 22:23:07 +02:00
Dessalines
8cb5939f50
Adding hot_rank columns in place of function sorting. ()
* Adding hot_rank columns in place of function sorting.

- Creates hot_rank columns for post, comment, and community.
- Fixes 

* Updating all hot ranks on startup.

* Fixing post.url migration.

* Removing update_instance_software from startup.

* Adding post_rank query
2023-06-08 16:15:15 -04:00
Charles Hall
4e5798852f
make shebangs posix compliant ()
Previously, these scripts wouldn't work on exotic systems such as NixOS.

```
fd '\.sh$' -t f --exec sed -i 's@#!/bin/bash@#!/usr/bin/env bash@'
```
2023-06-08 15:38:26 -04:00
Dessalines
8c0c1628e0
Adding a vector indexing check to prevent panics. Fixes ()
* Adding a vector indexing check to prevent panics. Fixes 

* Fixing for new clippy lint.

* Externalizing get_top_mod check. Adding get_first clippy lint

* Removing unit tests get(0)s

* Fixing some firsts manually
2023-02-28 12:34:50 +01:00
Dessalines
3735c6fabf
Adding instance software and version. Fixes ()
* Adding instance software and version. Fixes 

* Fix clippy.

* Fix clippy 2

* Fixing some more issues.
2023-02-18 09:36:12 -05:00
Dessalines
993489a80f
Combine prod and dev docker setups using build-arg ()
* Combine prod and dev docker setups using build-arg

- Fixes 

* Dont use cache for release build.
2023-02-17 15:29:45 +09:00
43b94e5f16
Fix paths in release script, update crate versions () 2023-02-01 00:26:51 +09:00
Dessalines
a610211557
Fixing .drone.yml ()
* Try to fix docker/drone plugin

* Trying to use one rust image.

* Fixing drone 1.

* Fixing drone 2.

* Add drone notify.

* Fixing drone 3.

* Fixing drone 4.

* Fix clippy.

* Remove uninlined format lint.

* Combine all cargo tasks

* Fixing drone 5.

* Fixing drone 6.

* Fixing drone 7.

* Fixing drone 8.

* Fixing drone 9.

* Fixing drone 10.

* Fixing drone 12.

* Fixing drone 13.

* Fixing drone 14.

* Fixing drone 15.

* Fixing drone 16.

* Fixing drone 17.

* Fixing drone 18.

* Fixing drone 19.

* Fixing drone 20.

* Fixing drone 21.

* Fixing drone 22.

* Fixing drone 23.

* Fixing drone 24.

* Fixing drone 25.

* Fixing drone 26.

* Fixing drone 27.

* Fixing drone 28.

* Fixing drone 29.

* Fixing drone 30.

* Fixing drone 31.

* Fixing drone 32.

* Fixing drone 33.

* Fixing drone 34.

* Fixing drone 35.

* Fixing drone 36.

* Fixing drone 37.

* Fixing drone 38.

* Fixing drone 39.

* Fixing drone 40.

* Fixing drone 41.

* Fixing drone 43.

* Fixing drone 44.

* Fixing drone 45.

* Last cleanup.

* Fixing drone 46.

* Separate ci steps ()

* separate ci steps

* fix 1

* add comments

* dont add rustfmt explicitly

* Revert "dont add rustfmt explicitly"

This reverts commit 358ce3302a134b7ac88d90a854079356995e9725.

* dont use all features for tests

---------

Co-authored-by: Nutomic <me@nutomic.com>
2023-01-30 14:17:24 -05:00
7e3d3839b6
Post creation from Mastodon (fixes ) ()
* Post creation from Mastodon (fixes )

* better logic for page title

* add deserialize helper

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-01-20 12:43:23 -05:00
Dessalines
ac56504291
Upgrade to postgres 15. () 2023-01-20 18:15:07 +01:00
2ec8bb877c
Some script improvements ()
- Allow specifying which packages should be tested
- Hardcode `lemmy` as db password because thats used in many different places
2023-01-13 00:23:58 +01:00
9f52d4ae53
Fix user following ()
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-12-19 10:55:26 -05:00
d39bc14c43
Add some more clippy lints ()
* Add some more clippy lints

* restore config

* no allow dirty

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-24 16:38:00 +00:00
Dessalines
65041a20bb
Fix clippy lints. ()
* Fix clippy lints.

* Fix fmt.

* Dont use cargo-workspaces for fix-clippy script.
2022-11-21 10:21:09 +00:00
6f3bf4634b
Various pedantic clippy fixes ()
* Various pedantic clippy fixes

* more clippy pedantic fixes

* try to fix ci

* add fix clippy script, use rust 1.65

* fix clippy
2022-11-19 04:33:54 +00:00
a39cf31466
Sort vecs before assert to avoid random test failures ()
* Sort language read queries to avoid random test failures

* change sort columns
2022-11-18 20:30:59 -05:00
df7809fbbb
Specify dependencies and metadata for entire workspace ()
* Specify dependencies and metadata for entire workspace (fixes )

* building api_common shouldnt depend on diesel

* remove drone task

* try with quotes

* fix clippy

* more clippy
2022-11-17 15:23:01 +00:00
83d2959b4b
Update doku dependency for easier formatting of defaults.hjson () 2022-11-11 16:01:29 -05:00
095591ef69 dont test with all features 2022-09-02 10:49:54 -04:00
d058e2217a api changes for comment language tagging 2022-09-02 10:49:54 -04:00
bc7450ae3e add test for comment view languages 2022-09-02 10:49:54 -04:00
f5b1ee6c34 fix tests 2022-09-02 10:49:54 -04:00
Dessalines
2f9d8776ac
Tweaking postgres upgrade script ()
* Tweaking postgres upgrade script

* Removing pointless comments.
2022-08-04 22:03:14 +02:00
Dessalines
9c3efe32e7
First pass at adding comment trees. ()
* First pass at adding comment trees.

- Extracted comment replies into its own table.
- Added ltree column to comment
- Added parent_id param to GetComments to fetch a tree branch
- No paging / limiting yet

* Adding child_count to comment_aggregates.

* Adding parent comment update counts

* Fix unit tests.

* Comment tree paging mostly done.

* Fix clippy

* Fix drone tests wrong postgres version.

* Fix unit tests.

* Add back in delete in unit test.

* Add postgres upgrade script.

* Fixing some PR comments.

* Move update ltree into Comment::create

* Updating based on comments.

* Fix send soft fail.
2022-07-30 05:55:59 +02:00
Dessalines
11b7525c41
Add update translations script. () 2022-03-29 16:54:16 +00:00
Dessalines
f6b543ae0f
Add tag to lemmy-ansible. () 2022-03-29 15:36:59 +00:00
Dessalines
052e509954
Fixing release script. () 2022-03-29 15:23:39 +00:00
611d336f94
Remove docker/prod unused files (fixes ) () 2022-03-17 16:28:35 +00:00
3032a2745b
Opentelemetry ()
* Add otlp export

* Add jaeger to dev docker

* More instrument

* Update deps

* Merge from main.

* Add comment about viewing traces

* Fixing reqwest-tracing dep.

* Update pre-commit regex

* Move imports to top

Co-authored-by: Dessalines <tyhou13@gmx.com>
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-01-06 19:10:20 +00:00
7bfe59a89f
Format config/defaults.hjson before committing () 2021-10-22 13:29:47 -04:00