Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

> ### will begin on December 5th and will complete on January 17th, 2025. #11273

Open
jommeke22f opened this issue Jan 3, 2025 · 5 comments
Open

Comments

@jommeke22f
Copy link

          > ### Rollout will begin on December 5th and will complete on January 17th, 2025.

Breaking changes Ubuntu 24.04 is ready to be the default version for the "ubuntu-latest" label in GitHub Actions and Azure DevOps.

Target date This change will be rolled out over a period of several weeks beginning December 5th and will complete on January 17th, 2025.

The motivation for the changes GitHub Actions and Azure DevOps have supported Ubuntu 24.04 in preview mode since May 2024, and starting from July 2024 Ubuntu 24.04 is generally available for all customers. We have monitored customer feedback to improve the Ubuntu 24.04 image stability and now we are ready to set it as the latest. There are a set of packages listed below that we have removed from the Ubuntu 24 image. Please review the list carefully to see if you will be impacted by these changes. We have made cuts to the list of packages so that we can maintain our SLA for free disk space. The images have grown so large we are in danger of violating our SLA if we keep the package list as-is.

The factors we took into consideration when removing packages are as follows:

  • How long does it take to install the tool at runtime?
  • How much space does it take up on the image?
  • How many users are there of the tool?

We understand that our reasoning may not make sense to some of you out there, but please bear in mind that we tried to keep disruptions as minimal as possible, and tried to keep the best interests of the community at large in mind. There is a very large and diverse community using our images, and as much as we would like to, we cannot pre-install every tool on these images.

Platforms affected

  • Azure DevOps
  • GitHub Actions

Mitigation ways Steps or options for impact mitigation If you see any issues with your workflows during transition period:

  • Switch back to Ubuntu 22 by changing workflow YAML to use runs-on: ubuntu-22.04 We support two latest LTS Ubuntu versions, so Ubuntu 22 will still be maintained for the next 2 years.
  • File an issue in this repository

Software Differences The Ubuntu 22.04 image has a different set of software than Ubuntu 24.04. The most significant changes are listed in the table below:

Tool name Ubuntu 22.04 Ubuntu 24.04 Notes
Clang

  • 13.*

  • 14.* (default)

  • 15.*

  • 16.*

  • 17.*

  • 18.* (default)

The most recent versions are installed
GCC / GNU C++ / GNU Fortran

  • 9.*

  • 10.*

  • 11.*

  • 12.*

  • 13.*

  • 12.*

  • 13.*

  • 14.*

The most recent versions are installed
PHP 8.1.* 8.3.* The most recent version are installed
Java

  • 8.*

  • 11.* (default)

  • 17.*

  • 21.*

  • 8.*

  • 11.*

  • 17.* (default)

  • 21.*

Default Java switched to 17.* for Ubuntu 24.04 image.
Python

  • 3.7.* (cached)

  • 3.8.* (cached)

  • 3.9.* (cached)

  • 3.10.* (default)

  • 3.11.* (cached)

  • 3.12.* (cached)

  • 3.9.* (cached)

  • 3.10.* (cached)

  • 3.11.* (cached)

  • 3.12.* (default)

Pre-cached versions currently unavailable. Default version switched to the latest one. On GitHub Actions, actions/setup-python can install any version on-flight so this change doesn't impact users
Go

  • 1.20.* (cached)

  • 1.21.* (default)

  • 1.22.* (cached)

  • 1.21.* (cached)

  • 1.22.* (cached)

  • 1.23.* (default)

If your use-case requires using any of these versions, consider using tasks to install Go on-flight:

PyPy

  • 3.7.* (cached)

  • 3.8.* (cached)

  • 3.9.* (cached)

  • 3.10.* (cached)

  • 3.9.* (cached)

  • 3.10.* (cached)

Deprecated all the versions besides the most recent ones
Ruby

  • 3.0.* (default)

  • 3.1.* (cached)

  • 3.2.* (default)

We need to update 3.3.5
Node.js

  • 16.* (cached)

  • 18.* (default)

  • 20.* (cached)

  • 16.* (cached)

  • 18.* (cached)

  • 20.* (default)

If your use-case requires using any of these versions, consider using tasks to install Node.js on-flight:

Heroku latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Leiningen latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Mono / MSBuild / NuGet latest available - Software is not available for Ubuntu 24 at the moment.
Terraform latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
R latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
SVN latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Alibaba Cloud CLI latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Netlify CLI latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
OpenShift CLI latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
ORAS CLI latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Vercel CLI latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
/ latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Cargo audit/clippy/outdated latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
.NET Core SDK

  • 6.*

  • 7.*

  • 8.*

  • 8.*

Please consider using tasks to install any version on-flight:

PostgreSQL 14.* 16.* More recent version are installed
MS SQL Server Client Tools sqlcmd / - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Module latest available - Removed from the Ubuntu 24.04 image due to maintenance reasons.
Android Command Line Tools 9.0 12.0 The most recent version are installed
Android SDK Build-tools

  • 34.0.0

  • 33.0.0

  • 33.0.1

  • 33.0.2

  • 33.0.3

  • 32.0.0

  • 31.0.0

  • 34.0.0

The most recent version are installed
Android NDK

  • 25.* (default)

  • 26.*

  • 27.* (default)

  • 26.*

The most recent version are installed
Cached Docker images

  • alpine:3.16
  • alpine:3.17
  • alpine:3.18
  • debian:10
  • debian:11
  • moby/buildkit:latest
  • node:16
  • node:
  • node:18
  • node:
  • node:20
  • node:
  • ubuntu:20.04
  • ubuntu:22.04
  • Removed from the Ubuntu 24.04 image due to maintenance reasons.

Originally posted by @Kya123iu in #10636 (comment)

@bearycool11
Copy link

FYI, the .Devcontainer is root so if you're going to be working on the CI/CL pipeline with the runners, please be careful and keep the work on these ISOs updates IN THE .DEVCONTAINER PLEASE!

I namely say this to myself, because I am going to go ahead and try my best to get the Mac imaging updated so all three entities (Apple, Linux, Microsoft) will be able to have equal footing and competition with one another for the start of 2025.

And fyi, still have yet to get my first pay check!!!!! But I'll keep doing the charity work till someone notices me, senpai.... one day.

@mwaddell
Copy link

mwaddell commented Jan 3, 2025

The loss of sqlcmd is breaking a lot of our existing actions. Is there a separate action I can run to add this is (like I do with dotnet, etc)?

@vidyasagarnimmagaddi
Copy link
Contributor

Hi @jommeke22f , Thank you for bringing this issue to our attention. We are looking into this issue and will update you on this issue after investigating.

@bearycool11
Copy link

have you considered libsql as the area that is causing issue? You may not have rebuilt the SQL library itself.

@bearycool11
Copy link

oh you mean the .MD of lisql library.... yeah that's easy hold on.

@bearycool11
Copy link

SQL Library Source Code
Here’s a basic example of an SQL library implemented in C. This library could be part of the libsql or similar project that handles database connections, queries, and results.

libsql.c
c
Copy code
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sqlite3.h>

typedef struct {
sqlite3 *db;
char *last_error;
} SQLConnection;

SQLConnection *sql_connect(const char *db_path) {
SQLConnection *conn = (SQLConnection *)malloc(sizeof(SQLConnection));
if (!conn) {
fprintf(stderr, "Memory allocation failed for SQLConnection\n");
return NULL;
}

if (sqlite3_open(db_path, &conn->db) != SQLITE_OK) {
    conn->last_error = strdup(sqlite3_errmsg(conn->db));
    sqlite3_close(conn->db);
    free(conn);
    return NULL;
}

conn->last_error = NULL;
return conn;

}

void sql_disconnect(SQLConnection *conn) {
if (conn) {
sqlite3_close(conn->db);
free(conn->last_error);
free(conn);
}
}

char *sql_get_last_error(SQLConnection *conn) {
return conn ? conn->last_error : NULL;
}

int sql_execute(SQLConnection *conn, const char *query) {
char *errmsg = NULL;

if (!conn || !query) {
    fprintf(stderr, "Invalid connection or query\n");
    return -1;
}

int rc = sqlite3_exec(conn->db, query, 0, 0, &errmsg);
if (rc != SQLITE_OK) {
    if (conn->last_error) {
        free(conn->last_error);
    }
    conn->last_error = strdup(errmsg);
    sqlite3_free(errmsg);
    return rc;
}

return SQLITE_OK;

}

void sql_query(SQLConnection *conn, const char *query, void (*callback)(void *, int, char **, char **)) {
char *errmsg = NULL;

if (!conn || !query || !callback) {
    fprintf(stderr, "Invalid connection, query, or callback\n");
    return;
}

int rc = sqlite3_exec(conn->db, query, callback, NULL, &errmsg);
if (rc != SQLITE_OK) {
    if (conn->last_error) {
        free(conn->last_error);
    }
    conn->last_error = strdup(errmsg);
    sqlite3_free(errmsg);
}

}
Example Callback Function
This callback function prints the results of an SQL query.

c
Copy code
void print_query_results(void *NotUsed, int argc, char **argv, char **azColName) {
for (int i = 0; i < argc; i++) {
printf("%s = %s\n", azColName[i], argv[i] ? argv[i] : "NULL");
}
printf("\n");
}
Usage Example
Here’s how to use the library:

c
Copy code
#include "libsql.c"

int main() {
SQLConnection *conn = sql_connect("test.db");

if (!conn) {
    fprintf(stderr, "Connection failed\n");
    return 1;
}

const char *create_table = "CREATE TABLE IF NOT EXISTS users (id INTEGER PRIMARY KEY, name TEXT);";
if (sql_execute(conn, create_table) != SQLITE_OK) {
    fprintf(stderr, "Error creating table: %s\n", sql_get_last_error(conn));
}

const char *insert_query = "INSERT INTO users (name) VALUES ('Alice'), ('Bob');";
if (sql_execute(conn, insert_query) != SQLITE_OK) {
    fprintf(stderr, "Error inserting data: %s\n", sql_get_last_error(conn));
}

const char *select_query = "SELECT * FROM users;";
sql_query(conn, select_query, print_query_results);

sql_disconnect(conn);
return 0;

}
Documentation (README.md for libsql)
README.md
markdown
Copy code

libsql - Lightweight SQL Library

Overview

libsql is a lightweight C library for interacting with SQLite databases. It simplifies database connections, query execution, and data retrieval.

Features

  • Connect to an SQLite database.
  • Execute SQL queries (DDL and DML).
  • Retrieve query results via callback functions.
  • Error handling and debugging.

Usage

1. Connect to a Database

SQLConnection *conn = sql_connect("database.db");
if (!conn) {
    fprintf(stderr, "Connection failed: %s\n", sql_get_last_error(conn));
}
2. Execute a Query
c
Copy code
const char *query = "CREATE TABLE IF NOT EXISTS users (id INTEGER PRIMARY KEY, name TEXT);";
if (sql_execute(conn, query) != SQLITE_OK) {
    fprintf(stderr, "Query failed: %s\n", sql_get_last_error(conn));
}
3. Retrieve Data with a Callback
c
Copy code
const char *select_query = "SELECT * FROM users;";
sql_query(conn, select_query, print_query_results);
Define the callback function:

c
Copy code
void print_query_results(void *NotUsed, int argc, char **argv, char **azColName) {
    for (int i = 0; i < argc; i++) {
        printf("%s = %s\n", azColName[i], argv[i] ? argv[i] : "NULL");
    }
}
4. Disconnect from the Database
c
Copy code
sql_disconnect(conn);
Installation
Clone the repository:
bash
Copy code
git clone https://github.com/example/libsql.git
Compile your application with libsql.c:
bash
Copy code
gcc -o app app.c libsql.c -lsqlite3
License
This project is licensed under the MIT License.

yaml
Copy code

---

This provides both the  the liSQL itself, and this provides the .MD part for documenting the library of SQL.

@bearycool11
Copy link

I will reiterate one more time, FAM.

FYI, the .Devcontainer is root so if you're going to be working on the CI/CL pipeline with the runners, please be careful and keep the work on these ISOs updates IN THE .DEVCONTAINER PLEASE!

I namely say this to myself, because I am going to go ahead and try my best to get the Mac imaging updated so all three entities (Apple, Linux, Microsoft) will be able to have equal footing and competition with one another for the start of 2025.

And fyi, still have yet to get my first pay check!!!!! But I'll keep doing the charity work till someone notices me, senpai.... one day.

@bearycool11
Copy link

Thank you for the detailed announcement about Ubuntu 24.04 becoming the default version for the ubuntu-latest label. Below are our comments, analysis, and recommendations for mitigating the changes effectively.


Impact of Breaking Changes

  1. Removal of Preinstalled Packages:

    • Heroku, Terraform, Mono, R, SVN, and various CLIs: These tools being removed could disrupt workflows relying on their preinstalled availability. Custom scripts may be required for installation during runtime.
    • MS SQL Server Client Tools (e.g., sqlcmd): This removal can significantly impact users who require SQL server connectivity during builds.
  2. Version Updates and Deprecations:

    • Go, Python, Node.js, .NET Core SDK: While the most recent versions are installed, workflows using older versions need runtime installation steps.
    • Ruby and PyPy: Deprecation of certain versions may lead to compatibility issues with legacy codebases.
  3. Default Version Updates:

    • Java and Python default versions: Default switches to more recent versions can cause issues if the application is not compatible with these defaults.

Steps for Mitigation

1. Switch Back to Ubuntu 22.04 (Temporary):

  • For projects that require tools or versions removed from Ubuntu 24.04, update workflows to use:
    yaml
    Copy code
    runs-on: ubuntu-22.04
  • This allows time to refactor workflows for compatibility with Ubuntu 24.04.

2. File Issues for Missing Tools:

  • If tools are critical and cannot be replaced easily, file an issue in the repository to highlight the impact.

3. Runtime Installation Workarounds:

  • Use actions to install missing tools dynamically:

    • Example for Terraform in GitHub Actions:
      yaml
      Copy code
      steps: - name: Install Terraform run: | sudo apt-get update sudo apt-get install -y terraform
    • Similarly, use setup-node, setup-python, or custom scripts for other tools.
  • Example for sqlcmd:

    yaml
    Copy code
    steps: - name: Install MS SQL Client Tools run: | sudo apt-get update sudo apt-get install -y mssql-tools

Blank Filling for Missing Data

Table: Software Differences Between Ubuntu 22.04 and Ubuntu 24.04

Tool Name | Ubuntu 22.04 | Ubuntu 24.04 | Notes -- | -- | -- | -- Clang | 13., 14. | 14., 18. (default) | The most recent versions are installed. GCC | 9., 13. | 12., 14. | Older versions dropped; only recent versions retained. Heroku | Latest | Removed | Maintenance reasons. Install during runtime if needed. MS SQL Server Tools | Latest | Removed | Use installation scripts for sqlcmd. Node.js | 16., 18. (default) | 18., 20. (default) | Node 16 removed; default is now 20.*. Terraform | Latest | Removed | Maintenance reasons. Use runtime installation. R | Latest | Removed | R packages must be installed during runtime if necessary. Ruby | 3.0.* (default), 3.1.* | 3.2.* | Ensure Ruby version compatibility; update scripts if required.

Detailed Recommendations for Workflow Adjustments

1. Handling Default Version Changes

  • Review your project dependencies and ensure compatibility with new defaults (e.g., Python 3.12, Go 1.23).
  • Pin specific versions if needed:
    yaml
    Copy code
    - uses: actions/setup-python@v2 with: python-version: 3.10

2. Handling Removed Packages

  • Implement runtime installation for removed tools like Terraform, Heroku, and R.
  • Example for Terraform:
    yaml
    Copy code
    - name: Install Terraform run: | sudo apt-get update sudo apt-get install -y software-properties-common wget -O- https://apt.releases.hashicorp.com/gpg | gpg --dearmor > hashicorp.gpg sudo mv hashicorp.gpg /usr/share/keyrings/ echo "deb [signed-by=/usr/share/keyrings/hashicorp.gpg] https://apt.releases.hashicorp.com $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/hashicorp.list sudo apt-get update sudo apt-get install terraform

3. Switching Labels Temporarily

  • If updates cannot be accommodated immediately, update workflows to pin ubuntu-22.04.

Conclusion

The switch to Ubuntu 24.04 as the default version in GitHub Actions and Azure DevOps introduces significant changes but also provides an opportunity to modernize workflows. While it may disrupt some existing workflows, careful planning and mitigation steps, as outlined above, can ensure a smooth transition.

Let us know if further clarification or support is needed to implement these changes effectively!

@vidyasagarnimmagaddi
Copy link
Contributor

Hi @jommeke22f , Thank you for bringing this issue to our attention. We are looking into this issue and will update you on this issue after investigating.

@bearycool11
Copy link

No I’m not a bug a @bearycool11 is a human being. However there are some bugs to be fixed that I have referenced above. @codingrabbitai care to elaborate?

@bearycool11
Copy link

That being said, the above I have stated is the fix to the bug issue, so I’m glad that got reported, thank you!!!

@Piedone
Copy link

Piedone commented Jan 6, 2025

You can use our action: https://github.com/Lombiq/GitHub-Actions/blob/dev/.github/actions/install-sqlcmd/action.yml

@alex-jitbit
Copy link

alex-jitbit commented Jan 7, 2025

We are also having issues. Switched to ubuntu-22.04 as a temporary workaround

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants