Wednesday, March 18, 2015

html5ever project update: one year!

I started the html5ever project just a bit over one year ago. We adopted the current name last July.

<kmc> maybe the whole project needs a better name, idk
<Ms2ger> htmlparser, perhaps
<jdm> tagsoup
<Ms2ger> UglySoup
<Ms2ger> Since BeautifulSoup is already taken
<jdm> html5ever
<Ms2ger> No
<jdm> you just hate good ideas
<pcwalton> kmc: if you don't call it html5ever that will be a massive missed opportunity

By that point we already had a few contributors. Now we have 469 commits from 18 people, which is just amazing. Thank you to everyone who helped with the project. Over the past year we've upgraded Rust almost 50 times; I'm extremely grateful to the community members who had a turn at this Sisyphean task.

Several people have also contributed major enhancements. For example:

  • Clark Gaebel implemented zero-copy parsing. I'm in the process of reviewing this code and will be landing pieces of it in the next few weeks.

  • Josh Matthews made it possible to suspend and resume parsing from the tree sink. Servo needs this to do async resource fetching for external <script>s of the old-school (non-async/defer) variety.

  • Chris Paris implemented fragment parsing and improved serialization. This means Servo can use html5ever not only for parsing whole documents, but also for the innerHTML/outerHTML getters and setters within the DOM.

  • Adam Roben brought us dramatically closer to spec conformance. Aside from foreign (XML) content and <template>, we pass 99.6% of the html5lib tokenizer and tree builder tests! Adam also improved the build and test infrastructure in a number of ways.

I'd also like to thank Simon Sapin for doing the initial review of my code, and finding a few bugs in the process.

html5ever makes heavy use of Rust's metaprogramming features. It's been something of a wild ride, and we've collaborated with the Rust team in a number of ways. Felix Klock came through in a big way when a Rust upgrade broke the entire tree builder. Lately, I've been working on improvements to Rust's macro system ahead of the 1.0 release, based in part on my experience with html5ever.

Even with the early-adopter pains, the use of metaprogramming was absolutely worth it. Most of the spec-conformance patches were only a few lines, because our encoding of parser rules is so close to what's written in the spec. This is especially valuable with a "living standard" like HTML.

The future

Two upcoming enhancements are a high priority for Web compatibility in Servo:

  • Character encoding detection and conversion. This will build on the zero-copy UTF-8 parsing mentioned above. Non-UTF-8 content (~15% of the Web) will have "one-copy parsing" after a conversion to UTF-8. This keeps the parser itself lean and mean.

  • document.write support. This API can insert arbitrary UTF-16 code units (which might not even be valid Unicode) in the middle of the UTF-8 stream. To handle this, we might switch to WTF-8. Along with document.write we'll start to do speculative parsing.

It's likely that I'll work on one or both of these in the next quarter.

Servo may get SVG support in the near future, thanks to canvg. SVG nodes can be embedded in HTML or loaded from an external XML file. To support the first case, html5ever needs to implement WHATWG's rules for parsing foreign content in HTML. To handle external SVG we could use a proper XML parser, or we could extend html5ever to support "XML5", an error-tolerant XML syntax similar to WHATWG HTML. Ygg01 made some progress towards implementing XML5. Servo would most likely use it for XHTML as well.

Improved performance is always a goal. html5ever describes itself as "high-performance" but does not have specific comparisons to other HTML parsers. I'd like to fix that in the near future. Zero-copy parsing will be a substantial improvement, once some performance issues in Rust get fixed. I'd like to revisit SSE-accelerated parsing as well.

I'd also like to support html5ever on some stable Rust 1.x version, although it probably won't happen for 1.0.0. The main obstacle here is procedural macros. Erick Tryzelaar has done some great work recently with syntex, aster, and quasi. Switching to this ecosystem will get us close to 1.x compatibility and will clean up the macro code quite a bit. I'll be working with Erick to use html5ever as an early validation of his approach.

Simon has extracted Servo's CSS selector matching engine as a stand-alone library. Combined with html5ever this provides most of the groundwork for a full-featured HTML manipulation library.

The C API for html5ever still builds, thanks to continuous integration. But it's not complete or well-tested. With the removal of Rust's runtime, maintaining the C API does not restrict the kind of code we can write in other parts of the parser. All we need now is to complete the C API and write tests. This would be a great thing for a community member to work on. Then we can write bindings for every language under the sun and bring fast, correct, memory-safe HTML parsing to the masses :)

82 comments:

  1. Get Shifting/Relocation Quotation from ###Packers and Movers Delhi. Packers and Movers Delhi 100% Affordable and Reliable ***Household Shifting Services. Compare Transportation Charges and Save Time, Verified and Trusted Packers and Movers in Delhi, Cheap and Safe Local, Domestic House Shifting @
    Packers and Movers Delhi

    ReplyDelete
  2. Packers and Movers Chennai Give Safe and Reliable ***Household Shifting Services in Chennai with Reasonable ###Packers and Movers Price Quotation. We Provide Household Shifting, Office Relocation, ✔✔✔Local and Domestic Transportation Services, Affordable and Reliable Shifting Service Charges @
    Packers And Movers Chennai

    ReplyDelete
  3. Hire Best Packers And Movers Mumbai for hassle-free Household Shifting, ***Office Relocation, ###Car Transporation, Loading Unloading, packing Unpacking at affordable ✔✔✔ Price Quotation. Top Rated, Safe and Secure Service Providers who can help you with 24x7 and make sure a Untroubled Relocation Services at Cheapest/Lowest Rate
    Packers And Movers Mumbai

    ReplyDelete
  4. Thanks for providing such a great Information, you can see, we also provide
    Peptide Synthesis

    ReplyDelete

  5. ارخص شركة نقل عفش بالدمام ارخص شركة نقل عفش بالدمام
    شركة تنظيف منازل بجدة بالبخار افضل شركة تنظيف منازل بجدة


    شركة غسيل خزانات بالمدينة المنورة شركة تنظيف خزانات بالمدينة المنورة
    افضل شركة تنظيف منازل بالمدينة المنورة شركة تنظيف منازل بالمدينة المنورة

    ReplyDelete
  6. شركة وسام الابداع من افضل الشركات في المملكة العربية السعودية حيث يوجد لدينا افضل الاساليب والمعدات في جميع مجالس الخدمات المنزلية تنظيف منازل شقق فلل خزانات موكيت سجاد كنب مسابح مساجد كشف تسربات المياة بدون تكسير رش مبيدات مكافحة النمل الابيض والصراصير وغيره

    شركه تنظيف بالرياض
    الكلمة الدلالية هنا


    شركه تنظيف فلل بالرياض


    شركه تنظيف شقق بالرياض


    شركه تنظيف منازل بالرياض


    شركة تنظيف سجاد بالرياض


    شركه تنظيف موكيت بالرياض


    شركه تنظيف مجالس بالرياض


    شركه نقل اثاث بالرياض


    شركه مكافحة حشرات بالرياض


    شركه رش مبيدات بالرياض


    شركه مكافحة نمل ابيض بالرياض

    ReplyDelete

  7. شركة تنظيف منازل بجازان شركات نظافة بجازان هل تريد التخلص من الأوساخ والاتربة وجلي وتلميع البلاط كما نقدم أيضاً خدمات مكافحة الحشرات عليكم بالتواصل معنا الأن شركتنا تعد من أفضل الشركات التي تقدم خدمات منزلية في المنطقة الجنوبية شركة تنظيف بجازان
    افضل شركة مكافحة حشرات بجازان
    افضل شركة تنظيف منازل بجازان
    شركة تنظيف موكيت بجازان
    شركة تنظيف بجازان
    شركة مكافحة حشرات بجازان
    شركة مكافحة حشرات بمحايل عسير
    شركة تنظيف بمحايل عسير

    ReplyDelete
  8. اهلاً ومرحباً بكم جميعاً في أفضل شركة متخصصة في خدمات التنظيف ومكافحة الحشرات عليكم بالتواصل معنا وسوف نلبي طلباتكم في أسرع وقت ممكن إتصل صل بنا نصلك في الحال شركة مكافحة حشرات بخميس مشيط
    شركة تنظيف منازل بخميس مشيط
    شركة تنظيف خزانات بخميس مشيط
    شركة تنظيف بخميس مشيط
    شركة تنظيف خزانات بابها
    شركة مكافحة حشرات بابها
    شركة تنظيف بابها
    شركة تنظيف منازل بابها

    ReplyDelete
  9. شركة فرسان المثالي لخدمات العزل وتنظيف المكيفات وكشف تسربات المياه تقدم لكم أفضل الخدمات بأرخص الأسعار عليكم بالتواصل معنا الأن
    شركة عزل اسطح بالاحساء
    شركة عزل اسطح بالقصيم
    شركة تنظيف مكيفات بالدمام
    شركة تنظيف مكيفات بالاحساء
    شركة كشف تسربات المياه بالدمام

    ReplyDelete
  10. AE Clicks is a leading Mobile App Development in Duabai building agile and robust mobile application i.e. both on Android and iOS platforms.

    ReplyDelete
  11. If you have any questions regarding canon wireless printer setup
    problem or if you are still experiencing some annoying printer problems then just call us +1 800-684-5649

    ReplyDelete
  12. My Herpes virus that was cured by a great herbal medicine man. Since last 7 months i was having these virus and some time i experience the herpes outbreak. last three weeks I was in a great pain so I told one of my friends about it she told me that there is a great herbal medicine man that can cure Herpes and so many diseases and he also help people in getting pregnant and bringing back EX. I asked her if she had the man contact so i could give it a try, she gave me the contact, I contacted him he talked to me, and he send me the herbal medicine and herbal soap via DHL service to my country, told me how i will be using the herbal soap and drinking the herbs and after two weeks I should go for a test. Which I did, when the doctor told me that am now Herpes negative I couldn't believe myself I went to see another doctor the result was still the same i couldn't keep this to myself when i know that a lot of people are having issues with their health due to ignorant so i decided to let it out on this page that if anyone here need help in curing his/her Herpes virus or trying to conceive should also contact him he also have herbal medicine for HIV, Herpes, Cancer, Hepatitis etc and deal with spiritual problems too once again you can email him on:drafridherbalhome@gmail.com  webs:http://drafridherbalhome.webs.com    

    ReplyDelete
  13. ROku is one of the most familiar services for know more about the Roku click the following link
    Roku.com/link

    ReplyDelete
  14. اشكال بلاط الحوش تراكوتا من الانواع المميزة
    شركة نقل اثاث بابها
    شركة تنظيف بحفر الباطن

    كم يكلف تبليط الحوش ؟ الحمامات من الاماكن التي يجب ان تكون نظيفة دائماً و احيانا نظافة الحمامات تعتمد علي عدم توازن البلاط و بالتالي تقف المياه ولا تسير في اتجاه الصرف و تلك الاخطاء تكن بسبب الالتوائات الموجودة في البلاط و السبب الاساسي هي الصناعة، يجب ايها الاخ القارئ ان تنفق ما في جيبك من اجل اختيار افضل انواع البلاط من حيث جودة البلاطة الاساسية في الصنع و من حيث الالوان.شركة تسليك مجارى بالمدينة المنورة
    شركة تنظيف بحفر الباطن

    المواصفات التي يمتلكها البلاط و السيراميك الذي يتواجد لدينا

    ReplyDelete
  15. Thank you for sharing your thoughts. I really appreciate
    your efforts and I am waiting for your further write ups thanks once again.

    ReplyDelete
  16. We support all types of HP printer troubleshooting and service. Just enter the model number of your printer in 123.hp.com/setup to identify the software and drivers your printer requires. Download and install it in your mac and 'Run' the file. The process is easy however if you have any doubts or queries regarding HP printers contact us.

    ReplyDelete
  17. This 123.hp.com/laserjet brand of printers come up with fast and two-sided printing options along with business-class features. This LaserJet Pro m404n model printer is compatible with Apple products and the AirPrint option
    Now that we’ve come to the end of the HP Laserjet Pro m404n Printer setup process, if you have any further queries, navigate to our web page.

    ReplyDelete
  18. This comment has been removed by the author.

    ReplyDelete
  19. You’re no longer beholden to cable subscription and if you want a wide range of television options get Roku device today start watching TV on upon Roku device activation by visiting roku.com/link.

    roku.com/link

    ReplyDelete

  20. Roku is a streaming device, which provides the simplest way to stream entertainment channel to your TV. On your terms. You can access more than 500000+ movies and TV episodes across free and pay on Roku. Also, you will get the best quality video streaming with it. You can watch shows, movies, an entertainment channel, web series, etc. For the activation of the Roku device, Go to URL: roku.com/link.

    roku.com/link

    ReplyDelete

  21. Roku is a package of entertainment. The Roku channel is the Expansion of programming for new generation children. Roku declares plans to Combined kids and family movies and TV together with the channel's other content, including subscriptions, its free, television, ad-supported movies, and live TV.

    roku.com/link

    ReplyDelete


  22. After the launching of "Kids & Family" section on Roku channel, Roku is also adding new features to give more control to parents over the channel, what their kids can watch when accessing Roku channels.

    roku.com/link

    ReplyDelete
  23. Do you require HP printer setup for your mac operating system? Is your printer driver not suitable for macOS? Then visit the 123.hp.com/setup to get the software and driver for better functioning of your printer. You can also call our expert HP support team for services.

    ReplyDelete
  24. Hulu provides the simplest way to stream entertainment to your TV. On your terms. With thousands of available channels. We provide information regarding Hulu Activation Code. Go to hulu.com/activate, and enter the Activation Code. To activate a new Hulu account using an existing email account and you can stream television shows and movies from the Hulu site using the Hulu activation link ) hulu.com/activate

    ReplyDelete
  25. Hulu provides the simplest way to stream entertainment to your TV. On your terms. With thousands of available channels. We provide information regarding Hulu Activation Code. Go to hulu.com/activate, and enter the Activation Code. To activate a new Hulu account using an existing email account and you can stream television shows and movies from the Hulu site using the Hulu activation link ) hulu.com/activate

    ReplyDelete
  26. Watch your favorite live sports, news, entertainment, and more. Plus, get unlimited access to the entire Hulu streaming library To activate Hulu code go to url: hulu.com/activate if you need help to activate Hulu hulu.com/activate

    ReplyDelete
  27. I rarely share my story with people, not only because it put me at the lowest point ever but because it made me a person of ridicule among family and friends. I put all I had into Binary Options ($690,000) after hearing great testimonies about this new investment

     strategy. I was made to believe my investment would triple, it started good and I got returns (not up to what I had invested). Gathered more and involved a couple family members, but I didn't know I was setting myself up for the kill, in less than no time all we had put ($820,000) was gone. It almost seem I had set them up, they came at me strong and hard. After searching and looking for how to make those scums pay back, I got introduced to maryshea03@gmail.com to WhatsApp her +15623847738.who helped recover about 80% of my lost funds within a month.

    ReplyDelete
  28. It’s not a tough task to activate Roku. Connecting the hardware is the first step. Visit the signup URL for account creation. Collect the code. Open the new browser to paste the URL, on Roku com link and wait for the prompt to enter the activation code. For assistance and to know more about device setup and troubleshooting, reach out to our customer support at the earliest

    ReplyDelete

  29. AVG antivirus is the highest point of the line antivirus for the confirmation of your automated contraptions. It is expected to keep you ensured and secure. It verifies your critical data and archives, out of the compass of software www.avg.com/retail
    . It analyzes the data set away in your PC paying little respect to whether you are away from your PC.

    ReplyDelete
  30. A Roku Help Upgraded remote with voice. Take in more about utilizing your voice to look for films. Network programs and the sky is the limit from there.

    www.hulu.com/activate
    connect cable to tcl roku tv
    reset roku stick
    roku customer support number
    set up roku stick
    set up youtube on roku tv

    ReplyDelete
  31. Really great article!! thanks for sharing your helpful information for us, and i would like to say that please continue sharing your information.

    time warner cable customer support number
    roku remote not blinking
    roku activation link
    roku customer service number
    roku.com/link

    ReplyDelete
  32. Now, go to your email inbox and check for mail from Match.com. This email consists of the link given for password reset. Click on the link and follow the instruction given. By following the information properly, you will be able to reset your password and hence login to your Match.com account easily.

    Match.com Customer Care
    Match.com Login Problem
    Cancel Match.com Membership
    can't login to match.com
    cancel match memberhsip

    ReplyDelete
  33. All these points attractively encourage each other to affirm That dependence upon our assistance and proficiency will surely help to come from the deep waters over one simple call. Telephone now! We are waiting to make you a proud beneficiary with impeccable business-standard.

    silverisngles login issues
    login silversingles
    cancel membership silversingles
    cancel silversingles
    silversingles cancelltion
    silversingles merbership cancel
    can't login to silveringles
    can't able to login my silversingles account

    ReplyDelete
  34. So, you can understand, it is an advanced level of TV viewing experience. If you are looking for a kind of streaming device that can offer you to watch a large number of TV Programs or movies for the sake of entertainment. Enjoy this amazing streaming device that opens a world of entertainment for you!

    Roku Activation Link
    Setup Roku Stick On TV
    Activate hulu On Roku Device

    ReplyDelete
  35. Awesome work you have done here, I am very happy to read this nice post. You are a great writer and give us much information Local Packers And Movers Bangalore

    ReplyDelete
  36. Get Packers and Movers Kolkata List of Top Reliable, 100% Affordable, Verified and Secured Service Provider. Get Free ###Packers and Movers Kolkata Price Quotation instantly and Save Cost and Time. ???Packers and Movers Kolkata Reviews and Compare Charges for household Shifting, Home/Office Relocation, ***Car Transportation, Pet Relocation, Bike SHifting @ Packers and Movers Kolkata

    ReplyDelete
  37. I rarely share my story with people, not only because it put me at the lowest point ever but because it made me a person of ridicule among family and friends. I put all I had into Binary Options ($690,000) after hearing great testimonies about this new investment

     strategy. I was made to believe my investment would triple, it started good and I got returns (not up to what I had invested). Gathered more and involved a couple family members, but I didn't know I was setting myself up for the kill, in less than no time all we had put ($820,000) was gone. It almost seem I had set them up, they came at me strong and hard. After searching and looking for how to make those scums pay back, I got introduced to maryshea03@gmail.com to WhatsApp her +15623847738.who helped recover about 80% of my lost funds within a month.

    ReplyDelete
  38. Superb post, we enjoyed each and everything as per written in your post. Thank you for this informative article because it’s really helpful, I really like site.
    Please visit our website: @ Packers and Movers Kolkata

    ReplyDelete
  39. AVG Retail is extraordinary compared to other Antivirus programming. Client can download the product from avg.com/retail. www.avg.com/retail
    . The product gives the total suite of the highlights which can verify your database from your gadgets. The product ensure you as well as control the obstruction of your framework it will improve the speed of your framework utilizing the framework enhancement apparatus.

    ReplyDelete
  40. Nice post! This is a very nice blog that I will definitively come back to more times this year! Thanks for informative post.# @ Packers and Movers Ahmedabad

    ReplyDelete
  41. Permainan Sabung Ayam tentunya sudah pada tahu ya, yang dimana ayam melawan ayam pertandingan yang sangat seru ini bisa kalian nonton secara live lohh, banyak yang bermain di situs kami dan merasa sangat nyaman, bagi kalian yang ingin bermain bisa kunjungi situs kami, dijamin kalian akan merasa sangat senang.

    download s128 apk mobile

    aplikasi s128 terbaru

    link download s128 apk

    link s128 apk

    cara download sabung ayam

    cara download s128 apk

    cara download aplikasi s128


    daftar judi adu ayam

    daftar adu ayam

    cara daftar s128

    cara daftar sabung ayam

    cara daftar sabung ayam s128

    cara daftar s128 sabung ayam

    cara daftar s128 apk


    login link alternatif s128

    link login alternatif s128

    ReplyDelete
  42. بسیاری از صاحبان کسب و کارها برای رونق کار و فعالیت خود در بازار تجارت الکترونیک ios ساخت اپلیکیشن و اندروید خود را به تیم فنی الو اپلیکیشن سپرده اند. نظر سنجی های انجام شده در الو اپلیکیشن نشان می دهد که اپلیکیشن های ساخته شده در این شرکت محبوبیت زیادی دارند. این امر انگیزه بیشتری به ما داده است تا پروژه های ساخت اپ خود را با خلاقیت و کارآیی بیشتر طراحی نموده و در مسیر خود کوشاتر باشیم.

    ReplyDelete
  43. Create Roku account to activate your Roku streaming device using Roku.com/link. You can understand the steps clearly, if you read the latest blog post on our webpage www.roku.com/link

    ReplyDelete
  44. I know the value of Garmin Express Update and keep reading good content about the same. I found this blog very informative and it increased my understanding about garmin update to a great extent.

    ReplyDelete
  45. I did not know the entire benefits of Garmin Nuvi Update. But since I have read this blog on map update, I have installed all available updates for my garmin device. I must say that this piece of blog has helped me improve navigation experience. I am not suggesting all my friends to read this blog and get Garmin map update with this team.

    ReplyDelete
  46. We did not know the all benefits of Panda Antivirus Support Number. I have read this blog on Antivirus I have installed all available updates. I must say that this piece of blog has helped me improving navigation experience. I am not suggesting all my friends to read this blog and get Antivirus Panda Support with this team. You can use Panda Antivirus to get panda help desk update. Be it Norton Internet security, panda, Kaspersky, McAfee, or any other antivirus.

    ReplyDelete
  47. If the driver has two-way communication, you may be warned not to switch to the printer, but you have not found anything in the print cartridge. Fortunately, these warnings often tell you what the problem is and recommend tactics to solve it. If everything else is not working, turn off the printer, wait a few minutes, and then restart the printer and software.
    how to setup hp wireless printer on windows 10

    ReplyDelete
  48. Thank you for the post. In the wake of following every one of these means your HP printer will doubtlessly get on the web and will work appropriately. Subsequent to taking a shot at these means you can without much of a stretch take care of every one of your issues. visit our website for any printer model issues like WPS Pin on HP Printer related any issues, etc.

    ReplyDelete
  49. Thank for sharing the such a good information. One most problem in printer is Why my HP Printer is not printing? Their should be many reasons for HP Envy Printer Offline Fix Windows 10 like paper jam, ink tank empty, etc. Get Troubleshooting by expert technicians then call our toll free No. Or visit our official website that will really be helpful to you.

    ReplyDelete
  50. Thanks for sharing this beautiful information with us your blog is really amazing, thanks for sharing it. HP printer may also suffer from different HP wireless printer problems. To resolve any printer issues quickly and effectively, get in touch with the HP printer customer service team.

    ReplyDelete
  51. Appreciated your hard work and effort for this Blog. Thanks for being a mentor in this digital-world. Your blog is really helpful and full of knowledge for all of us. If you are using an Ethernet cable, you can directly plug your Roku device into the router. If you have a wireless network, enter the password, and connect your Roku TV Account Activation with it.

    ReplyDelete
  52. All the articles here are informative. It is beneficial to the newcomers. Thanks for posting such a nice post.
    Make White Background
    Clipping Path
    Image Masking Service

    ReplyDelete
  53. Hey buddy, I must say you have written very nice article. Thanks for sharing it. The way you have described everything is phenomenal. You can follow us by visit our Web page How to Install Canon Pixma ip2820 Printer

    ReplyDelete
  54. This article is very good. We would like to leave a good article. To read more articles, click here >>>
    สล็อต

    ReplyDelete
  55. For those who like to do new things but get money right here. บาคาร่า

    ReplyDelete
  56. Your article is great. Come in, read my stuff, click. >> ไก่ชน

    ReplyDelete