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
doesn't work with LC_TIME=nb_NO.UTF8 ? #11
Comments
Wow. for some reason the command any idea why composer defaults to version 0.0.2 when 0.5.0 is available? (and has been available for 3 months now) |
Composer cache may have affected you: >composer require php81_bc/strftime
Info from https://repo.packagist.org: #StandWithUkraine
Using version ^0.5.0 for php81_bc/strftime
./composer.json has been created
Running composer update php81_bc/strftime
Loading composer repositories with package information
Updating dependencies
Lock file operations: 1 install, 0 updates, 0 removals
- Locking php81_bc/strftime (0.5.0)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
- Installing php81_bc/strftime (0.5.0): Extracting archive
Generating autoload files >composer info php81_bc/strftime
name : php81_bc/strftime
descrip. : Locale-formatted strftime using IntlDateFormatter (PHP 8.1 compatible)
keywords :
versions : * 0.5.0
type : library
license : MIT License (MIT) (OSI approved) https://spdx.org/licenses/MIT.html#licenseText
homepage :
source : [git] https://github.com/alphp/strftime.git 4c1b56eaae4bb3f02f994ba47c2e5a225378e62f
dist : [zip] https://api.github.com/repos/alphp/strftime/zipball/4c1b56eaae4bb3f02f994ba47c2e5a225378e62f 4c1b56eaae4bb3f02f994ba47c2e5a225378e62f
path : E:\_\kk\vendor\php81_bc\strftime
names : php81_bc/strftime
support
issues : https://github.com/alphp/strftime/issues
source : https://github.com/alphp/strftime
autoload
files
requires
ext-intl *
php >=7.1.0
requires (dev)
phpunit/phpunit @stable |
@alphp no i don't think so, here is a system that i believe has never ran composer before, and it also defaulted to 0.0.2:
|
It's strange. I don't know how the composer/packagist network works, but it seems that at some point the cache is not up to date. |
strange indeed. do you have Docker? |
I don't work with docker. |
@alphp the plot thickens. I am able to reproduce it on a clean docker image using the newest Composer version, this Dockerfile reproduce the issue, installing 0.0.2 on a clean system that has never ran Composer before:
However, if we use an older composer, the composer version that ships with Ubuntu 20.04, currently composer version 1.10.1-1, it does not reproduce the issue, this Dockerfile installs 0.5.0:
(it uses Ubuntu 20.04's default Composer, the ancient v1.10.1) practically speaking, it reproduce on Composer version 2.3.7 (installing 0.0.2) but it does not reproduce on Composer version 1.10.1 (it installs 0.5.0), when you said it works on Windows and CentOS, which versions of Composer were they running? |
2.0.1 in CentOS 6, 2.3.5 and 2.3.7 in Windows. |
"composer require php81_bc/strftime:@stable" also installs 0.0.2 btw if you could install Docker on a linux system, the way to test it on Docker for Linux is:
(btw i didn't type that echo command manually, i generated it with https://3v4l.org/59Fdt )
|
(could be a nice introduction to Docker, there's a first time for everything right? ^^) |
in any case, looks like a Composer issue, not a alphp/strftime issue, i've raised an issue with Composer: composer/composer#10884 |
I will leave the issue open for a while to follow up. |
composer/composer#10884 (comment)
|
my LC_TIME is "nb_NO.UTF8", and $format is "%A %d. %B" and $timestamp is 1655935200 and strftime() gives me "torsdag 23. juni", but \PHP81_BC\strftime gives me "Thursday 23. June"
.. any idea what went wrong here? reproduce script:
outputs on my system (PHP7.4.29):
what went wrong here?
The text was updated successfully, but these errors were encountered: