section
stringlengths
2
30
filename
stringlengths
1
82
text
stringlengths
783
28M
extractor
arkena
# coding: utf-8 from __future__ import unicode_literals import re from ..compat import compat_urlparse from ..utils import ExtractorError, float_or_none, int_or_none, parse_iso8601, try_get from .common import InfoExtractor class ArkenaIE(InfoExtractor): _VALID_URL = r"""(?x) https?:// ...
KindleUnpack
compatibility_utils
#!/usr/bin/env python # -*- coding: utf-8 -*- # vim:ts=4:sw=4:softtabstop=4:smarttab:expandtab # Copyright (c) 2014 Kevin B. Hendricks, John Schember, and Doug Massay # All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, # are permitted provided that the following ...
src
l10n
"""Localization helpers""" import logging import os import re import sys import time from bmconfigparser import config from six.moves import range logger = logging.getLogger("default") DEFAULT_ENCODING = "ISO8859-1" DEFAULT_LANGUAGE = "en_US" DEFAULT_TIME_FORMAT = "%Y-%m-%d %H:%M:%S" try: import locale en...
model
resource
# encoding: utf-8 from __future__ import annotations import datetime from collections import OrderedDict from typing import Any, Callable, ClassVar, Optional import ckan.model.core as core import ckan.model.domain_object as domain_object import ckan.model.meta as meta import ckan.model.types as _types from ckan.commo...
Scripts
instrumentSends
""" Warning: this script uses an undocumented, private API of the Objective-C runtime. It sometimes is useful to see which Objective-C methods are called in a program. Luckily the Objective-C runtime contains a private API for logging all method calls. This file shows how to call that API. """ import Foundation import...
autokey
setup
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright (C) 2011 Chris Dekter # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any lat...
gui-qt
dictionaries_widget
import os from contextlib import contextmanager from plover import _ from plover.config import DictionaryConfig from plover.dictionary.base import create_dictionary from plover.engine import ErroredDictionary from plover.gui_qt.dictionaries_widget_ui import Ui_DictionariesWidget from plover.gui_qt.dictionary_editor im...
VersionUpgrade30to31
VersionUpgrade30to31
# Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. import configparser # To parse preference files. import io # To serialise the preference files afterwards. from typing import Dict, List, Set, Tuple from UM.VersionUpgrade import VersionUpgrade # We're inheriting from t...
gui-qt
main
import signal import sys from pathlib import Path from plover import _ from plover import __name__ as __software_name__ from plover import __version__, log from plover.gui_qt.engine import Engine from plover.oslayer.config import CONFIG_DIR from plover.oslayer.keyboardcontrol import KeyboardEmulation from PyQt5.QtCore...
generated
index
#!/usr/bin/env python """ Generated Mon Feb 9 19:08:05 2009 by generateDS.py. """ import os import sys from xml.dom import minidom from . import compound from . import indexsuper as supermod class DoxygenTypeSub(supermod.DoxygenType): def __init__(self, version=None, compound=None): supermod.DoxygenTy...
PyObjCTest
test_nshttpcookie
from Foundation import * from PyObjCTools.TestSupport import * try: unicode except NameError: unicode = str class TestNSHTTPCookie(TestCase): def testConstants(self): self.assertIsInstance(NSHTTPCookieName, unicode) self.assertIsInstance(NSHTTPCookieValue, unicode) self.assertIsIn...
formats
_audio
# Copyright 2004-2005 Joe Wreschnig, Michael Urman # 2012-2022 Nick Boultbee # 2022 Jej@github # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the ...
quodlibet
_main
# Copyright 2012 Christoph Reiter # 2020 Nick Boultbee # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. impo...
Base
Drillable
import math import FreeCAD as App import numpy import Part import Path if False: Path.Log.setLevel(Path.Log.Level.DEBUG, Path.Log.thisModule()) Path.Log.trackModule(Path.Log.thisModule()) else: Path.Log.setLevel(Path.Log.Level.INFO, Path.Log.thisModule()) def checkForBlindHole(baseshape, selectedFace): ...
clientScripts
manual_normalization_check_for_manual_normalization_directory
#!/usr/bin/env python # This file is part of Archivematica. # # Copyright 2010-2013 Artefactual Systems Inc. <http://artefactual.com> # # Archivematica is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, ei...
plugin-base
item_list
from __future__ import absolute_import import os import urllib.parse from gi.repository import Gdk, Gtk from sunflower import common from sunflower.accelerator_group import AcceleratorGroup from sunflower.gui.history_list import HistoryList from sunflower.gui.input_dialog import ( CopyDialog, InputDialog, ...
extractor
tinypic
from __future__ import unicode_literals import re from ..utils import ExtractorError from .common import InfoExtractor class TinyPicIE(InfoExtractor): IE_NAME = "tinypic" IE_DESC = "tinypic.com videos" _VALID_URL = r"https?://(?:.+?\.)?tinypic\.com/player\.php\?v=(?P<id>[^&]+)&s=\d+" _TESTS = [ ...
core
actor
# ruff: noqa: ARG002 from __future__ import annotations import itertools import logging from collections.abc import Iterable from pathlib import Path from typing import TYPE_CHECKING, Optional import mopidy import pykka from mopidy import audio, backend, mixer from mopidy.audio import PlaybackState from mopidy.core....
songsmenu
albumart
# Copyright 2005 Eduardo Gonzalez <wm.eddie@gmail.com>, Niklas Janlert # 2006 Joe Wreschnig # 2008 Antonio Riva, Eduardo Gonzalez <wm.eddie@gmail.com>, # Anthony Bretaudeau <wxcover@users.sourceforge.net>, # 2010 Aymeric Mansoux <aymeric@goto10.org> # 2008-2013 Chr...
extractor
jwplatform
# coding: utf-8 from __future__ import unicode_literals import re from ..utils import unsmuggle_url from .common import InfoExtractor class JWPlatformIE(InfoExtractor): _VALID_URL = r"(?:https?://(?:content\.jwplatform|cdn\.jwplayer)\.com/(?:(?:feed|player|thumb|preview)s|jw6|v2/media)/|jwplatform:)(?P<id>[a-zA...
sabnzbd
zconfig
#!/usr/bin/python3 -OO # Copyright 2007-2023 The SABnzbd-Team (sabnzbd.org) # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later ver...
frescobaldi-app
quickremove
# This file is part of the Frescobaldi project, http://www.frescobaldi.org/ # # Copyright (c) 2013 - 2014 by Wilbert Berendsen # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 ...
BOPTools
SplitFeatures
# /*************************************************************************** # * Copyright (c) 2016 Victor Titov (DeepSOIC) <vv.titov@gmail.com> * # * * # * This file is part of the FreeCAD CAx development system. * # * ...
gpodder
directory
# -*- coding: utf-8 -*- # # gPodder - A media aggregator and podcast client # Copyright (c) 2005-2018 The gPodder Team # # gPodder is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the Licens...
graphs
tummytime_duration
# -*- coding: utf-8 -*- import plotly.graph_objs as go import plotly.offline as plotly from core.utils import duration_parts from django.db.models import Count, Sum from django.db.models.functions import TruncDate from django.utils.translation import gettext as _ from reports import utils def tummytime_duration(insta...
qtgui
dialgauge
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright 2020 Free Software Foundation, Inc. # # This file is part of GNU Radio # # SPDX-License-Identifier: GPL-3.0-or-later # # import sys import pmt from gnuradio import gr from PyQt5 import QtCore from PyQt5.QtCore import Qt as Qtc from PyQt5.QtGui import QColor,...
Part
InitGui
# *************************************************************************** # * Copyright (c) 2002 Juergen Riegel <juergen.riegel@web.de> * # * * # * This file is part of the FreeCAD CAx development system. * # * ...
extractors
pinterest
#!/usr/bin/env python from ..common import * from ..extractor import VideoExtractor class Pinterest(VideoExtractor): # site name name = "Pinterest" # ordered list of supported stream types / qualities on this site # order: high quality -> low quality stream_types = [ {"id": "original"}, ...
extractor
cbslocal
# coding: utf-8 from __future__ import unicode_literals from ..compat import compat_urlparse from ..utils import parse_iso8601, unified_timestamp from .anvato import AnvatoIE from .sendtonews import SendtoNewsIE class CBSLocalIE(AnvatoIE): _VALID_URL_BASE = r"https?://[a-z]+\.cbslocal\.com/" _VALID_URL = _VA...
actions
activitypropertypage
from gaphor import UML from gaphor.core import transactional from gaphor.core.format import format, parse from gaphor.diagram.propertypages import ( EditableTreeModel, PropertyPageBase, PropertyPages, handler_blocking, help_link, ) from gaphor.diagram.propertypages import new_builder as diagram_new_...
canto-curses
color
# -*- coding: utf-8 -*- # Canto-curses - ncurses RSS reader # Copyright (C) 2016 Jack Miller <jack@codezen.org> # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. from canto_ne...
frescobaldi-app
reformat
# This file is part of the Frescobaldi project, http://www.frescobaldi.org/ # # Copyright (c) 2008 - 2014 by Wilbert Berendsen # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 ...
extractor
udemy
from __future__ import unicode_literals import re from ..compat import ( compat_HTTPError, compat_kwargs, compat_str, compat_urllib_request, compat_urlparse, ) from ..utils import ( ExtractorError, determine_ext, extract_attributes, float_or_none, int_or_none, js_to_json, ...
slack
slack_formatter
import re import emoji from slackviewer.formatter import SlackFormatter as SlackFormatterBase class SlackFormatter(SlackFormatterBase): _LINK_PAT = re.compile( r"<(https|http|mailto):[A-Za-z0-9_\.\-\/\?\,\=\#\:\@\& ]+\|[^>]+>" ) def __init__(self, organization): self.__ORGANIZATION = org...
extractor
chaturbate
from __future__ import unicode_literals import re from ..utils import ExtractorError, lowercase_escape, url_or_none from .common import InfoExtractor class ChaturbateIE(InfoExtractor): _VALID_URL = r"https?://(?:[^/]+\.)?chaturbate\.com/(?:fullvideo/?\?.*?\bb=)?(?P<id>[^/?&#]+)" _TESTS = [ { ...
draftfunctions
join
# *************************************************************************** # * Copyright (c) 2009, 2010 Yorik van Havre <yorik@uncreated.net> * # * Copyright (c) 2009, 2010 Ken Cline <cline@frii.com> * # * Copyright (c) 2020 FreeCAD Developers * # * ...
sk1
app_actions
# -*- coding: utf-8 -*- # # Copyright (C) 2013-2018 by Ihor E. Novikov # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later ver...
externals
gi_composites
# # Copyright (C) 2015 Dustin Spicuzza <dustin@virtualroadside.com> # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either # version 2.1 of the License, or (at your option) any later ve...
JtReader
InitGui
# *************************************************************************** # * Copyright (c) 2002,2003 Juergen Riegel <juergen.riegel@web.de> * # * * # * This file is part of the FreeCAD CAx development system. * # * ...
util
namegenerator
#!/usr/bin/python3 # -*- coding: utf-8 -*- # # SoundConverter - GNOME application for converting between audio formats. # Copyright 2004 Lars Wirzenius # Copyright 2005-2020 Gautier Portet # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as ...
osf
protocol
#!/usr/bin/env python # -*- coding: utf-8 -*- # Dissemin: open access policy enforcement tool # Copyright (C) 2014 Antonin Delpeuch # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU Affero General Public License # as published by the Free Software Foundation; eith...
plugins
vinhlongtv
""" $description Vietnamese live TV channels from THVL, including THVL1, THVL2, THVL3 and THVL4. $url thvli.vn $type live $metadata id $metadata title $region Vietnam """ import logging import re from datetime import datetime, timezone from hashlib import md5 from streamlink.plugin import Plugin, pluginmatcher from s...
design
filter_design
# Copyright 2012 Free Software Foundation, Inc. # # This file is part of GNU Radio # # SPDX-License-Identifier: GPL-3.0-or-later # # import copy import csv import os import re import sys import warnings from optparse import OptionParser from gnuradio import fft, filter from .CustomViewBox import CustomViewBox try: ...
uic-files
main_window_view_rc
# -*- coding: utf-8 -*- # Resource object code # # Created by: The Resource Compiler for PyQt5 (Qt v5.11.2) # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore qt_resource_data = b"\ \x00\x00\x1e\x17\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x80\x...
invesalius
i18n
# -*- coding: UTF-8 -*- # -------------------------------------------------------------------------- # Software: InVesalius - Software de Reconstrucao 3D de Imagens Medicas # Copyright: (C) 2001 Centro de Pesquisas Renato Archer # Homepage: http://www.softwarepublico.gov.br # Contact: invesalius@cti.g...
devscripts
prepare_manpage
from __future__ import unicode_literals import optparse import os.path import re from utils import read_file, write_file ROOT_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) README_FILE = os.path.join(ROOT_DIR, "README.md") PREFIX = r"""%YOUTUBE-DL(1) # NAME youtube\-dl \- download videos from yo...
draftguitools
gui_edit_arch_objects
# *************************************************************************** # * Copyright (c) 2009, 2010 Yorik van Havre <yorik@uncreated.net> * # * Copyright (c) 2009, 2010 Ken Cline <cline@frii.com> * # * Copyright (c) 2019, 2020 Carlo Pavan <carlopav@gmail.com> * # * ...
lib
app_globals
# encoding: utf-8 """ The application's Globals object """ from __future__ import annotations import logging from threading import Lock from typing import Any, Union import ckan import ckan.model as model from ckan.common import asbool, aslist, config from ckan.lib.webassets_tools import is_registered from ckan.logi...
const
locales
# -*- coding: utf-8 -*- # # Picard, the next-generation MusicBrainz tagger # # Copyright (C) 2007 Lukáš Lalinský # Copyright (C) 2014, 2020 Laurent Monin # Copyright (C) 2017 Sambhav Kothari # Copyright (C) 2019 Philipp Wolfer # # This program is free software; you can redistribute it and/or # modify it under the terms...
chardet
euckrprober
######################## BEGIN LICENSE BLOCK ######################## # The Original Code is mozilla.org code. # # The Initial Developer of the Original Code is # Netscape Communications Corporation. # Portions created by the Initial Developer are Copyright (C) 1998 # the Initial Developer. All Rights Reserved. # # Con...
PyObjCTest
test_set_property
import pickle import sys import objc from PyObjCTest.test_object_property import OCObserve from PyObjCTools.TestSupport import * NSObject = objc.lookUpClass("NSObject") class TestSetPropertyHelper(NSObject): aSet = objc.set_property() aSet2 = objc.set_property() aROSet = objc.set_property(read_only=True...
api
system
__license__ = "GNU Affero General Public License http://www.gnu.org/licenses/agpl.html" __copyright__ = "Copyright (C) 2015 The OctoPrint Project - Released under terms of the AGPLv3 License" import collections import logging import re import threading import psutil from flask import abort, jsonify, request, url_for ...
cli
jobs
# encoding: utf-8 from __future__ import annotations import ckan.lib.jobs as bg_jobs import ckan.logic as logic import click from ckan.cli import error_shout @click.group(name="jobs", short_help="Manage background jobs.") def jobs(): pass @jobs.command( short_help="Start a worker.", ) @click.option("--burs...
stargate
audio_inputs
from sglib.lib import * from sglib.lib.util import * class AudioInputTracks: def add_track(self, a_index, a_track): self.tracks[a_index] = a_track def __init__(self): self.tracks = {} def __str__(self): f_result = [] for k, v in list(self.tracks.items()): f_re...
extractor
abc
from __future__ import unicode_literals import hashlib import hmac import re import time from ..compat import compat_str from ..utils import ( ExtractorError, int_or_none, js_to_json, parse_iso8601, try_get, unescapeHTML, update_url_query, ) from .common import InfoExtractor class ABCIE(...
archivebox
util
__package__ = "archivebox" import json as pyjson import re from datetime import datetime, timezone from functools import wraps from hashlib import sha256 from html import escape, unescape from inspect import signature from os import remove as remove_file from os.path import lexists from pathlib import Path from typing...
anchor-generators
multiple_grid_anchor_generator_test
# Copyright 2017 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
playlists
prefs
# Copyright 2016 Nick Boultbee # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. from gi.repository import Gtk from quo...
alembicrepo
env
from __future__ import with_statement from alembic import context from sqlalchemy import engine_from_config, pool # from logging.config import fileConfig # this is the Alembic Config object, which provides # access to the values within the .ini file in use. config = context.config # Interpret the config file for Py...
draftguitools
gui_grid
# *************************************************************************** # * (c) 2009, 2010 Yorik van Havre <yorik@uncreated.net> * # * (c) 2009, 2010 Ken Cline <cline@frii.com> * # * (c) 2020 Eliud Cabrera Castillo <e.cabrera-castillo@tum.de> * # * ...
apscheduler
events
__all__ = ( "EVENT_SCHEDULER_STARTED", "EVENT_SCHEDULER_SHUTDOWN", "EVENT_SCHEDULER_PAUSED", "EVENT_SCHEDULER_RESUMED", "EVENT_EXECUTOR_ADDED", "EVENT_EXECUTOR_REMOVED", "EVENT_JOBSTORE_ADDED", "EVENT_JOBSTORE_REMOVED", "EVENT_ALL_JOBS_REMOVED", "EVENT_JOB_ADDED", "EVENT_JOB_...
auth
password
# -*- coding: utf-8 -*- """ flaskbb.core.auth.password ~~~~~~~~~~~~~~~~~~~~~~~~~~~ Interfaces and services for auth services related to password. :copyright: (c) 2014-2018 the FlaskBB Team. :license: BSD, see LICENSE for more details """ from abc import ABC, abstractmethod class ResetPassword...
dialogs
progressdlg
# -*- coding: utf-8 -*- # # Copyright (C) 2013 by Ihor E. Novikov # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version....
stickiness
stickiness_event_query
from typing import Any, Dict, Tuple from posthog.constants import TREND_FILTER_TYPE_ACTIONS, PropertyOperatorType from posthog.models import Entity from posthog.models.action.util import format_action_filter from posthog.models.filters.mixins.utils import cached_property from posthog.models.filters.stickiness_filter i...
migrations
0339_add_user_scene_personalisation
# Generated by Django 3.2.19 on 2023-08-02 10:32 import django.db.models.deletion import posthog.models.utils from django.conf import settings from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("posthog", "0338_datawarehouse_saved_query"), ] operati...
papers
fingerprint
# -*- encoding: utf-8 -*- # Dissemin: open access policy enforcement tool # Copyright (C) 2014 Antonin Delpeuch # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU Affero General Public License # as published by the Free Software Foundation; either version 2 # of th...
saveddata
ship
# =============================================================================== # Copyright (C) 2010 Diego Duclos # # This file is part of eos. # # eos is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by # the Free Software Foundation, ...
extractor
folketinget
# coding: utf-8 from __future__ import unicode_literals from ..compat import compat_parse_qs from ..utils import int_or_none, parse_duration, parse_iso8601, xpath_text from .common import InfoExtractor class FolketingetIE(InfoExtractor): IE_DESC = "Folketinget (ft.dk; Danish parliament)" _VALID_URL = r"https...
BasicShapes
Shapes
# *************************************************************************** # * * # * Copyright (c) 2019 Werner Mayer <wmayer[at]users.sourceforge.net> * # * * # * Th...
engines
youtube_api
# SPDX-License-Identifier: AGPL-3.0-or-later """ Youtube (Videos) """ from json import loads from urllib.parse import urlencode from dateutil import parser from searx.exceptions import SearxEngineAPIException # about about = { "website": "https://www.youtube.com/", "wikidata_id": "Q866", "official_api_d...
pmt
qa_pmt
#!/usr/bin/env python # # Copyright 2011, 2018 Free Software Foundation, Inc. # # This file is part of GNU Radio # # SPDX-License-Identifier: GPL-3.0-or-later # # import struct import unittest import pmt class test_pmt(unittest.TestCase): MAXINT32 = (2**31) - 1 MININT32 = (-MAXINT32) - 1 def setUp(sel...
projectedModule
changeCharges
import eos.db import gui.mainFrame import wx from gui import globalEvents as GE from gui.fitCommands.calc.module.changeCharges import CalcChangeModuleChargesCommand from gui.fitCommands.helpers import InternalCommandHistory from service.fit import Fit class GuiChangeProjectedModuleChargesCommand(wx.Command): def ...
picard
metadata
# -*- coding: utf-8 -*- # # Picard, the next-generation MusicBrainz tagger # # Copyright (C) 2006-2008, 2011 Lukáš Lalinský # Copyright (C) 2009, 2015, 2018-2023 Philipp Wolfer # Copyright (C) 2011-2014 Michael Wiencek # Copyright (C) 2012 Chad Wilson # Copyright (C) 2012 Johannes Weißl # Copyright (C) 2012-2014, 2018,...
panel
files
# Copyright (C) 2008-2010 Adam Olsen # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This program is distributed in the hope that...
View
Library
#!/usr/bin/env python # -*- coding:utf-8 -*- # A GAE web application to aggregate rss and send it to your kindle. # Visit https://github.com/cdhigh/KindleEar for the latest version import datetime import urlparse try: import json except ImportError: import simplejson as json import web from apps.BaseHandler ...
model
script
# Copyright (C) 2011 Chris Dekter # Copyright (C) 2019-2020 Thomas Hess <thomas.hess@udo.edu> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your opt...
PyObjCTest
test_cvopengltexturecache
from PyObjCTools.TestSupport import * from Quartz import * try: unicode except NameError: unicode = str class TestCVOpenGLTextureCache(TestCase): def testTypes(self): self.assertIsCFType(CVOpenGLTextureCacheRef) def testConstants(self): self.assertIsInstance(kCVOpenGLTextureCacheChro...
Arch
ArchRoof
# *************************************************************************** # * Copyright (c) 2012 Yorik van Havre <yorik@uncreated.net> * # * * # * This program is free software; you can redistribute it and/or modify * # * it...
dialogs
abbrsettings
# Copyright (C) 2011 Chris Dekter # Copyright (C) 2018 Thomas Hess <thomas.hess@udo.edu> # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) a...
checker
background
# SPDX-License-Identifier: AGPL-3.0-or-later import json import os import random import signal import threading import time from searx import logger, searx_debug, settings from searx.exceptions import SearxSettingsException from searx.search.checker import Checker from searx.search.processors import processors from s...
accounts
FilecloudIo
# -*- coding: utf-8 -*- import json from ..base.account import BaseAccount from ..helpers import set_cookie class FilecloudIo(BaseAccount): __name__ = "FilecloudIo" __type__ = "account" __version__ = "0.13" __status__ = "testing" __description__ = """FilecloudIo account plugin""" __license_...
Scripts
stdinreader
from Foundation import * from PyObjCTools import AppHelper class FileObserver(NSObject): def initWithFileDescriptor_readCallback_errorCallback_(self, fileDescriptor, readCallback, errorCallback): self = self.init() self.readCallback = readCallback self.errorCallback = errorCall...
documents
lock
from __future__ import annotations from datetime import datetime, timedelta from typing import Any import dateutil.parser from abilian.core.models.subjects import User from abilian.core.util import utcnow from flask import current_app from flask_login import current_user DEFAULT_LIFETIME = 3600 class Lock: """...
femexamples
thermomech_bimetall
# *************************************************************************** # * Copyright (c) 2020 Bernd Hahnebach <bernd@bimstatik.org> * # * Copyright (c) 2020 Sudhanshu Dubey <sudhanshu.thethunder@gmail.com * # * * # * Th...
PyObjCTest
test_cfbag
from CoreFoundation import * from PyObjCTools.TestSupport import * try: long except NameError: long = int class TestCFBag(TestCase): def testCreation(self): bag = CFBagCreate(None, [1, 1, 2, 3, 4], 5) self.assert_(isinstance(bag, CFBagRef)) self.assertEqual(CFBagGetCountOfValue(ba...
schemas
users
from CTFd.models import UserFieldEntries, UserFields, Users, ma from CTFd.schemas.fields import UserFieldEntriesSchema from CTFd.utils import get_config, string_types from CTFd.utils.crypto import verify_password from CTFd.utils.email import check_email_is_whitelisted from CTFd.utils.user import get_current_user, is_ad...
engine
urls
"""engine URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.1/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-based ...
PyObjCTest
test_nskeyvaluebinding
from AppKit import * from PyObjCTools.TestSupport import * try: unicode except NameError: unicode = str class TestNSKeyValueBindingHelper(NSObject): def commitEditingWithDelegate_didCommitSelector_contextInfo_(self, d, s, i): return None def commitEditingAndReturnError_(self, v): ret...
migrations
0001_squashed_initial
# Generated by Django 3.2.5 on 2022-05-31 14:46 import apps.heartbeat.models import django.core.validators import django.db.models.deletion import django_migration_linter as linter from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ("alert...
saveddata
module
# =============================================================================== # Copyright (C) 2010 Diego Duclos # # This file is part of eos. # # eos is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by # the Free Software Foundation, ...
example-flask-iblueprint
plugin
# encoding: utf-8 import ckan.plugins as p from ckan.common import CKANConfig from flask import Blueprint, render_template_string def hello_plugin(): """A simple view function""" return "Hello World, this is served from an extension" def override_flask_home(): """A simple replacement for the flash Home...
windows
NsisUtilities
#!/usr/bin/python3 # vim: ts=4:sw=4:expandtab # BleachBit # Copyright (C) 2008-2023 Andrew Ziem # https://www.bleachbit.org # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of...
playorder
track_repeat
# Copyright 2011-2020 Nick Boultbee # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. from gi.repository import Gtk fr...
v1
topics
from typing import List from CTFd.api.v1.helpers.request import validate_args from CTFd.api.v1.helpers.schemas import sqlalchemy_to_pydantic from CTFd.api.v1.schemas import APIDetailedSuccessResponse, APIListSuccessResponse from CTFd.constants import RawEnum from CTFd.models import ChallengeTopics, Topics, db from CTF...
ControlledPreferences
PreferencesPanelController
# # PreferencesPanelController.py # ControlledPreferences # # Converted by u.fiedler on 04.02.05. # with great help from Bob Ippolito - Thank you Bob! # # The original version was written in Objective-C by Malcolm Crawford # at http://homepage.mac.com/mmalc/CocoaExamples/controllers.html from AppKit import * fr...
draftguitools
gui_polararray
# *************************************************************************** # * (c) 2019 Eliud Cabrera Castillo <e.cabrera-castillo@tum.de> * # * * # * This file is part of the FreeCAD CAx development system. * # * ...
utils
http
# -*- encoding: utf-8 -*- import http.client as httplib import socket from urllib.parse import urlparse from isso import dist from isso.wsgi import urlsplit MAX_RETRY_COUNT = 3 class curl(object): """Easy to use wrapper around :module:`httplib`. Use as context-manager so we can close the response properly...
tools
test_auth_server
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Simple HTTP web server for testing HTTP Authentication (see bug 1539) # from our crappy-but-does-the-job department # Thomas Perl <thp.io/about>; 2012-01-20 import base64 import datetime import hashlib import http.server import re import sys import threading import time...
gtk3
statusbar
# # Copyright (C) 2007-2008 Andrew Resch <andrewresch@gmail.com> # # This file is part of Deluge and is licensed under GNU General Public License 3.0, or later, with # the additional special exception to link portions of this program with the OpenSSL library. # See LICENSE for more details. # import logging import de...
supysonic
cache
# This file is part of Supysonic. # Supysonic is a Python implementation of the Subsonic server API. # # Copyright (C) 2013-2019 Alban 'spl0k' Féron # 2018-2019 Carey 'pR0Ps' Metcalfe # # Distributed under terms of the GNU AGPLv3 license. import contextlib import errno import logging import os import os....