Anna Buianova
08d34d5d34
Don't show low scoring articles in timeframe feeds ( #20525 )
2024-01-15 14:14:32 +00:00
Ben Halpern
1c25171cc6
Do not vacate tags if parameter not passed via API ( #20513 )
2024-01-11 16:25:21 -05:00
Ben Halpern
04d4b2340d
Add downstream score effects from spam role ( #20498 )
...
* Add downstream score effects from spam role
* Move async score calc down low
* Add tests
* Add stub
* Fix typo
* No need for guard
* No need for guard
2024-01-08 16:25:28 +00:00
Ben Halpern
108d753d68
Add articles clickbait_score as factor in final feed ordering ( #20493 )
...
* Add articles clickbait_score
* Add attributes
* Fix field test config
2024-01-05 09:37:53 -05:00
Anna Buianova
473594f192
Match spam role with existing suspended actions ( #20477 )
...
* Started matching spam and suspended roles
* Match spam and suspended roles in most cases
* Fixed check_suspended for unauthenticated users
2023-12-27 20:12:50 +00:00
Anna Buianova
1eeaa34e98
Added spam role ( #20434 )
...
* Added spam role
* Fixed role spec
2023-12-11 14:27:22 +00:00
Philip How
dde1b10ba6
Add 24 weeks to Community Wellness streak ( #20396 )
...
* add 24 as week option
* Fix flaky spec
---------
Co-authored-by: Mac Siri <krairit.siri@gmail.com>
2023-11-28 21:50:04 +00:00
Anna Buianova
3093e0207a
Refactoring Badges::AwardThumbsUp ( #20360 )
...
* Optimized Badges::AwardThumbsUp
* Reorganized Badges::AwardThumbsUp spec
2023-11-16 15:10:21 +00:00
Philip How
779701d5f6
Automatically reward thumbs-up milestone badges ( #20338 )
...
* initial work on #20111
* initial work on #20111
* fix cron
* is this a good test
* add in initial check, fix test data
* Update spec
---------
Co-authored-by: Mac Siri <krairit.siri@gmail.com>
2023-11-14 16:47:24 +00:00
Ben Halpern
e7fc1bb0ce
Add article id and geolocation info to billboard events ( #20329 )
...
* Add article id and geolocation info to billboard events
* Confirm destroyed in rollup
2023-11-09 12:43:23 -05:00
Ben Halpern
64fd4e7800
Adjust VariantQuery to dynamically account for recent last_comment_at ( #20323 )
...
* Adjust VariantQuery to dynamically account for recent last_comment_at
* Adjust test line which was temporarily adjusted
2023-11-07 08:22:22 -05:00
Ben Halpern
587a11d490
Adjust image optimization for billboards ( #20309 )
...
* Adjust image optimization for billboards
* Fix test typo
* Adjust default
2023-11-02 16:12:20 -04:00
Gabriel Quaresma
593d95e7a8
Feat Make tag score minimum configurable by admins ( #20233 )
...
* feat: add Settings::UserExperience.award_tag_minimum_score
* test: write new specs
* test: write a new test case
2023-11-01 17:48:25 +03:00
Anna Buianova
a14a1e9e7a
Accept published_at in Article API ( #20235 )
2023-10-11 09:12:35 -04:00
Ben Halpern
044fe88230
Follow on adjustments to flag counts ( #20207 )
2023-10-02 17:23:37 +07:00
Ben Halpern
f811f17830
Fix irrelevant flag numbers ( #20204 )
...
* Fix irrelevent numbers in admin display
* Remove unused possible_spam_users_count
* Fix tab styles
2023-10-02 15:01:50 +07:00
Ben Halpern
8268a59ae5
Add feed event for extended page view ( #20198 )
2023-10-02 10:28:31 +07:00
Ben Halpern
c5201ca888
Remove dead code associated with old roles ( #20175 )
...
* Remove dead code associated with old roles
* Remove test references
* Removed from seeds
* Removed unused roles from locales
---------
Co-authored-by: lightalloy <lightallloy@gmail.com>
2023-10-01 09:33:25 +07:00
Ben Halpern
e998e5bcac
Do not show suspended followers in aggregated siblings for notification ( #20174 )
2023-09-27 20:23:25 -04:00
Joshua Wehner
2c138d86ef
Add or remove limited role via API ( #20136 )
...
* Refactor API user suspend, make room for more roles
* Handle adding limited
* Handle remove limited
* And swagger docs
* Update & refactor roles spec
* Remove old route
* Remove old specs
2023-09-26 09:57:14 -04:00
Joshua Wehner
6a48b486ca
Onboarding: custom newsletter opt-in settings ( #20114 )
...
* Settings can process markdown into html
* Update Settings with new onboarding settings
* Async render onboarding newsletter step
* Tweak onboarding design
* Fix broken spec
* Better rendered component test
* Tweaks to match design
* Try to tweak design
* Try having a default state
* Tweak placeholder content
* Better await componentDidMount
* Continue to tweak the design
* ContentRenderer#process should always return Result
* Try more clarity in the partial
* Rubocop
2023-09-26 06:34:19 -04:00
PJ
47deeefe57
Optionally limit new users based on admin setting ( #20149 )
...
* create admin setting for new user status
* limiting on signup working 🎉
* update registration specs
* sort out OAuth registrations
2023-09-26 10:46:36 +01:00
PJ
da73343540
Skip round robin mod notifications for limited users ( #20128 )
...
* return early if user is limited
* fix worker specs
2023-09-19 15:03:20 +01:00
Ben Halpern
cadebde66f
Add feed_success_score and other count tallies ( #20106 )
...
* Add initial feed events score
* Add feed events score
* Clean up code styles
* Adjust how tests are run
* Fix conflicts
* Update app/javascript/articles/Feed.jsx
* Add additional feed events tabulation queries for more reliable eventual consistency
* Add additional feed events tabulation queries for more reliable eventual consistency
* Fix test logic
* Updates from feedback
2023-09-15 12:02:26 -04:00
Joshua Wehner
6fe9d7d7a6
Allow org admins to add members as co-authors ( #20008 )
...
* Basics might be working?
* Stop propagating button clicks in autocomplete pills
* Better blank slate
* Better location to stop propagation
* Remove author_id from org co-authors
* Move UserStore and try testing it
* Remove extraneous comments
* OH... that's what that does!
* Very basic testing
* Re-organize javascripts
* Rename & re-org for testing
* Cleanup
* More tests
* Remove unnecessary nesting
* Coninuing to try to bump coverage
* Include /packs/ in code coverage metric
* Try tweaking jest coverage more?
We probably can't collect coverage from all of packs/* (because coverage is too low) but maybe we can try to opt-in for newer areas as we go?
* Relocate JS tests, for build & coverage
* User ID exception on search, not fetch
* Remove commented-out console.log
---------
Co-authored-by: Mac Siri <krairit.siri@gmail.com>
2023-09-15 08:12:41 -04:00
PJ
3f922921e5
Admin setting to control enabled countries for billboard geotargeting ( #20083 )
...
* use instance setting for enabled target geolocations
* add validation for enabled geolocations setting
* a start on the UI?
* backend tweaks for UI
* proper crack at autocomplete component
* fix region targeting toggle
* e2e spec
2023-09-12 12:06:00 -04:00
PJ
95ca9d37c5
Record feed events for public reactions ( #20079 )
...
* create feed event on feed reaction
* move feed event creation to feed event model
* tiny whoops
* fix failing specs
* slightly less flaky e2e spec (maybe)
* tiny fixes (couldn't resist)
2023-09-12 08:36:10 -04:00
Anna Buianova
aa5cb535fa
Add languages to User model ( #20059 )
2023-09-11 11:44:19 -04:00
PJ
3f7d1fbc1a
Create feed impression and click events ( #20043 )
...
* getting started: model setup
* basic controller action & spec
* somewhat working click events
* pick up on impressions
* there was an attempt at batching without duplicates
* (better) bulk upsert service
* fix specs?
* touch up feed events JS
* end-to-end specs??
* workers wip
* fix failing user delete spec
2023-09-11 13:32:36 +01:00
Ben Halpern
ed853f7e1e
Fix "register" bugs in invitations ( #20071 )
...
* Fix registered bugs in invitations
* Update spec/requests/api/v0/admin/users_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Move to v1 spec
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-09-08 17:00:37 -04:00
Ben Halpern
02db638d9d
Remove cache headers from sidebars controller ( #20002 )
...
* Remove cache headers from sidebars controller
* Remove cache bust logic for sidebar
2023-08-29 13:42:10 -04:00
Joshua Wehner
d227e1d285
Suppressing articles negative-follow tags from appearing in the "relevant" feed ( #19948 )
...
* Try suppressing all negative-follow tags
* userData isn't always available
* Bolster test coverage for tag filter scenarios
* Antitags for the non-basic 'strategy'
* Rename antitags -> hidden_tags
* Rename 'anti_tags' -> 'hidden_tags' as well
* Use userData.followed_tags to derive hidden_tags
2023-08-28 10:11:20 -04:00
Ben Halpern
3324bf47f1
Add http_header to FastText for Fastly compatibility ( #19999 )
...
* Add http_header to FastText for Fastly compatibility
* Update app/services/articles/enrich_image_attributes.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/html/parser.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/display_ad_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Fix rubocop
* Also accept canges to main image for this re-calc
* Rename display_ad_spec for compatibility with main
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-08-28 09:34:59 -04:00
Anna Buianova
2d6b740940
Renamed DisplayAd model to Billboard ( #19993 )
...
* Renamed Resource Admin: DisplayAd to Billboard
* Renamed DisplayAd to Billboard
* Added a data update script for roles
2023-08-28 08:09:36 -04:00
Rajat Talesra
5ef0f43636
Added limited role ( #19969 )
...
* Added limited role
* Nit fix
* Updated tetss
* Added spec tests
* Attempt at 100% code coverage
* Rollback DB migration
* Revert timestamp
2023-08-25 14:41:17 +05:30
Ben Halpern
98c92bcde2
Fix never_imagga for imgproxy ( #19997 )
2023-08-24 19:00:23 -04:00
Ben Halpern
1463d8c98a
Do not crop with imagga if never_imagga is passed ( #19975 )
...
* Do not crop with imagga if never_imagga is passed
* Clean up code styles
2023-08-22 11:52:02 -04:00
Ben Halpern
ec7adf56fe
Allow admins to set cover image height configs ( #19936 )
...
* Initial basic work
* Bulk of related work, including find/replace on the inputs
* Adjust some tests
* Adjust some specs
* Fix a few more tests
* Clean up tests
* Adjust tests
* Test fiddle
* Adjust crop back to be a param
* Update tests
* Set proper defaults
* Fix some styling
* Adjust enrichment logic and tests
* Adjust form JS
* Update test snapshot
* Clean up formatting
* Fix spec name
* Adjust some css and defaults
* Adjust translation for image provider options
* Switch from fill to fill-down
* Proper fallback image
* Fix tests
* Update app/services/images/optimizer.rb
Co-authored-by: Mac Siri <mac@forem.com>
---------
Co-authored-by: Mac Siri <mac@forem.com>
2023-08-21 13:25:16 -04:00
Ben Halpern
0c92bc3f27
Full minimagick social image rollout ( #19949 )
...
* Full minimagick social image rollout
* Fix errant puts
* Remove unnecessary file
2023-08-21 09:11:14 -04:00
Joshua Wehner
c5731ac91a
FeatureFlag.enabled_for_user(_id) ( #19929 )
...
* FeatureFlag can work with user_id
* Use the new methods
* No thank you, rubocop
* Some tests would be nice
* Try to appease codecov
---------
Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2023-08-15 12:02:44 -04:00
Ben Halpern
33b11f1eac
Use direct relative path to access assets in minimagick ( #19933 )
...
* Use direct relative path to access assets in minimagick
* Skip Hairtrigger spec
* Add a test to get more coverage
2023-08-15 09:36:16 -04:00
Ben Halpern
c9af090af0
Prefer Minimagick for social image generation ( #19826 )
...
* Prefer Minimagick for social image generation
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Reformat main file
* Fix user tests
* Finish up tests
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Change asset path syntax
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Refactor magickally file
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Fix style issues
* Remove pure black
* Test color swap
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Add more test coverage to service
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Fix doubled spec name
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Add upload spec
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/images/generate_social_image_magickally_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Swap out magickally in social image worker
* Add test stub and rescue
* Update spec/rails_helper.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Fix regex
* Add cache busting and error logging
* Update app/services/images/generate_social_image_magickally.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Fix style issues
* Add more test coverage
* Add feature flag
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-08-11 08:22:06 -04:00
Mac Siri
1c351bf22c
BanishUser also destroy organization ( #19911 )
2023-08-10 08:26:45 -04:00
Anna Buianova
058fd17b58
Renamed display_ad variables to billboard ( #19851 )
...
* Renamed display ad variables and constants
* Renamed display_ads associations
* Fixed variable name in display ads
* Renamed display_ads variables in views
* Fixed admin billboard view spec
* Fixed variable name in FilteredAdsQuery
2023-07-31 17:19:02 +03:00
Josh Klar
0b63876044
fastly_config: Soft-deprecate FastlyConfig service used only for DEV. ( #19837 )
2023-07-26 16:45:58 -07:00
Anna Buianova
ffb560c2a7
Rename DisplayAdEvent to BillboardEvent ( #19833 )
2023-07-26 13:57:02 -04:00
Anna Buianova
963eea8126
Aliased DisplayAdEvent.display_ad_id to billboard_id ( #19805 )
...
* Aliased DisplayAdEvent.display_ad_id to billboard_id
* Allow :display_ad_id instead of :billboard_id for billboard_events in case of cache
2023-07-24 17:54:39 +03:00
Anna Buianova
e659dbfc00
Renamed display_ad_events variables and associations ( #19788 )
...
* Renamed stuff related to display_ad_events (except the model)
* Updated user billboard_events association spec
* Fixed display_ad_event factory
2023-07-21 14:59:28 +03:00
Duke Greene
9a6f04bd37
api v1 endpoint for creating an organization ( #19778 )
...
* api v1 endpoint for creating an organization
* address failing specs, regenerate swagger docs
* remove old comment in destroy now that woreker call takes third argument
* refactor our services for profile images into images folder
2023-07-21 07:43:56 -04:00
Ben Halpern
8335a37315
Language detection with CLD3 ( #19756 )
...
* Language detection with CLD3 POC
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update app/models/article.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Clean up tests
* Clean up tests
* Move language detection to service
* rubocop
* Update app/services/languages/detection.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* More linting cleanup
* Remove allow_any_instance_of
* Update tests to better exercise different paths
* Fix flaky spec
* Update spec/services/languages/detection_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/models/article_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/languages/detection_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/languages/detection_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/languages/detection_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update spec/services/languages/detection_spec.rb
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-17 08:57:20 -04:00