Typing should remain in insert mode
-
David Lee
Using insert mode allows users to use standard keyboard shortcuts that are available in insert mode. Also, insert mode allows users to use IMs to input non-ascii characters. Finally, insert mode will show a cursor (especially helpful since there seems to be an invisible cursor positioning).
Right now, it seems like user is taken out of insert mode:
- I can't use C-W to rubout a word (it's remapped in normal mode)
- I can't input Asian text using IMs
- I don't see a cursor, but there definitely is a cursor position since I can go left/right.
-
Greg Hurrell
Correct, you're not in insert mode when you're using Command-T.
There is a cursor, but it may be hard to see, depending on your color scheme.
There is a ticket open in the issue tracker for the inability to type non-ASCII characters (bug #1535).
Reply
This topic is now closed.


Not all our data fits on a heatmap. In addition, we are committed to making as much of the raw data files available as well, to make sure the 3i project can have a lasting impact on diverse areas of research. Browse this section to find out more about what data is available and how to access it.
We generated xxx images of DSS colitis gut sections, antinuclear antibody stainings and confocal sections of mouse ear epidermis. These can be found at the IMPC image repository.


--- title: Pole Figures sidebar: documentation_sidebar permalink: OrientationPoleFigure.html folder: documentation toc: false ---
Pole figures are two dimensional representations of orientations. To illustrate this we define a random orientation with trigonal crystal symmetry
{% highlight matlab %} cs = crystalSymmetry('321') ori = orientation.rand(cs) {% endhighlight %} {% highlight plaintext %} cs = crystalSymmetry symmetry : 321 elements : 6 a, b, c : 1, 1, 1 reference frame: X||a*, Y||b, Z||c* ori = orientation (321 → xyz) Bunge Euler angles in degree phi1 Phi phi2 233.057 173.181 215.251 {% endhighlight %}Starting point is a fixed crystal direction h
, e.g.,
Next the specimen directions corresponding to all crystal directions symmetrically equivalent to h
are computed
and ploted in a spherical projection
{% highlight matlab %} plot(r) {% endhighlight %}Since the trigonal symmetry group has six symmetry elements the orientation appears at six possitions.
A shortcut for the above computations is the command
{% highlight matlab %} % a pole figure plot plotPDF(ori,Miller({1,0,-1,0},{0,0,0,1},{1,1,-2,1},ori.CS)) {% endhighlight %}We observe, that for some crystal directions only the upper hemisphere is plotted while for other upper and lower hemisphere are plotted. The reason is that if h
and -h
are symmetrically equivalent the upper and lower hemisphere of the pole figure are symmetric as well.


Pregnant woman, 29, mauled to death by pack of dogs during deer hunt in France
Elisa Pilaski, 29, phoned her husband after feeling 'threatened' when she encountered a deer hunt including 93 dogs in Retz Forest in France
by Lila RandallA pregnant woman was mauled to death after stumbling across a ‘threatening’ deer hunt involving 93 dogs in France.
Elisa Pilaski, 29, had telephoned her husband when she was walking her own dogs in the Retz Forest, north of Paris, saying she felt ‘threatened’ by a hunt.
The attack came shortly after the call, however there was no time for him to help and he later found her body in the woods.
Local prosecutor Frederic Trinh confirmed her cause of death as ‘bleeding after several dog bites to the upper and lower limbs and the head.’
Mrs Pilaski was found mauled to death and a criminal investigation for manslaughter was launched by the prosecutor and judicial police.
Forensic tests have been carried out on 93 dogs connected with the incident, to try and work out which ones had attacked her.
However, France’s Hunting Association has rejected claims the hunting dogs are the perpetrators of this horrifying attack.
They said: “Nothing reveals the involvement of hunting hounds in the death of this woman”.
It said there were around 30,000 hunting hounds in France and “these dogs are trained to hunt a particular animal and to obey man in all circumstances”.
But Brigitte Bardot, the retired movie actress turned animal rights campaigner, called on the government to ‘suspend all hunt authorisation for this season’.
On Friday, a retired carpenter was blasted to death by a hunter who ‘mistook him for game’ in the French countryside.
Franck Jarry, 77, became another lethal statistic of the controversial shooting season last Friday.
He was out picking mushrooms close to the hamlet of Villars-les-Bois, in the western Charente-Maritime department, when the accident happened.
‘A 34-year-old hunter saw movement in the undergrowth and thought it was game,’ said an investigating source.
‘A dog was barking, and this seemed to confirm the presence of animals.
‘After realising that he had shot a man, the hunter immediately went to the victim's aid, and called the emergency services, but it was too late.’
Last year a 22-year-old British mountain biker was shot dead by a hunter in thick woods near the village of Montriond, in eastern France.
This was despite Marc Sutton – a restaurateur who originally came from Caerphilly, South Wales – wearing bright clothing and a helmet that made him easily identifiable.
There are around 1.2 million hunters in France, with some 37,000 new gun licences obtained each year.
But many people drop out of the administrative process because of the length of time it takes, and the cost, which is the equivalent of more than £400 for a permit.
France’s hunting season only started in September, but there have already been three deaths so far.
During the 2017/18 season, there were 113 serious accidents, with 13 people killed.


Side nav demo
John Doe
<EMAIL_ADDRESS>cloud
First Link With Icon
Second Link
Subheader
Third Link With Waves


Minh's Notes: Basic Web Info & HTML
World Wide Web (WWW)
- HTML (Hypertext Markup Language) is main type of document on the World Wide Web
- All types of files can be found (i.e. plain text, html, video, images, music)
- Computers run Web Browsers (i.e. Chrome, IE, Firefox, Safari) that uses HTTP (Hypertext Transport Protocol) protocol to communicate on the Internet to access resources/data on Web Servers
HTML (Hypertext Markup Language)
- HTML is comprised of structure with components called "tags"
- A complete HTML structure of a tag can be referenced as "element"
- Link to good video explanation here
Computers are Stupid
- Computers literally have to take instructions from what programmers give to them in code
Inline vs Block
- Certain tags are considered inline tags (i.e. break tags) which end the line while block tags (i.e. paragraph tags) place a virtual box surrounding the content


Select Cell Type from the dropdown and use use click and drag to add the selected cell.
Select path finding algorithm from the dropdown.
Press Go to visualize (mouse input is blocked during visualization).
Press Reset to reset the grid.


| I l@ve RuBoard |
This chapter covers techniques for working with files and processes. We first look at the facilities Python has for portably working with both files and processes, then we'll look at Windows-specific techniques. If you're an experienced Python developer, you may wish to skip to the later sections; if you're new to Python, this is essential groundwork.
We cover techniques for finding, moving, and rearranging files, look at file objects themselves, and then cover some of the standard Python idioms for reading and writing them. Then we look at techniques for starting, stopping, and generally working with processes.
| I l@ve RuBoard |


seeNA.Rmd
When cleaning up a data set, some of the most frequent exploration begins with the summary
function. From here, the data is broadly displayed, with NA values flagging the analyst to decide on their next move. Typically, a quick na.omit
command is run, deleting all those pesky missing values that plagued the data set.
However! Missing values can be hidden even moreso than the typical user can discern. Missing values could be 97’s, 98’s, or 99’s. They could even be outliers like 150 in an age column. One of the first commands in the seeNA package that can be used is the fixNA
command. This allows the user to recode certain data elements to NA by default. It allows for ease of recoding.
Here we load our package and call the data set that comes with seeNA, the emptyCars data set. The data set comes with the mtcars data set from base R
, however it is loaded with 100 99 values. We then test the fixNA function on the data, cleaning up the 99’s into NA values. We test to see if we have 100 from sum(is.na(randomCars))
.
library(seeNA)
data("randomCars")
fixNA(randomCars)
sum(is.na(randomCars))
Some of the other basic functions included in this package are the makeNA
and seeNA
functions. makeNA
takes a data frame and randomly assigns missing values throughout the data set. This function allows users to add missing values, or randomly recode their data set with new values.
library(seeNA)
data("mtcars")
makeNA(mtcars, n_missing = 10)
sum(is.na(mtcars)) # 10 missing values in mtcars
Another introductory function, seeNA
takes a data frame with missing values and plots a proportion of missing values per column in a data set. It allows for easy visualizations to understand exactly how missing values are impacting your data set. The example is below:
library(seeNA)
data("emptyCars")
seeNA(emptyCars)


{%extends display.suMain%} {%block content%}
{%trans "Indicate the current page's location within a navigational hierarchy that automatically adds separators via CSS."%}
{%trans "Separators are automatically added in CSS through ::before and content."%}
{%trans "A breadcrumb can vary in size"%}


La Ceremonie
France, 1995; in French with English subtitles
"Well, you will certain reconsider hiring help after this movie!" And with that, Linda and I plunged ahead to see La Ceremonie, director Claude Chabrol's 55th movie. The opening couldn't be more ordinary--Catherine Lelievre (Jacqueline Bisset) interviews Sophie (Sandrine Bonaire) at a cafe. She needs a domestic worker at her remote home in Bretagne for her blended family--her rich husband and their children from previous marriages.
Fate pairs Sophie with Jeanne (Isabelle Huppert), a wacked-out postal clerk (this stereotype extends beyond America), who has it in for the bourgeois family. They routinely receive their mail opened, mutilated, or not at all. The stage for unsettling us is set early, when Catherine picks up Sophie at the train and Jeanne asks for a ride. She shows an intense interest in Sophie, and the feeling that *something* is going to happen is palpable.
Without giving too much away, the secret Sophie hides is certainly part of her problem, and it is rather unnerving when it is revealed to us. That she has not remedied the problem is what seems truly disturbing. But she has bigger problems. Both she and Jeanne have had close relatives perish in suspicious circumstances, and this only bonds them further.
The family goes about its business, with worries about what to have for dinner, and other petit bourgeois concerns; the university student/daughter, Melinda, feels free to treat Sophie like a person; but Sophie grows to dislike this family, with Jeanne fanning the flames for a personal Marxist revolt. The family is used to having domestic help around, regardless of how the domestics feel about them. In a capitalist western nation like France, it is understood that when you are hired as a maid, democracy disappears, but you are free to leave employment. However, this freedom can disappear when you need housing and food. Is Catherine truly guilty of class insensitivity? The two are clearly unbalanced, but is there an underlying truth to their outrage? La Ceremonie is a nice comparison to *Breakdown*; the former pits intimate strangers against each other and grudges are overblown; the latter shows strangers deliberately victimizing people at random, and the grudge is just a rouse.
Sandrine Bonnaire has never looked more drab, but it suits the tabula rassa she becomes for Jeanne's vengefulness. Isabelle Huppert, often likened to an "ice princess"; because of her portrayals throughout her career (Madame Bovary, Sincerely Charlotte), really opens up as the unhinged, postal clerk. A very nice surprise is Jacqueline Bisset, who is elevated to a whole new level when she speaks French throughout a movie. Most people remember her for such unilluminating performances as Rob Lowe's mother and his classmates lover in Class.
Based on Ruth Rendell's novel *A Judgement in Stone*.
Copyright 1997 Seth J. Bookey, New York, NY 10021
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


When I think of the times in my life where I've been the happiest, the proudest, or the most satisfied, 'responsibility' is the value of mine that comes to mind. Responsibility is hugely important to me because whether I am carrying out my responsibilities and to what extent is a measure of success for me. I get super proud of myself when I execute on the responsibilities someone has entrusted me with, particularly when they are strenuous, like at work, or if they are self imposed, like maintaining a job through college. Starting with school, and through college, now into my career, as I've grown I've taken on more and more responsibility both personally and professionally. Nothing is more satisfying than being tasked with a challenging responsibility and perservering through to the end. When I fulfill professional responsibilities I am reassured that I am providing a meaningful contribution. In general, I really do try to live up to this value.
The last topic that someone asked for my advice on was in what direction she should take her professional career. My friend was being displaced from her role at the time, and asked for my input on what she should do next. I did my best to put myself in her shoes to offer what advice I could. Ultimately, I think I was really able to help her out by providing a second opinion, questioning some of the ideas she had (just to make sure she was seeing things from all angles), and just listening to her express her thoughts.
I feel inspired when I think about my values. Continuously reminding myself of my values would be a great way to fend off stereotype threat if recognize that I am feeling it. Reminding myself of my responsibilities both professionaly and personally would really motivate me to see past stereotype threat so that it doesn't impact me. Beyond this simple exercise, I think that if someone is feeling down at DBC, they should be open and let their peers know how they're feeling. They should reach out to others and express their thoughts and concerns so that others can provide feedback and support. It is likely that someone else will have shared similar thoughts or experiences and can provide meaningful advice.
Copyright: Gary Hammell 2014


HW6 Part1
HW6 Part2
HW6 Part3
CNIT 133 HOMEWORK 6 - Part 1
Enter a floating-point number with AT LEAST 4 decimal positions (no less than that).
Floating Number:
Round / Square Root Conversion:
Round to the nearest integer:
Square Root and round to the nearest integer:
Round to the nearest tenths position:
Round to the nearest hundredths position:
Round to the nearest thousandths position:


天，12月！！！
无题（七） October 26
没什么好说的，自从回来之后，GFW的影子便无处不在，好好的网络不停的reset。真使人挺无奈的。更让人无奈的事实是：不论是什么内容放到互联网上都能形成对骂，quite magical。
.r003 September 16
After the using rb file to import the posts from Textpattern, which I find a little bit tricky is that all posts’ detailed post time kinda lost, like original post time is “Mar 15th, 2011 21:59:00”, only the date were available exists, but the detail hour/minute got lost, kinda pity.
And for Jekyll part, I personally cloned this repository , it definitely meet regular requirement for blogging. But if the pagination is a demand, add this line in _config.yml
3 is the number of posts for each page. More information could be grab from here . See? It is in the wiki! But you can’t find it on the wiki’s home page.
On jekyll’s page structure, basically, it start from the index.html in the root container, and uses the file _layout folder. Extremely like what I have in Textpattern :)
And for code highlighting, pygments is great, and also which is part of github’s default setting(github uses jekyll --pygments --safe), you may need put pygments: true in _config.xml. Pygments does a bit slow
Well, I always said to myself, leave it tomorrow, you’ll have time to do it. In my face: I already forget details that have been done in this setup…


Preparation time
less than 30 mins
Cooking time
10 to 30 mins
Serves
Serves 2
This dish makes a quick and warming brunch or supper. Fried eggs work well if you don’t fancy poached.
Fry the bacon in a dry frying pan until crisp. Drain on kitchen paper and roughly chop.
Put the potato and parsnip on a clean tea towel and squeeze over a bowl to remove the excess liquid. Place in a separate bowl and mix in the bacon and parsley.
Melt the butter and oil in a frying pan over a medium heat. Add the potato mixture and press it down with the back of a spoon. Season with salt and pepper. Fry for 2-3 minutes on each side, using a fish slice to carefully turn it over, until crisp and golden-brown.
For the hollandaise, melt the butter in a saucepan over a low heat, then skim off the froth to leave a clear yellow liquid. Put the egg yolk, lemon juice and one tablespoon water in a blender. Turn on the machine and slowly pour the warm clarified butter through the lid. Add the mustard and salt and blend.
For the gammon, heat a large griddle pan over a medium-high heat and cook the gammon for 2-3 minutes on each side, until cooked through.
For the poached egg, heat a large saucepan of simmering water, add the salt and vinegar and spin the water. Crack an egg into the pool of water and cook for 2-3 minutes, or until your liking. Repeat with the second egg.
Place a rösti on a plate. Top with chargrilled gammon and a poached egg and pour over the hollandaise.


Apis Intro Methods Pill
Exercises
-
Implement the api call for the exercise 1 using
XMLHttpRequest
-
Implement the api call for the exercise 2 using
jQuery.get()
-
Implement the api call for the exercise 3 using
fetch()
-
Implement the api call for the exercise 4 using
axios.get()
Choose the method to fetch the data from the api


One dead, two injured in Tipperary collision
A man in his 30s has died following a collision in Tipperary.
Gardaí said they were called to the scene of the single-car collision shortly after 3am.
They said the collision occurred on the N24 at Killaloan on the outskirts of Clonmel.
The driver of the car, a man in his 30s, was removed to South Tipperary General Hospital where he has since been pronounced dead.
Two passengers in the car, a man and woman both in their 20s, were also taken to hospital.
Their injuries are not thought to be life-threatening.
Gardaí said the road is currently closed to traffic and local diversions are in place.
Garda forensic collision investigators and crime scene examiners have been requested to examine the crash site scene.
They said a report will be forwarded to the local Coroner.
Gardaí are appealing for witnesses to the collision.
"From our initial enquiries it’s understood the car, a 05WH registered silver Volkswagen Polo, left the road and struck a wall while travelling from Clonmel in the direction of Carrick-on-Suir," said Superintendent William Leahy.
"We are appealing for witnesses and in particular anyone who travelling on this stretch of road between 2.45am and 3.15am this morning to contact us at Clonmel Garda Station.
"We would also ask any road user with camera footage to make it available to investigating gardaí."
Anyone with information is asked to contact Clonmel Garda Station<PHONE_NUMBER> or the Garda Confidential Line 1800 666 111.
READ MORE
Housing crisis concern as two-thirds of 20-year-olds still live at home


Tickets are now on sale for both Friday night, Saturday day and Saturday night, so get in touch ASAP to order your tickets and avoid the risk of disappointment.
You can contact Penkridge Roundtable us by email or phone. We don't do faxes, they're soooo 1998.
<EMAIL_ADDRESS>Chris - 07743 095 878


This inspection reports libraries attached to the specified inspection scope that are not used directly from code.


The managed server responsible for this instance is not synchronized,
bulk controls are unavailable. Please synchronize the server to use
these controls.
Control
{{ bulkSelection.length || 0 }}
selected processes.
The selection contains one or more processes which require
confirmation. Those processes can not be controlled in a bulk.


{$ codeDefinition.masterDescription.text $}
{$ codeDefinition.partnerDescription.text $}
Your partner has not provided a definition yet.
Please select keywords from your tweets.
Your partner does not have any keyword for '{$ selectedCode.code_text $}'.
No system keywords for found for '{$ codeDefinition.name $}'.
No disagreements found.
No tweets found.


AppResponse
- id : integer
Identifier of this application.
- name : string
Displayable name of this application.
- api_name : string
Name of the application to use in API transactions.
- description : string
Description of this application.
- is_active : boolean
Is this system application active for use.
- url : string
URL for accessing this application.
- is_url_external : boolean
True when this application is hosted elsewhere, but available in Launchpad.
- import_url : string
If hosted and imported, the url of zip or package file where the code originated.
- storage_service_id : string
If hosted, the storage service identifier.
- storage_container : string
If hosted, the container of the storage service.
- requires_fullscreen : boolean
True when this app needs to hide launchpad.
- allow_fullscreen_toggle : boolean
True to allow launchpad access via toggle.
- toggle_location : string
Screen location for toggle placement.
- requires_plugin : boolean
True when the app relies on a browser plugin.
- roles_default_app : List[string]
Related roles by Role.default_app_id.
- users_default_app : List[string]
Related users by User.default_app_id.
- app_groups : List[string]
Related groups by app to group assignment.
- roles : List[string]
Related roles by app to role assignment.
- services : List[string]
Related services by app to service assignment.
- created_date : string
Date this application was created.
- created_by_id : integer
User Id of who created this application.
- last_modified_date : string
Date this application was last modified.
- last_modified_by_id : integer
User Id of who last modified this application.


Before Change
def export(self):
if self._in_forward_pass:
raise RuntimeError("Still in forward pass. Exporting might induce incompleteness.")
if not self._cache:
raise RuntimeError("No running history found. You need to call your model at least once before exporting. "
"You might also want to check if there are no valid mutables in your model.")
return self._cache
@contextmanager
def forward_pass(self):
After Change
-------
dict
return self.sample_final()
def on_forward_layer_choice(self, mutable, *inputs):
On default, this method calls :meth:`on_calc_layer_choice_mask` to get a mask on how to choose between layers


7 in fray for K.R. Pet seat
by Special CorrespondentSeven candidates remained in the fray for the December 5 byelection to K.R. Pet Assembly segment on the last day for withdrawal of nomination.
The battle lines are clearly drawn between K.B. Chandrashekar of the Congress), B.L. Devaraj of Janata Dal (Secular) and K.C. Narayana Gowda of the BJP.
H.M. Chandre Gowda of Uttama Prajakeeya Party (UPP), H.D. Revanna of Purvanchal Mahapanchayat, K.N. Shankare Gowda from Karnataka Rashtra Samithi (KRS) and Deve Gowda, an Independent, are the remaining candidates.


| PostgreSQL 9.0.10 Documentation | ||||
|---|---|---|---|---|
| Prev | Up | Chapter 12. Full Text Search | Next |
Dictionaries are used to eliminate words that should not be considered in a search (stop words), and to normalize words so that different derived forms of the same word will match. A successfully normalized word is called a lexeme. Aside from improving search quality, normalization and removal of stop words reduce the size of the tsvector representation of a document, thereby improving performance. Normalization does not always have linguistic meaning and usually depends on application semantics.
Some examples of normalization:
Linguistic - Ispell dictionaries try to reduce input words to a normalized form; stemmer dictionaries remove word endings
URL locations can be canonicalized to make equivalent URLs match:
http://www.pgsql.ru/db/mw/index.html
http://www.pgsql.ru/db/mw/
http://www.pgsql.ru/db/../db/mw/index.html
Color names can be replaced by their hexadecimal values, e.g., red, green, blue, magenta -> FF0000, 00FF00, 0000FF, FF00FF
If indexing numbers, we can remove some fractional digits to reduce the range of possible numbers, so for example 3.14159265359, 3.1415926, 3.14 will be the same after normalization if only two digits are kept after the decimal point.
A dictionary is a program that accepts a token as input and returns:
an array of lexemes if the input token is known to the dictionary (notice that one token can produce more than one lexeme)
a single lexeme with the TSL_FILTER flag set, to replace the original token with a new token to be passed to subsequent dictionaries (a dictionary that does this is called a filtering dictionary)
an empty array if the dictionary knows the token, but it is a stop word
NULL if the dictionary does not recognize the input token
PostgreSQL provides predefined dictionaries for many languages. There are also several predefined templates that can be used to create new dictionaries with custom parameters. Each predefined dictionary template is described below. If no existing template is suitable, it is possible to create new ones; see the contrib/ area of the PostgreSQL distribution for examples.
A text search configuration binds a parser together with a set of dictionaries to process the parser's output tokens. For each token type that the parser can return, a separate list of dictionaries is specified by the configuration. When a token of that type is found by the parser, each dictionary in the list is consulted in turn, until some dictionary recognizes it as a known word. If it is identified as a stop word, or if no dictionary recognizes the token, it will be discarded and not indexed or searched for. Normally, the first dictionary that returns a non-NULL output determines the result, and any remaining dictionaries are not consulted; but a filtering dictionary can replace the given word with a modified word, which is then passed to subsequent dictionaries.
The general rule for configuring a list of dictionaries is to place first the most narrow, most specific dictionary, then the more general dictionaries, finishing with a very general dictionary, like a Snowball stemmer or simple, which recognizes everything. For example, for an astronomy-specific search (astro_en configuration) one could bind token type asciiword (ASCII word) to a synonym dictionary of astronomical terms, a general English dictionary and a Snowball English stemmer:
ALTER TEXT SEARCH CONFIGURATION astro_en ADD MAPPING FOR asciiword WITH astrosyn, english_ispell, english_stem;
A filtering dictionary can be placed anywhere in the list, except at the end where it'd be useless. Filtering dictionaries are useful to partially normalize words to simplify the task of later dictionaries. For example, a filtering dictionary could be used to remove accents from accented letters, as is done by the contrib/unaccent extension module.
Stop words are words that are very common, appear in almost every document, and have no discrimination value. Therefore, they can be ignored in the context of full text searching. For example, every English text contains words like a and the, so it is useless to store them in an index. However, stop words do affect the positions in tsvector, which in turn affect ranking:
SELECT to_tsvector('english','in the list of stop words'); to_tsvector ---------------------------- 'list':3 'stop':5 'word':6
The missing positions 1,2,4 are because of stop words. Ranks calculated for documents with and without stop words are quite different:
SELECT ts_rank_cd (to_tsvector('english','in the list of stop words'), to_tsquery('list & stop')); ts_rank_cd ------------ 0.05 SELECT ts_rank_cd (to_tsvector('english','list stop words'), to_tsquery('list & stop')); ts_rank_cd ------------ 0.1
It is up to the specific dictionary how it treats stop words. For example, ispell dictionaries first normalize words and then look at the list of stop words, while Snowball stemmers first check the list of stop words. The reason for the different behavior is an attempt to decrease noise.
The simple dictionary template operates by converting the input token to lower case and checking it against a file of stop words. If it is found in the file then an empty array is returned, causing the token to be discarded. If not, the lower-cased form of the word is returned as the normalized lexeme. Alternatively, the dictionary can be configured to report non-stop-words as unrecognized, allowing them to be passed on to the next dictionary in the list.
Here is an example of a dictionary definition using the simple template:
CREATE TEXT SEARCH DICTIONARY public.simple_dict ( TEMPLATE = pg_catalog.simple, STOPWORDS = english );
Here, english is the base name of a file of stop words. The file's full name will be $SHAREDIR/tsearch_data/english.stop, where $SHAREDIR means the PostgreSQL installation's shared-data directory, often /usr/local/share/postgresql (use pg_config --sharedir to determine it if you're not sure). The file format is simply a list of words, one per line. Blank lines and trailing spaces are ignored, and upper case is folded to lower case, but no other processing is done on the file contents.
Now we can test our dictionary:
SELECT ts_lexize('public.simple_dict','YeS'); ts_lexize ----------- {yes} SELECT ts_lexize('public.simple_dict','The'); ts_lexize ----------- {}
We can also choose to return NULL, instead of the lower-cased word, if it is not found in the stop words file. This behavior is selected by setting the dictionary's Accept parameter to false. Continuing the example:
ALTER TEXT SEARCH DICTIONARY public.simple_dict ( Accept = false ); SELECT ts_lexize('public.simple_dict','YeS'); ts_lexize ----------- SELECT ts_lexize('public.simple_dict','The'); ts_lexize ----------- {}
With the default setting of Accept = true, it is only useful to place a simple dictionary at the end of a list of dictionaries, since it will never pass on any token to a following dictionary. Conversely, Accept = false is only useful when there is at least one following dictionary.
| Caution |
Most types of dictionaries rely on configuration files, such as files of stop words. These files must be stored in UTF-8 encoding. They will be translated to the actual database encoding, if that is different, when they are read into the server. |
| Caution |
Normally, a database session will read a dictionary configuration file only once, when it is first used within the session. If you modify a configuration file and want to force existing sessions to pick up the new contents, issue an ALTER TEXT SEARCH DICTIONARY command on the dictionary. This can be a "dummy" update that doesn't actually change any parameter values. |
This dictionary template is used to create dictionaries that replace a word with a synonym. Phrases are not supported (use the thesaurus template (Section 12.6.4) for that). A synonym dictionary can be used to overcome linguistic problems, for example, to prevent an English stemmer dictionary from reducing the word 'Paris' to 'pari'. It is enough to have a Paris paris line in the synonym dictionary and put it before the english_stem dictionary. For example:
SELECT * FROM ts_debug('english', 'Paris'); alias | description | token | dictionaries | dictionary | lexemes -----------+-----------------+-------+----------------+--------------+--------- asciiword | Word, all ASCII | Paris | {english_stem} | english_stem | {pari} CREATE TEXT SEARCH DICTIONARY my_synonym ( TEMPLATE = synonym, SYNONYMS = my_synonyms ); ALTER TEXT SEARCH CONFIGURATION english ALTER MAPPING FOR asciiword WITH my_synonym, english_stem; SELECT * FROM ts_debug('english', 'Paris'); alias | description | token | dictionaries | dictionary | lexemes -----------+-----------------+-------+---------------------------+------------+--------- asciiword | Word, all ASCII | Paris | {my_synonym,english_stem} | my_synonym | {paris}
The only parameter required by the synonym template is SYNONYMS, which is the base name of its configuration file — my_synonyms in the above example. The file's full name will be $SHAREDIR/tsearch_data/my_synonyms.syn (where $SHAREDIR means the PostgreSQL installation's shared-data directory). The file format is just one line per word to be substituted, with the word followed by its synonym, separated by white space. Blank lines and trailing spaces are ignored.
The synonym template also has an optional parameter CaseSensitive, which defaults to false. When CaseSensitive is false, words in the synonym file are folded to lower case, as are input tokens. When it is true, words and tokens are not folded to lower case, but are compared as-is.
An asterisk (*) can be placed at the end of a synonym
in the configuration file. This indicates that the synonym is a prefix.
The asterisk is ignored when the entry is used in
to_tsvector()
, but when it is used in
to_tsquery()
, the result will be a query item with
the prefix match marker (see
Section 12.3.2).
For example, suppose we have these entries in
$SHAREDIR/tsearch_data/synonym_sample.syn:
postgres pgsql postgresql pgsql postgre pgsql gogle googl indices index*
Then we will get these results:
mydb=# CREATE TEXT SEARCH DICTIONARY syn (template=synonym, synonyms='synonym_sample'); mydb=# SELECT ts_lexize('syn','indices'); ts_lexize ----------- {index} (1 row) mydb=# CREATE TEXT SEARCH CONFIGURATION tst (copy=simple); mydb=# ALTER TEXT SEARCH CONFIGURATION tst ALTER MAPPING FOR asciiword WITH syn; mydb=# SELECT to_tsvector('tst','indices'); to_tsvector ------------- 'index':1 (1 row) mydb=# SELECT to_tsquery('tst','indices'); to_tsquery ------------ 'index':* (1 row) mydb=# SELECT 'indexes are very useful'::tsvector; tsvector --------------------------------- 'are' 'indexes' 'useful' 'very' (1 row) mydb=# SELECT 'indexes are very useful'::tsvector @@ to_tsquery('tst','indices'); ?column? ---------- t (1 row)
A thesaurus dictionary (sometimes abbreviated as TZ) is a collection of words that includes information about the relationships of words and phrases, i.e., broader terms (BT), narrower terms (NT), preferred terms, non-preferred terms, related terms, etc.
Basically a thesaurus dictionary replaces all non-preferred terms by one preferred term and, optionally, preserves the original terms for indexing as well. PostgreSQL's current implementation of the thesaurus dictionary is an extension of the synonym dictionary with added phrase support. A thesaurus dictionary requires a configuration file of the following format:
# this is a comment sample word(s) : indexed word(s) more sample word(s) : more indexed word(s) ...
where the colon (:) symbol acts as a delimiter between a a phrase and its replacement.
A thesaurus dictionary uses a subdictionary (which is specified in the dictionary's configuration) to normalize the input text before checking for phrase matches. It is only possible to select one subdictionary. An error is reported if the subdictionary fails to recognize a word. In that case, you should remove the use of the word or teach the subdictionary about it. You can place an asterisk (*) at the beginning of an indexed word to skip applying the subdictionary to it, but all sample words must be known to the subdictionary.
The thesaurus dictionary chooses the longest match if there are multiple phrases matching the input, and ties are broken by using the last definition.
Specific stop words recognized by the subdictionary cannot be specified; instead use ? to mark the location where any stop word can appear. For example, assuming that a and the are stop words according to the subdictionary:
? one ? two : swsw
matches a one the two and the one a two; both would be replaced by swsw.
Since a thesaurus dictionary has the capability to recognize phrases it must remember its state and interact with the parser. A thesaurus dictionary uses these assignments to check if it should handle the next word or stop accumulation. The thesaurus dictionary must be configured carefully. For example, if the thesaurus dictionary is assigned to handle only the asciiword token, then a thesaurus dictionary definition like one 7 will not work since token type uint is not assigned to the thesaurus dictionary.
| Caution |
Thesauruses are used during indexing so any change in the thesaurus dictionary's parameters requires reindexing. For most other dictionary types, small changes such as adding or removing stopwords does not force reindexing. |
To define a new thesaurus dictionary, use the thesaurus template. For example:
CREATE TEXT SEARCH DICTIONARY thesaurus_simple ( TEMPLATE = thesaurus, DictFile = mythesaurus, Dictionary = pg_catalog.english_stem );
Here:
thesaurus_simple is the new dictionary's name
mythesaurus is the base name of the thesaurus configuration file. (Its full name will be $SHAREDIR/tsearch_data/mythesaurus.ths, where $SHAREDIR means the installation shared-data directory.)
pg_catalog.english_stem is the subdictionary (here, a Snowball English stemmer) to use for thesaurus normalization. Notice that the subdictionary will have its own configuration (for example, stop words), which is not shown here.
Now it is possible to bind the thesaurus dictionary thesaurus_simple to the desired token types in a configuration, for example:
ALTER TEXT SEARCH CONFIGURATION russian ALTER MAPPING FOR asciiword, asciihword, hword_asciipart WITH thesaurus_simple;
Consider a simple astronomical thesaurus thesaurus_astro, which contains some astronomical word combinations:
supernovae stars : sn crab nebulae : crab
Below we create a dictionary and bind some token types to an astronomical thesaurus and English stemmer:
CREATE TEXT SEARCH DICTIONARY thesaurus_astro ( TEMPLATE = thesaurus, DictFile = thesaurus_astro, Dictionary = english_stem ); ALTER TEXT SEARCH CONFIGURATION russian ALTER MAPPING FOR asciiword, asciihword, hword_asciipart WITH thesaurus_astro, english_stem;
Now we can see how it works.
ts_lexize
is not very useful for testing a thesaurus,
because it treats its input as a single token. Instead we can use
plainto_tsquery
and to_tsvector
which will break their input strings into multiple tokens:
SELECT plainto_tsquery('supernova star'); plainto_tsquery ----------------- 'sn' SELECT to_tsvector('supernova star'); to_tsvector ------------- 'sn':1
In principle, one can use to_tsquery
if you quote
the argument:
SELECT to_tsquery('''supernova star'''); to_tsquery ------------ 'sn'
Notice that supernova star matches supernovae stars in thesaurus_astro because we specified the english_stem stemmer in the thesaurus definition. The stemmer removed the e and s.
To index the original phrase as well as the substitute, just include it in the right-hand part of the definition:
supernovae stars : sn supernovae stars SELECT plainto_tsquery('supernova star'); plainto_tsquery ----------------------------- 'sn' & 'supernova' & 'star'
The Ispell dictionary template supports morphological dictionaries, which can normalize many different linguistic forms of a word into the same lexeme. For example, an English Ispell dictionary can match all declensions and conjugations of the search term bank, e.g., banking, banked, banks, banks', and bank's.
The standard PostgreSQL distribution does not include any Ispell configuration files. Dictionaries for a large number of languages are available from Ispell. Also, some more modern dictionary file formats are supported — MySpell (OO < 2.0.1) and Hunspell (OO >= 2.0.2). A large list of dictionaries is available on the OpenOffice Wiki.
To create an Ispell dictionary, use the built-in ispell template and specify several parameters:
CREATE TEXT SEARCH DICTIONARY english_ispell ( TEMPLATE = ispell, DictFile = english, AffFile = english, StopWords = english );
Here, DictFile, AffFile, and StopWords specify the base names of the dictionary, affixes, and stop-words files. The stop-words file has the same format explained above for the simple dictionary type. The format of the other files is not specified here but is available from the above-mentioned web sites.
Ispell dictionaries usually recognize a limited set of words, so they should be followed by another broader dictionary; for example, a Snowball dictionary, which recognizes everything.
Ispell dictionaries support splitting compound words; a useful feature. Notice that the affix file should specify a special flag using the compoundwords controlled statement that marks dictionary words that can participate in compound formation:
compoundwords controlled z
Here are some examples for the Norwegian language:
SELECT ts_lexize('norwegian_ispell', 'overbuljongterningpakkmesterassistent'); {over,buljong,terning,pakk,mester,assistent} SELECT ts_lexize('norwegian_ispell', 'sjokoladefabrikk'); {sjokoladefabrikk,sjokolade,fabrikk}
Note: MySpell does not support compound words. Hunspell has sophisticated support for compound words. At present, PostgreSQL implements only the basic compound word operations of Hunspell.
The Snowball dictionary template is based on a project by Martin Porter, inventor of the popular Porter's stemming algorithm for the English language. Snowball now provides stemming algorithms for many languages (see the Snowball site for more information). Each algorithm understands how to reduce common variant forms of words to a base, or stem, spelling within its language. A Snowball dictionary requires a language parameter to identify which stemmer to use, and optionally can specify a stopword file name that gives a list of words to eliminate. (PostgreSQL's standard stopword lists are also provided by the Snowball project.) For example, there is a built-in definition equivalent to
CREATE TEXT SEARCH DICTIONARY english_stem ( TEMPLATE = snowball, Language = english, StopWords = english );
The stopword file format is the same as already explained.
A Snowball dictionary recognizes everything, whether or not it is able to simplify the word, so it should be placed at the end of the dictionary list. It is useless to have it before any other dictionary because a token will never pass through it to the next dictionary.


VSL // Live Now, Eat Now
* Well+Good asks: Is Instagram is making people healthier
today’s Very Short List:
food 8 May 2015
Emily Borgeest is a Certified Holistic Health Coach, recipe creator, fitness/wellness fanatic, and founder of Cleo’s Wholesome Crunch (in stores soon!). INSTAGRAM
Subscribe
* Eckhart Tolle’s The Power of Now
* Minimalist Baker has recipe ideas that satisfy both sweet and savory cravings, and they all use no more than ten ingredients, one bowl, or take more than 30 minutes to prepare. Most recently, I tried their Vegan Cheez Its
http://link.nyobserver.com/516ca68465217dc6e1b9a3a62kzos.23kg/UHyHCJsf7NZSKXrPD9836
delightful e-mail that shares
cultural gems from a
different curator every day.
If you have any problems reading this e-mail, click here
http://link.nyobserver.com/516ca68465217dc6e1b9a3a62kzos.23kg/UHyHCJsf7NZSKXrPFe896
Subscribe
Forward
My Account
Unsubscribe
culture 6 May 2015
Artist Tabitha Soren reveals the connection between baseball and manifest destiny.
culture 29 Apr 2015
Singer-songwriter TORRES shares a few of her inspirations.
culture 27 Apr 2015
Trivia host Tony Hightower lays some good ol’ fact-based entertainment on us all.
Editorial Policy
Privacy Policy
Contact Us
Press
Terms + Conditions
very fine print: ©2015
Observer VSL LLC.
321 West 44th Street, 6th Floor
New York, NY 10036 USA
All rights reserved.
Questions?<PHONE_NUMBER>.
This message was intended for<EMAIL_ADDRESS>If you believe this has been sent to you in error, please safely unsubscribe


Sizing Blocks
Width without height is pretty cool - text
is autowrapped and the height just expands
as necessary.
Once you specify height, you are overriding the
natural way the browser sets height after
text wrapping.
If you use pixels to set the height, your
block may or may not resize as you use zoom
to make the text larger or smaller.
You can tell the browser to add a little scrollbar
if the text will not fit in the height you
set.
No scroll if text fits.
Or you can say, just hide any text that would
flow beyond the height. Like where did
all this text go???
For a puzzle, figure out why the body text
is monospace while the
navigation bar is stll sans-serif.
Go back to the
Starting page.


Have you ever wondered whether or not password strength meters help anyone? They’re employed on nearly every website with user capabilities.
Password strength meters can help users select stronger passwords but only if the script the meter uses to estimate password strength is helpful.
Below you can test Dropbox’s zxcvbn library. Please, be careful about who's watching, as the password field is fully visible.


| Version | CPU | Interface | Version | Comment |
|---|---|---|---|---|
| Packman packages. These packages are better included in your openSUSE distribution. It is preferable to use them. |
Packman website | Warning: they are currently out of date. | ||
| Leap_42.1 | x86_64 | openSUSE Leap_42.1, x86_64 | ||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | Factory | i586 | openSUSE Factory, i586 |
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| x86_64 | openSUSE Factory, x86_64 | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| Factory ARM | armv6l | openSUSE Factory ARM, armv6l | ||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| armv7l | openSUSE Factory ARM, armv7l | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| aarch64 | openSUSE Factory ARM, aarch64 | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| Tumbleweed | i586 | openSUSE Tumbleweed, i586 | ||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| x86_64 | openSUSE Tumbleweed, x86_64 | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| 13.2 | i586 | openSUSE 13.2, i586 | ||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| x86_64 | openSUSE 13.2, x86_64 | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| 13.1 | i586 | openSUSE 13.1, i586 | ||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| x86_64 | openSUSE 13.1, x86_64 | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| 12.3 | i586 | openSUSE 12.3, i586 | ||
| GUI | v0.7.73 | requires libmediainfo0 | ||
| CLI | v0.7.73 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.73 (devel) | requires libzen0 | ||
| libzen0 | v0.4.31 (devel) | |||
| x86_64 | openSUSE 12.3, x86_64 | |||
| GUI | v0.7.73 | requires libmediainfo0 | ||
| CLI | v0.7.73 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.73 (devel) | requires libzen0 | ||
| libzen0 | v0.4.31 (devel) | |||
| 12.2 | i586 | openSUSE 12.2, i586 | ||
| GUI | v0.7.73 | requires libmediainfo0 | ||
| CLI | v0.7.73 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.73 (devel) | requires libzen0 | ||
| libzen0 | v0.4.31 (devel) | |||
| x86_64 | openSUSE 12.2, x86_64 | |||
| GUI | v0.7.73 | requires libmediainfo0 | ||
| CLI | v0.7.73 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.73 (devel) | requires libzen0 | ||
| libzen0 | v0.4.31 (devel) | |||
| 12.1 | i586 | openSUSE 12.1, i586 | ||
| GUI | v0.7.72 | requires libmediainfo0 | ||
| CLI | v0.7.72 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.72 (devel) | requires libzen0 | ||
| libzen0 | v0.4.30 (devel) | |||
| x86_64 | openSUSE 12.1, x86_64 | |||
| GUI | v0.7.72 | requires libmediainfo0 | ||
| CLI | v0.7.72 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.72 (devel) | requires libzen0 | ||
| libzen0 | v0.4.30 (devel) | |||
| 11.4 | i586 | openSUSE 11.4, i586 | ||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| x86_64 | openSUSE 11.4, x86_64 | |||
| GUI | v0.7.82 | requires libmediainfo0 | ||
| CLI | v0.7.82 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.82 (devel) | requires libzen0 | ||
| libzen0 | v0.4.32 (devel) | |||
| 11.3 | i586 | openSUSE 11.3, i586 | ||
| GUI | v0.7.53 | requires libmediainfo0 | ||
| CLI | v0.7.53 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.53 (devel) | requires libzen0 | ||
| libzen0 | v0.4.24 (devel) | |||
| x86_64 | openSUSE 11.3, x86_64 | |||
| GUI | v0.7.53 | requires libmediainfo0 | ||
| CLI | v0.7.53 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.53 (devel) | requires libzen0 | ||
| libzen0 | v0.4.24 (devel) | |||
| 11.2 | i586 | openSUSE 11.2, i586 | ||
| GUI | v0.7.44 | requires libmediainfo0 | ||
| CLI | v0.7.44 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.44 (devel) | requires libzen0 | ||
| libzen0 | v0.4.24 (devel) | |||
| x86_64 | openSUSE 11.2, x86_64 | |||
| GUI | v0.7.44 | requires libmediainfo0 | ||
| CLI | v0.7.44 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.44 (devel) | requires libzen0 | ||
| libzen0 | v0.4.24 (devel) | |||
| 11.1 | i586 | openSUSE 11.1, i586 | ||
| GUI | v0.7.41 | requires libmediainfo0 | ||
| CLI | v0.7.41 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.41 (devel) | requires libzen0 | ||
| libzen0 | v0.4.24 (devel) | |||
| x86_64 | openSUSE 11.1, x86_64 | |||
| GUI | v0.7.41 | requires libmediainfo0 | ||
| CLI | v0.7.41 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.41 (devel) | requires libzen0 | ||
| libzen0 | v0.4.24 (devel) | |||
| 11.0 | i586 | openSUSE 11.0, i586 | ||
| GUI | v0.7.28 | requires libmediainfo0 | ||
| CLI | v0.7.28 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.28 (devel) | requires libzen0 | ||
| libzen0 | v0.4.14 (devel) | |||
| x86_64 | openSUSE 11.0, x86_64 | |||
| GUI | v0.7.28 | requires libmediainfo0 | ||
| CLI | v0.7.28 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.28 (devel) | requires libzen0 | ||
| libzen0 | v0.4.14 (devel) | |||
| 10.3 | i586 | openSUSE 10.3, i586 | ||
| GUI | v0.7.22 | requires libmediainfo0 | ||
| CLI | v0.7.22 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.22 (devel) | requires libzen0 | ||
| libzen0 | v0.4.7 (devel) | |||
| x86_64 | openSUSE 10.3, x86_64 | |||
| GUI | v0.7.22 | requires libmediainfo0 | ||
| CLI | v0.7.22 | requires libmediainfo0 | ||
| libmediainfo0 | v0.7.22 (devel) | requires libzen0 | ||
| libzen0 | v0.4.7 (devel) |


Top
The top section is typically a "sticky" header that remains on the page as the user scrolls. It is a great place to place email signups, call-to-action buttons, a phone number, or a shopping cart for e-commerce sites.
Pro Tips:
- Make it stick
- Give it some contrast from the rest of the site
- Keep it simple
Header
The header section typically contains your navigation and your company logo.
Pro Tips:
- Don't overthink it
- Make the navigation inuitive
- Try to center the logo for something unique
Hero Section
The Hero Section should describe what your product or service is. Why did you create it? What problems does it solve.
Pro Tips:
- Simple, clear statements
- Give real information
- Use a clear voice
Social Proof
The Social Proof Section should back up your claims with success stories related to how others are using your product to solve problems.
Pro Tips:
- Be genuine and honest
- Provide specific examples
- Be relatable
Details
The Details section goes deeper into the specific features for your product. This is a greate place to list the price of your solution, compare it to competitors, and deep dive into features.
Pro Tips:
- Focus on headlines
- Use plain, clear text
- Make sure you answer the big questions about your service
Footer
The Footer is typically the last place your potential customer looks. So, make it useful! Add links to learn more, blog posts, cases studies, call-to-actions and more.
Pro Tips:
- Make is useful
- Provide a clear path forward
- Leave with a good impression
Site
Top Bar
Header
Navigation
Hero
Footer
Ready to get Started? Build my site now


${problemtype} • ${jurisdiction} • ${county} • ${servicearea}
Solution Status ${solutionstatus}%
Cost


Hindsight… It’s is a wonderful thing!
A couple of hours ago I received an automated email from our Travelblog site, saying that we had a new user registration; which was strange, since we disabled that feature a long time ago! Great! We’ve just been hacked!
I put my hands up in the air, I’d been running an old version of WordPress (2.2) … which I’ve been meaning to upgrade for a long time; but hey, I’ve bought a house, had a baby and build my business during that time! It’s not been at the top of my priories. So yes, I’m aware of the security holes/risks, etc.
Needless to say, WordPress 2.2 has an ugly security hole which allows hackers to remotely inject SQL statements into the database. I’d heard about this at the time, but thought I was covered because it relied on the hacker having a valid username/password (see the trac ticket). Well it seems they don’t!
Within a minute of receiving the new user registration email, I deleted the user account, changed our passwords and upgraded to WordPress 2.6 – which came with it’s own set of problems (i.e. all the category names disappeared).
Here are the details of the would-be hacker, so others know about him:
Username: sidon
E-mail: Dimka@hotmail.com


Web-enabled AR experiences
AR.js Studio is an open-source AR creation platform for building custom augmented reality experiences. You can create location-based or marker-based AR applications and deploy them straight to the web. That means you won’t have to download any extra apps to access your experience! Working with AR.js Studio doesn’t require any knowledge of coding, either. You can start creating your first AR project right now.
Pick your project type
Please, select a project type.


WITNESS LIST Public Education Committee March 15, 1999-2:00P HB 87 For: Eaton, Holly (Texas Classroom Teachers Association) Wall, Marjorie (Texas State Teachers Association) Against: Shaddix, Julian (Texas Association of Secondary School Principals) HB 144 For: Cotti, Rena (Self) Doerfler, Claudia (Self) Hollingsworth, Lonnie (Texas Classroom Teachers Association) Johnson, Lauren (Self) Kennedy, Albert (Self) Lara, Rene (Texas Federation of Teachers) Martinez, Cecilia (Self) Reeves, Henry (Self) Against: Bowie, Jim (Self) On: Curtis, Lonnie (Self) HB 269 For: Lain, Jackie (Texas Association of School Boards) HB 277 For: Bowman, Julie (Texas Federation of Teachers) Eaton, Holly (Texas Classroom Teachers Association) HB 294 For: Lara, Rene (Texas Federation of Teachers) Against: Lain, Jackie (Texas Association of School Boards) HB 371 Against: Lain, Jackie (Texas Association of School Boards) Soehnge, Karen (Texas Association of School Administrators) On: Lara, Rene (Texas Federation of Teachers) Tackett, Pamela (State Board for Educator Certification) HB 373 For: McLamore, Mike (Association of Texas Professional Educators) On: Lara, Rene (Texas Federation of Teachers) HB 451 Against: Lara, Rene (Texas Federation of Teachers) McLemore, Mike (ATPE) Moore, Katherine (Texas State Teachers Association) On: Anderson, David (Texas Education Agency) HB 478 For: Hale, Tillman (Calhoun County ISD) Moehler, Michael (Calhoun County ISD) Against: Lara, Rene (Texas Federation of Teachers) Wall, Marjorie (Texas State Teachers Association) HB 513 For: Cooper, Kelt (Self) Hayes, Patricia (Texas Classroom Teachers Association) Lain, Jackie (Texas Association School Boards) Soehnge, Karen (Texas Association of School Administrators) On: Kyser, Ben (Texas Department of Public Safety) Lara, Rene (Texas Federation of Teachers) Tackett, Pamela (State Board for Educator Certification) HB 669 Against: Lain, Jackie (Texas Association of School Boards) Moore, Katherine (Texas State Teachers Association) Soehnge, Karen (Texas Association of School Administrators) On: Kyser, Ben (Texas Department of Public Safety) Lara, Rene (Texas Federation of Teachers) Tackett, Pamela (State Board for Educator Certification) HB 725 For: Bechtol, Bill (Texas Elementary Principals and Supervisors Association) Jackson, Norma (Self) Patterson, Charles (Kileen ISD Board of Trustees) On: Lara, Rene (Texas Federation of Teachers) HB 728 For: Treisman, Philip (Self) On: Lara, Rene (Texas Federation of Teachers) HB 835 For: Haecker, Rita (Self) Lara, Rene (Texas Federation of Teachers) Malfaro, Louis (Austin Federation of Teachers) On: Tackett, Pamela (State Board for Educator Certification) HB 849 For: Doerfler, Claudia (Self) McLemore, Mike (ATPE) On: Magin, Suzanne (Self) Tidwell, Kaye (Self) Wills, Leslie (Self) HB 850 For: Lara, Rene (Texas Federation of Teachers) HB 1180 Against: Shaddix, Julian (Texas Association of Secondary School Principals) HB 1451 For: Davila, Noemi (Self) Granger, Michael (Self) Kettler, Meryl (Texas Troops to Teachers) Taylor, H.G. (Self) HB 1570 For: Grusendorf, Bill (Texas Association of Rural Schools) McLemore, Mike (ATPE) HB 1582 For: Lara, Rene (Texas Federation of Teachers) New Haschke, Donna (Texas State Teachers Association) HB 1784 For: Moore, Katherine (Texas State Teachers Association) Against: Bechtol, Bill (Texas Elementary Principals and Supervisors Association) Lain, Jackie (Texas Association of School Boards) On: Anderson, David (Texas Education Agency) HB 1786 For: Brown, Frances (Texas Nurses Association) Hanna, Mark (Texas Nurses Association) McComb, Michelle (Hays Consolidated ISD) HB 1803 For: Cooper, Kelt (Self) Purdom, Rachael (Self) Schultz, Wanda (Self) Against: Moore, Katherine (Texas State Teachers Association) Soehnge, Karen (Texas Association of School Administrators) On: Kyser, Ben (Texas Department of Public Safety) Lara, Rene (Texas Federation of Teachers) Tackett, Pamela (State Board for Educator Certification) HB 2117 For: Digneo, Bob (Southwestern Bell Telephone Company) Yawn, Larry (Houston Independent School District) Against: Wall, Marjorie (Texas State Teachers Association)


Grumpy Cat
Grumpy Cat. The cat that is always grumpy. You can count on him to have a grumpy attitude towards whatever you do.
- Famous on the Internet
- Grumpy
- Furry
- Medium-sized
- Price: $1337
Grumpy Cat. The cat that is always grumpy. You can count on him to have a grumpy attitude towards whatever you do.
Tree Cat. Is completely fascinated with trees. Recommended you buy him only if you have trees near where you live.
Surprise Cat. Randomly makes funny faces, whether you are looking or not. Nobody knows why she does this.
Kitten in a Boot. Loves to sleep in furry boots like shown in the picture.
Paint Cat. Somehow always manages to find paint to roll around in. Recommended you either get paint-proof furniture, or train him to wait till he is dried before going on sofas and beds.


All the dirt around
The corporate minions
The soldiers of nothing
It makes me feel
Ashamed
I blame myself
For having
Right in my head
At the same moment
Divagating in time
The image
The eyes
The heart
A delicate masterpiece
The small and infinite
Universe of light.
The shy smile
Makes me cry
Swamped in joy
For no reason
And all reasons
At the same time
I just
Give
All my spirit
To surround
To harvest
To protect
The most authentic
Pure
Tender
Smile of my life.


This page demonstrates the XML importer. The link in the head applies three tags.
ex:itemTags specifies which tags in the XML document should be taken as the (roots of) items. The tags are assumed to name the types of the items.
ex:labelProperties specifies, for each item type, the property of that item that should be used as the label for the item (its value is copied to the label property
ex:parentRelations is used if one item Y may be a descendant of another item X in the XML; it specifies, for each type, the name a the relation that should be used to connect the parent to its descendant in the generated data.


Simulate Vim movements with caps lock as the main modifier.
After trying a few different rules, they were too complicated and the feature set ended up not combining well with native MacOS modifiers.
The objectives of this rule set are:
| Key | Maps To |
|---|---|
| Caps lock | Escape |
| Caps lock + Return (if enable "CAPS+↩ › CAPS" rule) | Caps lock |
| Caps lock + A (if enable "CAPS+A › CAPS" rule) | Caps lock |
| Caps lock + H | Left arrow |
| Caps lock + J | Down arrow |
| Caps lock + K | Up arrow |
| Caps lock + L | Right arrow |
| Caps lock + D | Page Down |
| Caps lock + U | Page Up |
This rule was largely based on work done by "CAPS LOCK: Converts 'jkl;' to arrow keys, and 'spacebar' to a shift+opt modifier for easy text selection".


|
MISA++ Core
1.0.0
MISA++ core library
|
#include <misa_root_module_base.h>
Public Member Functions | |
| void | setup () override |
Additional Inherited Members | |
| Public Attributes inherited from misaxx::misa_module_interface | |
| misa_filesystem | filesystem |
Empty module definition for misa_multiobject_root
|
overridevirtual |
Initializes the data and sets them into relation with each other
Implements misaxx::misa_module_interface.


2013
The year I graduated from a third-tier college in Durgapur. I did not expect much from the college, mostly because of the poor placement record in the college.
To get myself a job, I was primarily going through hasjob.co and any job opportunities that came through Bangpypers mailing list.
Finally, I landed myself into an internship and later which turned into a full-time at HackerEarth was through the hasjob.co.
2018
5 years later, finding a job in a suitable company is still tough. In the last 5 years, I have come to know about more options, be it AngelList, Hasjob, StackOverflow, Facebook Job Groups etc.
But the problem still I think is the same, even if you apply through these websites a lot of times you don’t get a reply from the company you applied to. On the other hand, referrals work. I’ve referred good people to companies I know. This way, there is a chance of getting an interview in the company. Cracking the interview is a different story altogether which I believe depends a lot on the candidate.
Recently, I got to know that Prashant, one of my school senior and a close friend, who famously known in the tech community for his “Bitcoin Wedding” started an effort called “SkipTheLine”.
SkipTheLine is a newsletter where Prashant publishes profiles of three developers. These developers are from the community, who are active in open source, or competitive programming, or just good at technologies they work on. He goes on to introduce the developers through email with the companies point of contact via email and then the candidate and the POC take the discussion forward.
I personally loved the initiative that he took as at the end of the day if people whom I know come asking for a job referral I would just direct them to SkipTheLine. Prashant has quite a stronghold in the startup community and does great work in connecting the folks with some really good startup across the country.
I know people personally who got hired a within few days of their newsletter published so if you are looking out for a job, do fill out the SkipTheLine form.
If you are looking to hire, do drop me an email at gmail AT yudocaa DOT in.


WebTransport Test Page
Ready to connect...
WebTransport Server URL:
Due to the need to synchronize certificates, you cannot modify the url at this time.
Connect
Close active stream
Close connection
Create bidirectional stream
Create unidirectional stream
Open Streams
Empty
Send Message
Send
Communication Log
Timestamp
From
To
Data


Psalm 127
A song of ascents, of Solomon.
1 Unless Yahweh builds the house,
they work uselessly, those who build it.
Unless Yahweh guards the city,
the watchman stands guard uselessly.
2 It is useless for you to rise up early,
to come home late,
or to eat the bread of hard work,
for Yahweh gives his beloved sleep.
3 See, children are a heritage from Yahweh,
and the fruit of the womb is a reward from him.
4 Like arrows in the hand of a warrior,
so are the children of one's youth.
5 How blessed is the man that has his quiver full of them.
He will not be put to shame
when he confronts his enemies in the gate.


cFreedom6SDevice describes an interface to the Freedom6S haptic device from MPB Technologies Inc. More...
#include <CFreedom6SDevice.h>
Public Member Functions | |
| cFreedom6SDevice () | |
| Constructor of cFreedom6SDevice. | |
| virtual | ~cFreedom6SDevice () |
| Destructor of cFreedom6SDevice. | |
| int | open () |
| Open connection to MPB device. | |
| int | close () |
| Close connection to MPB device. | |
| int | initialize (const bool a_resetEncoders=false) |
| Initialize MPB device. | |
| unsigned int | getNumDevices () |
| Returns the number of devices available from this class of device. | |
| int | getPosition (cVector3d &a_position) |
| Read the position of the device. Units are meters [m]. | |
| int | getLinearVelocity (cVector3d &a_linearVelocity) |
| Read the linear velocity of the device. Units are in meters per second [m/s]. | |
| int | getRotation (cMatrix3d &a_rotation) |
| Read the orientation frame of the device end-effector. | |
| int | getAngularVelocity (cVector3d &a_angularVelocity) |
| Read the angular velocity of the device. Units are in radians per second [m/s]. | |
| int | getGripperAngleRad (double &a_angle) |
| Read the gripper angle in radian. | |
| int | setForce (cVector3d &a_force) |
| Send a force [N] to the haptic device. | |
| int | setTorque (cVector3d &a_torque) |
| Send a torque [N*m] to the haptic device. | |
| int | setGripperTorque (double a_gripperTorque) |
| Send a torque [N*m] to the gripper. | |
| int | setForceAndTorqueAndGripper (cVector3d &a_force, cVector3d &a_torque, double a_gripperTorque) |
| Send a force [N] and a torque [N*m] and gripper torque [N*m] to the haptic device. | |
| int | getUserSwitch (int a_switchIndex, bool &a_status) |
| Read the status of the user switch [true = ON / false = OFF]. | |
Protected Attributes | |
| void * | m_hf6s |
| Handle to device. | |
Static Protected Attributes | |
| static int | m_activeFreedom6SDevices |
| Reference count used to control access to the DLL. |
cFreedom6SDevice describes an interface to the Freedom6S haptic device from MPB Technologies Inc.
| cFreedom6SDevice::cFreedom6SDevice | ( | ) |
Constructor of cFreedom6SDevice.
Constructor of cFreedom6SDevice. Loads interface DLL.
| int cFreedom6SDevice::close | ( | ) | [virtual] |
Close connection to MPB device.
Close connection to Freedom6S device.
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::getAngularVelocity | ( | cVector3d & | a_angularVelocity | ) | [virtual] |
Read the angular velocity of the device. Units are in radians per second [m/s].
Read the angular velocity of the device. Units are in radians per second [m/s].
| a_angularVelocity | Return value. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::getGripperAngleRad | ( | double & | a_angle | ) | [virtual] |
Read the gripper angle in radian.
Read the gripper angle in radian.
| a_angle | Return value. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::getLinearVelocity | ( | cVector3d & | a_linearVelocity | ) | [virtual] |
Read the linear velocity of the device. Units are in meters per second [m/s].
Read the linear velocity of the device. Units are in meters per second [m/s].
| a_linearVelocity | Return value. |
Reimplemented from cGenericHapticDevice.
| unsigned int cFreedom6SDevice::getNumDevices | ( | ) | [virtual] |
Returns the number of devices available from this class of device.
Returns the number of devices available from this class of device.
Reimplemented from cGenericDevice.
| int cFreedom6SDevice::getPosition | ( | cVector3d & | a_position | ) | [virtual] |
Read the position of the device. Units are meters [m].
Read the position of the device. Units are meters [m].
| a_position | Return value. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::getRotation | ( | cMatrix3d & | a_rotation | ) | [virtual] |
Read the orientation frame of the device end-effector.
Read the orientation frame of the device end-effector
| a_rotation | Return value. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::getUserSwitch | ( | int | a_switchIndex, | |
| bool & | a_status | |||
| ) | [virtual] |
Read the status of the user switch [true = ON / false = OFF].
Read the status of the user switch [1 = ON / 0 = OFF].
| a_switchIndex | index number of the switch. | |
| a_status | result value from reading the selected input switch. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::initialize | ( | const bool | a_resetEncoders = false |
) | [virtual] |
Initialize MPB device.
Calibrate Freedom6S device. Initializes the driver, loading appropriate settings according to current Freedom6S configuration.
| a_resetEncoders | Ignored; exists for forward compatibility. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::open | ( | ) | [virtual] |
Open connection to MPB device.
Open connection to Freedom6S device.
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::setForce | ( | cVector3d & | a_force | ) | [virtual] |
Send a force [N] to the haptic device.
Send a force [N] to the haptic device
| a_force | Force command to be applied to device. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::setForceAndTorqueAndGripper | ( | cVector3d & | a_force, | |
| cVector3d & | a_torque, | |||
| double | a_gripperTorque | |||
| ) | [virtual] |
Send a force [N] and a torque [N*m] and gripper torque [N*m] to the haptic device.
Send a force [N] and a torque [N*m] and gripper torque [N*m] to the haptic device.
| a_force | Force command. | |
| a_torque | Torque command. | |
| a_gripperTorque | Gripper torque command. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::setGripperTorque | ( | double | a_gripperTorque | ) | [virtual] |
Send a torque [N*m] to the gripper.
Send a torque [N*m] to the gripper
| a_gripperTorque | Torque command to be sent to gripper. |
Reimplemented from cGenericHapticDevice.
| int cFreedom6SDevice::setTorque | ( | cVector3d & | a_torque | ) | [virtual] |
Send a torque [N*m] to the haptic device.
Send a torque [N*m] to the haptic device
| a_torque | Force command to be applied to device. |
Reimplemented from cGenericHapticDevice.


Testing Utilities Overview¶
Contents
WebDriverTestCase Assertion Methods¶
In addition to the unittest.TestCase
assertion methods, WebDriverTestCase
has additional assertions:
Method |
Checks That |
|---|---|
Element exists on the page |
|
Element does not exists on the page |
|
Element is scrolled into view |
|
Element is not scrolled into view |
|
Element is visible |
|
Element is not visible |
|
Element is enabled |
|
Element is disabled |
|
URL matches |
|
Base URL (ignoring query strings)
matches |
Each of these assertion methods accepts the following optional keyword arguments:
msg
: If specified, used as the error message on failurewait_timeout
: (Default =self.DEFAULT_ASSERTION_TIMEOUT
) Number of seconds to wait for expected conditions to occur before test fails
Some assertions have other optional keyword arguments specific to what they are
testing. For details, check the documentation for WebDriverTestCase
.
Page Object Prototypes¶
The webdriver_test_tools
package includes pre-defined subclasses of
BasePage
for common components like forms and navbars.
These classes define common methods and attributes to reduce the amount of code
needed to create page objects.
For more information on usage and the different prototypes available, see the following documentation:
Example¶
Suppose we have a “Contact Us” form with form validation that disables the submit button until required inputs are filled. When submit is clicked, a modal appears informing the user that their submission was successful. The modal has a close button that hides the modal when clicked.
To test the form submission process, we’ll need to have page objects for the
contact form and the success modal, as well as functions for filling out the
form inputs, submitting the form and getting the success modal page object, and
clicking the close button on the modal. We’ll need to create
pages/contact.py
with ContactPage
and SuccessModal
page object
classes for the “Contact Us” page and submission success modal respectively.
We’ll then need to create tests/contact.py
with test class
ContactTestCase
.
To save time writing tests, we can use the prototypes.FormObject
and prototypes.ModalObject
classes, which have pre-defined methods for most of the tasks we want them to
do.
import os
from selenium.webdriver.common.by import By
from webdriver_test_tools.pageobject import *
from webdriver_test_tools.webdriver import actions, locate
class ContactPage(prototypes.FormObject):
# Path to YAML file representing the form object
YAML_FILE = os.path.join(os.path.dirname(__file__), 'contact.yml')
# Relative to SiteConfig.BASE_URL
PAGE_FILENAME = 'contact.html'
# Page object class to return on click_submit()
SUBMIT_SUCCESS_CLASS = SuccessModal
class SuccessModal(prototypes.ModalObject):
# Path to YAML file representing the modal object
YAML_FILE = os.path.join(os.path.dirname(__file__), 'success_modal.yml')
The FormObject
parses the file specified with the YAML_FILE
attribute on
initialization:
form:
# REQUIRED: Locator for the form
form_locator:
by: ID
locator: contact-form
# REQUIRED: Locator for the submit button
submit_locator:
by: CSS_SELECTOR
locator: 'button[type="submit"]'
# List of inputs in the form
inputs:
- name: firstname
- name: lastname
- name: email
type: email
- name: message
type: textarea
This is used to set the attributes FORM_LOCATOR
and SUBMIT_LOCATOR
,
which are required to use the methods fill_inputs()
and click_submit()
.
If the SUBMIT_SUCCESS_CLASS
attribute is set, click_submit()
will return
an initialized page object of that type.
The ModalObject
parses the file specified with the YAML_FILE
attribute
on initialization:
modal:
# REQUIRED: Locator for the modal
modal_locator:
by: ID
locator: success-modal
# REQUIRED: Locator for the close button
close_locator:
by: ID
locator: close
This is used to set the attributes MODAL_LOCATOR
and CLOSE_LOCATOR
,
which are required to use the click_close_button()
method and other
ModalObject
methods.
Note
For more information on YAML syntax, see Page Object Prototype Syntax.
After creating those page object classes, we have everything necessary to
write our test in ContactTestCase
:
def test_contact_form(self):
"""Send message through contact form"""
# Initialize ContactPage form object
contact_page = ContactPage(self.driver)
# Generate form data
# NOTE: We'll write generate_contact_form_data() in the following section
contact_form_data = self.generate_contact_form_data()
# Fill all required fields
contact_page.fill_inputs(contact_form_data)
# Assert submit is enabled after filling required fields
# NOTE: SUBMIT_LOCATOR is set based on the 'submit_locator' value in contact.yml
self.assertEnabled(contact_page.SUBMIT_LOCATOR,
msg='Submit was disabled after filling form inputs')
# Submit contact form
# NOTE: click_submit() returns an instance of SUBMIT_SUCCESS_CLASS
# (which we set to SuccessModal)
success_modal = contact_page.click_submit()
# Assert success modal is visible on submit
# NOTE: MODAL_LOCATOR is set based on the 'modal_locator' value in success_modal.yml
self.assertVisible(success_modal.MODAL_LOCATOR,
msg='Success modal was not visible after clicking submit')
# Close success modal
success_modal.click_close_button()
# Assert success modal is no longer visible
self.assertInvisible(success_modal.MODAL_LOCATOR,
msg='Success modal still visible after clicking close button')
The fill_inputs()
method takes a
dictionary mapping input names to the values to set them to. In the Test Data
Generation section, we will create the generate_contact_form_data()
method
used to assign contact_form_data
in the above example.
Using Prototypes in New Page Objects¶
By default, page objects generated using the new page
command use a basic
template and subclass BasePage
. You can specify a page
object prototype to use as a basis for a new page using the --prototype
(or
-p
) argument:
<test_package> new page <module_name> <PageObjectClass> -p <prototype>
Where <prototype>
is one of the options listed when calling python -m
<test_package> new page --help
:
...
-p <prototype_choice>, --prototype <prototype_choice>
Page object prototype to subclass.
Options: {form,modal,nav,"collapsible nav","web page"}
...
The generated page object will subclass the corresponding prototype class and include any variable declarations used by that prototype’s methods.
Test Data Generation¶
The webdriver_test_tools
package includes some utility packages for
generating random user information and placeholder text to use for sample data:
The RandomUser
class generates fake user
information (names, emails, contact info, addresses, etc). The loremipsum
module generates lorem ipsum
placeholder text.
These utilities are imported in the webdriver_test_tools.data
module for
convenience. To use them, add the following import statement:
from webdriver_test_tools import data
Example¶
Continuing from the above example, we’ll add the following method to
ContactTestCase
:
def generate_contact_form_data(self):
"""Returns a dictionary mapping input names to generated user data"""
user = data.RandomUser({'nat': 'us'})
msg = data.loremipsum.generate(1, 'short')
form_data = {
'firstname': user.get_first_name(),
'lastname': user.get_last_name(),
'email': user.get_email(),
'message': msg,
}
return form_data
This method generates random user info and message text and returns a dictionary mapping form input names to the corresponding values.
Static Test Data¶
Some tests may require static data for testing (e.g. login info for a registered
user). These values can be stored in inside the <test_package>/data.py
module to keep them independent of test modules or page objects.
Example¶
Suppose we have a user registration form that displays an error when registering
with an email of an existing user. To test this functionality, we’ll need to use
an email that we know is already registered. We can add the following value to
the data
module and import it in our test modules:
# email for a registered user
REGISTERED_USER_EMAIL =<EMAIL_ADDRESS>We can then import it in our test cases. Since this data is independent of our test cases, it can be easily used in other tests (e.g. testing a sign in page). Additionally, if the registered user email changes at any point, it can be updated in a single place without altering the tests.
Screenshots¶
Take Screenshot on Test Failure¶
The WebDriverTestCase.screenshotOnFail()
decorator method can be used to
save screenshots when a test assertion fails. This can be particularly useful
when running tests using headless browsers.
class ExampleTestCase(WebDriverTestCase):
...
@WebDriverTestCase.screenshotOnFail()
def test_method(self):
...
See Configure Screenshot Directory and Filename Format for details on screenshot filename and path configurations.
Note
Currently, this method does not take a screenshot for assertions that fail
within a subTest. See the method's documentation
for more information.
Take Screenshots During Test Execution¶
The WebDriverTestCase.takeScreenshot()
method can be used to take screenshots at arbitrary points during test
execution.
class ExampleTestCase(WebDriverTestCase):
...
def test_method(self):
...
self.takeScreenshot()
This method accepts optional parameter print_filename
, which will print the
path to the new file to standard output.
See Configure Screenshot Directory and Filename Format for details on screenshot filename and path configurations.
Configure Screenshot Directory and Filename Format¶
Screenshots are saved to the directory configured in
WebDriverConfig.SCREENSHOT_PATH
, which is set to
<test_package>/screenshot/
by default.
Screenshot filenames are determined by the format string configured in
WebDriverConfig.SCREENSHOT_FILENAME_FORMAT
. The format string can include
the following parameters:
{date}
: Replaced with the date the screenshot was taken (YYYY-MM-DD)
{time}
: Replaced with the time the screenshot was taken (HHMMSS)
{test}
: Replaced with the test method running when screenshot was taken
{browser}
: Replaced with the browser used when screenshot was taken
The format string can include ‘/’ directory separators to save screenshots in
subdirectories of WebDriverConfig.SCREENSHOT_PATH
.
# The default output format
SCREENSHOT_FILENAME_FORMAT = '{date}/{time}-{test}-{browser}.png'
# Parameters can be used more than once
SCREENSHOT_FILENAME_FORMAT = '{date}-{time}/{time}-{test}-{browser}.png'
# Can include multiple subdirectories
SCREENSHOT_FILENAME_FORMAT = '{date}/{time}/{test}/{browser}.png'


SHUTDOWN
Section: Linux Programmer's Manual (2)
Updated: 2012-09-06
Index
Return to Main Contents
NAME
shutdown - shut down part of a full-duplex connection
SYNOPSIS
#include <sys/socket.h>
int shutdown(int sockfd, int how);
DESCRIPTION
The
shutdown()
call causes all or part of a full-duplex connection on the socket
associated with
sockfd
to be shut down.
If
how
is
SHUT_RD,
further receptions will be disallowed.
If
how
is
SHUT_WR,
further transmissions will be disallowed.
If
how
is
SHUT_RDWR,
further receptions and transmissions will be disallowed.
RETURN VALUE
On success, zero is returned.
On error, -1 is returned, and
errno
is set appropriately.
ERRORS
- EBADF
-
sockfd
is not a valid descriptor.
- EINVAL
-
An invalid value was specified in
how
(but see BUGS).
- ENOTCONN
-
The specified socket is not connected.
- ENOTSOCK
-
sockfd
is a file, not a socket.
CONFORMING TO
POSIX.1-2001, 4.4BSD (the
shutdown()
function call first appeared in 4.2BSD).
NOTES
The constants
SHUT_RD,
SHUT_WR,
SHUT_RDWR
have the value 0, 1, 2,
respectively, and are defined in
<sys/socket.h>
since glibc-2.1.91.
BUGS
As currently implemented,
checks for the validity of
how
are done in domain-specific code, and not all domains perform these checks.
Most notably, UNIX domain sockets simply ignore invalid values;
this may change in the future.
SEE ALSO
connect(2),
socket(2),
socket(7)
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- RETURN VALUE
-
- ERRORS
-
- CONFORMING TO
-
- NOTES
-
- BUGS
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 02:54:45 GMT, September 18, 2014


|
||||||||||
| PREV NEXT | FRAMES NO FRAMES |
| Packages that use Rule | |
|---|---|
| com.hp.hpl.jena.reasoner.rulesys | Provides a selection of simple rule engines for Jena inference models. |
| Uses of Rule in com.hp.hpl.jena.reasoner.rulesys |
|---|
| Methods in com.hp.hpl.jena.reasoner.rulesys that return Rule | |
|---|---|
Rule |
Rule.cloneRule()
Clone a rule, cloning any embedded variables. |
Rule |
RuleDerivation.getRule()
|
Rule |
RuleContext.getRule()
Returns the rule. |
Rule |
Rule.instantiate(BindingEnvironment env)
Instantiate a rule given a variable binding environment. |
Rule |
Rule.Parser.parseRule()
Parse a rule, terminated by a "]" or "." character. |
static Rule |
Rule.parseRule(java.lang.String source)
Parse a string as a rule. |
| Methods in com.hp.hpl.jena.reasoner.rulesys with parameters of type Rule | |
|---|---|
void |
ForwardRuleInfGraphI.addBRule(Rule brule)
Adds a new Backward rule as a rules of a forward rule process. |
void |
FBRuleInfGraph.addBRule(Rule brule)
Adds a new Backward rule as a rusult of a forward rule process. |
void |
BasicForwardRuleInfGraph.addBRule(Rule brule)
Adds a new Backward rule as a rules of a forward rule process. |
void |
FBRuleInfGraph.addRuleDuringPrepare(Rule rule)
Add a new rule to the rule set. |
void |
ForwardRuleInfGraphI.deleteBRule(Rule brule)
Deletes a new Backward rule as a rules of a forward rule process. |
void |
FBRuleInfGraph.deleteBRule(Rule brule)
Deletes a new Backward rule as a rules of a forward rule process. |
void |
BasicForwardRuleInfGraph.deleteBRule(Rule brule)
Deletes a new Backward rule as a rules of a forward rule process. |
boolean |
LPBackwardRuleInfGraph.processBuiltin(ClauseEntry clause,
Rule rule,
BindingEnvironment env)
Process a call to a builtin predicate |
boolean |
FBRuleInfGraph.processBuiltin(ClauseEntry clause,
Rule rule,
BindingEnvironment env)
Process a call to a builtin predicate |
boolean |
BackwardRuleInfGraphI.processBuiltin(ClauseEntry clause,
Rule rule,
BindingEnvironment env)
Process a call to a builtin predicate |
void |
RuleContext.setRule(Rule rule)
Sets the rule. |
| Constructors in com.hp.hpl.jena.reasoner.rulesys with parameters of type Rule | |
|---|---|
RuleDerivation(Rule rule,
Triple conclusion,
java.util.List matches,
InfGraph infGraph)
Constructor |
|
||||||||||
| PREV NEXT | FRAMES NO FRAMES |


Returns true iff transaction A is older than transaction B.
(defgeneric transaction-older-p (a b) (:documentation "Returns true iff transaction A is older than transaction B."))


Favorite Things?
Favorite Food:
Favorite Drink:
Favorite Color:
Favorite Book:
Favorite Movie:
Submit