## 1 Introduction  
Grapevines are one of the most economically important fruit species worldwide. The current world vineyard area is approximately 7.4 million ha and Portugal ranked fifth and eleventh as a wine producer in Europe and worldwide, respectively [1]. The viticultural and winemaking sector heavily relies on the ability to produce high-quality wines, which are in turn strongly dependent on grape berry chemical components and their concentration at harvest [2]. Although the suitability of a region for grapevine cultivation is largely controlled by growing season mean temperature that should range between 12 and 22 \({}^{\circ}\)C, other atmosphere-driven conditions, such as growing season length, radiation levels, winter minimum temperatures, spring and fall frosts or soil water balance, among others, are also important limiting factors [3]. Air temperature plays a central role in determining grapevine phenology [4], influencing the onset of phenological stages like budbreak, flowering and veraison and the phenophase intervals [5; 6]. Temperature also affects grapevine yield [7], wine production [8] and quality [9]. Relatively constant and moderate temperatures during ripening favour the biochemical processes of colour, flavour and aroma development in grape berries [10]. For rainfed grapevines, the water balance is mainly determined by precipitation, atmospheric humidity and soil water holding capacity [10]. The amount of annual precipitation and its seasonal distribution are also crucial to the evolution of the plant water status, with subsequent effects on berry quality [10]. Moreover, under extremely dry atmospheric conditions, stomata can close to preserve moisture, ceasing photosynthesis [11]. Nevertheless, some reported effects of water stress on grape berry quality attributes are contradictory, being strongly dependent on the local conditions, on the degree of water stress and on the period in which it occurred. The acid versus sugar balance is fundamental to build grape flavour, which ultimately determines the wine quality. Grape juice with low acidity often results in unstable mustable musts and wines that are more susceptible to organoleptic degradation (e.g., due to oxidative and microbiological spoilage [12]), while excessive berry acidity is commonly undesirable for the production of high-quality wines. The titratable acidity levels are frequently lower in warmer years than in cooler ones [13]. It was suggested that some of the strongest and most consistent negative links between titratable acidity and temperature are related to maximum temperatures [14]. In general, respiration of tartaric and malic acids, particularly malic acid, increases with increasing temperatures, thus leading to a drop in titratable acidity and increased pH [15; 16]. Total acidity also drops due to the dilution of acids caused by increased berry size, but in semi-arid regions, total acidity values are significantly higher under irrigation than in non-irrigated conditions [17], hinting at the need of a minimum of water availability for balance in berry composition to be achieved. Furthermore, higher levels of malic acid measured under those conditions of irrigation may be associated with greater synthesis during the growth period [17]. Overall, titratable acidity at maturity is preserved with moderate precipitation and/or irrigation [14], which can be explained by a combined effect, of enhanced vegetative growth prior to maturity with greater moisture availability and by the lowering of air temperature often associated with rainy weather. High temperatures promote sugar accumulation and thus higher potential alcohol levels [18; 19]. Previous studies showed that total soluble solids accumulation are greater at higher temperatures (30 \({}^{\circ}\)C) than lower temperatures (20 \({}^{\circ}\)C) at veraison and a few days after [20; 21]. During the growing season, the highest sugar content is frequently associated with drier years, while the lowest is related to rainier years [13].