text:
Have Ryanair, EasyJet and cruise ships ruined Europe?
Aug 30, 2018 – 11.00pm
It doesn't take long before the woman at the hotel reception pulls out a city map of Porto. Look, she says, there's the Old Town and the Douro, there's the harbour and here, by the way, the pride evident in her voice, is the world's most beautiful bookshop: Livraria Lello.
It sounds fantastic and the place looks even more amazing in the photos. It's located in a two-storey, neo-Gothic building with lots of dark wood, an abundance of old books, ornamentation and stained glass, and a curved staircase right in the middle. It was opened in 1906, a cathedral of books, a dream for voracious bookworms from all over the world. It has been said that JK Rowling often visited the Livraria when she lived in Porto at the beginning of the 1990s, a time when she taught English and began dreaming up the Harry Potter series.
The bookstore is every bit as beautiful as the one in the photos, even if it's not much of a bookstore these days. No one browses through the merchandise here. They all seem to be taking pictures with their smartphones – photos that look exactly like the more than 7000 images already posted on TripAdvisor, where Livraria is listed as one of the city's top sightseeing attractions.
A cruise ship passes the San Giorgio Maggiore Church in Venice. Alamy Stock Photo
Just like the rest of the country, Livraria Lello stood on the verge of bankruptcy four years ago as a result of the financial crisis. But even then, the bookshop had no lack of visitors. The problem was people were buying fewer and fewer books. Someone suggested the store ought to start charging an admission fee of €5. It may have sounded crazy at the time, but at least 4000 people now visit Livraria each day. The store had 1.2 million visitors in 2017 and revenues of over €7 million ($11.1 million).
If the thought of buying a book does cross a visitor's mind, and there are many tomes to be found here, the ticket serves as a credit towards that purchase. But Livraria ultimately feels more like a museum or a theatre backdrop than a real place.
Predatory modern tourism
More than anything, in fact, it has become a symbol for the predatory nature of modern-day tourism – a style of travel that is devouring all the beautiful places that drive it.
Portugal owes its recovery in part to double-digit growth in tourism, including in the areas in the once impoverished north around Porto. Ryanair and EasyJet have been flying to the city for years, and it has long been regarded as the new in-spot for city-escape tourism. Last year, about 2.5 million foreign tourists visited the region, and half of them visited Livraria Lello. Porto still hasn't become as overrun as places like Barcelona or Amsterdam, cities where locals have begun defending themselves against the hordes of tourists who seem to be taking over. But a divide has developed in Porto – between the tourist city and the city for locals. One can't help but wonder when a local last visited Livraria Lello. Do Porto residents also have to stand in line and pay €5?
There were times when the hotels lining the beaches in Benidorm, in Arenal on Mallorca and along the Adriatic Sea in Italy, were symbols of the ugliness of modern mass tourism. In retrospect, though, that era seems almost quiet. Benidorm and Arenal are cities that were created so Europeans would have a place to lie on the beach in summer. They are artificial resorts and not very nice, but they do serve a purpose: as factories for mass tourism that could just as easily be removed should the need arise.
Today, these tourist reserves no longer fill the demand. The crowds of sun-seekers have grown so large on the beaches of southern Europe, that some small bays on Mallorca should actually be closed due to overcrowding. Even along the North and Baltic seas in Germany, hotels are fully booked out in places like Sylt and Rugen.
David Rowe
Yet beach holidaymakers now comprise just under half of modern tourism in Europe, while the other half are cruise and city-escape travellers. For years, it's been tourists rather than local residents who have been shaping the image of some of Europe's most beautiful and unique cities. They are being transformed into museums and theme parks and are developing special zones for tourists where locals may work, but certainly don't live. Tourists sit in traditional restaurants devoid of locals as they watch other tourists. They are no longer places where people come together, but where divides seem to deepen. At times, it really does feel like a tourist invasion. They come, they stay briefly and then they are gone again, but they act as though they own the cities they visit.
The virtue of hospitality "which one wants to invoke is destroyed by making use of it", German writer Hans Magnus Enzensberger wrote in 1958 in his widely cited treatise on mass tourism. At the time, mass tourism as we know it hadn't even been invented, and travelling was still the privilege of the well-to-do. At most, those who could afford it would drive their modest VW Beetles from Germany over the Brenner Pass to Italy. For most people, a visit to Venice or Rome was something they could only dream about.
Modern-day tourism has little in common with that dream. An ever-growing fleet of budget airlines transport millions of people to the world's beaches and sights, long-distance buses offer trips at ridiculously low prices, and cruise ships dump thousands of passengers into the ports, with as many as five vessels a day docking in Palma de Mallorca, Barcelona and Dubrovnik, pumping additional hordes into city centres that are already hopelessly overcrowded. Once there, they eternalise their memories of the sights they see in the form of selfies. After that, it's on to the next hot spot.
Travel has gone from being a luxury product to an everyday good, with the boom in discount travel and the internet opening an increasing number of markets.
In Venice, a cruise ship passes through the Canale della Giudecca. Alamy Stock Photo
Tourist go home
With overloaded infrastructure and overcrowded cities and beaches, the travel industry seems to be choking on its own success. An estimated 670 million people travelled in Europe last year and it is likely that this summer alone, the continent hosted 200 million tourists.
It's not just Europeans exploring each others' countries. The boom is fuelled by people from countries that have benefited handsomely from globalisation. Much of the responsibility for the growth in global tourism lies with members of the newly emerging middle classes in Russia and with people from the Far East and Arab countries.
They also bear a significant share of the responsibility for the growing problems. The boom, after all, is also producing losers, and many of them have begun revolting, as recently seen in the pilot strikes at European budget carrier Ryanair, whose poor working conditions and low wages are what make the airline's low-cost strategy possible.
But residents of the cities and regions affected are perhaps the biggest losers. When, for example, it becomes more lucrative for property owners to rent their apartments to tourists on a daily or weekly basis than to locals who need an affordable place to live. Or when commuters have to squeeze into overcrowded public transportation because local buses and trains have been filled to capacity by tourists. Or when people no longer feel comfortable in their neighbourhood because they have become a minority in the cafes and restaurants they traditionally frequented. That is, assuming they can get in at all or afford the new prices.
Venice locals have started leaving messages for unwelcome tourists. Alamy Stock Photo
The tourism industry finds itself confronted by a group that it hadn't previously paid much attention to. Having always focused on the guests, it tended to overlook the hosts. "Tourism is a phenomenon that creates many private profits but also many socialised losses," says Christian Laesser, a tourism professor at the University of St Gallen in Switzerland.
Often the profits benefit very few – the landlords and hotel owners primarily, but also, to a much lesser extent, the often poorly paid employees working in the travel sector. The rest are stuck with the noise and the mess, the high rents and the feeling of being a stranger in their own country, like being an extra at a Disney World for tourists.
In many places, that feeling has manifested itself in expressions of open hostility. Activists paint "tourists go home" on the walls in many places overflowing with tourists, and in Mallorca, they even proclaimed a "summer of action", with protests against travellers at the airport and hotels. In Palma, activists have thrown horse droppings at tourists. In Barcelona they have pushed people from bicycles and harassed them in cafes. In Venice, self-proclaimed pirates have taken the dramatic step of blocking cruise ships from entering the port.
The notion that tourists are foreign invaders who represent some kind of threat to the local population's cultural identity broadly echoes the way refugees are viewed in large parts of Europe. But whereas hardship has driven the refugees from their homelands, the tourists are seeking to escape the boredom of everyday life.
The blossoming lavender fields at Alpes de Haute in Provence have become hugely popular with chinese tourists. Alamy Stock Photo
Barcelona has experience with both of these globalisation-driven migratory movements, but the protests there have only been directed at the tourists not refugees. Last year, 150,000 protesters even called on the government to allow more refugees into the country. "Immigration has changed the city, but tourism is destabilising it," Britain's Guardian newspaper wrote in June, describing the mood in the city.
'Overtourism'
The travel industry has begun recognising that its own success is increasingly undermining the foundation of its business model. "Overtourism" is the buzzword dominating industry conferences. Discussions are taking place about how tourist flows can be directed so they will no longer be perceived as a threat.
But is that possible with the number of tourists continuing to rise? In the emerging countries of Asia, umpteen millions of people ascend to the middle class each year, meaning they can suddenly afford to travel to exotic destinations. And they do. According to industry estimates, the number of tourists globally is expected to increase by 500 million by 2030, with the Chinese making up roughly half of that growth. And many of them will want to visit Europe and its sights – events like the lavender blossom in Provence.
It must have been during the summer of 2008, Jean-Paul Angelvin recalls. That's when a film team from China rang and asked if they could take a few shots in his lavender fields. "They filmed a young couple, and, after a few hours, they were finished. I didn't think much about it at the time," says Angelvin, an elderly gentleman wearing grey shorts and beige compression stockings. Angelvin and his family have been cultivating lavender in Provence for close to 40 years, at an elevation of 580 meters, on a plateau in Valensole.
Angelvin has gone through some hard times, like when prices hit rock bottom during the 1990s. But demand picked up again, and during the lavender blossom in June and July, the small boutique the family established also managed to produce a bit of profit.
Then summer 2012 arrived and Angelvin's shop turned into a gold mine. A growing number of tour buses began stopping in front of his boutique – buses filled with Chinese tourists. They wanted to perform exact recreations of the scenes they knew from the popular (and cheesy) Chinese TV series Dreams Behind a Crystal Curtain. They were the shots that had been filmed four years earlier in Angelvin's lavender fields. "Never in my life did I think this shoot would have triggered such a wave," the lavender farmer says. Jean-Frederic Gonthier of the regional tourism association estimates that 3000 Chinese visitors came the first summer after the start of series production. Today, he estimates, there are about 60,000 Chinese visitors each season.
"To create something out of the boom other than just suffering, we have to understand the Chinese," Gonthier says. To address the need, he trained Chinese-speaking guides and also hired two people to answer questions about the region on the Chinese messaging service WeChat. Gonthier hopes these efforts help change the vacationing patterns of the Chinese and motivate them to stay longer in the region rather than rushing through.
Travel has become almost a human right.
The lavender fields at Parc Naturel Regional du Verdon appear in a popular Chinese TV show, leading to a tourism boom in the area. Alamy Stock Photo
The travel industry is probably the most important economic sector in the world. It's far larger than the oil industry or the automotive industry and has an estimated turnover of €7 trillion a year, about 10 per cent of global economic output. In addition to direct revenues, this staggering sum also includes related business sectors such as the hotel trade or the transport industry with all its aircraft, cruise ships and buses. It also includes souvenir shops and travel agencies.
In Spain, popular among holidaymakers, the travel industry accounts for 14.9 per cent of the country's gross domestic product. And in many nations – Greece, Portugal, Spain, France and the Czech Republic, for example – the number of people entering the country exceeds the number of inhabitants. This creates jobs and modest prosperity, but it also establishes a certain dependency, which can also be dangerous if, as seen in Turkey and Egypt in recent years, there is a sudden plunge in the number of travellers.
Tourists, though, have begun returning to both countries. After all, when it comes to vacation, we tend to ignore potential terrorist threats or human rights violations – as long as the price is right and the weather is nice.
Cheap, cheaper, cheapest
Affordability is the main thing – and travel has indeed gotten much cheaper thanks to the internet. Travel portals like Expedia, Trivago and Booking.com have edged out established travel agencies and even pose a threat to major European travel companies like TUI or Thomas Cook, which previously dominated the package travel market. Such websites constantly offer flights and overnight stays at bargain prices.
In contrast to holiday providers from the era of package tours featured in catalogues, these digital competitors don't operate their own hotels and they don't own airplanes, cruise ships, travel agencies or other things with expensive overheads. Their money is earned solely by brokering services provided by others. They can literally control prices in real time on their platforms and they constantly optimise their algorithms to generate revenues. They collect targeted data on customer preferences and are even able to create tailor-made offerings on the fly.
This system, of course, wouldn't work without budget airlines. And without the internet, airlines such as Ryanair or EasyJet would not have become what they are today: the powerful drivers of the tourism boom. Thirty years ago, they didn't even exist. Back then, Europe was still strictly regulated, with specific rules on which airline was allowed to fly to what destination. Each country had its own airline, and national airlines weren't allowed to service domestic routes in other European countries. Usually, there were also limits on the number of seats that could be offered on cross-border flights. The regulations were in place to protect the respective national airlines that were, almost without exception, state-owned.
Air traffic in Europe only gradually began opening up in 1987. Irish budget pioneer Ryanair, in particular, benefited from market liberalisation, because it made excessive use of the new freedoms in air transportation. And because it was more consistent – and brutal – than any other company when it came to low costs. Budget carriers in Germany and Europe have a 30 per cent market share today, a figure that is still growing.
Thanks to low ticket prices, travel has almost become a universal right, just like buying cheap T-shirts or shopping at a discount supermarket like Aldi. This has also meant that a weekend trip to Berlin or Barcelona was suddenly seen as a viable alternative to an excursion to the local lake – with dramatic consequences for the places and cities being visited. Barcelona, for example, has gone from being an insider tip to a mass destination, and budget airlines have a market share of almost 70 per cent in the city. At Berlin's Schonefeld Airport, budget carriers are responsible for almost 90 per cent of all arrivals and departures. In the past 10 years, the number of passengers at the airport has more than doubled, from about 6 million to almost 13 million travellers.
Young German tourists at a foam party hosted at Guaba Beach Bar on Sunny Beach, Bulgaria.
This has helped transform the German capital into one of the most popular destinations for overnight stays in Europe after London and Paris. During the evenings and on weekends, hundreds of young people from Europe can be seen partying across Berlin's central Mitte district.
For years it looked as if the two systems, traditional hub-and-spoke airlines and budget airlines, could continue to grow side by side uninhibited. But this summer, the model seemed to hit its limits. Flight cancellations, delays and re-bookings have become the order of the day. According to the International Air Transportation Association (IATA), delays in air traffic in Europe increased 133 per cent during the first half of the year. Some airports, such as those in Frankfurt, Dusseldorf and Berlin, are asking travellers to arrive at the airport up to three hours before takeoff so they can cope with the masses.
The already heavily loaded system isn't designed for such a boom. And it's unlikely the situation will change soon. European air traffic controller Eurocontrol even expects the number of flights departing up to two hours late to increase sevenfold by 2040.
The rising stress associated with travel, however, is not enough to deter tourists. Sociologist Paolo Giuntarelli thinks he knows why: "Mass tourism is a phenomenon of our post-materialistic society. Possessions are no longer a priority – we just want to be entertained."
A city overrun
Giuntarelli is the head of tourism for the Lazio region, with offices located in Rome. He's here to hold down the fort, with many Romans having fled to the countryside in the height of summer. It is too hot for them in the city.
But the high temperatures don't appear to have deterred visitors to Rome.
There are weeks when the Italian capital is overrun – like at the end of July, when 60,000 altar boys and girls from across Europe invaded the city, including 50,000 from Germany. The motto of the pilgrimage was: "Seek peace and pursue it!" Above all, though, it was the sights they pursued.
On Tuesday night, they visited the Pope. When their audience ended, St Peter's Square was littered with plastic bottles, lyrics to hymns, Haribo bags and banana peels. The situation was similar at Pius XII Square, located just before it. The garbage bags on the side of the street had long since overflowed or burst. Even the pious produce refuse.
A number of Barcelona residents are pushing back against the massive tourist influx to the City. Alamy Stock Photo
Rome is all about long nights on the piazza, with pasta, red wine and jovial singing. Late at night, though, tourists are no longer allowed to drink alcohol on the streets of Rome, with Mayor Virginia Raggi having decreed in 2017 that the ban would be imposed each year between July and October.
Rome needs tourists – but it also needs to rein them in. This is most evident at the Trevi Fountain, where the first visitors start showing up early in the morning. Police stand guard around the clock so that nobody misbehaves. If someone holds their foot too close to the water, a carabinieri blows his whistle – and those who dare jump into the fountain face a fine of up to €450 under rules imposed last year by the mayor.
As a source of revenue, though, the visitors are highly welcome. Many throw coins over their shoulders into the fountain, because they believe it means they will return to Rome. Municipal workers regularly vacuum the coins out of the fountain, adding up to €1 million a year, which is donated to Rome's Catholic charity Caritas.
Marco D'Eramo lives next door to Rome's Colosseum. He can monitor the daily growth of tourism right outside the front door of his seven-storey building. Until about 15 years ago, all of his neighbours were Italian, now 12 of the 40 units are holiday rentals.
Not long ago, D'Eramo set out to write down what was happening around him. But he quickly realised that there was much more to the story. So he wrote a book called The World in a Selfie, which provides a thorough description of what he calls the "tourist era".
He believes the transformation of entire cities due to tourism follows a simple economic logic: The needs of the locals do not correspond with the needs of the tourists. Whereas a local resident might need a cobbler, the tourist wants a snack. With the rise of tourism, craftsman establishments are being transformed into fast food outlets – and the neighbour with worn-out shoes ultimately loses out.
The transformation of an entire city happens very fast, d'Eramo observed. If the Lonely Planet guide reports on a market, where "the locals do their shopping," more and more tourists flood the place. "At first it still looks authentic. But increasingly, items are sold that are of interest for tourists. And before long, the insider tip has become a purely tourist market."
In 2017, 14.7 million visitors poured through Rome's alleyways, representing one quarter of all visitors to Italy. Overnight visitors stayed an average of 2.5 days, much like in other major European cities.
The tourism party isn't over for young Germans at Sunny Beach, Bulgaria. Alamy Stock Photo
Travellers rarely end up in the surrounding areas, in Frascati, Tivoli or other parts of the region, known as Latium. Giuntarelli, Rome's chief tourism official, would like to redirect them to the smaller towns and cities, where they could experience the Italian way of life, "good food, good wine". Or follow the Way of the St Francis pilgrimage trail, which runs through Latium.
Giuntarelli extols the virtues of Latium in newspaper and radio ads and distributes pamphlets at tourism expos. One of them advertises Latium as a great site for a wedding, another presents Latium's thermal baths. Giuntarelli also wants to make the region known as a golf destination. "We're working on it," he says.
Little money, but lots of garbage
Because Latium isn't alone in its problems, the region has teamed up with NecsTour, a network of 37 European regions that have committed themselves to sustainable tourism, a form of travel that satisfies economies and vacationers without harming the environment.
In other words, the opposite of cruise ships. "That is not the tourism that we want to support," Giuntarelli says.
The gigantic ships belch massive amounts of pollution and contribute little to the regional trade or hospitality industries. Their passengers are only in the city for a few hours, they spend their nights on board and often eat food they bring with them when they go on land. They leave behind little money, but lots of garbage. "Cruise ship tourism is good," Giuntarelli says with a resigned smile, "for the cruise ship operators."
In Dubrovnik, Croatia, cruise ship passengers only spend an average of €24 a day compared to an average of €160 a day spent by other visitors. The city is suffering more than most from the onslaught of the tourists. Since its picturesque Old Town became the backdrop for the fantasy saga Game of Thrones, the number of visitors has risen dramatically. Each year, 800,000 people arrive on cruise ships.
Dubrovnik has 42,000 inhabitants – and most of them prefer to stay home when the cruise ships arrive. But because not only the residents, but also the medieval city structures themselves, are suffering, the number of visitors is to be reduced to 8000 people a day. Otherwise, UNESCO has threatened to strip the city of its status as a World Heritage site.
"A new approach is now being considered – one that moves away from the one-sided thinking about growth that has characterised tourism policy in most cities so far," says urban planner Johannes Novy, who is researching urban development and tourism at London's Westminster University. He says that for too long, the question was: How do we lure more tourists to a city? "It was not about other goals, including the question of how one could work to counter the negative consequences."
Novy says tourism itself isn't always the problem, but certain aspects of it – "for example, the party tourism that is pervasive in many cities, or the long-time unrestrained boom in holiday rentals."
Increasingly, he says, those in positions of responsibility have begun trying to combat the "growing pains" associated with the travel boom, as Novy calls it. They want to redirect the streams of tourists, as officials in Rome are trying to do, or even to limit them, as Dubrovnik is doing. Barcelona is no longer approving new hotels, Paris has strictly regulated Airbnb and other apartment-rental platforms and Palma de Mallorca has completely banned the renting of holiday apartments on the platform.
But still they exist, the cities and regions that welcome the tourists who are no longer as welcome elsewhere, where nobody gets worked up about constant parties and binge drinking rituals.
Daniel Stefanov is standing on a podium, squeezed between a street and the beach, where he watches the crowd as it sinks into the foam. His helpers have placed two foam cannons by the dance floor at the Megapark Dolphin, a giant, insane party venue that Stefanov has created with his business partners at Golden Sands, Bulgaria. From one cannon, the foam is spraying like raw cake batter onto the partying vacationers, while fine soap clouds are raining out of the other one. The crowd, standing in knee-deep foam, cheers.
Stefanov has come one step closer to fulfilling his goal: that of turning Golden Sands into a regular destination for partying German tourists, an alternative to El Arenal and Playa de Palma.
Fifteen years ago, Stefanov and his partner Sava Daritkov, 44, opened the outdoor nightclub Megapark Dolphin in Slatni Pjasazi, a vacation spot on the Black Sea. The club is filled with swimming pools and an adjacent dance floor. Eight years ago, they added the "partystadl", or "party city", where German pop music is played and a half-litre of beer costs the equivalent of €2.
Stefanov and Daritkov have invested a lot in their dream. They imported hefeweizen wheat beer from Germany and hired singers who otherwise performed at establishments in Mallorca that are popular among German party tourists. And they began organising foam parties. For €20 cover, visitors can drink the cocktails of their choice for an hour and get covered in foam, every Tuesday and Saturday.
This season has proven more successful than any that has come before. First came the wave of high-school graduates from Germany in the early summer. They were followed by football and bowling clubs. Their guests tend to be men and women in their early and mid-20s who only need three things for a successful vacation: "sun, sand and suds". The trend is likely to continue until late September, Daritkov says. And there is one more thing he really wants to say: "We're pleased about all the visitors."
It's a sentence that has taken on a new meaning in an age when tourists partying to excess with buckets of cheap sangria are no longer welcome in many places. Mallorca no longer wants to be a party island and has even banned nighttime binge drinking and sex on the beach. Golden Sands, the message seems to be, is cheap, and the party isn't over.
Niklas, Marvin and Marcel are standing at the bar at Megapark Dolphin holding a glass of vodka with peach, wearing bright green vests with the motto of their previous trip, an excursion last year to Mallorca: "Malle 2017. Buckets for everyone". They were there with about a dozen friends. The new rules on Mallorca, says Niklas, a 24-year-old car mechatronics technician, are the reason they decided to come to Bulgaria. He says they had witnessed in El Arenal how Spanish police arrived with three cars when a bucket of sangria was spotted on the beach despite the ban. They thought the reaction was a bit over the top.


text:
import logging

from elasticsearch.exceptions import RequestError, NotFoundError

logger = logging.getLogger(__name__)

class SchemaEnforcer(object):
    def __init__(self, client):
        self.client = client

    def enforce(self, schema):
        for name, template in schema['templates'].items():
            logger.info("Creating template %s" % name)
            self.client.indices.put_template(name=name, body=template)

        for index in schema['indexes']:
            logger.info("Creating index %s" % index['name'])
            self.create_index(index)

        for alias in schema['aliases']:
            logger.info("Creating alias %s" % alias['name'])
            self.create_alias(alias)

        for setting_cfg in schema['settings']:
            self.apply_settings(setting_cfg)

    def create_index_by_name(self, index_name):
        # By default ES will enforce whatever mapping mappings and settings are in the SI lib, IF the index name matches a template
        try:
            self.client.indices.create(index=index_name)
            return
        except RequestError, e:
            # index_already_exists_exception was introduced in ES 2.x
            if 'index_already_exists_exception' not in e.error and 'IndexAlreadyExistsException' not in e.error:
                raise

    def create_index(self, index):
        body = {}
        if index.get('mappings'):
            body['mappings'] = index['mappings']

        if index.get('settings'):
            body['settings'] = index['settings']

        try:
            self.client.indices.create(index=index['name'], body=body)
            return
        except RequestError, e:
            # index_already_exists_exception was introduced in ES 2.x
            if 'index_already_exists_exception' not in e.error and 'IndexAlreadyExistsException' not in e.error:
                raise

        if not index.get('mappings'):
            return

        for doc_type, mapping in index['mappings'].items():
            try:
                self.client.indices.put_mapping(index=index['name'], doc_type=doc_type, body={doc_type: mapping})
            except RequestError, e:
                # MergeMappingException is ES 1x
                if 'illegal_argument_exception' in e.error or 'MergeMappingException' in e.error:
                    logger.exception("Error merging mappings")
                else:
                    raise

    def create_alias(self, alias):
        existing = set()
        try:
            existing.update(self.client.indices.get_alias(name=alias['name']))
        except NotFoundError:
            pass

        actions = []

        for index in alias['indexes']:
            if index in existing:
                existing.discard(index)

            body = {'index': index, 'alias': alias['name']}
            body.update({key: alias[key] for key in ['routing', 'filter'] if key in alias})
            actions.append({'add': body})
        for index in existing:
            actions.append({'remove': {'index': index, 'alias': alias['name']}})

        if actions:
            self.client.indices.update_aliases({'actions': actions})

    def apply_settings(self, setting_cfg):
        print 'putting settings to %s, body=%s' % (','.join(setting_cfg['indexes']), setting_cfg['settings'])
        self.client.indices.put_settings(index=','.join(setting_cfg['indexes']), body=setting_cfg['settings'])

    def index_exists(self, index):
        return self.client.indices.exists(index=index)

redpajama_set_name: RedPajamaGithub


So I wanted to write a python script to automate the installation of certain types of AUR packages. However, I am unsure about the most preferred, if not the best way to send commands to bash using python such as downloading AUR packages from the website and installing them. And as a relatively non-experienced person, I would like to hear your suggestions before starting this mini-project.
Be nice and live for others.
Python evolved over time with a number of unrelated and ad-hoc methods to run external programs like os.system, backquote, os.spawn etc. They were generally adopted from other languages for alternative use cases. Around python 2.4 all these were depreciated when the subprocess module was introduced to replace them in a consolidated manner. Even then, subprocess itself evolved further until subprocess.run() was introduced in 3.5 and that is what you should now prefer, except for some advanced cases which require subprocess.Popen(). I have found it interesting to watch this particular API design converge over the many years it took the Python devs to get to where they are now.
Why would you spawn a bash process from python? Just do the shell work in python. The above mentioned `subprocess` is also my recommendation for starting some other process - but there is no case in which that other process should be BASH. You may run makepkg, or pacman via subprocess, but what do you think you need BASH for?
My own AUR tool written in python uses subprocess.run for spawning git commands to clone and subprocess.check_output to get the results from pacman for local packages. I don't recall the details, but I believe there has been some back-and-forth on whether check_output of Popen would be better for the latter use, but for my purposes the former works well.
Thank you for your suggestion. I would like to state that I am not a linux expert. Therefore, I could not totally understand what you meant. Wouldn't running pacman, makepkg via subprocess be considered sending commands to bash? Aren't such commands bash commands themselves?
Wouldn't running pacman, makepkg via subprocess be considered sending commands to bash? Aren't such commands bash commands themselves?
Git and makepkg are binary executables: they can be executed directly. You can type them on the command line of an interactive shell (bash, ash, ksh, etc) and the shell will spawn git or makepkg as a subprocess of itself, but this is pointless if your goal is just to run git or makepkg: why add a pointless (bloated) middleman?
This does not start any shell to run git, it runs git directly.
Part of this is just terminological issues, but I think there is a bit more to it than that. Binary executables do not need a shell to run. But even if it is just terminology, your search results will be much better if you google (or ddg) for something like 'run git from python' or 'start other process from python' rather than 'send bash commands from python' as BASH here is a red herring.
For added background, there is a linux system call `exec` (there's actually a family of exec functions in C like execv execl execvp ...). This `exec` call starts a new process running the binary executable passed to this system call. When you run a bash shell and you type a line and hit enter, much of the time that line is chopped up (tokenized) by bash, then just sent to the exec system call. Python's subprocess is the python interface to this same `exec` system call (more or less). So python can `exec` git directly, there is no need to `exec` bash just to ask bash to `exec` git.
That was a very intuitive explanation. Thank you for elaborating. Can we say that every package's bash commands are basically binary executables and do not necessarily need a "middleman"? Or is it not always the case?
It's not *always* the case.
makepkg is actually a bash script. The first line has a "shebang" (#!/usr/bin/bash), and the file has executable permission. So when this file is `exec`ed the system see's the shebang and starts bash as an interpreter for the script. So bash is needed here regardless. But if you use the longer `subprocess` command above from python, you'd launch bash to exec makepkg which in turn would launch a new bash process. So you'd add an *additional* bash process which is not needed: you'd have bash->bash->makepkg as the process tree rather than just bash->makepkg.
Gtester-report is a python script. So if you `exec` it, the system will start a python process to interpret gtester-report. But here, there is no bash needed at all. If you start bash to run gtester-report you'll have bash->python->gtester-report as the process tree rather than just python->gtester-report which is all that is needed.
Ahh I see. Everything is crystal clear now. Thanks a billion!


FC Barcelona will make their 2013/14 debut in their new away kit which figures the Catalan flag – the Senyera. The game against Bayern Munich will be Barça's first game of the pre-season, after the match in Gdansk last Saturday was postponed following the announcement of Tito Vilanova's standing down.
Two seasons ago, when Barça also played a pre-season friendly in Munich, playing Bayern in the final of the Audi Cup, they again wore their away strip. This year's new shirts have been a massive success amongst fans and have been selling really well during the first few weeks it has been on sale.
Kick off time for the game in Munich has been brought forward two hours to 18.30, with the German TV company covering the game also committed to the broadcast of the Women's European Championship semi-final, which will feature the German national team. The change in kick off time was foreseen in the original deal to set up the game, because of the agreement with the German TV company with UEFA, should the German team reach this stage of the competition.


text:
A Masterpiece of Digital Technology: History Told in 3D mapping at St. Michael's Fortress
Two underground water tanks that date back to the 15th century were hidden inside Šibenik's St. Michael's fortress for a long time. Soon, inside them, the legend of Šibenik's creation and the turbulent history of the fortress will come alive. Thanks to the European project Fortress ReInvented – Innovative approach and digital contents in historical fortification monuments, St. Michael's Fortress will become richer in terms of a visual masterpiece via 3D video mapping projection technique inside the tanks. By this project Šibenik continues and remains the trailblazer in interactive presentations of cultural and historical contents.
In one tank, the biblical story of the battle between Good and Evil and the victory of St. Michael, Šibenik's patron, over the embodiment of evil, the dragon, will be evoked. In the second tank the history of Šibenik will be depicted, with an emphasis on the role of St. Michael's fortress as a foundation for the whole city. Seen as how the narrative is set inside cistern areas that are crisscrossed by arches, those bacome a breakpoint in the elaboration of a scenario based on time travel: the tanks' arches become a sort of casters which launch the system and set the year, or rather the era in which the travelers (visitors inside cisterns) stop and to which they bear witness.
To provide additional contents besides 3D mapping on cistern walls, the appropriate audio backdrop will be used to create a complete sensation of a virtual space, in which visitors will be given a unique taste of St. Michael's fortress, which will contribute significantly to the enhancement of visitor experience and the charm of the monument itself.
The work on the implementation of the equipment and the contents is currently in its final stages. Jelena Filipaj, the representative of the Produkcijski tim company, responsible for the development of the audiovisual contents, talks about the complexity of accomplishment of the project: ''This project is comprehensive and very complicated in material preparation. No one in Croatia has yet met with a project this challenging, and we believe there haven't been or there aren't any similar examples either abroad. Conceptualizing cultural heritage coming alive by mapping technology is not revolutionary in itself. However, never before has, at least that we know of, this kind of project been accomplished in small, intimate areas that bear the mark of times in their walls and this close a vicinity. The challenge is even greater because this space is not typical – not round but curved. The curvature of the surface is precisely what defines the approach to material production. To be able to monitor the work in progress, or rather to check if everything fits, a complete VR (virtual reality) simulation is necessary.''
Apart from the contents in cisterns, St. Michael's fortress will get audio guides – tablets containing digital and audio contents arranged over 12 theme units. The distinctiveness of it lies in the fact that the content of the guides will launch independently at the moment of passing the designated points. In that way, the visitors will obtain an impression of time travel.
Four partner fortresses in three countries were included in this project: besides St. Michael's fortress, digital contents will also be implemented at Klis fortress in Klis (HRV), at Kanli Kula fortress in Herceg Novi (MNE), and Old Town Vranduk in Zenica (BIH). With the goal of cross-border cooperation in sight, four cultural attractions – fortresses in Croatia, Bosnia and Herzegovina and Montenegro will be connected via so-called partners' corner. It is a touch screen containing a single joint app via which visitors at each of the fortresses will be able to follow live the present goings-on at three remaining monuments (live stream technology).
Additionally, to determine the fortresses-partners as tourist attractions, in all of their four home towns inside old city centers, there will be touch screens placed as info points that will promote the offer of the fortresses, of the city, of the partner destinations, and also of local small and middle-sized entrepreneurship units.
The Fortress ReInvented project started on July 1st of 2017 and ends on December 31st of 2019. The project holder is Šibenik City Museum in partnership with Municipality of Klis, Municipality of Herceg Novi and Public Institution Zenica City Museum. Its total value comprises 1.310.232,30 EUR out of which 85% of co-financing came from the program Interreg IPA CBC Croatia – Bosnia and Herzegovina – Montenegro 2014-2020. The principal objective of the project is increasing and advancing sustainability and tourist offer by implementing digital contents at four partner fortresses – St. Michael's fortress in Šibenik, Klis fortress in Klis, Kanli Kula fortress in Herceg Novi and Old Town Vranduk in Zenica.

redpajama_set_name: RedPajamaCommonCrawl


text:
Q: Novel/Story with wireheads? I remember reading a long time ago a novel where some people who, through a surgical operation had a wire connected to the pleasure center of their brains. They could just plug themselves in, it became an addiction. The were called wireheads. Does anyone recall what novel that was ?

A: Per wikipedia:

In Larry Niven's Known Space stories, a wirehead is someone who has
been fitted with an electronic brain implant (called a "droud" in the
stories) to stimulate the pleasure centres of their brain. In the
Known Space universe, wireheading is the most addictive habit known
(Louis Wu is the only given example of a recovered addict), and
wireheads usually die from neglecting themselves in favour of the
ceaseless pleasure. Wireheading is so powerful and easy that it
becomes an evolutionary pressure, selecting against that portion of
Known Space humanity without self-control. Wireheading need not use an
actual brain implant; the pleasure centre can be remotely activated by
a small device called a "tasp" (important in the Ringworld novels)

"Wireheading" appears in several Niven works, notably Flatlander and the Ringworld Engineers

She reminded me of a wirehead. You can't get a wirehead's attention, either, when house current is trickling down a fine wire from the top of his skull into the pleasure center of his brain. But no, the pure egocentric joy of a wirehead hardly matched Charlotte's egocentric misery. Flatlander - Larry Niven

and

Times change. Generations later, these same cultures usually see
current addiction as a mixed lessing. Older sins—alcoholism and drug
addiction and compulsive gambling—cannot compete. People who can be
hooked by drugs are happier with the wire. They take longer to die,
and they tend not to have children.
It costs almost nothing. An ecstasy peddler can raise the price of the
operation, but for what? The user isn't a wirehead until the wire has
been embedded in the pleasure center of his brain. Then the peddler
has no hold over him, for the user gets his kicks from house current.
And the joy comes pure, with no overtones and no hangover. Ringworld Engineers - Larry Niven

redpajama_set_name: RedPajamaStackExchange


text:
Home/Leaders/President Kim Il Sung/President Kim Il Sung's Anectodes/The Aide Severely Criticized
The Aide Severely Criticized
Immediately after Korea's liberation, Kim Il Sung's bedroom and drawing-room were quite simply furnished, with only an ironframed bed and a round table respectively.
His aide purchased a bed, desk and carpet from a furniture store at Sadong. Everybody was glad that the rooms had become brighter.
That evening when he returned home, Kim Il Sung showed his displeasure.
"Who brought them?" he asked in an angry tone of voice.
"I did," stammered the aide.
Kim Il Sung scolded him there and then that he was so concerned about furnishing, and continued You too know about the living conditions of the people. The country has been liberated, but the workers and peasants are still hard-pressed. If we lead a luxurious life from the beginning, we cannot continue the revolution. We never made revolution for the sake of our own luxury. At present, we must do our utmost to make the country rich and strong and the people well-off as soon as possible.
After a pause, he added firmly "Whoever we might be, we must not live above the people's living standards!"
He Lives on in the Heart of Mankind
Korea Today 2015
Members of Leadership Body of Party Central Committee Visit Kumsusan Palace of the Sun
By the Hwangju Stream


Recent Google searches that brought visitors to this page: creme de menthe-sugar & carbs, What is the purpose of alcohol in creme de menthe, how much alcohol is in creme de menth, what is the alcoholic conten in creme de mint, Does creme de menthe contain alcohol, creme de minth alcohol percent, creme de menthe liqueur alcohol caffeine content, How much alcohol is in cream demint, how many ounces is creme de menthe glass, creme de menthe does it contain alcohol, How many calories in a serving of Creme De menthe\, how much sgar is in creme de menthe, creme de menthe printable labels, creme de menthe pie fat content, creme de menthe sugar content, caffeine in creme de mint, creme de menthe nutritional information, creme de.menthe alcohol.content, is creme de menthe high in alcohol, is creme de menthe high glycemic?
The chart below shows how much of the recommended daily intake (RDI) of each vitamin that 33.6g (1.19 oz) of Creme de Menthe 72 proof contains.
The chart below shows how much of the recommended daily intake (RDI) of each mineral that 33.6g (1.19 oz) of Creme de Menthe 72 proof contains.
Proteins are made up of chains of amino acids. A complete protein contains all essential amino acids. We are currently compiling pages describing the benefits of nutrients and recently wrote about the benefits of Arginine. The chart below is a visual guide showing how complete the protein in Creme de Menthe 72 proof is. The chart shows all amino acid and amino combinations for which the World Health Organization (WHO) publish a recommended daily intake (RDI).
The chart below shows the balance of essential amino acids in 33.6g (1.19 oz) of Creme de Menthe 72 proof. The distance from the center shows how much each amino acid contributions to your recommended daily intake (RDI). Please note that this chart is for 33.6g (1.19 oz) of this food item. Increasing the weight will show a larger contribution to your RDI.
33.6g (1.19 oz) grams of Creme de Menthe 72 proof contains 13.9776 grams of carbohydrates which is 5% of your recommended daily carbohydrate intake acording to the Food and Drug Administration guidelines for a 2000 calorie diet. The table below shows how much this food contributes to your recommended daily intake for different total daily calories consumed.
The chart below shows good fats in Creme de Menthe 72 proof in relation to bad fats. Read more about each type of fat and fatty acid below.
To lose weight, you need to burn more calories than you consume. The table below shows how long you need to perform various types of exercise to burn the 125 calories contained in 33.6g (1.19 oz)g of Creme de Menthe 72 proof. The calorie burn rates for each exercise are included and are based on the US Department of Health and Human Services Dietary Guidelines for Americans.


THIS Saturday, October 20 and Sunday, October 21, top flight football across Europe's elite leagues returns after a two-week international break. Saturday, especially, there are some eye-catching encounters in England and Spain, and JustBet previews two of those tantalising duels for you. Firstly, we hit the train for London where the 'Blue Power' of Chelsea hopes to blow out the flames of the Red Devils of Manchester, after which we jet over to Spain where league leaders Sevilla try to ambush Barcelona in their backyard.
What a game to kick-start the English Premier League (EPL) after the international break. Two of the EPL heavyweights, Chelsea and Manchester United, will be clashing in an eagerly anticipated showdown with both bitter rivals looking for a win more so Man United.
It's the return of the "Special One" to his former stomping ground where he looks to halt Chelsea's unbeaten start to the season.
Chelsea, in particular, are keen to get the win to make a title statement in front of their home crowd in this big match-up. They have taken an impressive 20 points from a possible 24 under their new coach as they quickly adapt to life under Italian Maurizio Sarri who replaced Antonio Conte this past summer.
Meanwhile, a beleaguered Man United are hoping to stage an upset and sneak out of the "Bridge" with maximum points. Their coach, Jose Mourinho, appeared on the brink of being fired at Old Trafford before a huge comeback victory against Newcastle, before the international break gave the United boss a little breathing space. Chelsea have three wins to United's two wins in their last 5 meetings.
Now we turn our attention to Spain for our second match on Saturday at 1:45 local time. This expected thriller sees La Liga champions Barcelona welcome the surprising current league leaders Sevilla to the Nou Camp looking to make a statement win to get their season back on track after a stop-start affair so far.
Despite Lionel Messi putting in some stunning performances, a leaky defence and passive attack have seen Barcelona's title defence in disarray. They have gone winless in their last four La Liga games. With Real Madrid also failing to impress so far this term, that has allowed a sneaky Sevilla to make an early impression, albeit an early one. Sevilla will be hoping to exploit Barcelona's obvious weakness at the back come Saturday. Barca's defensive leader Gerald Pique has made three errors leading to goals this season, costing his team five points. In contrast, Sevilla has been banging in the goals recently, and they can take advantage of Barca's lack of form and create a stunning upset here.
That said, Barcelona has conceded in all their seven league games this term, while Sevilla has scored two or more goals in each of their last four league games. Based on the foregoing, we expect lots of goals in this one and Barcelona to return to winning ways.
Football fans, you will be treated to some exhilarating matches this weekend, so grab a Beer and kick it with us and enjoy the game with JustBet and win with us.
ful aray of beting options.


We have done a few MVP chat's before on other mediums including Twitter and Yammer, but we thought it would be fun to take our MVP chat concept over to Reddit in the SharePoint subreddit /r/sharepoint. We've never tried this before on Reddit so we are hoping you all have lots of questions for us on Wednesday, Oct. 29th at 1pm Eastern.
Microsoft MVP Lead Melissa Travers will be on hand to answer any questions pertaining to the MVP Award Program.
Please feel free to tell the world (#spmvpchat) on Twitter to come to reddit.com/r/sharepoint for the AMA!


A little bit of planning can go a long way to minimising your capital gains tax (CGT) bill. Read on to find out tips and traps that may help you minimise the tax you have to pay.
A capital gain or loss is the difference between what it cost you to buy a parcel of shares and what you received when you sold them. If you make a gain, this amount is added to your income and is then subject to your marginal rate of tax.
Do you have any capital losses?
If you make a capital loss, you cannot claim it against income but you can use it to reduce a capital gain in the same income year.
If your capital losses exceed your capital gains or you make a capital loss in an income year and you don't have a capital gain, you can carry the loss forward indefinitely and deduct it against capital gains in future years. Before your capital gain is added to your income it can be reduced by capital losses you have made in the current or past financial years.
There are three ways to work out your capital gain. You can choose the method that gives you the best result, i.e. the method that gives you the smallest capital gain.
Although two of the methods reduce the amount of your capital gain, you need to have owned the shares for at least 12 months before you sell them.
If you sell shares that you have owned for less than 12 months the full capital gain will be assessable for income tax purposes.
For more information on working out your CGT click here to view the Australian Taxation Office (AT0) guide to the three calculation methods.
Since 19 September 1999, if you purchase shares and subsequently sell or transfer ownership after holding them for more than 12 months you are entitled to a 50% discount.
Ken earns $85,000 per year as a landscape gardener. He buys 3,000 shares for $2.00, valued at $6,000 with brokerage paid separately on 15 July 2012. The shares are trading at $4.00 throughout July 2013. If he sells his shares for $4.00 on 14 July 2013, his assessable capital gain will be $6,000, i.e. $3,000 x $4.00 = $12,000 less what he paid for them which was $6,000.
If Ken held the shares for an extra two days and sold them on 16 July 2013 his assessable capital gain would be $3,000 as he is entitled to the 50% CGT discount. This is because he held the shares for more than 12 months.
Assuming he had no other capital losses or deductions, holding his shares for longer than 12 months, has earned Ken a tax saving of $1,110.
When lodging your tax return you will need the purchase and sale prices of shares you have sold in the previous financial year. This information can be found on your contract notes.
When lodging your tax return you will need the purchase and sale prices of shares you have sold in the previous financial year. This information can be found on your contract notes. Also, remember to keep any tax invoices for any deductible expenses.
If you participated in a dividend re-investment plan you will find the purchase price of each parcel of shares on your dividend statement. For more information on CGT click here to view the ATO guide. For more information on financial products please visit: www.mywealth.commbank.com.au or email peter@mywealth.com.au. This article is to be read as a guide only and may not suit your individual circumstances.