Releases: getsentry/sentry-native
0.4.1
0.4.0
Breaking Changes:
- The minimum CMake version required to build on windows was raised to
3.16.4
to avoid potential build failures on older versions. - The
sentry_get_options
function was removed, as it was unsafe to use after asentry_shutdown
call. - The
sentry_options_set_logger
function now accepts auserdata
parameter. - The
name
parameter ofsentry_options_add_attachment(w)
was removed, it will now be inferred from the filename ofpath
. - The transport startup hook that is set via
sentry_transport_set_startup_func
now needs to return anint
, and a failure will propagate tosentry_init
. - The return value of the transport shutdown hook set via
sentry_transport_set_shutdown_func
was also changed to return anint
. - Both functions should return 0 on success, and a non-zero error code on failure, as does
sentry_init
. - Similarly, the return value of
sentry_shutdown
was also changed to anint
, and will return 0 on success and a non-zero error code on unclean shutdown. - Documentation for custom transports was updated to highlight the ordering requirements of submitted envelopes, which is important for release health.
// before
sentry_options_set_logger(options, my_custom_logger);
sentry_options_add_attachment(options, "some-attachment", "/path/to/some-attachment.txt");
void transport_startup(sentry_options_t *options, void*state) {
}
sentry_transport_set_startup_func(transport, transport_startup);
bool transport_shutdown(uint64_t timeout, void*state) {
return true;
}
sentry_transport_set_shutdown_func(transport, transport_shutdown);
// after
sentry_options_set_logger(options, my_custom_logger, NULL);
sentry_options_add_attachment(options, "/path/to/some-attachment.txt");
int transport_startup(sentry_options_t *options, void*state) {
return 0;
}
sentry_transport_set_startup_func(transport, transport_startup);
int transport_shutdown(uint64_t timeout, void*state) {
return 0;
}
sentry_transport_set_shutdown_func(transport, transport_shutdown);
Features:
- Release Health support is now stable and enabled by default. After the update, you will see the number of crash free sessions and crash free users on the Releases page in Sentry. To disable automatic session tracking, use
sentry_options_set_auto_session_tracking
. - Breakpad support for Windows. This allows you to use
sentry-native
even on Windows XP! (#278) - Add an in-process backend for Windows. As opposed to Breakpad, stack traces are generated on the device and sent to Sentry for symbolication. (#287)
- Support for the Crashpad backend was fixed and enabled for Linux. (#320)
- A new
SENTRY_BREAKPAD_SYSTEM
CMake option was added to link to the system-installed breakpad client instead of building it as part of sentry.
Fixes:
- Reworked thread synchronization code and logic in
sentry_shutdown
, avoiding an abort in case of an unclean shutdown. (#323) - Similarly, reworked global options handling, avoiding thread safety issues. (#333)
- Fixed errors not being properly recorded in sessions. (#317)
- Fixed some potential memory leaks and other issues. (#304 and others)
Thank you:
Features, fixes and improvements in this release have been contributed by:
0.3.4
0.3.3
Warning: This release contains a memory unsafety issue when using sentry_options_set_debug(1)
. Please do not set this option until a bugfix is released.
Fixes:
- Fix a memory unsafety issue when calling
sentry_value_remove_by_key
. (#297) - Improvements to internal logging. (#301, #302)
- Better handling of timeouts. (#284)
- Better 32-bit build support. (#291)
- Run more checks on CI. (#299)
Thank you:
Fixes in this release have been contributed by:
0.3.2
Features:
-
Implement a new logger hook. (#267)
This adds the new
sentry_options_set_logger
function, which can be used to customize the sentry-internal logging, for example to integrate into an app’s own logging system, or to stream logs to a file. -
New CMake options:
SENTRY_LINK_PTHREAD
,SENTRY_BUILD_RUNTIMESTATIC
andSENTRY_EXPORT_SYMBOLS
along with other CMake improvements.
Fixes:
- Avoid memory unsafety when loading session from disk. (#270)
- Avoid Errors in Crashpad Backend without prior scope changes. (#272)
- Fix absolute paths on Windows, and allow using forward-slashes as directory separators. (#266, #289)
- Various fixes uncovered by static analysis tools, notably excessive allocations by the page-allocator used inside signal handlers.
- Build fixes for MinGW and other compilers.
Thank you:
Features, fixes and improvements in this release have been contributed by:
0.3.1
- Add support for on-device symbolication, which is enabled by default on
Android. Usesentry_options_set_symbolize_stacktraces
to customize. - Enable gzip compressed crashpad minidumps on windows.
- Correctly 0-pad short
build-id
s. - Fix build for 32bit Apple targets.
0.3.0
- Always send the newer
x-sentry-envelope
format, which makes this
incompatible with older on-premise installations. - Better document and handle non-ASCII paths. Users on windows should use the
w
version of the appropriate APIs. - Avoid segfaults due to failed sentry initialization.
- Avoid creating invalid sessions without a
release
. - Make
sentry_transport_t
opaque, and instead expose APIs to configure it.
More functionality related to creating custom transports will be exposed in
future versions.
Breaking changes
- The
sentry_backend_free
function was removed. - The
sentry_backend_t
type was removed. - The
sentry_transport_t
type is now opaque. Use the following new API to
create a custom transport.
New API
sentry_transport_new
sentry_transport_set_state
sentry_transport_set_free_func
sentry_transport_set_startup_func
sentry_transport_set_shutdown_func
See sentry.h
for more documentation.
Deprecations
sentry_new_function_transport
has been deprecated in favor of the new
transport builder functions.