KoenZomers / RingRecordingDownload

Console Application for Windows, Raspberry Pi, Linux and macOS which allows for downloading of Ring recorded events
Apache License 2.0
20 stars 9 forks source link

[BUG] Brief description #12

Closed matziq closed 3 months ago

matziq commented 1 year ago

Hello fellow MSFT guy. I just ran the latest version (2.1.0.1) and I get this right after it connects and tries to pull a list. Any ideas?

Retrieving all devices... Unhandled exception. System.Text.Json.JsonException: The JSON value could not be converted to System.Nullable1[System.Int64]. Path: $.stickup_cams[0].battery_life | LineNumber: 0 | BytePositionInLine: 6320. ---> System.InvalidOperationException: Cannot get the value of a token type 'String' as a number. at System.Text.Json.Utf8JsonReader.TryGetInt64(Int64& ) at System.Text.Json.Utf8JsonReader.GetInt64() at System.Text.Json.Serialization.Converters.Int64Converter.Read(Utf8JsonReader& , Type , JsonSerializerOptions ) at System.Text.Json.Serialization.Converters.NullableConverter1.Read(Utf8JsonReader& , Type , JsonSerializerOptions ) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object , ReadStack& , Utf8JsonReader& ) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& ) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& ) at System.Text.Json.Serialization.JsonCollectionConverter2.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , TCollection& ) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& ) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object , ReadStack& , Utf8JsonReader& ) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& ) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& ) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& , JsonSerializerOptions , ReadStack& ) --- End of inner exception stack trace --- at System.Text.Json.ThrowHelper.ReThrowWithPath(ReadStack& , Utf8JsonReader& , Exception ) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& , JsonSerializerOptions , ReadStack& ) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan1 , JsonTypeInfo , Nullable1 ) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 , JsonTypeInfo ) at System.Text.Json.JsonSerializer.Deserialize[TValue](String , JsonSerializerOptions ) at KoenZomers.Ring.Api.Session.GetRingDevices() at KoenZomers.Ring.SnapshotDownload.Program.Main(String[] args) at KoenZomers.Ring.SnapshotDownload.Program.

(String[] args)

matziq commented 1 year ago

As a test, I reverted back to v2.1.0.0 and had the same issue. However, v2.0.5.0 does work.

donl commented 1 year ago

Similar issue here, running on Linux x64. Falling back to using v2.0.5.0 successfully for now.

sqyu commented 1 year ago

Same issue with 2.1.0.1 and 2.1.0.0, and unfortunately I'm not able to run v2.0.5.0 or v2.0.4.0 on MacOS either -- always got this error zsh: exec format error: /Users/.../Downloads/RingRecordingDownload

alistairstubbs commented 1 year ago

I am getting the same issue here

abulsme commented 1 year ago

Just adding a +1, same issue on 2.1.0.1 on an M1 Mac running Ventura, and get the same error as sqyu trying to run 2.0.5.0.

akrauze commented 1 year ago

+1 Works with 2.0.5.0. Fails with 2.1.0.1 with

Ring Recordings Download Tool v2.1.0.1 by Koen Zomers

Connecting to Ring services
Authenticating using refresh token from previous session
Retrieving all devices... Unhandled exception. System.Text.Json.JsonException: The JSON value could not be converted to System.Int32. Path: $.chimes[0].do_not_disturb.seconds_left | LineNumber: 0 | BytePositionInLine: 7121.
 ---> System.FormatException: Either the JSON value is not in a supported format, or is out of bounds for an Int32.
   at System.Text.Json.Utf8JsonReader.GetInt32()
   at System.Text.Json.Serialization.Converters.Int32Converter.Read(Utf8JsonReader& , Type , JsonSerializerOptions )
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object , ReadStack& , Utf8JsonReader& )
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object , ReadStack& , Utf8JsonReader& )
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.JsonCollectionConverter`2.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , TCollection& )
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object , ReadStack& , Utf8JsonReader& )
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& , Type , JsonSerializerOptions , ReadStack& , T& )
   at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& , JsonSerializerOptions , ReadStack& )
   --- End of inner exception stack trace ---
   at System.Text.Json.ThrowHelper.ReThrowWithPath(ReadStack& , Utf8JsonReader& , Exception )
   at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& , JsonSerializerOptions , ReadStack& )
   at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 , JsonTypeInfo , Nullable`1 )
   at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 , JsonTypeInfo )
   at System.Text.Json.JsonSerializer.Deserialize[TValue](String , JsonSerializerOptions )
   at KoenZomers.Ring.Api.Session.GetRingDevices()
   at KoenZomers.Ring.RecordingDownload.Program.Main(String[] args)
   at KoenZomers.Ring.RecordingDownload.Program.<Main>(String[] args)
cantaloop2 commented 1 year ago

Same issue with 2.1.0.1 and 2.1.0.0, and unfortunately I'm not able to run v2.0.5.0 or v2.0.4.0 on MacOS either -- always got this error zsh: exec format error: /Users/.../Downloads/RingRecordingDownload

same issue here

KoenZomers commented 1 year ago

Can you try this again with the latest version I've just published and share if it works now?

Mistahmilla commented 1 year ago

Hi, I am getting this with the latest version you just published. I am able to login but the -list command gives me the above error.

C:\Users...\RingDownloader>RingRecordingDownload -startdate "06-12-2023" -list

Ring Recordings Download Tool v2.2.0.0 by Koen Zomers

Connecting to Ring services Authenticating using refresh token from previous session Retrieving all devices... Unhandled exception. System.Text.Json.JsonException: The JSON value could not be converted to System.Nullable1[System.Boolean]. Path: $.stickup_cams[0].settings.enable_vod | LineNumber: 0 | BytePositionInLine: 14779. ---> System.InvalidOperationException: Cannot get the value of a token type 'Number' as a boolean. at System.Text.Json.Utf8JsonReader.GetBoolean() at System.Text.Json.Serialization.Converters.BooleanConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) at System.Text.Json.Serialization.Converters.NullableConverter1.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonCollectionConverter2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) --- End of inner exception stack trace --- at System.Text.Json.ThrowHelper.ReThrowWithPath(ReadStack& state, Utf8JsonReader& reader, Exception ex) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan1 utf8Json, JsonTypeInfo jsonTypeInfo, Nullable1 actualByteCount) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan1 json, JsonTypeInfo jsonTypeInfo) at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options) at KoenZomers.Ring.Api.Session.GetRingDevices() at KoenZomers.Ring.RecordingDownload.Program.Main(String[] args) at KoenZomers.Ring.RecordingDownload.Program.

(String[] args)

matziq commented 1 year ago

Hi, I am getting this with the latest version you just published. I am able to login but the -list command gives me the above error.

C:\Users...\RingDownloader>RingRecordingDownload -startdate "06-12-2023" -list

Ring Recordings Download Tool v2.2.0.0 by Koen Zomers

Connecting to Ring services Authenticating using refresh token from previous session Retrieving all devices... Unhandled exception. System.Text.Json.JsonException: The JSON value could not be converted to System.Nullable1[System.Boolean]. Path: $.stickup_cams[0].settings.enable_vod | LineNumber: 0 | BytePositionInLine: 14779. ---> System.InvalidOperationException: Cannot get the value of a token type 'Number' as a boolean. at System.Text.Json.Utf8JsonReader.GetBoolean() at System.Text.Json.Serialization.Converters.BooleanConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) at System.Text.Json.Serialization.Converters.NullableConverter1.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonCollectionConverter2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) --- End of inner exception stack trace --- at System.Text.Json.ThrowHelper.ReThrowWithPath(ReadStack& state, Utf8JsonReader& reader, Exception ex) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan1 utf8Json, JsonTypeInfo jsonTypeInfo, Nullable1 actualByteCount) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan1 json, JsonTypeInfo jsonTypeInfo) at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options) at KoenZomers.Ring.Api.Session.GetRingDevices() at KoenZomers.Ring.RecordingDownload.Program.Main(String[] args) at KoenZomers.Ring.RecordingDownload.Program.

(String[] args)

I get the same errors: Ring Recordings Download Tool v2.2.0.0 by Koen Zomers

Connecting to Ring services Authenticating using refresh token from previous session Retrieving all devices... Unhandled exception. System.Text.Json.JsonException: The JSON value could not be converted to System.String. Path: $.stickup_cams[0].motion_snooze | LineNumber: 0 | BytePositionInLine: 8758. ---> System.InvalidOperationException: Cannot get the value of a token type 'StartObject' as a string. at System.Text.Json.Utf8JsonReader.GetString() at System.Text.Json.Serialization.Converters.StringConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonCollectionConverter2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader) at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) --- End of inner exception stack trace --- at System.Text.Json.ThrowHelper.ReThrowWithPath(ReadStack& state, Utf8JsonReader& reader, Exception ex) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan1 utf8Json, JsonTypeInfo jsonTypeInfo, Nullable1 actualByteCount) at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 json, JsonTypeInfo jsonTypeInfo) at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options) at KoenZomers.Ring.Api.Session.GetRingDevices() at KoenZomers.Ring.RecordingDownload.Program.Main(String[] args) at KoenZomers.Ring.RecordingDownload.Program.

(String[] args)

KoenZomers commented 1 year ago

Can you try it again with version 3.0.0.0 and see if the issue is resolved in that?

danespinosa commented 5 months ago

Hi everyone, I just recently took over the repo, I just published a couple of new versions. Can you please try them out and let me know if you are still able to repro the issue? Version 3.1.1.0

danespinosa commented 3 months ago

Issue should be solved in latest Version 3.1.1.0