Visual Studio 1.82

  • 12/September/2023
  • Paul Krill

Visual Studio 1.82, the newest iteration of Microsoft’s popular open source code editor, features built-in port forwarding, for sharing services over the internet with others. WebAssembly debugging also is highlighted in the release.

Introduced September 7, VS Code 1.82 introduces a port forwarding system that allows developers to share locally running services over the internet with other people and devices. To use it, developers select the Forward a Port button in the Ports view available on the Panel region.

VS Code 1.82 also improves debugging for WebAssembly. With the new release, VS Code’s JavaScript debugger now will automatically decompile WebAssembly modules to the WebAssembly Text Format and allow developers to step through and set breakpoints in decompiled modules.

 

Visual Studio Code vs. Visual Studio: How to choose 

VS Code 1.82, also known as the August 2023 release, also now displays the Command Center by default. Introduced last summer as a quick way to discover and interact with VS Code, Command Center can be used as a launch pad for finding a command in the Command Palette, running a task, and other quick experiences.

Developers can download VS Code 1.82 from the project website for Windows, Linux, or Mac. This month’s release follows last month’s VS Code 1.81, which brought diff editor improvements and GitHub capabilities. Other new features and improvements in VS Code 1.82:

  • The diff editor is enabled by default, with improvements and bug fixes.
  • Code detection has been polished, and can be enabled with "diffEditor.experimental.showMoves": true or in the diff editor context menu.
  • For notebooks, the cell output menu now has an option to copy the output to the system clipboard.
  • The “status area” below the filter box in the Testing view now is more concise and provides a clickable action to rerun the most recently run tests.
  • Source map loading has been improved. Source maps in some common cases like applications compiled with the ts command line now are loaded 3x to 5x faster. Hot module reloading from the Vite dev server now is supported. Source maps also can be automatically loaded from authenticated endpoints.
  • The Move to File refactoring for JavaScript and TypeScript lets developers move a class, a function, or constant into an existing file.
  • TypeScript 5.2.2 ships with the editor, bringing language features, better performance, and bug fixes.

77th Independence Day

  • 15/August/2023
  • Ankit Patel

On August 15, 2023, India will proudly celebrate its 77th Independence Day, marking 76 years of freedom. The theme for this year’s celebration is “Nation First, Always First,” an integral part of the broader “Azadi Ka Amrit Mahotsav” Celebration. In 2023, PM Narendra Modi also introduced the “HAR GHAR TRINGA” Campaign, encouraging the public to participate in the flag-hoisting ceremony on Independence Day, August 15, 2023.

Significance of Independence Day

Independence Day on August 15 holds immense significance for India. It marks the day in 1947 when our country gained freedom from British colonial rule. Here’s why it’s so important:

  • Historical Milestone: August 15, 1947, is a historic milestone in India’s history. It ended nearly two centuries of British rule, granting the nation the right to self-govern and determine its destiny.
  • Sacrifices of Freedom Fighters: Independence Day honors the sacrifices made by countless freedom fighters who struggled, protested, and sometimes even gave their lives for India’s freedom. Their dedication and resilience are remembered and celebrated on this day.
  • National Unity: Independence Day brings people from diverse backgrounds together as one nation. It reinforces the idea of unity in diversity, highlighting that India is a land of many cultures, languages, and religions, all united under the Indian flag.
  • Democratic Values: It underscores the core democratic values that India upholds. The country adopted a democratic system of governance, with its Constitution guaranteeing fundamental rights and equality for all citizens.
  • Progress and Aspirations: Independence Day is an occasion to reflect on India’s progress since 1947, celebrating its achievements in various fields, including science, technology, arts, and sports. It’s also a time to look forward to a better, more prosperous future.
  • Renewal of Commitment: The day is a reminder of the responsibilities that come with freedom. It encourages citizens to contribute to the development of the country and to protect the democratic ideals that India stands for.
  • International Importance: Independence Day showcases India’s emergence as a global player. The celebrations often have international significance, with leaders and representatives from around the world recognizing India’s role on the global stage.

Independence Day 2023 National Holiday

On August 15, 2023, India is having a special day off. It’s a big deal because it’s the 77th time they’re celebrating Independence Day. This day is all about remembering when India became free from British rule a long time ago in 1947. The Prime Minister will raise the national flag, and the theme for this year is “Nation First, Always First,” showing how India wants to keep growing and being diverse and fair. It’s a day to feel proud of the past and hopeful for the future.

 

Interesting Facts About Independence Day 2023

Historic Event: Independence Day commemorates India gaining freedom from British colonial rule on August 15, 1947.

National Flag Evolution: The Indian tricolor flag has evolved over the years, with its current design officially adopted in 1947.

Gandhi’s Influence: Mahatma Gandhi’s philosophy of nonviolent resistance, or “Satyagraha,” played a significant role in India’s struggle for freedom.

Red Fort Tradition: The Prime Minister of India hoists the national flag at the Red Fort in Delhi, followed by a patriotic speech.

Cultural Showcases: Parades, traditional dances, and cultural events celebrate India’s rich diversity and unity.

Salt Satyagraha: Mahatma Gandhi’s symbolic Salt March in 1930 highlighted civil disobedience and ignited the freedom movement.

Symbolic Midnight Hour: India’s first Prime Minister, Jawaharlal Nehru, delivered his iconic “Tryst with Destiny” speech at midnight on Independence Day.

Iconic Songs: The national anthem “Jana Gana Mana” and the patriotic song “Vande Mataram” evoke strong feelings of nationalism.

Inspirational Icons: Heroes like Bhagat Singh, Netaji Subhas Chandra Bose, and Rani Lakshmi Bai are celebrated for their contributions to freedom.

Global Diaspora: Indians worldwide mark Independence Day, fostering a sense of unity and pride in their cultural heritage.

 

Story of Freedom (Azadi)

India’s freedom story was a long fight. People wanted India to be free from British rule. They protested peacefully, like Gandhi’s ways, and faced tragic events, like the Jallianwala Bagh tragedy in 1919. The Indian National Congress was formed in 1885 to work for self-governance. During World War II, big movements pushed the British to leave. Finally, on August 15, 1947, India became independent, ending almost 200 years of British rule. This struggle shows how people, through unity and determination, can win their freedom.

 

Some songs tribute to Freedom Fighters and our Heroes

Several songs in India pay tribute to freedom fighters and heroes who played significant roles in the country’s struggle for independence. Some of these songs are:

  1. “Ae Mere Watan Ke Logon” – This iconic song sung by Lata Mangeshkar beautifully commemorates the sacrifices of Indian soldiers and is often dedicated to the memory of freedom fighters.
  2. “Rang De Basanti” – This title track from the movie “Rang De Basanti” reflects the spirit of youth inspired by the stories of freedom fighters and their willingness to bring about change.
  3. “Vande Mataram” – The timeless and patriotic “Vande Mataram” celebrates the love for the motherland and the spirit of India’s freedom struggle.
  4. “Maa Tujhe Salaam” – Sung by A.R. Rahman, this song is a tribute to the sacrifices of freedom fighters and the unity of the nation.
  5. “Ae Watan” – This heartfelt song from the movie “Raazi” expresses the deep love for the country and acknowledges the bravery of those who fought for its freedom.

GitHub Copilot Chat available in a preview for businesses

  • 24/July/2023
  • Paul krill

GitHub has made a limited public beta release of GitHub Copilot Chat available to all customers of GitHub Copilot for Business, giving these users a context-aware, conversational programming assistant within their Visual Studio and Visual Studio Code development environments.

Previously, GitHub Copilot Chat was available only through a private, gated beta program. Coplot Chat provides context-specific, real-time coding assistance, including:

  • Guidance such as best practices, tips, and solutions tailored to specific coding challenges.
  • Code analysis, breaking down complex concepts and explaining code suggestions. Complex concepts can be broken down and code snippets explained.
  • Troubleshooting, identifying issues, offering suggestions, explanations, and alternative approaches.
  • Suggested remediations for security issues in code.

 

GitHub Copilot for Business users can sign up for the beta at github.com. Users are able to use the beta via Visual Studio Code and Visual Studio extensions. Developers with GitHub Copilot Chat will be able to execute complex tasks with simple prompts, according to GitHub.

Announced July 20, the wider beta serves as a first step in bringing GitHub Copilot X to enterprises, featuring technical previews of generative AI and GPT-4 for developers. GitHub Copilot Chat goes beyond being a chat window, GitHub said. It is contextually aware of the code the developer has typed and any error messages that are displayed by the IDE.

Microsoft previously previewed Copilot Chat for GitHub Copilot in Visual Studio Code. GitHub Copilot has raised concerns and a lawsuit regarding the fairness and legality of its use of publicly available code. The technology has been trained on billions of lines of code and has been used all over the world, GitHub has said.

 

ECMA

  • 30/June/2023
  • Paul Krill

ECMAScript 2023, an update to the official specification for the JavaScript programming language, has been approved by ECMA International. The new spec adds new methods for searching and changing arrays, extends the WeakMap API to allow unique symbols, and introduces some standardization for the use of hashbangs.

 

      The rise of WebAssembly 

  • Array find from last, a proposal for .findlast() and .findLastIndex() methods on array and typed array. Finding an element in an array is a very common programming pattern, the proposal states. Scenarios under which this feature would be used include when a developer knows that finding an element from last to first may have better performance, or developers care about the order of the elements.
  • Permitting symbols as keys in WeakMap keys, a proposal that extends the WeakMap API to allow the use of unique symbols as keys. Currently, WeakMaps are limited to allow only objects as keys.
  • Change array by copy, a proposal that provides additional methods on Array.prototype and TypedArray.prototype to enable changes on the array by returning a new copy of it with the change.
  • Hashbang grammar, a proposal to match the de facto usage in some CLI JS hosts that allow for Shebangs/Hashbang. These hosts strip the hashbang to generate valid JS source texts before passing to JS engines. This plan would move the stripping to engines and unify and standardize how that is done.

Updated versions of ECMAScript traditionally are finalized by ECMA in June. Last year’s ECMAScript 2022 featured class elements and top-level await capabilities.

Java Development Kit (JDK)

  • 23/May/2023
  • Paul Krill

Java Development Kit (JDK) 21, due in September as the next long-term support release of Oracle’s standard Java implementation, now has 13 features officially proposed for it, with two more features added in recent days.

The latest proposals include a key encapsulation mechanism (KEM) API and deprecation of the 32-bit x86 Windows port. Three other features—a generational Shenandoah garbage collector, unnamed classes and instance main methods, and unnamed patterns and variables—were added earlier this month.

These five proposals join eight features proposed in March and April: a generational ZGC (Z Garbage Collector), record patterns, pattern matching for switch expressions and statements, a vector API, sequenced collections, virtual threads, a preview of string templates, and a third preview of a foreign function and memory API. Separately, JDK 21 also is due to change how network names are assigned to network interfaces on Windows.

Also on InfoWorld: 7 reasons Java is still great 

Early-access binaries under the GPL are available at jdk.java.net. Oracle publishes new releases of standard Java every six months, with the most recent, JDK 20, having arrived March 21. The specific proposals for JDK 21 so far include:

 

  • Key encapsulation mechanism API, an encryption technique for securing symmetric keys via public cryptography. One goal of the proposal is to enable applications to use KEM algorithms such as the RSA Key Encapsulation Mechanism (RSA-KEM), the Elliptic Curve Integrated Encryption Scheme (ECIES), and candidate algorithms for the National Institute of Standards and Technology (NIST) Post-Quantum Cryptography standardization process. Another goal is to enable use of KEMs in higher level protocols such as Transport Layer Security (TLS) and in cryptographic schemes such as Hybrid Public Key Encryption (HPKE). Also, security providers would be able to implement KEM algorithms in either Java code or native code, and include an implementation of the Diffie-Hellman KEM (DHKEM) defined in RFC 9180.
  •  
  • Deprecation of the Windows 32-bit x86 port for removal, with the goal to remove it in a future release. The proposal is intended to update the build system to issue an error message when an attempt is made to configure a build for Windows 32-bit x86. The message will be suppressible via a new configuration option. Also, the plan is to mark the port, and related port-specific features, as deprecated for removal in relevant documentation. The proposal notes that Windows 10, the last Windows OS to support 32-bit operation, reaches end of life in October 2025.
  •  
  • Generational Shenandoah, a proposal to enhance the Shenandoah GC with experimental generation collection capabilities to boost sustainable throughput, load-spike resilience, and memory utilization. The main goal of the proposal is to provide an experimental generational mode without breaking non-generational Shenandoah, with the intent to make the generational mode the default in a future release. Other goals include reducing the sustained memory footprint without sacrificing low GC pauses, reducing CPU and power usage, sustaining high throughput, and continuing to support compressed object pointers. The proposal initially would support x64 and AArch64, with support for other instruction sets added as the experimental mode progresses to readiness. It is not a goal to replace non-generational Shenandoah, which will continue as the default mode of operation with no regressions in its performance or functionality. Improving performance of every conceivable workload also is not a goal.
  •  
  • A preview of unnamed classes and instance main methods, to evolve the language so that students will be able write their first Java programs without needing to understand language features designed for large programs. Far from using a separate dialect of Java, students could write streamlined declarations for single-class programs and then seamlessly expand programs to use more advanced features as their skills grow. The intent is to offer a smooth onramp to Java.
  •  
  • A preview of unnamed patterns and variables, to enhance the language with unnamed patterns and unnamed variables. Unnamed patterns match a record component without stating the component’s name or type, while unnamed variables can be initialized but not used. Both are denoted by an underscore character, _. This proposal is intended to improve the readability of record patterns by eliding unnecessary nested patterns, and to improve maintainability of all code by identifying variables that must be declared but will not be used.
  •  
  • Generational ZGC is intended to improve application performance by extending ZGC to maintain separate generations for young and old objects. Young objects tend to die young, and maintaining separate generations will allow ZGC to collect them more frequently. Applications running with generational ZGC should see the following benefits: lower risks of allocation stalls, lower required heap memory overhead, and lower garbage collection CPU overhead. These benefits should happen without significant throughput reduction compared to non-generational ZGC.
  •  
  • Record patterns, previewed in both JDK 19 and JDK 20, would deconstruct record values. Record patterns and type patterns can be nested to enable a powerful, declarative, and composable form of data navigation and processing. Goals of the proposal include extending pattern matching to destructure instances of record classes and adding nested patterns, enabling more composable data queries. This feature has co-evolved with pattern matching for switch. Record patterns in the current JEP (JDK Enhancement Proposal) proposes to finalize the feature with further refinements based on continued experience and feedback. Apart from minor editorial changes, the main change since the second preview is to remove support for record patterns appearing in the header of an enhanced for statement. The feature may be re-proposed in a future JEP.
  •  
  • Pattern matching for switch enables a switch expression or statement to be tested against a number of patterns, each with a specific action, so complex data-oriented queries can be expressed safely and concisely. This feature originally was proposed in JDK 17 and subsequently was refined in JDK 18, JDK 19, and JDK 20. It would be finalized in JDK 21 with further refinements based upon feedback and experience. Main changes from previous JEPs are the removal of parenthesized patterns and allowing qualified enum constants such as case constants with switch expressions and statements. Goals include expanding the expressiveness and applicability of switch expressions and statements by allowing patterns to appear in case labels, allowing historical null-hostility of switch to be relaxed when desired, and increasing the safety of switch statements by requiring that pattern switch statements cover all potential input values. Another goal is ensuring existing switch expressions and statements continue to compile with no changes and execute with identical semantics.
  •  
  • A sixth incubator of a vector API to express vector computations that reliably compile at run time to optimal vector instructions on supported CPU architectures, achieving performance superior to equivalent scalar computations. This previously has been incubated in JDK 16 through JDK 20. The latest incarnation includes performance enhancements and bug fixes. Goals of the proposal include being clear and concise, being platform agnostic, and offering reliable runtime compilation and performance on x64 and AArch64 architectures. Other goals include graceful degradation, for when a vector computation cannot be fully expressed at runtime as a sequence of vector instructions, and alignment with Project Valhalla.
  •  
  • The foreign function and memory API enables Java programs to interoperate with code and data outside the Java runtime. By efficiently invoking foreign functions and safely accessing foreign memory, this preview API enables Java programs to call native libraries and process native data without the brittleness and danger of JNI (Java Native Interface). The API previously was previewed in JDK 20, which debuted last month, and JDK 19, which was released in September 2022. Refinements in the latest preview include enhanced layout paths with a new element to dereference address layouts, centralized management of the lifetimes of native segments in the Arena interface, a fallback native linker implementation, and removal of the VaList. Goals of the proposal include ease of use, performance, generality, and safety. It is not a goal to either reimplement JNI on top of this API or change JNI in any way.
  •  
  • Virtual threads are lightweight threads that promise to “dramatically” reduce the effort of writing, maintaining, and observing high-throughput concurrent applications. Goals of the plan include enabling server applications written in the simple thread-per-request style to scale with near-optimal hardware utilization, enabling existing code that uses the lang.Thread API to adopt virtual threads with minimal change, and enabling easy debugging and profiling of virtual threads with current JDK tools. Previously previewed in both JDK 20 and JDK 19, virtual threads will be finalized in JDK 21. With JDK 21, virtual threads now support thread-local variables all of the time, and make it impossible to create virtual threads that do not have these variables. Guaranteed support for thread-local variables ensures that more existing libraries can be used unchanged with virtual threads and assists with migrating task-oriented code to use virtual threads.
  •  
  • Sequenced collections introduces interfaces to represent collections with a defined encounter order. Each collection has well-defined first and second elements and so forth, to the last element. Uniform APIs are provided for accepting first and last elements and processing elements in reverse order. Motivating the proposal is a situation in which Java’s collections framework lacks a collection type to represent a sequence of elements with a defined encounter order. It also lacks a uniform set of operations that apply across these collections. These gaps have been a problem and a source of complaints. The proposal calls for defining interfaces for sequencing for collections, sets, and maps, and retrofitting this into the existing collections type hierarchy. All of these new methods have default implementations.
  •  
  • String templates, to appear as a preview feature, complement Java’s existing string literals and text blocks by coupling literal text with embedded expressions and processors to produce specialized results. This language feature and API is intended to simplify writing of Java programs by making it easy to express strings that include values computed at runtime. It promises to enhance readability of expressions, improve program security, retain flexibility, and simplify the use of APIs that accept strings written in non-Java languages. Enabling development of non-string expressions derived from combining literal text and embedded expressions also is a goal.

 

 

Visual Studio Code 1.77

  • 17/April/2023
  • Paul Krill

Visual Studio Code 1.77, published March 30 as the March 2023 version of Microsoft’s extensible code editor, introduces a preview of deeper integration with the GitHub Copilot AI coding assistant, including inline suggestions and chat capabilities.

The VS Code update also brings TypeScript/JavaScript switch case completions, helping users scaffold out switch statements over literal types in either programming language. Type case inside of the switch statement and accept the suggestion for case … to automatically insert cases for all values of this type. But note this only works when the value being switched over is either a union or literal type.

Also in VS Code 1.77, users can try out GitHub Copilot features such as inline suggestions, a chat view to ask for help, and inline chat. Developers can try the new capabilities by using the GitHub Copilot Nightly extension and the VS Code Insiders Build. For chat capabilities, developers also must sign up for the GitHub Copilot Chat waitlist. This deeper integration with Copilot is in a preview state.

A new GitHub integration now allows VS Code users to copy deep links for an editor line or range from the editor gutter when working in a GitHub repository. In the desktop version of VS Code, developers need to install the GitHub Pull Requests and Issues extension to create GitHub Permalinks and HEAD links from the editor gutter. In vscode.dev, the online version of VS Code, deep links for GitHub repos are available out of the box.

 

Visual Studio Code 1.77 can be downloaded for Windows, Linux, or macOS from the project website. Also in VS Code 1.77:

  • Users can more conveniently refactor Python code with the Pylance extension for Python language support. This is done via a new “Move symbol to” Code Action.
  • The editor now can recommend extensions based on file content. For example, if a Python file is opened that has notebook cells syntax, the editor recommends the Jupyter extension to deal with these cells.
  • Developers can enable “Format on save” for notebooks, which will format the entire notebook when saved.

VS Code 1.77 follows the release earlier this month of VS Code 1.76, which brought usability enhancements to configuration profiles and remote development.