giseldo/neodataset huggingface dataset:
Remove self service condition from activation code logic

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

## Background

The original activation code logic had a couple of checks in place in order for a code to be generated:
1. Validate the Super Sonics fields (i.e. auto-renewal, operational metrics) were populated OR
2. Validate the purchase was made through self service 

In reviewing this logic, it was determined that there was no need for the SS field dependency (detailed reasoning outlined [here](https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/4688#note_1070731626)). As a result, this was removed as part of this issue: https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/4688

## Problem
Since this update, we have identified that the activation code logic still includes the check that a purchase was completed through a self-service path. With the SS logic removed, this is now preventing activation code creation for _all_ sales assisted Self-Managed purchases.

_Note: self-service purchases are still working as expected_

#### Reported Examples
1. https://gitlab.zendesk.com/agent/tickets/321798 
2. https://gitlab.slack.com/archives/C018C623KBJ/p1661947151593559?thread_ts=1661268847.706399&cid=C018C623KBJ

### Proposal

Remove the `self_service?` check altogether from the activation code logic.


### Result
Cloud activation codes will be created for all Self-Managed subscriptions who do not have `TurnOnCloudLicensing` = `No`, regardless of purchase method.

Story points: 1.0
Follow up: Add Product Order Action

### Summary

The following feedback is addressed: https://gitlab.com/gitlab-org/customers-gitlab-com/-/merge_requests/5320#note_1083185137

For the checks in this form:

```ruby
raise SomeError, 'Error message' unless value
```

Within the `orders/actions` we want to update to

```ruby
raise SomeError, 'Error message' if value.blank?
```

To account for empty strings and other possible empty states.

Story points: 1.0
Marketplace subscription ZuoraCallbackWorker wait for the right order status

After marketplace subscription is created, when Zuoracallback starts, in theory, there is a chance:
- the new customer record is not committed (because we are using [DB transaction](https://gitlab.com/gitlab-org/customers-gitlab-com/-/blob/fc0f52c30c4420b8f79d8b3a2ba2c4da04236ece/app/services/marketplace/create_subscription_service.rb#L21-26))
- the [new order creation](https://gitlab.com/gitlab-org/customers-gitlab-com/-/blob/fc0f52c30c4420b8f79d8b3a2ba2c4da04236ece/app/services/marketplace/create_subscription_service.rb#L28) has not finished yet

In reality, these are less likely(we assume the Postgres DB transaction and Rails code runs fast enough). But we should ensure to handle this safely.

Depends on https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/4732+

### Proposal

In the Zuora callback worker, add a validation as the first thing:
 1. check whether this is a marketplace subscription. If it is NOT a marketplace subscription, return.
     - A marketplace subscription is a subscription with: `Marketplace::CHANNELS.include?(external_subscription_source)`
 2. query the MarketplaceOrder table, check the order status. raise exception if the `status != :created`.
     - The Zuoracallback worker will retry, per the Sidekiq worker retry settings.
     - If it does not succeed after all retries, this requires a manual check. This is unexpected. Actually, most likely we will perform more frequently(probably daily) check the failed Marketplace order.

<!-- Consult with `@gitlab-com/business-technology/enterprise-apps/zuora-architects` on the ~"Enterprise Applications" team if Zuora business logic is involved. -->

### Result

Avoid unexpected errors from duplicated Customer record and Order record creation competition. -- as the same customer/order creation will be initiated from both Rails(Marketplace::CreateSubcriptionService) and Sidekiq(ZuoracallbackWorker).

### Next steps (if any)

### How will we measure success?

Story points: 2.0
Validate duplicate Marketplace order request

We want to validate a marketplace request duplication. For duplicated requests, we will return error message.

The proposal is [option 2 in the comment](https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/4637#note_1066891473).

We allow the same `external_subscription_source`/`external_subscritpion_id` to retry when the request processing failed. For other status, we reject the request with an error message.
* When a Marketplace request comes, we search saved `external_subscription_source`/`external_subscritpion_id` with `status != 'failed'`. If found, reject the request. Otherwise, continue.
* We **upsert** `external_subscription_source`/`external_subscritpion_id`, update the status as `in_progress`.
* When the CDot failed to create the subscription, we mark the status as `failed`(This includes other validation failures)
* When the CDot succeeds to create the subscription, we mark the status as `created`
* When the CDot succeeds to notify the customer(and reseller?), we mark the status as `provisioned`

This issue depends on issue https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/4732+

### Problem

### Proposal

<!-- Consult with `@gitlab-com/business-technology/enterprise-apps/zuora-architects` on the ~"Enterprise Applications" team if Zuora business logic is involved. -->

### Result

### Next steps (if any)

### How will we measure success?

Story points: 2.0
Serve CSS styles through webpacker

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem

During the process of moving JavaScript code to `webpack` we don't do anything with styles. But we are going to drop `sprockets` completely. Dropping it will require moving styles processing to `webpack` too. I also would like to point that we will connect Pajamas Design System via Node.js packaging system (`@gitlab/ui`).

### Proposal

Move styles processing to `webpacker` too.

Note: moving to webpacker is also on the CSS roadmap for the GitLab project. https://gitlab.com/groups/gitlab-org/-/epics/950#css-roadmap 

### Result

This will make the process of moving to Pajamas easier. For example, #663.
Another pro is we can start using features like `autoprefixer`.

### Next steps (if any)

### How will we measure success?

Story points: 3.0
Broken deployment: Upgrade flow

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
We introduced a bug in !470 (f951c19f) 
Events are not being set correctly on Info Panels.

This got onto `staging` because we were in the middle of transitioning from feature test quarantine.

Story points: 2.0
[Portal Pajamas] Add FE testing infrastructure

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
Currently our only way of testing JS is to spin up a feature spec.

This is slow and overkill in many cases.
### Proposal
Adopt the [gitlab FE testing guide](https://docs.gitlab.com/ee/development/testing_guide/frontend_testing.html) to our needs.
Since the Customer portal differs from gitlab-com (notably in size) we should only adopt what makes sense.

Be sure to add `vue-test-utils` and a small Vue test
### Result
We have increased confidence in our JS
### Next steps (if any)
Add coverage report metrics to CI (?)

Story points: 5.0
[Portal Pajamas] Consume gitlab-ui components

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
The Customer Portal should follow the Pajamas design system.
The best way to ensure that's the case is to use the codified implementation of it: [gitlab-ui](https://gitlab.com/gitlab-org/gitlab-ui)

### Proposal
Setup infrastructure to consume `gitlab-ui` Vue components.

- [x] Add Vue webpack support https://github.com/rails/webpacker#vue
- [x] Add `gitlab-ui` dependencies: `Bootstrap` v4 
- [x] Add `gitlab-ui` dependencies: `bootstrap-vue`
- [x] Ensure migrating from `Bootstrap` v3 -> v4 does not break UI and any visual changes are intentional; handled in https://gitlab.com/gitlab-org/customers-gitlab-com/issues/753
- [x] Add `gitlab-ui` as a dependency
- [ ] Migrate a small piece of UI behind a feature flag (registrations form f.x.) WIP in https://gitlab.com/gitlab-org/customers-gitlab-com/merge_requests/603

Story points: 5.0
Remove import.rake & RecurlyMigrationMailer

### Problem
I noticed while working on a separate issue that `lib/tasks/import.rake` and the `RecurlyMigrationMailer` hasn't been touched in a while.  I wondered if this was still being used, or if this was a relic of an old migration?

### Proposal
If deemed obsolete, remove the following:
- `lib/tasks/import.rake`
- `RecurlyMigrationMailer`
  -  related views and specs

### Result
A cleaner codebase! :100:

Story points: 1.0
Add com routes to rubocop.yml

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
To add `com` related routes to `rubocop.yml`

### Proposal

### Result

### Next steps (if any)

### How will we measure success?

Story points: 1.0
Move trial registration api under com module

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
Trials Registration api is specific to `gitlab.com`. It currently resides under `ee` module with a check to see if it is a `gl.com` environment.

### Proposal
Move the Trials Registration api under the `com` module.

### Result

### Next steps (if any)

### How will we measure success?

Story points: 2.0
Add documentation for developers to add Com-only code

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
1. With the `.com` code segregation, add developer documentation on the steps to add code specific to only `com`
2. Add a checkbox to MR `Separation of Com specific content`

### Proposal

### Result

### Next steps (if any)

### How will we measure success?

Story points: 2.0
Create skeleton files and folders for com module

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
Add logical code seperation for `com` module that would get loaded only for `com` environement.

### Proposal
Create `com` module with the following hierarchy:

![Screen_Shot_2019-09-24_at_8.04.42_PM](/uploads/2bd0c0a973e99af5eafa09c35e23223b/Screen_Shot_2019-09-24_at_8.04.42_PM.png)

1. Load the module only if it's a `com` environement
2. Draw `com` specific routes only if it's a `.com` environment

### Result

### Next steps (if any)

### How will we measure success?

Story points: 2.0
De-couple any trial related information/integration from customers.gitlab.com

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem

Historically, trials were integrated with the customer portal to store customer data. This leads to an additional point of failure with trials if something goes wrong, and Fulfillment becomes a bottleneck for fixing any trial issues which are dependent on this integration as Marketing cannot fix it themselves. It also makes it harder to identify issues with trials if there are more points of failure.

### Proposal

Trials should not need to interact with the portal or any other tool other than Marketo > Salesforce for lead creation. We should remove any integrating code regarding trials from the portal and run a clean up of customer information and accounts in the portal that relates to trials. 

### Result

### Next steps (if any)

### How will we measure success?

Story points: 8.0
Use Sentry to proactively catch errors

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem
It's not clear which developers should react to Sentry error reports in the Customer Portal.
The reports we currently have need to be triaged.

We're also suffering from similar issues mentioned https://gitlab.com/groups/gitlab-org/-/epics/737

### Proposal
Determine a process for handling Sentry errors.
Document and codify the process.

Enable relevant alerts for dev team; slack or email.

### Concrete TODOs

- [x] Update Sentry
- [x] Add SentryJS to JS bundle
- [ ] Upload sourcemaps to Sentry

### How will we measure success?
We're proactive in catching and fixing bugs instead of customers reporting them.

Story points: 8.0
Better error/warning messaging when installing new license

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem

When installing a new license with seats less than historical max, the warning message is a bit misleading like below.

> “During the year before this license started, the GitLab installation had 77 active users, exceeding this license’s limit of 50 by 27 users. Please upload a license for at least 77 users or contact renewals@gitlab.com.”

The customer actually needs to pay true-up if they don't need to keep 77 users for the renewal. Once the license includes the true-up and seats for the new year it will work.

### Proposal

New message should display 

MVC (all cases) 

`The submitted license is not compatible with this system’s usage: X active users, Y maximum users and Z users in license. Please get in touch with our [Support team](https://support.gitlab.com/hc/en-us/requests/new?ticket_form_id=360000071293) for further assistance.`

Let's also update the banner so it uses the correct styling (from the design system):

![image](/uploads/fda050a6a6bda7d60f7b217481d1345d/image.png)

### Alternate Approach
If we are able to create tailored messages for each [error case](https://gitlab.com/gitlab-org/customers-gitlab-com/issues/713#note_276616812), then we will want to provide better specific information for the customers based on their situation. This is TBD based on initial investigation. 


### Result

### Next steps (if any)

* [ ] Eng to determine our ability to have tailored messages 
* [ ] Eng to define additional effort to provide tailored messages 
* [ ] If tailored messages are possible, we will need to create new ones for each case, assuming we want to invest the extra effort

Story points: 2.0
Bug: Customers portal trial form throwing error on missing field

### Problem

user went to [this link](https://customers.gitlab.com/trials/new?return_to=http%3A%2F%2Flocalhost&id=YWRtaW5AZXhhbXBsZS5jb20=) and cannot complete trial because of this error `There were some errors when trying to generate your trial:
Company size can't be blank`.

### Steps to recreate

1. started gitlab-ee:latest in local docker environment.
2. from administration -> licenses click to "obtain trial" goes to this url

### User reports

1. https://gitlab.zendesk.com/agent/tickets/133408

Story points: 1.0
Extra purchased CI minutes aren't added to namespace where the namespace path contains a dot

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem

Extra purchased CI minutes do not apply to namespace where the namespace **path** contains a `.`. I suspect there was a change to the `/namespaces` endpoint.

`GET` works as expected, for example `GET /namespaces/deandre.test-group.2` returns:

```
{
  "id": 4248792,
  "name": "deandre-test-group-2",
  "path": "deandre.test-group.2",
  "kind": "group",
  "full_path": "deandre.test-group.2",
  "parent_id": null,
  "avatar_url": null,
  "web_url": "https://gitlab.com/groups/deandre.test-group.2",
  "members_count_with_descendants": 1,
  "shared_runners_minutes_limit": null,
  "extra_shared_runners_minutes_limit": null,
  "billable_members_count": 1,
  "plan": "free"
}
```

`PUT` (and presumably `POST`) fails, for example `PUT /namespaces/deandre.test-group.2?extra_shared_runners_minutes_limit=1000` returns:

```
{
  "error": "404 Not Found"
}
```

### Related Support Tickets (internal)

- https://gitlab.zendesk.com/agent/tickets/133265
- https://gitlab.zendesk.com/agent/tickets/135238

Story points: 3.0
Follow-up from "Make company_size optional"

The following discussion from !481 should be addressed:

- [ ] @jejacks0n started a [discussion](https://gitlab.com/gitlab-org/customers-gitlab-com/merge_requests/481#note_222130659): 

    > I’d say you can probably skip the added test, since generally testing a negative isn’t worth it. What might be better is to test a simulated request from zuora where it wouldn't be present.

Story points: 1.0
Update admin management roles

<!-- Please complete the template below as best as you can. Make sure to check if this issue has already been raised by someone else first to avoid duplication. 

For each section below, please add screenshots or links or anything that may help visual learners understand the problem better, even if this takes you an extra minute or two this is a great help to some folks.

https://www.learning-styles-online.com/style/visual-spatial/

-->

### Problem

Following up on https://gitlab.com/gitlab-org/customers-gitlab-com/issues/639 we should add a restriction so not all admins can add/remove admins

### Proposal

Add a flag in order to do this

### Result

### Next steps (if any)

### How will we measure success?

Story points: 2.0
Customers getting 500s on customers.gitlab.com  - ActionView::Template::Error: uninitialized constant TransactionViewer::LINK_GITLAB_ACCOUNT

Relates to: https://gitlab.com/gitlab-com/support/dotcom/dotcom-internal/issues/886

https://sentry.gitlab.net/gitlab/customersgitlabcom/issues/951624/

```
NameError: uninitialized constant TransactionViewer::LINK_GITLAB_ACCOUNT
  app/views/subscriptions/_update_btn.html.haml:10:in `_app_views_subscriptions__update_btn_html_haml___3390558228538312127_47056115447700'
    = link_to 'Link my GitLab.com account', edit_subscription_path(subscription.id,
  app/views/subscriptions/_subscription.html.haml:37:in `_app_views_subscriptions__subscription_html_haml___1229786290608102266_47056103999600'
    = render 'subscriptions/update_btn', subscription: subscription
  app/views/subscriptions/index.html.haml:7:in `_app_views_subscriptions_index_html_haml___3338024472363674668_47056104101860'
    = render partial: 'subscription', collection: @subscriptions
  app/middleware/basic_health_check.rb:20:in `call'
    return @app.call(env) unless env['PATH_INFO'] == HEALTH_PATH
...
(157 additional frame(s) were not displayed)

ActionView::Template::Error: uninitialized constant TransactionViewer::LINK_GITLAB_ACCOUNT

ActionView::Template::Error: uninitialized constant TransactionViewer::LINK_GITLAB_ACCOUNT
```

## Reported Examples

1. https://gitlab.zendesk.com/agent/tickets/132861
1. https://gitlab.zendesk.com/agent/tickets/133079

Story points: 1.0