Emails Subscriptions Not Following Timezone

Hi,

Metabase says it will send out an email at 8AM MT, but it is somehow converting that time to UTC. The emails in this example go out at 2PM. Any idea on what is going on? JVM and server are using MT, and it says right in the screenshot that it will use MT.

  "system-info": {
"file.encoding": "UTF-8",
"java.runtime.name": "OpenJDK Runtime Environment",
"java.runtime.version": "11.0.15-ea+8-LTS",
"java.vendor": "Red Hat, Inc.",
"java.vendor.url": "https://www.redhat.com/",
"java.version": "11.0.15-ea",
"java.vm.name": "OpenJDK 64-Bit Server VM",
"java.vm.version": "11.0.15-ea+8-LTS",
"os.name": "Linux",
"os.version": "4.18.0-373.el8.x86_64",
"user.language": "en",
"user.timezone": "America/Edmonton"

},

Hi @cbeauch
Post "Diagnostic Info" from Admin > Troubleshooting.

Hi @flamber

Here is the rest of the diagnostics info. We are only using BigQuery and Google Analytics, if that makes any difference.

{
  "browser-info": {
    "language": "en-US",
    "platform": "MacIntel",
    "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.0.0.0 Safari/537.36",
    "vendor": "Google Inc."
  },
  "system-info": {
    "file.encoding": "UTF-8",
    "java.runtime.name": "OpenJDK Runtime Environment",
    "java.runtime.version": "11.0.15-ea+8-LTS",
    "java.vendor": "Red Hat, Inc.",
    "java.vendor.url": "https://www.redhat.com/",
    "java.version": "11.0.15-ea",
    "java.vm.name": "OpenJDK 64-Bit Server VM",
    "java.vm.version": "11.0.15-ea+8-LTS",
    "os.name": "Linux",
    "os.version": "4.18.0-373.el8.x86_64",
    "user.language": "en",
    "user.timezone": "America/Edmonton"
  },
  "metabase-info": {
    "databases": [
      "bigquery-cloud-sdk",
      "googleanalytics"
    ],
    "hosting-env": "unknown",
    "application-database": "mysql",
    "application-database-details": {
      "database": {
        "name": "MySQL",
        "version": "8.0.26"
      },
      "jdbc-driver": {
        "name": "MariaDB Connector/J",
        "version": "2.7.5"
      }
    },
    "run-mode": "prod",
    "version": {
      "date": "2022-05-16",
      "tag": "v0.43.1",
      "branch": "release-x.43.x",
      "hash": "7f1a1c4"
    },
    "settings": {
      "report-timezone": null
    }
  }
}

@cbeauch Metabase's scheduler will follow the Report Timezone in Admin > Settings > Localization.
At the same time, you are storing your information in MySQL, and I cannot tell the timezone of that.
Timezones are complicated and running servers (databases, apps) in non-UTC is generally not recommended.

Ok, thanks. So you would recommend that I change Java, Centos and MySQL to UTC?

Wouldn't that make the message in subscriptions to say

"Emails will be sent at 8:AM UTC, your Metabase timezone"?

That doesn't sound ideal for users

@cbeauch In a perfect world all servers runs UTC and just uses frontend settings to make adjustments.
Go and change your Report Timezone in Admin > Settings > Localization.

Gotcha, thanks. I will put everything back to UTC and change the report timezone to MST.

I misunderstood how report timezone worked, thinking it didn't matter if I left it to default because it doesn't support BigQuery.

@cbeauch Yeah, the Report Timezone is a bit too broad currently. We are working on splitting it up, so it's more granular (in case you need timezone adjustments for one database, but not another).
For reference: https://github.com/metabase/metabase/issues/14056

Timezones are generally really complicated, since there are so many layers that can differ.

Make sure you do proper testing after you change timezones, since it can impact broadly everywhere.

1 Like