glaubinix
Repos
61
Followers
42
Following
25

Simple conference schedule app

14
3

Dynamic quest system including features such as tasks, rewards, slots,

4
1

Private Packagist API Client

29
8

Dependency Manager for PHP

26967
4061

Package Repository Website - try https://packagist.com if you need your own -

1596
441

A PHP port of Ruby's Factory Girl.

112
27

Events

glaubinix create branch main
Created at 2 weeks ago
glaubinix create repository
Created at 2 weeks ago
glaubinix create tag 1.30.0
Created at 2 weeks ago

API: Add SDK Methods for Team Management Endpoints

Team Permissions Model

Team: Add Type-honts and Update Tests

Team: Permissions from Team Response

Team: DELETE Requests should return empty response, consistent with the rest of SDK

Team: Make Permissions Model Final

Merge pull request #55 from zanbaldwin/z/team-management-endpoints

API: Add SDK Methods for Team Management Endpoints

Created at 2 weeks ago
API: Add SDK Methods for Team Management Endpoints

See packagist/private-packagist#1954

Created at 2 weeks ago
glaubinix delete tag 1307.0.0
Created at 2 weeks ago
glaubinix create tag 1317.0.0
Created at 2 weeks ago
glaubinix delete tag 1786.0.0
Created at 2 weeks ago
glaubinix create tag 1796.0.0
Created at 2 weeks ago
issue comment
FilesystemAdapter::listContents inconsistent exception handling

Thank you!

Created at 2 weeks ago
opened issue
FilesystemAdapter::listContents inconsistent exception handling

Bug Report

| Q | A |------------ | ------ | BC Break | no | Version | 3.3.0

Summary

Methods of a FilesystemAdapter implementation usually throw a FilesystemException in case the operation fails, e.g. UnableToCheckFileExistence if something fails while checking the existence of a file. FilesystemAdapter::listContents is the exception here as it (or better the returned Generator) throws an implementation specific exception, e.g. for the AwsS3V3Adapter an S3Exception or CredentialsException is thrown.

How to reproduce

The example below will throw a \Aws\Exception\CredentialsException because no credentials are sent to AWS.

$filesystem = new \League\Flysystem\Filesystem(
    new \League\Flysystem\AwsS3V3\AwsS3V3Adapter(
        new \Aws\S3\S3Client(['region' => 'us-east-1', 'version' => 'latest']),
        'invalid-bucket'
    )
);
$items = $filesystem->listContents('', true);
foreach ($items as $item) {
    $doSomething = true;
}
Created at 2 weeks ago
delete branch
glaubinix delete branch docs-cleanup-authentication
Created at 2 weeks ago

Docs: remove OAuth1 from authentication docs and fix OAuth2 bearer auth example

Merge pull request #9 from packagist/docs-cleanup-authentication

Docs: remove OAuth1 from authentication docs and fix OAuth2 bearer auth example

Created at 2 weeks ago
pull request closed
Docs: remove OAuth1 from authentication docs and fix OAuth2 bearer auth example

Resolves https://github.com/packagist/bitbucket-api/issues/7

Created at 2 weeks ago
OAuth2 example seems broken (out of date?)

following the OAuth2 example on https://github.com/packagist/bitbucket-api/blob/master/docs/examples/authentication.md i think this should work:

composer require private-packagist/bitbucket-api php-http/guzzle6-adapter;
echo '<?php declare(strict_types=1); require_once("vendor/autoload.php"); 
 $oauth_params = array(
    "client_id"         => "aaa",
    "client_secret"     => "bbb",
);

$bitbucket = new \Bitbucket\API\Api();
$bitbucket->addPlugin(
    new \Bitbucket\API\Http\Plugin\OAuth2Plugin($oauth_params)
);' > test.php;
php test.php;

but when i run that, it crashes with

PHP Fatal error:  Uncaught Error: Class "Bitbucket\API\Http\Plugin\OAuth2Plugin" not found in /test2/test.php:9

full output:

$ composer require private-packagist/bitbucket-api php-http/guzzle6-adapter
Info from https://repo.packagist.org: #StandWithUkraine
Using version ^2.1 for private-packagist/bitbucket-api
Using version ^2.0 for php-http/guzzle6-adapter
./composer.json has been created
Running composer update private-packagist/bitbucket-api php-http/guzzle6-adapter
Loading composer repositories with package information
Updating dependencies
Lock file operations: 22 installs, 0 updates, 0 removals
  - Locking clue/stream-filter (v1.6.0)
  - Locking guzzlehttp/guzzle (6.5.8)
  - Locking guzzlehttp/promises (1.5.2)
  - Locking guzzlehttp/psr7 (1.9.0)
  - Locking php-http/client-common (2.5.0)
  - Locking php-http/discovery (1.14.3)
  - Locking php-http/guzzle6-adapter (v2.0.2)
  - Locking php-http/httplug (2.3.0)
  - Locking php-http/message (1.13.0)
  - Locking php-http/message-factory (v1.0.2)
  - Locking php-http/promise (1.1.0)
  - Locking private-packagist/bitbucket-api (2.1.0)
  - Locking psr/http-client (1.0.1)
  - Locking psr/http-factory (1.0.1)
  - Locking psr/http-message (1.0.1)
  - Locking ralouphie/getallheaders (3.0.3)
  - Locking symfony/deprecation-contracts (v3.1.1)
  - Locking symfony/options-resolver (v6.1.0)
  - Locking symfony/polyfill-intl-idn (v1.26.0)
  - Locking symfony/polyfill-intl-normalizer (v1.26.0)
  - Locking symfony/polyfill-php72 (v1.26.0)
  - Locking symfony/polyfill-php80 (v1.26.0)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 22 installs, 0 updates, 0 removals
  - Installing symfony/polyfill-php72 (v1.26.0): Extracting archive
  - Installing symfony/polyfill-intl-normalizer (v1.26.0): Extracting archive
  - Installing symfony/polyfill-intl-idn (v1.26.0): Extracting archive
  - Installing ralouphie/getallheaders (3.0.3): Extracting archive
  - Installing psr/http-message (1.0.1): Extracting archive
  - Installing guzzlehttp/psr7 (1.9.0): Extracting archive
  - Installing guzzlehttp/promises (1.5.2): Extracting archive
  - Installing guzzlehttp/guzzle (6.5.8): Extracting archive
  - Installing php-http/message-factory (v1.0.2): Extracting archive
  - Installing clue/stream-filter (v1.6.0): Extracting archive
  - Installing php-http/message (1.13.0): Extracting archive
  - Installing php-http/promise (1.1.0): Extracting archive
  - Installing psr/http-client (1.0.1): Extracting archive
  - Installing php-http/httplug (2.3.0): Extracting archive
  - Installing php-http/discovery (1.14.3): Extracting archive
  - Installing php-http/guzzle6-adapter (v2.0.2): Extracting archive
  - Installing symfony/polyfill-php80 (v1.26.0): Extracting archive
  - Installing symfony/deprecation-contracts (v3.1.1): Extracting archive
  - Installing symfony/options-resolver (v6.1.0): Extracting archive
  - Installing psr/http-factory (1.0.1): Extracting archive
  - Installing php-http/client-common (2.5.0): Extracting archive
  - Installing private-packagist/bitbucket-api (2.1.0): Extracting archive
10 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating autoload files
10 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
No security vulnerability advisories found
$ echo '<?php declare(strict_types=1); require_once("vendor/autoload.php"); 
 $oauth_params = array(
    "client_id"         => "aaa",
    "client_secret"     => "bbb",
);

$bitbucket = new \Bitbucket\API\Api();
$bitbucket->addPlugin(
    new \Bitbucket\API\Http\Plugin\OAuth2Plugin($oauth_params)
);' > test.php
$ php test.php
PHP Fatal error:  Uncaught Error: Class "Bitbucket\API\Http\Plugin\OAuth2Plugin" not found in /test2/test.php:9
Stack trace:
#0 {main}
  thrown in /test2/test.php on line 9

also.. does anyone know how to use OAuth2 with this api? i haven't figured it out yet

Created at 2 weeks ago
issue comment
OAuth2 example seems broken (out of date?)

Bitbucket doesn't support OAuth1 anymore. I updated the OAuth2 example here. This library doesn't provide code anymore to obtain an OAuth2 access token but there are several other packages out there that can help with that. The Bitbucket docs linked at the bottom of the authentication.md file also shows to obtain the access token

Created at 2 weeks ago
pull request opened
Docs: remove OAuth1 from authentication docs and fix OAuth2 bearer auth example

Resolves https://github.com/packagist/bitbucket-api/issues/7

Created at 2 weeks ago