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

fix: datetime picker #2

Merged
merged 35 commits into from
Feb 4, 2022
Merged

fix: datetime picker #2

merged 35 commits into from
Feb 4, 2022

Conversation

n-studio
Copy link
Owner

No description provided.

dependabot bot and others added 24 commits January 20, 2022 18:12
…= 2.29.2

Updates the requirements on [momentjs-rails](https://github.com/derekprior/momentjs-rails) to permit the latest version.
- [Release notes](https://github.com/derekprior/momentjs-rails/releases)
- [Changelog](https://github.com/derekprior/momentjs-rails/blob/main/news.md)
- [Commits](derekprior/momentjs-rails@v2.20.1...v2.29.1.1)

---
updated-dependencies:
- dependency-name: momentjs-rails
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
The tests weren't actually running, only the "bundler:audit" task was.
No idea of what I'm doing. Documentation is lacking. This seems
to work. It's taken from https://chromedriver.chromium.org/capabilities
Several years ago in PR 1245 this was pinned with this message:

> Pin the capybara gem, until we can drop Ruby 2.2.0
> Any capybara versions above 3.0.0 require a newer Ruby than 2.2.0, which
> we will support in line with Rails requirements.

Ruby 2.2 support has been dropped, so I think we can drop the pinning now?

It doesn't really do much at this point anyway since dependabot is automatically
updating to the lastest versions soon after they are released.
As of Ruby 3.0 webrick is no longer part of the Ruby standard library:
https://www.ruby-lang.org/en/news/2020/12/25/ruby-3-0-0-released/

Adding it for Ruby 2 in the "test" section should be fine also.

A recent update happened to add webrick to the Gemfile.lock indirectly, when
"yard" was updated since the new version of yard requires webrick. But it's
probably worth adding webrick to the Gemfile explicitly since we depend on it
for tests, not just for yard.
"rspec-rails" is already declared in the "test" section of the Gemfile.

This was generating this Bundler warning:

    Your Gemfile lists the gem rspec-rails (>= 0) more than once.
    You should probably keep only one of them.
    Remove any duplicate entries and specify the gem only once.
    While it's not a problem now, it could cause errors if you change the
    version of one of them later.
Ruby 2.7.5 is the latest 2.7 version.
Updating also removes this warning during "bin/setup"

    warning: parser/current is loading parser/ruby27, which recognizes
    2.7.5-compliant syntax, but you are running 2.7.2.
Bundler 2.3.5 is the latest Bundler version.
Support for Rails 4 was dropped in Aug 2020 in PR 1740.
Update "front_matter_parser" to be compatible with Psych 4.
Psych 4 is the version included in Ruby 3.1.
See PR 11 in the "waiting-for-dev/front_matter_parser" repo.

"front_matter_parser" was explicitly locked at 1.0.0 in Administrate in PR 2023
to avoid an incompatibility with Ruby 2.5.
Then it was unlocked in PR 2027 when support for Ruby 2.5 was dropped.
However, front_matter_parser was also dependabot-ignored in PR 2021, and I think
it was never un-ignored, so dependabot hasn't suggested an upgrade.
Bumps [pg](https://github.com/ged/ruby-pg) from 1.2.3 to 1.3.0.
- [Release notes](https://github.com/ged/ruby-pg/releases)
- [Changelog](https://github.com/ged/ruby-pg/blob/master/History.rdoc)
- [Commits](ged/ruby-pg@v1.2.3...v1.3.0)

---
updated-dependencies:
- dependency-name: pg
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Silences this warning while running "bundle exec rspec":

    WARN Selenium [DEPRECATION] [:browser_options] :options as a parameter for
    driver initialization is deprecated. Use :capabilities with an Array of
    value capabilities/options if necessary instead.

But with a cleaner approach from that introduced in thoughtbot#2064.
Remove Aliases in "config/secrets.yml" to support Ruby 3.1 + Rails 6.1

Ruby 3.1 ships with Psych 4. Psych 4 switched it's default YAML parsing mode to
a safer mode, including not allowing aliases. This broke parsing of
"secrets.yml" in Rails, if the secrets file contains any aliases.

Some discussion: https://bugs.ruby-lang.org/issues/17866

Rails PR 42687 implemented a fix, and that fix was included in Rails 7 here:
rails/rails@0ebb708

It was also included in the Rails 6-1-stable branch here:
rails/rails@aac3edb

But that commit happened after Rails 6.1.4 was published, and no patch-level
releases have been made for Rails 6.1 since that commit. Only security-level
releases have been published. I assume if Rails 6.1.5 is released it will
contain the fix.

Until Rails 6.1.5 is released, the best option to be able to test Ruby 3.1
against Rails 6.1 apps is probably to just eliminate any aliases in yaml files
that Rails uses.

Using new CircleCI image "cimg/ruby"
And refactor ".circleci/config" a bit.

With all the current variations & limitations it's probably better to just list
the supported configurations explicitly rather than trying to share config
blocks.
`classify` will singularise a namespace, that feels like unintended behaviour. E.g. if I use `--namespace=operations`, with `classify`, the generated module name is `Operation`, but I would expect this to be `Operations`.

Swapping `classify` for `camelize` solves this issue.
dependabot bot and others added 5 commits February 2, 2022 11:09
Bumps [pg](https://github.com/ged/ruby-pg) from 1.3.0 to 1.3.1.
- [Release notes](https://github.com/ged/ruby-pg/releases)
- [Changelog](https://github.com/ged/ruby-pg/blob/master/History.rdoc)
- [Commits](ged/ruby-pg@v1.3.0...v1.3.1)

---
updated-dependencies:
- dependency-name: pg
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
If you have ActiveRecord i18n translation of the model you don't need to do
anything extra, if not, make an ActiveRecord i18n translation of the model.

e.g.:

The recipe has many recipe items.

```ruby
ATTRIBUTE_TYPES = {
  recipe_items: Field::HasMany,
  id: Field::Number,
  name: Field::String,
  package_spec: Field::String,
  remark: Field::String,
  created_at: Field::DateTime,
  updated_at: Field::DateTime,
}.freeze
```

```yaml
zh-TW:
  activerecord:
    models:
      recipe: 配方表
      recipe_item: 材料
```
@n-studio n-studio merged commit 5a0b9b3 into compile-assets Feb 4, 2022
@n-studio n-studio deleted the fix/datetime-picker branch February 4, 2022 07:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants