<!DOCTYPE html>
<html lang="en-US" prefix="og: https://ogp.me/ns#">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width" />
<title>How to make Win32Services - Marco Islas</title>
<link rel="profile" href="https://gmpg.org/xfn/11" />
<link rel="pingback" href="https://islascruz.org/blog/xmlrpc.php" />
<!--[if lt IE 9]>
<script src="https://islascruz.org/blog/wp-content/themes/superhero/js/html5.js" type="text/javascript"></script>
<![endif]-->

		    <!-- PVC Template -->
    <script type="text/template" id="pvc-stats-view-template">
    <i class="pvc-stats-icon medium" aria-hidden="true"><svg aria-hidden="true" focusable="false" data-prefix="far" data-icon="chart-bar" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" class="svg-inline--fa fa-chart-bar fa-w-16 fa-2x"><path fill="currentColor" d="M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z" class=""></path></svg></i>
	 <%= total_view %> total views	<% if ( today_view > 0 ) { %>
		<span class="views_today">,  <%= today_view %> views today</span>
	<% } %>
	</span>
	</script>
		    
<!-- Search Engine Optimization by Rank Math - https://rankmath.com/ -->
<meta name="description" content="Hi, in this case I&#039;m going to show you how to create simple services for the win32 platform using the powerfull Python programming language and the py2exe"/>
<meta name="robots" content="index, follow, max-snippet:-1, max-video-preview:-1, max-image-preview:large"/>
<link rel="canonical" href="https://islascruz.org/blog/win32services/" />
<meta property="og:locale" content="en_US" />
<meta property="og:type" content="article" />
<meta property="og:title" content="How to make Win32Services - Marco Islas" />
<meta property="og:description" content="Hi, in this case I&#039;m going to show you how to create simple services for the win32 platform using the powerfull Python programming language and the py2exe" />
<meta property="og:url" content="https://islascruz.org/blog/win32services/" />
<meta property="og:site_name" content="Marco Islas" />
<meta property="og:updated_time" content="2017-07-11T13:55:23-05:00" />
<meta property="og:image" content="https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png" />
<meta property="og:image:secure_url" content="https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png" />
<meta property="og:image:width" content="286" />
<meta property="og:image:height" content="364" />
<meta property="og:image:alt" content="How to make Win32Services" />
<meta property="og:image:type" content="image/png" />
<meta property="article:published_time" content="2015-08-24T13:15:46-05:00" />
<meta property="article:modified_time" content="2017-07-11T13:55:23-05:00" />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="How to make Win32Services - Marco Islas" />
<meta name="twitter:description" content="Hi, in this case I&#039;m going to show you how to create simple services for the win32 platform using the powerfull Python programming language and the py2exe" />
<meta name="twitter:image" content="https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png" />
<meta name="twitter:label1" content="Time to read" />
<meta name="twitter:data1" content="4 minutes" />
<script type="application/ld+json" class="rank-math-schema">{"@context":"https://schema.org","@graph":[{"@type":["Organization","Person"],"@id":"https://islascruz.org/blog/#person","name":"marco","url":"https://islascruz.org/blog"},{"@type":"WebSite","@id":"https://islascruz.org/blog/#website","url":"https://islascruz.org/blog","name":"marco","publisher":{"@id":"https://islascruz.org/blog/#person"},"inLanguage":"en-US"},{"@type":"ImageObject","@id":"https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png","url":"https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png","width":"286","height":"364","inLanguage":"en-US"},{"@type":"WebPage","@id":"https://islascruz.org/blog/win32services/#webpage","url":"https://islascruz.org/blog/win32services/","name":"How to make Win32Services - Marco Islas","datePublished":"2015-08-24T13:15:46-05:00","dateModified":"2017-07-11T13:55:23-05:00","isPartOf":{"@id":"https://islascruz.org/blog/#website"},"primaryImageOfPage":{"@id":"https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png"},"inLanguage":"en-US"},{"@type":"Person","@id":"https://islascruz.org/blog/author/marco/","name":"marco","url":"https://islascruz.org/blog/author/marco/","image":{"@type":"ImageObject","@id":"https://secure.gravatar.com/avatar/c068a9bd30c0d948387293085e566085f58affae8224680e96cf5621b61e78b9?s=96&amp;d=mm&amp;r=g","url":"https://secure.gravatar.com/avatar/c068a9bd30c0d948387293085e566085f58affae8224680e96cf5621b61e78b9?s=96&amp;d=mm&amp;r=g","caption":"marco","inLanguage":"en-US"}},{"@type":"Article","headline":"How to make Win32Services - Marco Islas","datePublished":"2015-08-24T13:15:46-05:00","dateModified":"2017-07-11T13:55:23-05:00","author":{"@id":"https://islascruz.org/blog/author/marco/","name":"marco"},"publisher":{"@id":"https://islascruz.org/blog/#person"},"description":"Hi, in this case I&#039;m going to show you how to create simple services for the win32 platform using the powerfull Python programming language and the py2exe","name":"How to make Win32Services - Marco Islas","@id":"https://islascruz.org/blog/win32services/#richSnippet","isPartOf":{"@id":"https://islascruz.org/blog/win32services/#webpage"},"image":{"@id":"https://islascruz.org/blog/wp-content/uploads/2015/12/python-logo-glassy.png"},"inLanguage":"en-US","mainEntityOfPage":{"@id":"https://islascruz.org/blog/win32services/#webpage"}}]}</script>
<!-- /Rank Math WordPress SEO plugin -->

<link rel='dns-prefetch' href='//cdn.jsdelivr.net' />
<link rel="alternate" type="application/rss+xml" title="Marco Islas &raquo; Feed" href="https://islascruz.org/blog/feed/" />
<link rel="alternate" type="application/rss+xml" title="Marco Islas &raquo; Comments Feed" href="https://islascruz.org/blog/comments/feed/" />
<link rel="alternate" type="application/rss+xml" title="Marco Islas &raquo; How to make Win32Services Comments Feed" href="https://islascruz.org/blog/win32services/feed/" />
<link rel="alternate" title="oEmbed (JSON)" type="application/json+oembed" href="https://islascruz.org/blog/wp-json/oembed/1.0/embed?url=https%3A%2F%2Fislascruz.org%2Fblog%2Fwin32services%2F" />
<link rel="alternate" title="oEmbed (XML)" type="text/xml+oembed" href="https://islascruz.org/blog/wp-json/oembed/1.0/embed?url=https%3A%2F%2Fislascruz.org%2Fblog%2Fwin32services%2F&#038;format=xml" />
<style id='wp-img-auto-sizes-contain-inline-css' type='text/css'>
img:is([sizes=auto i],[sizes^="auto," i]){contain-intrinsic-size:3000px 1500px}
/*# sourceURL=wp-img-auto-sizes-contain-inline-css */
</style>
<style id='wp-emoji-styles-inline-css' type='text/css'>

	img.wp-smiley, img.emoji {
		display: inline !important;
		border: none !important;
		box-shadow: none !important;
		height: 1em !important;
		width: 1em !important;
		margin: 0 0.07em !important;
		vertical-align: -0.1em !important;
		background: none !important;
		padding: 0 !important;
	}
/*# sourceURL=wp-emoji-styles-inline-css */
</style>
<link rel='stylesheet' id='wp-block-library-css' href='https://islascruz.org/blog/wp-includes/css/dist/block-library/style.min.css?ver=6.9.4' type='text/css' media='all' />

<style id='classic-theme-styles-inline-css' type='text/css'>
/*! This file is auto-generated */
.wp-block-button__link{color:#fff;background-color:#32373c;border-radius:9999px;box-shadow:none;text-decoration:none;padding:calc(.667em + 2px) calc(1.333em + 2px);font-size:1.125em}.wp-block-file__button{background:#32373c;color:#fff;text-decoration:none}
/*# sourceURL=/wp-includes/css/classic-themes.min.css */
</style>
<style id='global-styles-inline-css' type='text/css'>
:root{--wp--preset--aspect-ratio--square: 1;--wp--preset--aspect-ratio--4-3: 4/3;--wp--preset--aspect-ratio--3-4: 3/4;--wp--preset--aspect-ratio--3-2: 3/2;--wp--preset--aspect-ratio--2-3: 2/3;--wp--preset--aspect-ratio--16-9: 16/9;--wp--preset--aspect-ratio--9-16: 9/16;--wp--preset--color--black: #000000;--wp--preset--color--cyan-bluish-gray: #abb8c3;--wp--preset--color--white: #ffffff;--wp--preset--color--pale-pink: #f78da7;--wp--preset--color--vivid-red: #cf2e2e;--wp--preset--color--luminous-vivid-orange: #ff6900;--wp--preset--color--luminous-vivid-amber: #fcb900;--wp--preset--color--light-green-cyan: #7bdcb5;--wp--preset--color--vivid-green-cyan: #00d084;--wp--preset--color--pale-cyan-blue: #8ed1fc;--wp--preset--color--vivid-cyan-blue: #0693e3;--wp--preset--color--vivid-purple: #9b51e0;--wp--preset--gradient--vivid-cyan-blue-to-vivid-purple: linear-gradient(135deg,rgb(6,147,227) 0%,rgb(155,81,224) 100%);--wp--preset--gradient--light-green-cyan-to-vivid-green-cyan: linear-gradient(135deg,rgb(122,220,180) 0%,rgb(0,208,130) 100%);--wp--preset--gradient--luminous-vivid-amber-to-luminous-vivid-orange: linear-gradient(135deg,rgb(252,185,0) 0%,rgb(255,105,0) 100%);--wp--preset--gradient--luminous-vivid-orange-to-vivid-red: linear-gradient(135deg,rgb(255,105,0) 0%,rgb(207,46,46) 100%);--wp--preset--gradient--very-light-gray-to-cyan-bluish-gray: linear-gradient(135deg,rgb(238,238,238) 0%,rgb(169,184,195) 100%);--wp--preset--gradient--cool-to-warm-spectrum: linear-gradient(135deg,rgb(74,234,220) 0%,rgb(151,120,209) 20%,rgb(207,42,186) 40%,rgb(238,44,130) 60%,rgb(251,105,98) 80%,rgb(254,248,76) 100%);--wp--preset--gradient--blush-light-purple: linear-gradient(135deg,rgb(255,206,236) 0%,rgb(152,150,240) 100%);--wp--preset--gradient--blush-bordeaux: linear-gradient(135deg,rgb(254,205,165) 0%,rgb(254,45,45) 50%,rgb(107,0,62) 100%);--wp--preset--gradient--luminous-dusk: linear-gradient(135deg,rgb(255,203,112) 0%,rgb(199,81,192) 50%,rgb(65,88,208) 100%);--wp--preset--gradient--pale-ocean: linear-gradient(135deg,rgb(255,245,203) 0%,rgb(182,227,212) 50%,rgb(51,167,181) 100%);--wp--preset--gradient--electric-grass: linear-gradient(135deg,rgb(202,248,128) 0%,rgb(113,206,126) 100%);--wp--preset--gradient--midnight: linear-gradient(135deg,rgb(2,3,129) 0%,rgb(40,116,252) 100%);--wp--preset--font-size--small: 13px;--wp--preset--font-size--medium: 20px;--wp--preset--font-size--large: 36px;--wp--preset--font-size--x-large: 42px;--wp--preset--spacing--20: 0.44rem;--wp--preset--spacing--30: 0.67rem;--wp--preset--spacing--40: 1rem;--wp--preset--spacing--50: 1.5rem;--wp--preset--spacing--60: 2.25rem;--wp--preset--spacing--70: 3.38rem;--wp--preset--spacing--80: 5.06rem;--wp--preset--shadow--natural: 6px 6px 9px rgba(0, 0, 0, 0.2);--wp--preset--shadow--deep: 12px 12px 50px rgba(0, 0, 0, 0.4);--wp--preset--shadow--sharp: 6px 6px 0px rgba(0, 0, 0, 0.2);--wp--preset--shadow--outlined: 6px 6px 0px -3px rgb(255, 255, 255), 6px 6px rgb(0, 0, 0);--wp--preset--shadow--crisp: 6px 6px 0px rgb(0, 0, 0);}:where(.is-layout-flex){gap: 0.5em;}:where(.is-layout-grid){gap: 0.5em;}body .is-layout-flex{display: flex;}.is-layout-flex{flex-wrap: wrap;align-items: center;}.is-layout-flex > :is(*, div){margin: 0;}body .is-layout-grid{display: grid;}.is-layout-grid > :is(*, div){margin: 0;}:where(.wp-block-columns.is-layout-flex){gap: 2em;}:where(.wp-block-columns.is-layout-grid){gap: 2em;}:where(.wp-block-post-template.is-layout-flex){gap: 1.25em;}:where(.wp-block-post-template.is-layout-grid){gap: 1.25em;}.has-black-color{color: var(--wp--preset--color--black) !important;}.has-cyan-bluish-gray-color{color: var(--wp--preset--color--cyan-bluish-gray) !important;}.has-white-color{color: var(--wp--preset--color--white) !important;}.has-pale-pink-color{color: var(--wp--preset--color--pale-pink) !important;}.has-vivid-red-color{color: var(--wp--preset--color--vivid-red) !important;}.has-luminous-vivid-orange-color{color: var(--wp--preset--color--luminous-vivid-orange) !important;}.has-luminous-vivid-amber-color{color: var(--wp--preset--color--luminous-vivid-amber) !important;}.has-light-green-cyan-color{color: var(--wp--preset--color--light-green-cyan) !important;}.has-vivid-green-cyan-color{color: var(--wp--preset--color--vivid-green-cyan) !important;}.has-pale-cyan-blue-color{color: var(--wp--preset--color--pale-cyan-blue) !important;}.has-vivid-cyan-blue-color{color: var(--wp--preset--color--vivid-cyan-blue) !important;}.has-vivid-purple-color{color: var(--wp--preset--color--vivid-purple) !important;}.has-black-background-color{background-color: var(--wp--preset--color--black) !important;}.has-cyan-bluish-gray-background-color{background-color: var(--wp--preset--color--cyan-bluish-gray) !important;}.has-white-background-color{background-color: var(--wp--preset--color--white) !important;}.has-pale-pink-background-color{background-color: var(--wp--preset--color--pale-pink) !important;}.has-vivid-red-background-color{background-color: var(--wp--preset--color--vivid-red) !important;}.has-luminous-vivid-orange-background-color{background-color: var(--wp--preset--color--luminous-vivid-orange) !important;}.has-luminous-vivid-amber-background-color{background-color: var(--wp--preset--color--luminous-vivid-amber) !important;}.has-light-green-cyan-background-color{background-color: var(--wp--preset--color--light-green-cyan) !important;}.has-vivid-green-cyan-background-color{background-color: var(--wp--preset--color--vivid-green-cyan) !important;}.has-pale-cyan-blue-background-color{background-color: var(--wp--preset--color--pale-cyan-blue) !important;}.has-vivid-cyan-blue-background-color{background-color: var(--wp--preset--color--vivid-cyan-blue) !important;}.has-vivid-purple-background-color{background-color: var(--wp--preset--color--vivid-purple) !important;}.has-black-border-color{border-color: var(--wp--preset--color--black) !important;}.has-cyan-bluish-gray-border-color{border-color: var(--wp--preset--color--cyan-bluish-gray) !important;}.has-white-border-color{border-color: var(--wp--preset--color--white) !important;}.has-pale-pink-border-color{border-color: var(--wp--preset--color--pale-pink) !important;}.has-vivid-red-border-color{border-color: var(--wp--preset--color--vivid-red) !important;}.has-luminous-vivid-orange-border-color{border-color: var(--wp--preset--color--luminous-vivid-orange) !important;}.has-luminous-vivid-amber-border-color{border-color: var(--wp--preset--color--luminous-vivid-amber) !important;}.has-light-green-cyan-border-color{border-color: var(--wp--preset--color--light-green-cyan) !important;}.has-vivid-green-cyan-border-color{border-color: var(--wp--preset--color--vivid-green-cyan) !important;}.has-pale-cyan-blue-border-color{border-color: var(--wp--preset--color--pale-cyan-blue) !important;}.has-vivid-cyan-blue-border-color{border-color: var(--wp--preset--color--vivid-cyan-blue) !important;}.has-vivid-purple-border-color{border-color: var(--wp--preset--color--vivid-purple) !important;}.has-vivid-cyan-blue-to-vivid-purple-gradient-background{background: var(--wp--preset--gradient--vivid-cyan-blue-to-vivid-purple) !important;}.has-light-green-cyan-to-vivid-green-cyan-gradient-background{background: var(--wp--preset--gradient--light-green-cyan-to-vivid-green-cyan) !important;}.has-luminous-vivid-amber-to-luminous-vivid-orange-gradient-background{background: var(--wp--preset--gradient--luminous-vivid-amber-to-luminous-vivid-orange) !important;}.has-luminous-vivid-orange-to-vivid-red-gradient-background{background: var(--wp--preset--gradient--luminous-vivid-orange-to-vivid-red) !important;}.has-very-light-gray-to-cyan-bluish-gray-gradient-background{background: var(--wp--preset--gradient--very-light-gray-to-cyan-bluish-gray) !important;}.has-cool-to-warm-spectrum-gradient-background{background: var(--wp--preset--gradient--cool-to-warm-spectrum) !important;}.has-blush-light-purple-gradient-background{background: var(--wp--preset--gradient--blush-light-purple) !important;}.has-blush-bordeaux-gradient-background{background: var(--wp--preset--gradient--blush-bordeaux) !important;}.has-luminous-dusk-gradient-background{background: var(--wp--preset--gradient--luminous-dusk) !important;}.has-pale-ocean-gradient-background{background: var(--wp--preset--gradient--pale-ocean) !important;}.has-electric-grass-gradient-background{background: var(--wp--preset--gradient--electric-grass) !important;}.has-midnight-gradient-background{background: var(--wp--preset--gradient--midnight) !important;}.has-small-font-size{font-size: var(--wp--preset--font-size--small) !important;}.has-medium-font-size{font-size: var(--wp--preset--font-size--medium) !important;}.has-large-font-size{font-size: var(--wp--preset--font-size--large) !important;}.has-x-large-font-size{font-size: var(--wp--preset--font-size--x-large) !important;}
/*# sourceURL=global-styles-inline-css */
</style>

<link rel='stylesheet' id='github-embed-css' href='https://islascruz.org/blog/wp-content/plugins/github-embed/css/github-embed.css?ver=6.9.4' type='text/css' media='all' />
<link rel='stylesheet' id='ib-educator-base-css' href='https://islascruz.org/blog/wp-content/plugins/ibeducator/css/base.css?ver=6.9.4' type='text/css' media='all' />
<link rel='stylesheet' id='a3-pvc-style-css' href='https://islascruz.org/blog/wp-content/plugins/page-views-count/assets/css/style.min.css?ver=2.9.0' type='text/css' media='all' />
<link rel='stylesheet' id='wpos-font-awesome-css' href='https://islascruz.org/blog/wp-content/plugins/slider-and-carousel-plus-widget-for-instagram/assets/css/font-awesome.min.css?ver=1.9.3' type='text/css' media='all' />
<link rel='stylesheet' id='wpos-magnific-style-css' href='https://islascruz.org/blog/wp-content/plugins/slider-and-carousel-plus-widget-for-instagram/assets/css/magnific-popup.css?ver=1.9.3' type='text/css' media='all' />
<link rel='stylesheet' id='wpos-slick-style-css' href='https://islascruz.org/blog/wp-content/plugins/slider-and-carousel-plus-widget-for-instagram/assets/css/slick.css?ver=1.9.3' type='text/css' media='all' />
<link rel='stylesheet' id='iscwp-public-css-css' href='https://islascruz.org/blog/wp-content/plugins/slider-and-carousel-plus-widget-for-instagram/assets/css/iscwp-public.css?ver=1.9.3' type='text/css' media='all' />
<link rel='stylesheet' id='SFSImainCss-css' href='https://islascruz.org/blog/wp-content/plugins/ultimate-social-media-icons/css/sfsi-style.css?ver=2.9.6' type='text/css' media='all' />
<link rel='stylesheet' id='style-css' href='https://islascruz.org/blog/wp-content/themes/superhero/style.css?ver=6.9.4' type='text/css' media='all' />
<link rel='stylesheet' id='a3pvc-css' href='//islascruz.org/blog/wp-content/uploads/sass/pvc.min.css?ver=1496808394' type='text/css' media='all' />
<script type="text/javascript" src="https://islascruz.org/blog/wp-includes/js/jquery/jquery.min.js?ver=3.7.1" id="jquery-core-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-includes/js/jquery/jquery-migrate.min.js?ver=3.4.1" id="jquery-migrate-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-includes/js/underscore.min.js?ver=1.13.7" id="underscore-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-includes/js/backbone.min.js?ver=1.6.0" id="backbone-js"></script>
<script type="text/javascript" id="a3-pvc-backbone-js-extra">
/* <![CDATA[ */
var pvc_vars = {"rest_api_url":"https://islascruz.org/blog/wp-json/pvc/v1","ajax_url":"https://islascruz.org/blog/wp-admin/admin-ajax.php","security":"092d90511a","ajax_load_type":"rest_api"};
//# sourceURL=a3-pvc-backbone-js-extra
/* ]]> */
</script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/page-views-count/assets/js/pvc.backbone.min.js?ver=2.9.0" id="a3-pvc-backbone-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/jw-player-7-for-wp/js/jwppp.js?ver=6.9.4" id="jwppp-js"></script>
<script type="text/javascript" id="jwppp-licence-js-extra">
/* <![CDATA[ */
var data = {"licence":""};
//# sourceURL=jwppp-licence-js-extra
/* ]]> */
</script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/jw-player-7-for-wp/js/jwppp-licence.js?ver=6.9.4" id="jwppp-licence-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/themes/superhero/js/superhero.js?ver=6.9.4" id="superhero-script-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/google-analyticator/external-tracking.min.js?ver=6.5.7" id="ga-external-tracking-js"></script>
<link rel="https://api.w.org/" href="https://islascruz.org/blog/wp-json/" /><link rel="alternate" title="JSON" type="application/json" href="https://islascruz.org/blog/wp-json/wp/v2/pages/873" /><link rel="EditURI" type="application/rsd+xml" title="RSD" href="https://islascruz.org/blog/xmlrpc.php?rsd" />
<meta name="generator" content="WordPress 6.9.4" />
<link rel='shortlink' href='https://islascruz.org/blog/?p=873' />
<meta name="follow.it-verification-code-YTV3MC9QQVVHazJsbkpwV0c2Rm5VdU1GWjdqT1VXUnR3QlZaa2xwVWwrZU40b2VWdTNWOTRucmJieTFjMHFSZm1oRElTY1krTXNBSDRwMFF1US9wM0cvYjFUc1pDUndLSkQwQ1RmNDFBTzlQYVFnd0tQaDhNWDVMV2hXYms3L1F8TEVaMk9pUWROT2tvZkNVOUZmQWppNmtHTkpaMlFnL2EwbE05MW5zWUQwMD0=" content="eWBl7BD3kWQ25Lu6kqQf"/><style type="text/css">.recentcomments a{display:inline !important;padding:0 !important;margin:0 !important;}</style><link rel="icon" href="https://islascruz.org/blog/wp-content/uploads/2016/03/cropped-apple_icon-32x32.jpg" sizes="32x32" />
<link rel="icon" href="https://islascruz.org/blog/wp-content/uploads/2016/03/cropped-apple_icon-192x192.jpg" sizes="192x192" />
<link rel="apple-touch-icon" href="https://islascruz.org/blog/wp-content/uploads/2016/03/cropped-apple_icon-180x180.jpg" />
<meta name="msapplication-TileImage" content="https://islascruz.org/blog/wp-content/uploads/2016/03/cropped-apple_icon-270x270.jpg" />
<!-- Google Analytics Tracking by Google Analyticator 6.5.7 -->
<script type="text/javascript">
    var analyticsFileTypes = [];
    var analyticsSnippet = 'disabled';
    var analyticsEventTracking = 'enabled';
</script>
<script type="text/javascript">
	(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
	(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
	m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
	})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
	ga('create', 'UA-955861-1', 'auto');
 
	ga('send', 'pageview');
</script>
		<style type="text/css" id="wp-custom-css">
			/*
Welcome to Custom CSS!

To learn how this works, see http://wp.me/PEmnE-Bt
*/
.adsbygoogle {
	background: #FFFFFF;
}		</style>
		<style id="kirki-inline-styles"></style><link rel='stylesheet' id='hljstheme-css' href='https://islascruz.org/blog/wp-content/plugins/wp-code-highlightjs/styles/darkula.css?ver=0.6.2' type='text/css' media='all' />

</head>

<body class="wp-singular page-template-default page page-id-873 wp-theme-superhero sfsi_actvite_theme_default">
<div id="page" class="hfeed site">
		<div id="masthead-wrap">
	<header id="masthead" class="site-header" role="banner">
		<hgroup>
									<h1 class="site-title"><a href="https://islascruz.org/blog/" title="Marco Islas" rel="home">Marco Islas</a></h1>
			<h2 class="site-description">Python programming and stuff</h2>
		</hgroup>

		<nav role="navigation" class="site-navigation main-navigation">
			<h1 class="assistive-text">Menu</h1>
			<div class="assistive-text skip-link"><a href="#content" title="Skip to content">Skip to content</a></div>

			<div class="menu-contango-container"><ul id="menu-contango" class="menu"><li id="menu-item-2327" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-has-children menu-item-2327"><a href="#">Top Categories</a>
<ul class="sub-menu">
	<li id="menu-item-2326" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-2326"><a href="https://islascruz.org/blog/category/programming/">programming</a></li>
	<li id="menu-item-2083" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-2083"><a href="https://islascruz.org/blog/category/share/">Share</a></li>
	<li id="menu-item-3605" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-3605"><a href="https://islascruz.org/blog/category/pictures/">Pictures</a></li>
	<li id="menu-item-3606" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-3606"><a href="https://islascruz.org/blog/category/pictures/flickr/">Flickr</a></li>
</ul>
</li>
<li id="menu-item-876" class="menu-item menu-item-type-custom menu-item-object-custom current-menu-ancestor current-menu-parent menu-item-has-children menu-item-876"><a href="#" title="Things that you might want to read!">Top posts</a>
<ul class="sub-menu">
	<li id="menu-item-6029" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-6029"><a href="https://islascruz.org/blog/2018/08/02/documentando-codigo-en-python/">Documentando código en Python</a></li>
	<li id="menu-item-6028" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-6028"><a href="https://islascruz.org/blog/2018/07/25/buenas-practicas-en-python/">Buenas prácticas en Python</a></li>
	<li id="menu-item-6027" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-6027"><a href="https://islascruz.org/blog/2018/07/27/buenas-practicas-en-django/">Buenas practicas en Django</a></li>
	<li id="menu-item-877" class="menu-item menu-item-type-post_type menu-item-object-page current-menu-item page_item page-item-873 current_page_item menu-item-877"><a href="https://islascruz.org/blog/win32services/" aria-current="page">Win32 Services</a></li>
	<li id="menu-item-2321" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-2321"><a href="https://islascruz.org/blog/2015/10/19/python-trick-how-to-make-lazy-objects/">Python trick: How to make lazy objects?</a></li>
	<li id="menu-item-5270" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-5270"><a href="https://islascruz.org/blog/2017/01/27/attachments-python-imap/">Get attachments with Python over IMAP</a></li>
	<li id="menu-item-2421" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-2421"><a href="https://islascruz.org/blog/2015/12/22/python-simple-http-server-on-python/">Python: Simple HTTP Server on python.</a></li>
	<li id="menu-item-2325" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-2325"><a href="https://islascruz.org/blog/2016/06/03/the-best-macbook-pro-is-the-one-that-is-obsolete/">The best MacBook Pro is the one that is obsolete</a></li>
	<li id="menu-item-3604" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-3604"><a href="https://islascruz.org/blog/2015/04/28/my-experience-with-digital-ocean/">My (zen) experience with Digital Ocean</a></li>
	<li id="menu-item-4538" class="menu-item menu-item-type-post_type menu-item-object-post menu-item-4538"><a href="https://islascruz.org/blog/2015/05/29/la-realidad-del-voto-nulo-youtube/">La realidad del voto nulo – YouTube</a></li>
</ul>
</li>
<li id="menu-item-4536" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-has-children menu-item-4536"><a href="#">Servicios recomendados</a>
<ul class="sub-menu">
	<li id="menu-item-2100" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-2100"><a href="https://m.do.co/c/cb6fcac2998c">Digital Ocean</a></li>
	<li id="menu-item-4535" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-4535"><a href="http://https://lastpass.com/f?9883436">LastPass</a></li>
</ul>
</li>
<li id="menu-item-5395" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-has-children menu-item-5395"><a href="#">Cursos</a>
<ul class="sub-menu">
	<li id="menu-item-5394" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-5394"><a href="https://islascruz.org/blog/courses/programacion-basica-en-python/">Programación basica en Python</a></li>
</ul>
</li>
<li id="menu-item-337" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-337"><a href="http://flickr.com/photos/markuz">Flickr</a></li>
<li id="menu-item-338" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-338"><a href="http://www.islascruz.org/html/">Old Blog</a></li>
<li id="menu-item-1196" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-1196"><a href="https://www.amazon.com.mx/registry/wishlist/3QZLH0B23T7YX">Amazon Wishlist</a></li>
</ul></div>		</nav><!-- .site-navigation .main-navigation -->

		<div class="clearfix"></div>
	</header><!-- #masthead .site-header -->
	</div><!-- #masthead-wrap -->

	
	<div id="main" class="site-main">

<div id="primary" class="content-area">
	<div id="content" class="site-content" role="main">
	<content>

		
			
<article id="post-873" class="post-873 page type-page status-publish has-post-thumbnail hentry">
	
	<header class="entry-header">
		<h1 class="entry-title">How to make Win32Services</h1>
	</header><!-- .entry-header -->

	<div class="entry-content">1
		<p>[adinserter block=&#8221;2&#8243;]<br />
<img decoding="async" src="https://islascruz.org/html/data/files/python-logo-glassy.png" alt="" align="right" />Hi, in this case I&#8217;m going to show you how to create simple services for the win32 platform using the powerfull Python programming language and the py2exe utility.</p>
<p>Writing Python applications under windows is quite simple, maybe you didn&#8217;t use windows to develop your application (as I do most times), the code, what you want to do with your application is up to you, and I&#8217;m not goint to touch the programming techniques for developing windows applications, Just, create a simple -and useles- win32 service that will help you to uderstand how to create your very own windows service.</p>
<p>First, every single program that you create with python and compile with py2exe and does run well, may be a win32 service, it may be a program that fetches the <a href="http://feeds2.feedburner.com/islascruz/general?format=xml" target="_blank" rel="noopener">RSS xml feed</a> for <a href="http://www.islascruz.org">islascruz.org</a>, maybe is a more complex program to generate some files and then send them to another server, maybe is a simple program to remind you to sand up an walk 10 minutes.</p>
<p>Said that we don&#8217;t really need to create a program thinking on it as a service, we will create a simple program and test it using the python interpreter, who needs to compile?, well, we need it, but just when we are sure that our program performs well.</p>
<pre class="lang:python decode:1 ">#!/usr/bin/env python
import time
import thread
import os
import sys

class service_test:
    def __init__(self):
        thread.start_new(self.do_something, tuple())
        while True:
            if getattr(sys,'stopservice', False):
                sys.exit()
            time.sleep(0.3)

    def do_something(self):
        '''
        Do something
        '''
        while True:
            fname ='C:\\\\test.txt'
            f = open(fname , 'a')
            f.write(time.time())
            f.close()
            time.sleep(1)


if __name__ == "__main__":
    tst = service_test()

</pre>
<p>Now that we have this program running in our windows environment, we can start thinking in converting into a service. First, I don&#8217;t know you, but I haven&#8217;t make Windows to load a python script and run it as a service. This is because Win32 use it&#8217;s own method to start/stop the services. Then, we will need to create a wrapper for our program, this wrapper will interface with the windows service mananger. Doing it is quite simple, lets see it.</p>
<pre class="lang:python decode:1 ">
import win32serviceutil
import win32service
import win32event
import os
import sys
import time

sys.stopservice = "false"

def main():
    '''
    Modulo principal para windows
    '''
    sys.path.insert(0,os.getcwd())
    import service_module
    a = service_module.service_test()

class ServiceLauncher(win32serviceutil.ServiceFramework):
    _svc_name_ = 'ServiceTest'
    _scv_display_name_ ='Servicio de pruebas'
    def __init__(self, args):
        win32serviceutil.ServiceFramework.__init__(self, args)
        self.hWaitStop = win32event.CreateEvent(None, 0, 0, None)

    def SvcStop(self):
        self.ReportServiceStatus(win32service.SERVICE_STOP_PENDING)
        sys.stopservice = "true"
        win32event.SetEvent(self.hWaitStop)

    def SvcDoRun(self):
        main()
</pre>
<p>[adinserter block=&#8221;2&#8243;]</p>
<p>As you can see in this piece of code, we have a class called ServiceLauncher, actually it doesn&#8217;t really matter if you name it as you want, but, we need some variables that starts with &#8220;<em>svc</em>&#8221; and the important is _svc_name, this variable should have the name of our service, the very same name of the executable that we are going to compile. The <strong>init</strong> method initialize our service.</p>
<p>Then, we have two methods. one SvcStop, this method will be called when we want to stop the service in the service mananger. As our program is not running here, is safe to communicate with it by some method, I use a variable stored in &#8220;sys&#8221; which is &#8220;pooled&#8221; on the main program to know when it&#8217;s time to stop the program.</p>
<p>THe method SvcDoRun is quite explicit, it starts the program. Now, you guess that when you start your service must be doing something, even sleeping, because, if it stops, then an error message will be saved in the Windows logs.</p>
<p>Ok, we have our program and our wrapper class, but, did I said that Windows cannot load a python scritp as a service?. Well, we need to compile it. here is when <a href="http://www.py2exe.org" target="_blank" rel="noopener">py2exe</a> comes in.</p>
<p>Py2Exe will help us to convert those scripts in a binary for windows, a simple binary for execution or a Windows service :-D. I use this script to create my windows services, py2exe makes use of the distutils and hence a setup.py script must be used to compile the our scripts. check the next code that will help you to create console programs and win32 services.</p>
<p>[adinserter block=&#8221;2&#8243;]</p>
<pre class="lang:python decode:1 ">import sys
buildservice = True
if '--no-service' in sys.argv[1:]:
    buildservice = False
    sys.argv = [k for k in sys.argv if k != '--no-service']
    print sys.argv

from distutils.core import setup
import os
import py2exe
import glob
import shutil

sys.path.insert(0,os.getcwd())

def getFiles(dir):
    """
    Retorna una tupla de tuplas del directorio
    """
    # dig looking for files
    a= os.walk(dir)
    b = True
    filenames = []

    while (b):
        try:
            (dirpath, dirnames, files) = a.next()
            filenames.append([dirpath, tuple(files)])
        except:
            b = False
    return filenames

DESCRIPTION = 'Servicio de pruebas'
NAME = 'servicetest'


class Target:
    def __init__(self,**kw):
            self.__dict__.update(kw)
            self.version        = "1.00.00"
            self.compay_name    = "islascruz.org"
            self.copyright      = "(c) 2009, Marco Islas"
            self.name           = NAME
            self.description    = DESCRIPTION

my_com_server_target = Target(
        description    = DESCRIPTION,
        service = ["service_module"],
        modules = ["service_module"],
        create_exe = True,
        create_dll = True)

if not buildservice:
    print 'Compilando como ejecutable de windows...'
    setup(
        name = NAME ,
        description = DESCRIPTION,
        version = '1.00.00',
        console = ['service_module.py'],
        zipfile=None,
        options = {
                "py2exe":{"packages":"encodings",
                    "includes":"win32com,win32service,win32serviceutil,win32event",
                    "optimize": '2'
                    },
                },
    )
else:
    print 'Compilando como servicio de windows...'
    setup(
        name = NAME,
        description = DESCRIPTION,
        version = '1.00.00',
        service = [{'modules':["ServiceLauncher"], 'cmdline':'pywin32'}],
        zipfile=None,
        options = {
                "py2exe":{"packages":"encodings",
                    "includes":"win32com,win32service,win32serviceutil,win32event",
                    "optimize": '2'
                    },
                },
    )
</pre>
<p>Maybe you want to read the distutils documentation to understand it. Once you have your binary, you can use it to install it on the win32 services list, just run your program with the &#8220;-install&#8221; parameter and you are done!.</p>
<div class="pvc_clear"></div>
<p id="pvc_stats_873" class="pvc_stats all  pvc_load_by_ajax_update" data-element-id="873" style=""><i class="pvc-stats-icon medium" aria-hidden="true"><svg aria-hidden="true" focusable="false" data-prefix="far" data-icon="chart-bar" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" class="svg-inline--fa fa-chart-bar fa-w-16 fa-2x"><path fill="currentColor" d="M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z" class=""></path></svg></i> <img decoding="async" width="16" height="16" alt="Loading" src="https://islascruz.org/blog/wp-content/plugins/page-views-count/ajax-loader-2x.gif" border=0 /></p>
<div class="pvc_clear"></div>
			</div><!-- .entry-content -->

	</article><!-- #post-## -->
			
<div id="disqus_thread"></div>

			</content>
	</div><!-- #content .site-content -->
</div><!-- #primary .content-area -->

<div id="secondary" class="widget-area" role="complementary">
		<aside id="custom_html-2" class="widget_text widget widget_custom_html"><h1 class="widget-title">Get Dropbox today</h1><div class="textwidget custom-html-widget"><center>
<a href="https://db.tt/g0bbjXJa"><img src="https://islascruz.org/blog/wp-content/uploads/2020/01/dropbox-icon-png-4.png"></a></center></div></aside><aside id="recent-comments-4" class="widget widget_recent_comments"><h1 class="widget-title">Recent coments</h1><ul id="recentcomments"><li class="recentcomments"><span class="comment-author-link"><a href="https://www.binance.com/register?ref=QCGZMHR6" class="url" rel="ugc external nofollow">Binance推荐</a></span> on <a href="https://islascruz.org/blog/2019/07/15/8-errores-que-todo-programador-novato-comete/#comment-2962">8 errores que todo programador novato comete</a></li><li class="recentcomments"><span class="comment-author-link"><a href="https://islascruz.org/blog/2015/10/19/python-trick-how-to-make-lazy-objects/" class="url" rel="ugc">Python trick: How to make lazy objects? | Marco Islas</a></span> on <a href="https://islascruz.org/blog/2019/08/07/truco-de-python-como-crear-objetos-flojos-lazy-objects/#comment-924">Truco de Python, como crear objetos &#8220;flojos&#8221; (Lazy objects)</a></li><li class="recentcomments"><span class="comment-author-link"><a href="https://islascruz.org/blog/2019/08/07/truco-de-python-como-crear-objetos-flojos-lazy-objects/" class="url" rel="ugc">Como crear objetos tontos en Python?</a></span> on <a href="https://islascruz.org/blog/2015/10/19/python-trick-how-to-make-lazy-objects/#comment-923">Python trick: How to make lazy objects?</a></li><li class="recentcomments"><span class="comment-author-link"><a href="https://islascruz.org/blog/2018/11/21/yay-pycharm-2018-3/" class="url" rel="ugc">Yay! PyCharm 2018.3 !! | Marco Islas</a></span> on <a href="https://islascruz.org/blog/2016/06/03/the-best-macbook-pro-is-the-one-that-is-obsolete/#comment-922">The best MacBook Pro is the one that is obsolete</a></li><li class="recentcomments"><span class="comment-author-link"><a href="https://mkzhost.com/2018/05/30/get-attachments-with-python-over-imap-marco-islas/" class="url" rel="ugc external nofollow">Get attachments with Python over IMAP | Marco Islas | MkzHost</a></span> on <a href="https://islascruz.org/blog/2017/01/27/attachments-python-imap/#comment-921">Get attachments with Python over IMAP</a></li></ul></aside></div><!-- #secondary .widget-area -->

	</div><!-- #main .site-main -->

	<div id="colophon-wrap">
	<footer id="colophon" class="site-footer" role="contentinfo">
		<div class="site-info">
						<a href="http://wordpress.org/" title="A Semantic Personal Publishing Platform" rel="generator">Proudly powered by WordPress</a>
			<span class="sep"> | </span>
			Theme: Superhero by <a href="https://wordpress.com/themes/" rel="designer">WordPress.com</a>.		</div><!-- .site-info -->
	</footer><!-- #colophon .site-footer -->
	</div><!-- #colophon-wrap -->
</div><!-- #page .hfeed .site -->

<script type="speculationrules">
{"prefetch":[{"source":"document","where":{"and":[{"href_matches":"/blog/*"},{"not":{"href_matches":["/blog/wp-*.php","/blog/wp-admin/*","/blog/wp-content/uploads/*","/blog/wp-content/*","/blog/wp-content/plugins/*","/blog/wp-content/themes/superhero/*","/blog/*\\?(.+)"]}},{"not":{"selector_matches":"a[rel~=\"nofollow\"]"}},{"not":{"selector_matches":".no-prefetch, .no-prefetch a"}}]},"eagerness":"conservative"}]}
</script>
                <!--facebook like and share js -->
                <div id="fb-root"></div>
                <script>
                    (function(d, s, id) {
                        var js, fjs = d.getElementsByTagName(s)[0];
                        if (d.getElementById(id)) return;
                        js = d.createElement(s);
                        js.id = id;
                        js.src = "https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v3.2";
                        fjs.parentNode.insertBefore(js, fjs);
                    }(document, 'script', 'facebook-jssdk'));
                </script>
                <script>
window.addEventListener('sfsi_functions_loaded', function() {
    if (typeof sfsi_responsive_toggle == 'function') {
        sfsi_responsive_toggle(0);
        // console.log('sfsi_responsive_toggle');

    }
})
</script>
    <script>
        window.addEventListener('sfsi_functions_loaded', function () {
            if (typeof sfsi_plugin_version == 'function') {
                sfsi_plugin_version(2.77);
            }
        });

        function sfsi_processfurther(ref) {
            var feed_id = 'YTV3MC9QQVVHazJsbkpwV0c2Rm5VdU1GWjdqT1VXUnR3QlZaa2xwVWwrZU40b2VWdTNWOTRucmJieTFjMHFSZm1oRElTY1krTXNBSDRwMFF1US9wM0cvYjFUc1pDUndLSkQwQ1RmNDFBTzlQYVFnd0tQaDhNWDVMV2hXYms3L1F8TEVaMk9pUWROT2tvZkNVOUZmQWppNmtHTkpaMlFnL2EwbE05MW5zWUQwMD0=';
            var feedtype = 8;
            var email = jQuery(ref).find('input[name="email"]').val();
            var filter = /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
            if ((email != "Enter your email") && (filter.test(email))) {
                if (feedtype == "8") {
                    var url = "https://api.follow.it/subscription-form/" + feed_id + "/" + feedtype;
                    window.open(url, "popupwindow", "scrollbars=yes,width=1080,height=760");
                    return true;
                }
            } else {
                alert("Please enter email address");
                jQuery(ref).find('input[name="email"]').focus();
                return false;
            }
        }
    </script>
    <style type="text/css" aria-selected="true">
        .sfsi_subscribe_Popinner {
             width: 100% !important;

            height: auto !important;

         padding: 18px 0px !important;

            background-color: #ffffff !important;
        }

        .sfsi_subscribe_Popinner form {
            margin: 0 20px !important;
        }

        .sfsi_subscribe_Popinner h5 {
            font-family: Helvetica,Arial,sans-serif !important;

             font-weight: bold !important;   color:#000000 !important; font-size: 16px !important;   text-align:center !important; margin: 0 0 10px !important;
            padding: 0 !important;
        }

        .sfsi_subscription_form_field {
            margin: 5px 0 !important;
            width: 100% !important;
            display: inline-flex;
            display: -webkit-inline-flex;
        }

        .sfsi_subscription_form_field input {
            width: 100% !important;
            padding: 10px 0px !important;
        }

        .sfsi_subscribe_Popinner input[type=email] {
         font-family: Helvetica,Arial,sans-serif !important;   font-style:normal !important;   font-size:14px !important; text-align: center !important;        }

        .sfsi_subscribe_Popinner input[type=email]::-webkit-input-placeholder {

         font-family: Helvetica,Arial,sans-serif !important;   font-style:normal !important;  font-size: 14px !important;   text-align:center !important;        }

        .sfsi_subscribe_Popinner input[type=email]:-moz-placeholder {
            /* Firefox 18- */
         font-family: Helvetica,Arial,sans-serif !important;   font-style:normal !important;   font-size: 14px !important;   text-align:center !important;
        }

        .sfsi_subscribe_Popinner input[type=email]::-moz-placeholder {
            /* Firefox 19+ */
         font-family: Helvetica,Arial,sans-serif !important;   font-style: normal !important;
              font-size: 14px !important;   text-align:center !important;        }

        .sfsi_subscribe_Popinner input[type=email]:-ms-input-placeholder {

            font-family: Helvetica,Arial,sans-serif !important;  font-style:normal !important;   font-size:14px !important;
         text-align: center !important;        }

        .sfsi_subscribe_Popinner input[type=submit] {

         font-family: Helvetica,Arial,sans-serif !important;   font-weight: bold !important;   color:#000000 !important; font-size: 16px !important;   text-align:center !important; background-color: #dedede !important;        }

                .sfsi_shortcode_container {
            float: left;
        }

        .sfsi_shortcode_container .norm_row .sfsi_wDiv {
            position: relative !important;
        }

        .sfsi_shortcode_container .sfsi_holders {
            display: none;
        }

            </style>

        <style>code.hljs { /*margin: 5px;*/ }</style>
    <script type="text/javascript">
    (function($, window) {
        var init_fn_flag = false;
        var init_fn = (function() {
            if (init_fn_flag)
                return;
            init_fn_flag = true;
             hljs.configure({"tabReplace":"    "});
            $('pre code').each(function(i, block) {
                hljs.highlightBlock(block);
            });
        $('pre:not(:has(code))').each(function(i, block){
            var class_desc = $(block).attr("class") || "";
            var reg_mat = class_desc.match(/lang\s*:\s*([\w\d]+)/i);
            var code_content = $("<code class='hljs'></code>").html($(block).removeAttr('class').html());
            if (reg_mat && reg_mat.length >= 2) {
                code_content.addClass(reg_mat[1]);
            }
            $(block).empty().append(code_content);
            hljs.highlightBlock(block);
        });
        });
        $(document).ready(init_fn);
        $(window).on("load", init_fn);
    })(jQuery, window);
    </script>
<script type="text/javascript" id="disqus_count-js-extra">
/* <![CDATA[ */
var countVars = {"disqusShortname":"islascruz"};
//# sourceURL=disqus_count-js-extra
/* ]]> */
</script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/disqus-comment-system/public/js/comment_count.js?ver=3.1.4" id="disqus_count-js"></script>
<script type="text/javascript" id="disqus_embed-js-extra">
/* <![CDATA[ */
var embedVars = {"disqusConfig":{"integration":"wordpress 3.1.4 6.9.4"},"disqusIdentifier":"873 http://islascruz.org/blog/?page_id=873","disqusShortname":"islascruz","disqusTitle":"How to make Win32Services","disqusUrl":"https://islascruz.org/blog/win32services/","postId":"873"};
//# sourceURL=disqus_embed-js-extra
/* ]]> */
</script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/disqus-comment-system/public/js/comment_embed.js?ver=3.1.4" id="disqus_embed-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-includes/js/jquery/ui/core.min.js?ver=1.13.3" id="jquery-ui-core-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/ultimate-social-media-icons/js/shuffle/modernizr.custom.min.js?ver=6.9.4" id="SFSIjqueryModernizr-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/ultimate-social-media-icons/js/shuffle/jquery.shuffle.min.js?ver=6.9.4" id="SFSIjqueryShuffle-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/ultimate-social-media-icons/js/shuffle/random-shuffle-min.js?ver=6.9.4" id="SFSIjqueryrandom-shuffle-js"></script>
<script type="text/javascript" id="SFSICustomJs-js-extra">
/* <![CDATA[ */
var sfsi_icon_ajax_object = {"nonce":"7d7e03da96","ajax_url":"https://islascruz.org/blog/wp-admin/admin-ajax.php","plugin_url":"https://islascruz.org/blog/wp-content/plugins/ultimate-social-media-icons/"};
//# sourceURL=SFSICustomJs-js-extra
/* ]]> */
</script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/ultimate-social-media-icons/js/custom.js?ver=2.9.6" id="SFSICustomJs-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/themes/superhero/js/small-menu.js?ver=20120206" id="small-menu-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-includes/js/comment-reply.min.js?ver=6.9.4" id="comment-reply-js" async="async" data-wp-strategy="async" fetchpriority="low"></script>
<script type="text/javascript" id="wp_slimstat-js-extra">
/* <![CDATA[ */
var SlimStatParams = {"transport":"ajax","ajaxurl_rest":"https://islascruz.org/blog/wp-json/slimstat/v1/hit","ajaxurl_rest_query":"https://islascruz.org/blog/index.php?rest_route=/slimstat/v1/hit","resturl":"https://islascruz.org/blog/wp-json/","ajaxurl_ajax":"https://islascruz.org/blog/wp-admin/admin-ajax.php","ajaxurl":"https://islascruz.org/blog/wp-admin/admin-ajax.php","baseurl":"/blog","dnt":"noslimstat,ab-item","ci":"eyJjb250ZW50X3R5cGUiOiJwYWdlIiwiY29udGVudF9pZCI6ODczLCJhdXRob3IiOiJtYXJjbyJ9.0790d3fdb6d933538ffc467fd19572ac5b794e8f96c1c24b170d478d3828703f","wp_rest_nonce":"6d41d3504b","is_logged_in":"0","wp_consent_integration":"disabled","consent_integration":"","consent_level_integration":"statistics","respect_dnt":"off","gdpr_enabled":"off","anonymous_tracking":"off","anonymize_ip":"no","hash_ip":"off","set_tracker_cookie":"on","use_slimstat_banner":"off"};
//# sourceURL=wp_slimstat-js-extra
/* ]]> */
</script>
<script defer type="text/javascript" src="https://cdn.jsdelivr.net/wp/wp-slimstat/tags/5.4.11/wp-slimstat.min.js" id="wp_slimstat-js"></script>
<script type="text/javascript" src="https://islascruz.org/blog/wp-content/plugins/wp-code-highlightjs/highlight.common.pack.js?ver=0.6.2" id="hljs-js"></script>
<script id="wp-emoji-settings" type="application/json">
{"baseUrl":"https://s.w.org/images/core/emoji/17.0.2/72x72/","ext":".png","svgUrl":"https://s.w.org/images/core/emoji/17.0.2/svg/","svgExt":".svg","source":{"concatemoji":"https://islascruz.org/blog/wp-includes/js/wp-emoji-release.min.js?ver=6.9.4"}}
</script>
<script type="module">
/* <![CDATA[ */
/*! This file is auto-generated */
const a=JSON.parse(document.getElementById("wp-emoji-settings").textContent),o=(window._wpemojiSettings=a,"wpEmojiSettingsSupports"),s=["flag","emoji"];function i(e){try{var t={supportTests:e,timestamp:(new Date).valueOf()};sessionStorage.setItem(o,JSON.stringify(t))}catch(e){}}function c(e,t,n){e.clearRect(0,0,e.canvas.width,e.canvas.height),e.fillText(t,0,0);t=new Uint32Array(e.getImageData(0,0,e.canvas.width,e.canvas.height).data);e.clearRect(0,0,e.canvas.width,e.canvas.height),e.fillText(n,0,0);const a=new Uint32Array(e.getImageData(0,0,e.canvas.width,e.canvas.height).data);return t.every((e,t)=>e===a[t])}function p(e,t){e.clearRect(0,0,e.canvas.width,e.canvas.height),e.fillText(t,0,0);var n=e.getImageData(16,16,1,1);for(let e=0;e<n.data.length;e++)if(0!==n.data[e])return!1;return!0}function u(e,t,n,a){switch(t){case"flag":return n(e,"\ud83c\udff3\ufe0f\u200d\u26a7\ufe0f","\ud83c\udff3\ufe0f\u200b\u26a7\ufe0f")?!1:!n(e,"\ud83c\udde8\ud83c\uddf6","\ud83c\udde8\u200b\ud83c\uddf6")&&!n(e,"\ud83c\udff4\udb40\udc67\udb40\udc62\udb40\udc65\udb40\udc6e\udb40\udc67\udb40\udc7f","\ud83c\udff4\u200b\udb40\udc67\u200b\udb40\udc62\u200b\udb40\udc65\u200b\udb40\udc6e\u200b\udb40\udc67\u200b\udb40\udc7f");case"emoji":return!a(e,"\ud83e\u1fac8")}return!1}function f(e,t,n,a){let r;const o=(r="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?new OffscreenCanvas(300,150):document.createElement("canvas")).getContext("2d",{willReadFrequently:!0}),s=(o.textBaseline="top",o.font="600 32px Arial",{});return e.forEach(e=>{s[e]=t(o,e,n,a)}),s}function r(e){var t=document.createElement("script");t.src=e,t.defer=!0,document.head.appendChild(t)}a.supports={everything:!0,everythingExceptFlag:!0},new Promise(t=>{let n=function(){try{var e=JSON.parse(sessionStorage.getItem(o));if("object"==typeof e&&"number"==typeof e.timestamp&&(new Date).valueOf()<e.timestamp+604800&&"object"==typeof e.supportTests)return e.supportTests}catch(e){}return null}();if(!n){if("undefined"!=typeof Worker&&"undefined"!=typeof OffscreenCanvas&&"undefined"!=typeof URL&&URL.createObjectURL&&"undefined"!=typeof Blob)try{var e="postMessage("+f.toString()+"("+[JSON.stringify(s),u.toString(),c.toString(),p.toString()].join(",")+"));",a=new Blob([e],{type:"text/javascript"});const r=new Worker(URL.createObjectURL(a),{name:"wpTestEmojiSupports"});return void(r.onmessage=e=>{i(n=e.data),r.terminate(),t(n)})}catch(e){}i(n=f(s,u,c,p))}t(n)}).then(e=>{for(const n in e)a.supports[n]=e[n],a.supports.everything=a.supports.everything&&a.supports[n],"flag"!==n&&(a.supports.everythingExceptFlag=a.supports.everythingExceptFlag&&a.supports[n]);var t;a.supports.everythingExceptFlag=a.supports.everythingExceptFlag&&!a.supports.flag,a.supports.everything||((t=a.source||{}).concatemoji?r(t.concatemoji):t.wpemoji&&t.twemoji&&(r(t.twemoji),r(t.wpemoji)))});
//# sourceURL=https://islascruz.org/blog/wp-includes/js/wp-emoji-loader.min.js
/* ]]> */
</script>
<script type="text/javascript">(()=>{"use strict";var e={};e.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}();var t,n,r={isResourceTiming:!1,isElementTiming:!1,maxTime:3e4,reportOptions:{},enableNavigationTracking:!0},i=window,o=i.console,a=i.navigator,s=i.performance,c=function(){return a.deviceMemory},u=function(){return a.hardwareConcurrency},d=function(){return s&&!!s.getEntriesByType&&!!s.now&&!!s.mark},l="4g",f=!1,h={},p={value:0},m={value:{beacon:0,css:0,fetch:0,img:0,other:0,script:0,total:0,xmlhttprequest:0}},v={value:0},y={value:0},g={},T={isHidden:!1,didChange:!1},b=function(){T.isHidden=!1,document.hidden&&(T.isHidden=document.hidden,T.didChange=!0)},w=function(e,t){try{var n=new PerformanceObserver((function(e){t(e.getEntries())}));return n.observe({type:e,buffered:!0}),n}catch(e){o.warn("Perfume.js:",e)}return null},S=function(){return!!(u()&&u()<=4)||!!(c()&&c()<=4)},E=function(e,t){switch(e){case"slow-2g":case"2g":case"3g":return!0;default:return S()||t}},k=function(e){return parseFloat(e.toFixed(4))},M=function(e){return"number"!=typeof e?null:k(e/Math.pow(1024,2))},B=function(e,t,n,o,s){var d,h=function(){r.analyticsTracker&&(T.isHidden&&!["CLS","INP"].includes(e)||r.analyticsTracker({attribution:o,metricName:e,data:t,navigatorInformation:a?{deviceMemory:c()||0,hardwareConcurrency:u()||0,serviceWorkerStatus:"serviceWorker"in a?a.serviceWorker.controller?"controlled":"supported":"unsupported",isLowEndDevice:S(),isLowEndExperience:E(l,f)}:{},rating:n,navigationType:s}))};["CLS","INP"].includes(e)?h():(d=h,"requestIdleCallback"in i?i.requestIdleCallback(d,{timeout:3e3}):d())},R=function(e){e.forEach((function(e){if(!("self"!==e.name||e.startTime<p.value)){var t=e.duration-50;t>0&&(v.value+=t,y.value+=t)}}))};!function(e){e.instant="instant",e.quick="quick",e.moderate="moderate",e.slow="slow",e.unavoidable="unavoidable"}(t||(t={})),(n={})[t.instant]={vitalsThresholds:[100,200],maxOutlierThreshold:1e4},n[t.quick]={vitalsThresholds:[200,500],maxOutlierThreshold:1e4},n[t.moderate]={vitalsThresholds:[500,1e3],maxOutlierThreshold:1e4},n[t.slow]={vitalsThresholds:[1e3,2e3],maxOutlierThreshold:1e4},n[t.unavoidable]={vitalsThresholds:[2e3,5e3],maxOutlierThreshold:2e4};var A,C,_,I,x,L={RT:[100,200],TBT:[200,600],NTBT:[200,600]},O=function(e,t){return L[e]?t<=L[e][0]?"good":t<=L[e][1]?"needsImprovement":"poor":null},P=function(e,t,n){Object.keys(t).forEach((function(e){"number"==typeof t[e]&&(t[e]=k(t[e]))})),B(e,t,null,n||{})},D=function(e){var t=e.attribution,n=e.name,i=e.rating,o=e.value,a=e.navigationType;"FCP"===n&&(p.value=o),["FCP","LCP"].includes(n)&&!g[0]&&(g[0]=w("longtask",R)),"FID"===n&&setTimeout((function(){T.didChange||(D({attribution:t,name:"TBT",rating:O("TBT",v.value),value:v.value,navigationType:a}),P("dataConsumption",m.value))}),1e4);var s=k(o);s<=r.maxTime&&s>=0&&B(n,s,i,t,a)},F=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},q=function(e){if("loading"===document.readyState)return"loading";var t=F();if(t){if(e<t.domInteractive)return"loading";if(0===t.domContentLoadedEventStart||e<t.domContentLoadedEventStart)return"dom-interactive";if(0===t.domComplete||e<t.domComplete)return"dom-content-loaded"}return"complete"},j=function(e){var t=e.nodeName;return 1===e.nodeType?t.toLowerCase():t.toUpperCase().replace(/^#/,"")},U=function(e,t){var n="";try{for(;e&&9!==e.nodeType;){var r=e,i=r.id?"#"+r.id:j(r)+(r.className&&r.className.length?"."+r.className.replace(/\s+/g,"."):"");if(n.length+i.length>(t||100)-1)return n||i;if(n=n?i+">"+n:i,r.id)break;e=r.parentNode}}catch(e){}return n},N=-1,H=function(){return N},z=function(e){addEventListener("pageshow",(function(t){t.persisted&&(N=t.timeStamp,e(t))}),!0)},W=function(){var e=F();return e&&e.activationStart||0},V=function(e,t){var n=F(),r="navigate";return H()>=0?r="back-forward-cache":n&&(r=document.prerendering||W()>0?"prerender":document.wasDiscarded?"restore":n.type.replace(/_/g,"-")),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},G=function(e,t,n){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(e){}},J=function(e,t){var n=function n(r){"pagehide"!==r.type&&"hidden"!==document.visibilityState||(e(r),t&&(removeEventListener("visibilitychange",n,!0),removeEventListener("pagehide",n,!0)))};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},X=function(e,t,n,r){var i,o;return function(a){t.value>=0&&(a||r)&&((o=t.value-(i||0))||void 0===i)&&(i=t.value,t.delta=o,t.rating=function(e,t){return e>t[1]?"poor":e>t[0]?"needs-improvement":"good"}(t.value,n),e(t))}},$=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},Y=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},Z=-1,K=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},Q=function(e){"hidden"===document.visibilityState&&Z>-1&&(Z="visibilitychange"===e.type?e.timeStamp:0,te())},ee=function(){addEventListener("visibilitychange",Q,!0),addEventListener("prerenderingchange",Q,!0)},te=function(){removeEventListener("visibilitychange",Q,!0),removeEventListener("prerenderingchange",Q,!0)},ne=function(){return Z<0&&(Z=K(),ee(),z((function(){setTimeout((function(){Z=K(),ee()}),0)}))),{get firstHiddenTime(){return Z}}},re=function(e,t){t=t||{},Y((function(){var n,r=[1800,3e3],i=ne(),o=V("FCP"),a=G("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(a.disconnect(),e.startTime<i.firstHiddenTime&&(o.value=Math.max(e.startTime-W(),0),o.entries.push(e),n(!0)))}))}));a&&(n=X(e,o,r,t.reportAllChanges),z((function(i){o=V("FCP"),n=X(e,o,r,t.reportAllChanges),$((function(){o.value=performance.now()-i.timeStamp,n(!0)}))})))}))},ie={passive:!0,capture:!0},oe=new Date,ae=function(e,t){A||(A=t,C=e,_=new Date,ue(removeEventListener),se())},se=function(){if(C>=0&&C<_-oe){var e={entryType:"first-input",name:A.type,target:A.target,cancelable:A.cancelable,startTime:A.timeStamp,processingStart:A.timeStamp+C};I.forEach((function(t){t(e)})),I=[]}},ce=function(e){if(e.cancelable){var t=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,t){var n=function(){ae(e,t),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,ie),removeEventListener("pointercancel",r,ie)};addEventListener("pointerup",n,ie),addEventListener("pointercancel",r,ie)}(t,e):ae(t,e)}},ue=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(t){return e(t,ce,ie)}))},de=0,le=1/0,fe=0,he=function(e){e.forEach((function(e){e.interactionId&&(le=Math.min(le,e.interactionId),fe=Math.max(fe,e.interactionId),de=fe?(fe-le)/7+1:0)}))},pe=function(){return x?de:performance.interactionCount||0},me=0,ve=function(){return pe()-me},ye=[],ge={},Te=function(e){var t=ye[ye.length-1],n=ge[e.interactionId];if(n||ye.length<10||e.duration>t.latency){if(n)n.entries.push(e),n.latency=Math.max(n.latency,e.duration);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};ge[r.id]=r,ye.push(r)}ye.sort((function(e,t){return t.latency-e.latency})),ye.splice(10).forEach((function(e){delete ge[e.id]}))}},be={},we=function e(t){document.prerendering?Y((function(){return e(t)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(t)}),!0):setTimeout(t,0)},Se=function(e,t){t=t||{};var n=[800,1800],r=V("TTFB"),i=X(e,r,n,t.reportAllChanges);we((function(){var o=F();if(o){var a=o.responseStart;if(a<=0||a>performance.now())return;r.value=Math.max(a-W(),0),r.entries=[o],i(!0),z((function(){r=V("TTFB",0),(i=X(e,r,n,t.reportAllChanges))(!0)}))}}))},Ee=function(e){e.forEach((function(e){e.identifier&&D({attribution:{identifier:e.identifier},name:"ET",rating:null,value:e.startTime})}))},ke=function(e){e.forEach((function(e){if(r.isResourceTiming&&P("resourceTiming",e),e.decodedBodySize&&e.initiatorType){var t=e.decodedBodySize/1e3;m.value[e.initiatorType]+=t,m.value.total+=t}}))},Me=function(){!function(e,t){Se((function(e){!function(e){if(e.entries.length){var t=e.entries[0],n=t.activationStart||0,r=Math.max(t.domainLookupStart-n,0),i=Math.max(t.connectStart-n,0),o=Math.max(t.requestStart-n,0);e.attribution={waitingTime:r,dnsTime:i-r,connectionTime:o-i,requestTime:e.value-o,navigationEntry:t}}else e.attribution={waitingTime:0,dnsTime:0,connectionTime:0,requestTime:0}}(e),function(e){e.value>0&&D(e)}(e)}),t)}(0,r.reportOptions.ttfb),function(e,t){!function(e,t){t=t||{},Y((function(){var e,n=[.1,.25],r=V("CLS"),i=-1,o=0,a=[],s=function(e){i>-1&&function(e){!function(e){if(e.entries.length){var t=e.entries.reduce((function(e,t){return e&&e.value>t.value?e:t}));if(t&&t.sources&&t.sources.length){var n=(r=t.sources).find((function(e){return e.node&&1===e.node.nodeType}))||r[0];if(n)return void(e.attribution={largestShiftTarget:U(n.node),largestShiftTime:t.startTime,largestShiftValue:t.value,largestShiftSource:n,largestShiftEntry:t,loadState:q(t.startTime)})}}var r;e.attribution={}}(e),function(e){D(e)}(e)}(e)},c=function(t){t.forEach((function(t){if(!t.hadRecentInput){var n=a[0],i=a[a.length-1];o&&t.startTime-i.startTime<1e3&&t.startTime-n.startTime<5e3?(o+=t.value,a.push(t)):(o=t.value,a=[t]),o>r.value&&(r.value=o,r.entries=a,e())}}))},u=G("layout-shift",c);u&&(e=X(s,r,n,t.reportAllChanges),re((function(t){i=t.value,r.value<0&&(r.value=0,e())})),J((function(){c(u.takeRecords()),e(!0)})),z((function(){o=0,i=-1,r=V("CLS",0),e=X(s,r,n,t.reportAllChanges),$((function(){return e()}))})))}))}(0,t)}(0,r.reportOptions.cls),function(e,t){re((function(e){!function(e){if(e.entries.length){var t=F(),n=e.entries[e.entries.length-1];if(t){var r=t.activationStart||0,i=Math.max(0,t.responseStart-r);return void(e.attribution={timeToFirstByte:i,firstByteToFCP:e.value-i,loadState:q(e.entries[0].startTime),navigationEntry:t,fcpEntry:n})}}e.attribution={timeToFirstByte:0,firstByteToFCP:e.value,loadState:q(H())}}(e),function(e){D(e)}(e)}),t)}(0,r.reportOptions.fcp),function(e,t){!function(e,t){t=t||{},Y((function(){var n,r=[100,300],i=ne(),o=V("FID"),a=function(e){e.startTime<i.firstHiddenTime&&(o.value=e.processingStart-e.startTime,o.entries.push(e),n(!0))},s=function(e){e.forEach(a)},c=G("first-input",s);n=X(e,o,r,t.reportAllChanges),c&&J((function(){s(c.takeRecords()),c.disconnect()}),!0),c&&z((function(){var i;o=V("FID"),n=X(e,o,r,t.reportAllChanges),I=[],C=-1,A=null,ue(addEventListener),i=a,I.push(i),se()}))}))}((function(e){!function(e){var t=e.entries[0];e.attribution={eventTarget:U(t.target),eventType:t.name,eventTime:t.startTime,eventEntry:t,loadState:q(t.startTime)}}(e),function(e){D(e)}(e)}),t)}(0,r.reportOptions.fid),function(e,t){!function(e,t){t=t||{},Y((function(){var n,r=[2500,4e3],i=ne(),o=V("LCP"),a=function(e){var t=e[e.length-1];if(t){var r=Math.max(t.startTime-W(),0);r<i.firstHiddenTime&&(o.value=r,o.entries=[t],n())}},s=G("largest-contentful-paint",a);if(s){n=X(e,o,r,t.reportAllChanges);var c=function(){be[o.id]||(a(s.takeRecords()),s.disconnect(),be[o.id]=!0,n(!0))};["keydown","click"].forEach((function(e){addEventListener(e,c,{once:!0,capture:!0})})),J(c,!0),z((function(i){o=V("LCP"),n=X(e,o,r,t.reportAllChanges),$((function(){o.value=performance.now()-i.timeStamp,be[o.id]=!0,n(!0)}))}))}}))}((function(e){!function(e){if(e.entries.length){var t=F();if(t){var n=t.activationStart||0,r=e.entries[e.entries.length-1],i=r.url&&performance.getEntriesByType("resource").filter((function(e){return e.name===r.url}))[0],o=Math.max(0,t.responseStart-n),a=Math.max(o,i?(i.requestStart||i.startTime)-n:0),s=Math.max(a,i?i.responseEnd-n:0),c=Math.max(s,r?r.startTime-n:0),u={element:U(r.element),timeToFirstByte:o,resourceLoadDelay:a-o,resourceLoadTime:s-a,elementRenderDelay:c-s,navigationEntry:t,lcpEntry:r};return r.url&&(u.url=r.url),i&&(u.lcpResourceEntry=i),void(e.attribution=u)}}e.attribution={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadTime:0,elementRenderDelay:e.value}}(e),function(e){D(e)}(e)}),t)}(0,r.reportOptions.lcp),function(e,t){!function(e,t){t=t||{},Y((function(){var n=[200,500];"interactionCount"in performance||x||(x=G("event",he,{type:"event",buffered:!0,durationThreshold:0}));var r,i=V("INP"),o=function(e){e.forEach((function(e){e.interactionId&&Te(e),"first-input"===e.entryType&&!ye.some((function(t){return t.entries.some((function(t){return e.duration===t.duration&&e.startTime===t.startTime}))}))&&Te(e)}));var t,n=(t=Math.min(ye.length-1,Math.floor(ve()/50)),ye[t]);n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())},a=G("event",o,{durationThreshold:t.durationThreshold||40});r=X(e,i,n,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),J((function(){o(a.takeRecords()),i.value<0&&ve()>0&&(i.value=0,i.entries=[]),r(!0)})),z((function(){ye=[],me=pe(),i=V("INP"),r=X(e,i,n,t.reportAllChanges)})))}))}((function(t){!function(e){if(e.entries.length){var t=e.entries.sort((function(e,t){return t.duration-e.duration||t.processingEnd-t.processingStart-(e.processingEnd-e.processingStart)}))[0];e.attribution={eventTarget:U(t.target),eventType:t.name,eventTime:t.startTime,eventEntry:t,loadState:q(t.startTime)}}else e.attribution={}}(t),e(t)}),t)}((function(e){return D(e)}),r.reportOptions.inp),r.isResourceTiming&&w("resource",ke),r.isElementTiming&&w("element",Ee)},Be=function(e){var t="usageDetails"in e?e.usageDetails:{};P("storageEstimate",{quota:M(e.quota),usage:M(e.usage),caches:M(t.caches),indexedDB:M(t.indexedDB),serviceWorker:M(t.serviceWorkerRegistrations)})},Re={finalMarkToStepsMap:{},startMarkToStepsMap:{},active:{},navigationSteps:{}},Ae=0,Ce=function(){function e(e){if(void 0===e&&(e={}),this.v="9.0.0-rc.3",r.analyticsTracker=e.analyticsTracker,r.isResourceTiming=!!e.resourceTiming,r.isElementTiming=!!e.elementTiming,r.maxTime=e.maxMeasureTime||r.maxTime,r.reportOptions=e.reportOptions||r.reportOptions,r.steps=e.steps,r.onMarkStep=e.onMarkStep,r.enableNavigationTracking=e.enableNavigationTracking,d()){"PerformanceObserver"in i&&Me(),void 0!==document.hidden&&document.addEventListener("visibilitychange",b);var t=function(){if(!d())return{};var e=s.getEntriesByType("navigation")[0];if(!e)return{};var t=e.responseStart,n=e.responseEnd;return{fetchTime:n-e.fetchStart,workerTime:e.workerStart>0?n-e.workerStart:0,totalTime:n-e.requestStart,downloadTime:n-t,timeToFirstByte:t-e.requestStart,headerSize:e.transferSize-e.encodedBodySize||0,dnsLookupTime:e.domainLookupEnd-e.domainLookupStart,redirectTime:e.redirectEnd-e.redirectStart}}();P("navigationTiming",t),t.redirectTime&&D({attribution:{},name:"RT",rating:O("RT",t.redirectTime),value:t.redirectTime}),P("networkInformation",function(){if("connection"in a){var e=a.connection;return"object"!=typeof e?{}:(l=e.effectiveType,f=!!e.saveData,{downlink:e.downlink,effectiveType:e.effectiveType,rtt:e.rtt,saveData:!!e.saveData})}return{}}()),a&&a.storage&&"function"==typeof a.storage.estimate&&a.storage.estimate().then(Be),r.steps&&r.steps&&(Re.startMarkToStepsMap={},Re.finalMarkToStepsMap={},Re.active={},Re.navigationSteps={},Object.entries(r.steps).forEach((function(e){var t,n,r=e[0],i=e[1].marks,o=i[0],a=i[1],s=null!==(n=Re.startMarkToStepsMap[o])&&void 0!==n?n:{};if(s[r]=!0,Re.startMarkToStepsMap[o]=s,Re.finalMarkToStepsMap[a]){var c=Re.finalMarkToStepsMap[a][o]||[];c.push(r),Re.finalMarkToStepsMap[a][o]=c}else Re.finalMarkToStepsMap[a]=((t={})[o]=[r],t)})))}}return e.prototype.start=function(e){d()&&!h[e]&&(h[e]=!0,s.mark("mark_".concat(e,"_start")))},e.prototype.end=function(e,t,n){if(void 0===t&&(t={}),void 0===n&&(n=!0),d()&&h[e]){s.mark("mark_".concat(e,"_end")),delete h[e];var r=function(e){s.measure(e,"mark_".concat(e,"_start"),"mark_".concat(e,"_end"));var t=s.getEntriesByName(e).pop();return t&&"measure"===t.entryType?t.duration:-1}(e);n&&P(e,k(r),t)}},e.prototype.endPaint=function(e,t){var n=this;setTimeout((function(){n.end(e,t)}))},e.prototype.clear=function(e){delete h[e],s.clearMarks&&(s.clearMarks("mark_".concat(e,"_start")),s.clearMarks("mark_".concat(e,"_end")))},e.prototype.markNTBT=function(){var e=this;this.start("ntbt"),y.value=0,clearTimeout(Ae),Ae=setTimeout((function(){e.end("ntbt",{},!1),D({attribution:{},name:"NTBT",rating:O("NTBT",y.value),value:y.value}),y.value=0}),2e3)},e}(),_e="undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof self&&self||void 0!==e.g&&e.g||{},Ie="URLSearchParams"in _e,xe="Symbol"in _e&&"iterator"in Symbol,Le="FileReader"in _e&&"Blob"in _e&&function(){try{return new Blob,!0}catch(e){return!1}}(),Oe="FormData"in _e,Pe="ArrayBuffer"in _e;if(Pe)var De=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],Fe=ArrayBuffer.isView||function(e){return e&&De.indexOf(Object.prototype.toString.call(e))>-1};function qe(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||""===e)throw new TypeError('Invalid character in header field name: "'+e+'"');return e.toLowerCase()}function je(e){return"string"!=typeof e&&(e=String(e)),e}function Ue(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return xe&&(t[Symbol.iterator]=function(){return t}),t}function Ne(e){this.map={},e instanceof Ne?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){if(2!=e.length)throw new TypeError("Headers constructor: expected name/value pair to be length 2, found"+e.length);this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function He(e){if(!e._noBody)return e.bodyUsed?Promise.reject(new TypeError("Already read")):void(e.bodyUsed=!0)}function ze(e){return new Promise((function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}}))}function We(e){var t=new FileReader,n=ze(t);return t.readAsArrayBuffer(e),n}function Ve(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function Ge(){return this.bodyUsed=!1,this._initBody=function(e){var t;this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:Le&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:Oe&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:Ie&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():Pe&&Le&&(t=e)&&DataView.prototype.isPrototypeOf(t)?(this._bodyArrayBuffer=Ve(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):Pe&&(ArrayBuffer.prototype.isPrototypeOf(e)||Fe(e))?this._bodyArrayBuffer=Ve(e):this._bodyText=e=Object.prototype.toString.call(e):(this._noBody=!0,this._bodyText=""),this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):Ie&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},Le&&(this.blob=function(){var e=He(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))}),this.arrayBuffer=function(){if(this._bodyArrayBuffer)return He(this)||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer));if(Le)return this.blob().then(We);throw new Error("could not read as ArrayBuffer")},this.text=function(){var e,t,n,r,i,o=He(this);if(o)return o;if(this._bodyBlob)return e=this._bodyBlob,n=ze(t=new FileReader),i=(r=/charset=([A-Za-z0-9_-]+)/.exec(e.type))?r[1]:"utf-8",t.readAsText(e,i),n;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),n=new Array(t.length),r=0;r<t.length;r++)n[r]=String.fromCharCode(t[r]);return n.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},Oe&&(this.formData=function(){return this.text().then($e)}),this.json=function(){return this.text().then(JSON.parse)},this}Ne.prototype.append=function(e,t){e=qe(e),t=je(t);var n=this.map[e];this.map[e]=n?n+", "+t:t},Ne.prototype.delete=function(e){delete this.map[qe(e)]},Ne.prototype.get=function(e){return e=qe(e),this.has(e)?this.map[e]:null},Ne.prototype.has=function(e){return this.map.hasOwnProperty(qe(e))},Ne.prototype.set=function(e,t){this.map[qe(e)]=je(t)},Ne.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)},Ne.prototype.keys=function(){var e=[];return this.forEach((function(t,n){e.push(n)})),Ue(e)},Ne.prototype.values=function(){var e=[];return this.forEach((function(t){e.push(t)})),Ue(e)},Ne.prototype.entries=function(){var e=[];return this.forEach((function(t,n){e.push([n,t])})),Ue(e)},xe&&(Ne.prototype[Symbol.iterator]=Ne.prototype.entries);var Je=["CONNECT","DELETE","GET","HEAD","OPTIONS","PATCH","POST","PUT","TRACE"];function Xe(e,t){if(!(this instanceof Xe))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');var n,r,i=(t=t||{}).body;if(e instanceof Xe){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new Ne(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,i||null==e._bodyInit||(i=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new Ne(t.headers)),this.method=(r=(n=t.method||this.method||"GET").toUpperCase(),Je.indexOf(r)>-1?r:n),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal||function(){if("AbortController"in _e)return(new AbortController).signal}(),this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(i),!("GET"!==this.method&&"HEAD"!==this.method||"no-store"!==t.cache&&"no-cache"!==t.cache)){var o=/([?&])_=[^&]*/;o.test(this.url)?this.url=this.url.replace(o,"$1_="+(new Date).getTime()):this.url+=(/\?/.test(this.url)?"&":"?")+"_="+(new Date).getTime()}}function $e(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var n=e.split("="),r=n.shift().replace(/\+/g," "),i=n.join("=").replace(/\+/g," ");t.append(decodeURIComponent(r),decodeURIComponent(i))}})),t}function Ye(e,t){if(!(this instanceof Ye))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');if(t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.status<200||this.status>599)throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");this.ok=this.status>=200&&this.status<300,this.statusText=void 0===t.statusText?"":""+t.statusText,this.headers=new Ne(t.headers),this.url=t.url||"",this._initBody(e)}Xe.prototype.clone=function(){return new Xe(this,{body:this._bodyInit})},Ge.call(Xe.prototype),Ge.call(Ye.prototype),Ye.prototype.clone=function(){return new Ye(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new Ne(this.headers),url:this.url})},Ye.error=function(){var e=new Ye(null,{status:200,statusText:""});return e.status=0,e.type="error",e};var Ze=[301,302,303,307,308];Ye.redirect=function(e,t){if(-1===Ze.indexOf(t))throw new RangeError("Invalid status code");return new Ye(null,{status:t,headers:{location:e}})};var Ke=_e.DOMException;try{new Ke}catch(e){(Ke=function(e,t){this.message=e,this.name=t;var n=Error(e);this.stack=n.stack}).prototype=Object.create(Error.prototype),Ke.prototype.constructor=Ke}function Qe(e,t){return new Promise((function(n,r){var i=new Xe(e,t);if(i.signal&&i.signal.aborted)return r(new Ke("Aborted","AbortError"));var o=new XMLHttpRequest;function a(){o.abort()}if(o.onload=function(){var e=o.getAllResponseHeaders(),t=o.getResponseHeader("set-cookie");t&&(e=e.replace(t,t.replace(/\r?\n/g,", ")));var r,i,a={status:o.status,statusText:o.statusText,headers:(r=e||"",i=new Ne,r.replace(/\r?\n[\t ]+/g," ").split("\r").map((function(e){return 0===e.indexOf("\n")?e.substr(1,e.length):e})).forEach((function(e){var t=e.split(":"),n=t.shift().trim();if(n){var r=t.join(":").trim();try{i.append(n,r)}catch(e){console.warn("Response "+e.message)}}})),i)};a.url="responseURL"in o?o.responseURL:a.headers.get("X-Request-URL");var s="response"in o?o.response:o.responseText;setTimeout((function(){n(new Ye(s,a))}),0)},o.onerror=function(){setTimeout((function(){r(new TypeError("Network request failed"))}),0)},o.ontimeout=function(){setTimeout((function(){r(new TypeError("Network request failed"))}),0)},o.onabort=function(){setTimeout((function(){r(new Ke("Aborted","AbortError"))}),0)},o.open(i.method,function(e){try{return""===e&&_e.location.href?_e.location.href:e}catch(t){return e}}(i.url),!0),"include"===i.credentials?o.withCredentials=!0:"omit"===i.credentials&&(o.withCredentials=!1),"responseType"in o&&(Le?o.responseType="blob":Pe&&(o.responseType="arraybuffer")),t&&"object"==typeof t.headers&&!(t.headers instanceof Ne||_e.Headers&&t.headers instanceof _e.Headers)){var s=[];Object.getOwnPropertyNames(t.headers).forEach((function(e){s.push(qe(e)),o.setRequestHeader(e,je(t.headers[e]))})),i.headers.forEach((function(e,t){-1===s.indexOf(t)&&o.setRequestHeader(t,e)}))}else i.headers.forEach((function(e,t){o.setRequestHeader(t,e)}));i.signal&&(i.signal.addEventListener("abort",a),o.onreadystatechange=function(){4===o.readyState&&i.signal.removeEventListener("abort",a)}),o.send(void 0===i._bodyInit?null:i._bodyInit)}))}Qe.polyfill=!0,_e.fetch||(_e.fetch=Qe,_e.Headers=Ne,_e.Request=Xe,_e.Response=Ye);try{window.clWebVitals={dt:null,clId:"62c50da5396c42c0862fbd8cd308a7f2",apiUrl:"https://xray.cloudlinux.com/api/xray/web-vitals",requestId:null,processTimeout:6e4,intervalId:null,intervalToSend:5e3,generalMetrics:[],cssResourceMetrics:[],collectedCSSResources:0,neededCSSResources:3,sentCss:!1,imgResourceMetrics:[],collectedImgResources:0,neededImgResources:5,neededImgSize:2e5,sentImg:!1,init:function(){"#cl_id#"!==this.clId&&0!==this.clId.length&&(this.setDt(),this.setRequestId(),this.setEvents(),this.initTimer(),this.initPerfume())},setDt:function(){var e=new Date,t=e.getFullYear(),n=String(e.getMonth()+1).padStart(2,"0"),r=String(e.getDate()).padStart(2,"0"),i=String(e.getHours()).padStart(2,"0"),o=String(e.getMinutes()).padStart(2,"0"),a=String(e.getSeconds()).padStart(2,"0");this.dt=t+"-"+n+"-"+r+" "+i+":"+o+":"+a},setRequestId:function(){this.requestId=Date.now().toString()+"_"+(Math.random()+1).toString(36).substring(2)},setEvents:function(){var e=this;window.addEventListener("beforeunload",(function(t){e.send(!0)}))},initTimer:function(){var e=this;this.intervalId=setInterval((function(){e.send()}),this.intervalToSend),setTimeout((function(){e.intervalId&&(clearInterval(e.intervalId),e.intervalId=null)}),this.processTimeout)},initPerfume:function(){var e=this;new Ce({resourceTiming:!0,elementTiming:!0,maxMeasureTime:this.processTimeout,analyticsTracker:function(t){if(void 0!==t.metricName&&(void 0===t.data||void 0===t.data.name||t.data.name!==e.apiUrl))switch(t.metricName.toLowerCase()){case"fp":case"fcp":case"fid":case"lcp":case"cls":case"clsfinal":case"tbt":case"ttfb":e.collect(t);break;case"resourcetiming":void 0!==t.data.initiatorType&&("link"===t.data.initiatorType&&"string"==typeof t.data.name&&t.data.name.includes(".css")||"img"===t.data.initiatorType&&"number"==typeof t.data.decodedBodySize&&t.data.decodedBodySize>=e.neededImgSize&&"string"==typeof t.data.name&&!t.data.name.includes(".webp"))&&e.collect(t,t.data.initiatorType);break;default:return}}})},collect:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];switch(void 0!==e.navigationEntry&&"string"==typeof e.navigationEntry.name?e.url=e.navigationEntry.name:void 0!==e.data.name&&"string"==typeof e.data.name?e.url=e.data.name:e.url=window.location.href,e.id=this.clId,e.dt=this.dt,e.requestId=this.requestId,e.timestamp=Date.now(),e.windowWidth=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,e.windowHeight=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,t){case"link":this.collectedCSSResources++,this.cssResourceMetrics.push(e);break;case"img":this.collectedImgResources++,this.imgResourceMetrics.push(e);break;default:this.generalMetrics.push(e)}},send:function(){if(!0===(arguments.length>0&&void 0!==arguments[0]&&arguments[0])||!1===this.sentCss&&this.collectedCSSResources>=this.neededCSSResources||!1===this.sentImg&&this.collectedImgResources>=this.neededImgResources){this.cssResourceMetrics.length>0&&(this.cssResourceMetrics.sort(this.compareResources),this.cssResourceMetrics=this.cssResourceMetrics.slice(0,this.neededCSSResources),this.sentCss=!0),this.imgResourceMetrics.length>0&&(this.imgResourceMetrics.sort(this.compareResources),this.imgResourceMetrics=this.imgResourceMetrics.slice(0,this.neededImgResources),this.sentImg=!0);var e=this.generalMetrics.concat(this.cssResourceMetrics,this.imgResourceMetrics);if(0===e.length)return;var t=JSON.stringify({data:e});this.generalMetrics=[],this.cssResourceMetrics=[],this.imgResourceMetrics=[],window.fetch(this.apiUrl,{method:"POST",headers:{"Content-Type":"application/json"},body:t}).then()}},compareResources:function(e,t){return e.data.decodedBodySize<t.data.decodedBodySize?1:e.data.decodedBodySize>t.data.decodedBodySize?-1:0}},clWebVitals.init()}catch(e){console.log(e)}})();</script></body>
</html>