github Freika/dawarich 0.25.0

13 hours ago

This release is focused on improving the visits experience.

Since previous implementation of visits was not working as expected, this release introduces a new approach. It is recommended to remove all non-confirmed visits before or after updating to this version. To do that, run this in the Console:

Visit.suggested.destroy_all

Short Visits demo:

visits-demo.mov

There is a known issue when data migrations are not being run automatically on some systems. If you're experiencing issues when opening map page, trips page or when trying to see visits, try executing the following command in the Console:

User.includes(:tracked_points, visits: :places).find_each do |user|
  places_to_update = user.places.where(lonlat: nil)

  # For each place, set the lonlat value based on longitude and latitude
  places_to_update.find_each do |place|
    next if place.longitude.nil? || place.latitude.nil?

    # Set the lonlat to a PostGIS point with the proper SRID
    # rubocop:disable Rails/SkipsModelValidations
    place.update_column(:lonlat, "SRID=4326;POINT(#{place.longitude} #{place.latitude})")
    # rubocop:enable Rails/SkipsModelValidations
  end

  user.tracked_points.update_all('lonlat = ST_SetSRID(ST_MakePoint(longitude, latitude), 4326)')
end

If you have encountered the Caused by PG::UniqueViolation: ERROR: duplicate key value violates unique constraint "index_points_on_lonlat_timestamp_user_id" error, there is a potential solution for you: #948 (reply in thread)

For solutions to some more errors, take a look at the Updating guides page.

With any errors, don't hesitate to ask for help in the Discord server.

Added

  • A new button to open the visits drawer.
  • User can now confirm or decline visits directly from the visits drawer.
  • Visits are now being shown on the map: orange circles for suggested visits and slightly bigger blue circles for confirmed visits.
  • User can click on a visit circle to rename it and select a place for it.
  • User can click on a visit card in the drawer panel to move to it on the map.
  • User can select click on the "Select area" button in the top right corner of the map to select an area on the map. Once area is selected, visits for all times in that area will be shown on the map, regardless of whether they are in the selected time range or not. #921 #319 #674
  • User can now select two or more visits in the visits drawer and merge them into a single visit. This operation is not reversible. #909 #927 #674 #817 #898
  • User can now select two or more visits in the visits drawer and confirm or decline them at once. This operation is not reversible.
  • Status field to the User model. Inactive users are now being restricted from accessing some of the functionality, which is mostly about writing data to the database. Reading is remaining unrestricted.
  • After user is created, a sample import is being created for them to demonstrate how to use the app.

Changed

  • Links to Points, Visits & Places, Imports and Exports were moved under "My data" section in the navbar.
  • Restrict access to Sidekiq in non self-hosted mode.
  • Restrict access to background jobs in non self-hosted mode.
  • Restrict access to users management in non self-hosted mode.
  • Restrict access to API for inactive users.
  • All users in self-hosted mode are active by default.
  • Points are now using lonlat column for storing longitude and latitude.
  • Semantic history points are now being imported much faster.
  • GPX files are now being imported much faster.
  • Trips, places and points are now using PostGIS' database attributes for storing longitude and latitude.
  • Distance calculation are now using Postgis functions and expected to be more accurate.
  • Visits names are now being suggested based on place and address. #902 #899
  • Confirmed/rejected visits should now be remembered. #848

Fixed

  • Fixed a bug where non-admin users could not import Immich and Photoprism geolocation data.
  • Fixed a bug where upon point deletion it was not being removed from the map, while it was actually deleted from the database. #883
  • Fixed a bug where upon import deletion stats were not being recalculated. #824

💙 This release is supported by Steven B., James Manolios, chenrik, aldumil, derpderpington, Chippie, dint, jhalpern, Lex Fradski, Schlufo, cyberswan.at, craftyklaus, JMyrng, Andre and Jonah B. on Patreon 💙

What's Changed

Full Changelog: 0.24.1...0.25.0

Don't miss a new dawarich release

NewReleases is sending notifications on new releases.