Skip to content

Instantly share code, notes, and snippets.

View jdm's full-sized avatar

Josh Matthews jdm

View GitHub Profile
'ServoApp.exe' (Win32): Loaded 'U:\Users\DefaultAccount\AppData\Local\DevelopmentFiles\MozillaFoundation.FirefoxRealityVS.Debug_ARM64.image\ServoApp.exe'. Symbols loaded.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\ntdll.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\KernelBase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\combase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\ucrtbase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\rpcrt4.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\kernel32legacy.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\bcryptprimitives.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\oleaut32.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\msvcp_win.dll'.
@jdm
jdm / rgsoc.md
Last active March 31, 2020 14:44
How to implement a new DOM API for Servo
title layout
How to implement a new DOM API for Servo
post

Servo is an awesome project about making a web browser engine in Rust! It is really well maintained with friendly contributors and mentors. Because Servo is a new web browser engine, there are so many relatively easy tasks waiting for new contributors. One of the things you as a contributor can do is implementing a DOM API for Servo.

Malisa and I implemented a few DOM APIs over the summer. There are lots of great documentation on how to get started, but we still felt a bit lost in the beginning. So we decided to make a tutorial for people who are relatively new to Servo and want a little more concrete example on implementing a new DOM API for Servo.

In this blog post, I will implement the up and coming DOM API called ✨Doge✨. This API has a spec that describes the standard Doge API should follow. [You should give it a very brief skim before continuing](https://jeenale

'ServoApp.exe' (Win32): Loaded 'U:\Users\DefaultAccount\AppData\Local\DevelopmentFiles\MozillaFoundation.FirefoxRealityVS.Debug_ARM64.image\ServoApp.exe'. Symbols loaded.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\ntdll.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\KernelBase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\combase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\ucrtbase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\rpcrt4.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\kernel32legacy.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\bcryptprimitives.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\oleaut32.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\msvcp_win.dll'.
'ServoApp.exe' (Win32): Loaded 'U:\Users\DefaultAccount\AppData\Local\DevelopmentFiles\MozillaFoundation.FirefoxRealityVS.Debug_ARM64.image\ServoApp.exe'. Symbols loaded.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\ntdll.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\KernelBase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\combase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\ucrtbase.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\rpcrt4.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\kernel32legacy.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\bcryptprimitives.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\oleaut32.dll'.
'ServoApp.exe' (Win32): Loaded 'C:\Windows\system32\msvcp_win.dll'.
This file has been truncated, but you can view the full file.
[2020-03-13T15:56:45Z DEBUG gfx::font_context] FontContext::font cache miss for font_descriptor=FontDescriptor { template_descriptor: FontTemplateDescriptor { weight: FontWeight(700.0), stretch: FontStretch(NonNegative(Percentage(1.0))), style: Normal }, variant: Normal, pt_size: 32px } family_descriptor=FontFamilyDescriptor { name: Generic(Atom('serif' type=static)), scope: Any }
[2020-03-13T15:56:45Z DEBUG gfx::font_context] FontContext::font_template cache miss for template_descriptor=FontTemplateDescriptor { weight: FontWeight(700.0), stretch: FontStretch(NonNegative(Percentage(1.0))), style: Normal } family_descriptor=FontFamilyDescriptor { name: Generic(Atom('serif' type=static)), scope: Any }
[2020-03-13T15:56:45Z DEBUG gfx::font_cache_thread] FontList: Found font family with name=times new roman
[2020-03-13T15:56:45Z DEBUG gfx::platform::macos::font_list] Looking for faces of family: times new roman
[2020-03-13T15:56:45Z DEBUG gfx::platform::macos::font] Font metrics (@32 pt): FontMetrics { underline_
<Starting application c:\Users\image\servo\target\debug\servo.exe (6316)>
<Running on newer-than-this-build "Microsoft Windows 10-1903 x64">
<Early threads found>
<Initial options = -no_dynamic_options -logdir 'C:\Users\image\Downloads\DrMemory-Windows-2.2.18081-1\DrMemory-Windows-2.2.18081-1\drmemory\logs\dynamorio' -client_lib 'C:\Users\image\Downloads\DrMemory-Windows-2.2.18081-1\DrMemory-Windows-2.2.18081-1\bin64\debug\drmemorylib.dll;0;-logdir `C:\Users\image\Downloads\DrMemory-Windows-2.2.18081-1\DrMemory-Windows-2.2.18081-1\drmemory\logs` -symcache_dir `C:\Users\image\Downloads\DrMemory-Windows-2.2.18081-1\DrMemory-Windows-2.2.18081-1\drmemory\logs\symcache` -lib_blacklist `C:\WINDOWS*.d??,C:\Program Files\Common Files\Microsoft Shared*.d??,C:\Program Files (x86)\Common Files\Microsoft Shared*.d??` -resfile 6316 ' -code_api -probe_api -stack_size 56K -disable_traces -no_enable_traces -max_elide_jmp 0 -max_elide_call 0 -no_shared_traces -bb_ibl_targets -bb_single_restore_prefix -no_shared_trace_ibl_rout
WARN: resolveCompile(441):
WARNING: 0:1: 'GL_ARB_gpu_shader5' : extension is not supported
ERROR: 0:2: '' : No precision specified for (float)
0:00:04.594021000 2136 0000019707C64180 FIXME bin gstbin.c:4337:gst_bin_query: implement duration caching in GstBin again
0:00:04.753488000 2136 00000197111430C0 WARN qtdemux qtdemux.c:3240:qtdemux_parse_trex:<qtdemux0> failed to find fragment defaults for stream 1
0:00:04.768788000 2136 00000197111430C0 WARN qtdemux qtdemux.c:3240:qtdemux_parse_trex:<qtdemux0> failed to find fragment defaults for stream 2
0:00:05.395132000 2136 0000019710F7D360 ERROR libav :0:: Invalid NAL unit size (-479989232 > 612).
0:00:05.395168000 2136 00000197111436C0 ERROR libav :0:: channel element 3.14 is not allocated
WARN libav gstavauddec.c:756:gst_ffmpegauddec_handle_frame:<avdec_aac0> decoding error
0:00:05.458232000 2136 00000197112A2BD0 ERROR libav :0:: Invalid NAL unit size (-1625337686 > 171).
0:00:05.480354000 2136 00000197111436C0 ERROR libav :0:: channel element 3.3 is not alloc
0:00:13.376579000 16916 00000210ACAAF180 INFO GST_ELEMENT_FACTORY gstelementfactory.c:359:gst_element_factory_create: creating element "playbin" named "playbin"
0:00:13.396751000 16916 00000210ACAAF180 INFO GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "scaletempo"
0:00:13.414610000 16916 00000210ACAAF180 INFO GST_ELEMENT_PADS gstelement.c:669:gst_element_add_pad:<GstBaseTransform@00000210AC832180> adding pad 'sink'
0:00:13.442011000 16916 00000210ACAAF180 INFO GST_ELEMENT_PADS gstelement.c:669:gst_element_add_pad:<GstBaseTransform@00000210AC832180> adding pad 'src'
0:00:13.456844000 16916 00000210ACAFC180 INFO GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "appsink"
0:00:13.484717000 16916 00000210ACAFC180 INFO GST_ELEMENT_PADS gstelement.c:669:gst_element_add_pad:<GstBaseSink@00000210AC836F40> adding pad 'sink'
0:00:13.508951000 16916 00000210ACAFC180 INFO playbin gstplaybin2
gst_dlls = [
"gstapp.dll",
"gstaudioconvert.dll",
"gstaudiofx.dll",
"gstaudioparsers.dll",
"gstaudioresample.dll",
"gstautodetect.dll",
"gstcoreelements.dll",
"gstdeinterlace.dll",
"gstplayback.dll",