Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jul 16 15:13
    aik099 commented #139
  • Jul 16 15:12

    aik099 on 1.3.3

    (compare)

  • Jul 16 15:11

    aik099 on master

    Preparing 1.3.3 release (compare)

  • Jul 16 15:04
    aik099 commented #139
  • Jul 16 15:04

    aik099 on master

    ignore phpstan annotations ignore code coverage annotations ignore psalm annotations and 1 more (compare)

  • Jul 16 15:04
    aik099 closed #139
  • Jul 13 14:12
    dimtrovich commented #139
  • Jul 08 17:39
    aik099 commented #139
  • Jul 08 16:05
    dimtrovich review_requested #139
  • Jun 27 18:04
    aik099 commented #139
  • Jun 27 17:14
    dimtrovich opened #139
  • Dec 08 2021 11:36
    mindplay-dk commented #138
  • Dec 06 2021 16:19
    aik099 closed #138
  • Dec 06 2021 16:19
    aik099 commented #138
  • Dec 04 2021 18:59
    aik099 opened #138
  • Nov 07 2021 18:13
    aik099 closed #137
  • Nov 07 2021 18:13

    aik099 on master

    Improve GitHub Actions workflow… Merge pull request #137 from ai… (compare)

  • Nov 07 2021 18:06
    aik099 opened #137
  • Oct 31 2021 11:28

    aik099 on master

    Change build badge to Travis CI (compare)

  • Oct 31 2021 11:25

    aik099 on master

    Move to GitHub Actions (#136) … (compare)

Alex
@aik099
Yeah, we had some issues with attempts to get annotations from built-in classes or classes, that sub-class built-in ones, like PDO or SplFile.
Lester Caine
@lsces
My biggest stumbling block is 'namespace' ... any attempt to try and add that to bitweaver seem to fail ...
Alex
@aik099
php-annotations respects namespaces. you also can get annotations from classes that doesn't use namespaces.
but it seems that what you're talking about here isn't the "how do I use php-annotations" problem belonging to this chat room, but rather "how do I make another library to work with composer" problem, which isn't topic to be discussed here.
Lester Caine
@lsces
How about 'Install dependencies first ' ;) Have php-annotations added to my local github mirror and now I need to bypass the composer install so I can run the demo stuff.
Alex
@aik099

How about 'Install dependencies first '

Not sure what you mean by that.

Lester Caine
@lsces
Basically how do I use php-annotations WITHOUT composer ... I run php on several servers and have phar disabled along with 'command line' php as they run several versions in parallel in order to keep legacy sites running while bowing to the pressure from the security needs of other code. I don't need composer to run any of the rest of the code base ... http://lsces.org.uk/externals/php-annotations/demo/index.php
Alex
@aik099
You can. Not sure if it's still there, but before php-annotations was using composer it was using it's own auto-loader. If it's missing then:
  • you can create one and submit PR that I would gladly accept
  • you can configure auto-loader you-re using in the project to auto-load php-annotations own classes
Lester Caine
@lsces
It was using Loader.php from the test section. Now I've got the development environment sorted I can rewind prior to composer as necessary ;)
Alex
@aik099
I highly don't recommend doing that due number of bugfixes and improvements since that moment.
I recommend sending a PR where Loader.php is resurrected and updated to support new class placement.
You won't be able to use the library on PHP 5.2 though if that's your intension due namespace usage.
Lester Caine
@lsces
That is more what I mean ... but I have the demo code using Loader and can identify other changes ...
Lester Caine
@lsces
Main problem with the autoloader crap is that the directory names no longer line up ... mindplay -> src ... but then I refuse to use PSR as well ;)
Alex
@aik099
it's PSR-4 now if I'm not mistaken
I've created an issue about this php-annotations/php-annotations#111 . Once you send a PR you can reference that issue.
Lester Caine
@lsces
I can see now why I was having a problem with the Smarty3 recent switch to composer ... just sorted the problem that created so bypassing composer here should be a little easier. I'd not twigged that 'namespace' and 'directory' did not need to be the same, so while the classes are still 'mindplay', they can be loaded from 'src' ...
Alex
@aik099
the filenames match class name as in PSR-0, but the namespace prefix is mapped to src directory. not that hard.
Lester Caine
@lsces
http://lsces.org.uk/externals/php-annotations/demo/index.php ... the demo namespace is messing up the code one ... at least I think that is the case, I'll have the local code mirror accessible shortly ...
Lester Caine
@lsces
http://hg.lsces.org.uk/bw/bitweaver/externals/php-annotations/rev/6f00bebda38d ... mirror of github which I can play with locally. My problem is not really understanding where the automatic load picks up different directories of files.
the demo script adds one more mapping to that array: https://github.com/php-annotations/php-annotations/blob/master/demo/index.php#L20
just basic composer autoloader configuration, nothing custom here.
Lester Caine
@lsces
But I don't have composer loaded ... trying to avoid the hassle.
Alex
@aik099
I'm still not sure why you you've decided not to use Composer, but it's your choice and I'm respecting it. Please do inspect composer autoloader code next time instead of reinventing the wheel.
Lester Caine
@lsces
I've supposedly installed it on this machine ... but I can't find where it's hidden itself! My code was never designed to follow the changes that PSR and composer now require and it's proving difficult when the likes of Smarty now break working code by changing everything to work with it. My production servers all run nginx and various fpm versions of PHP including PHP5.2 still, so some code has to be stable back that far and keeping composer out of the picture helps make that stable.
Alex
@aik099
I see. Then I wish you luck with writing custom autoloader for php-annotations and looking forward to seeing PR containing it from you.
Lester Caine
@lsces
OK I've got my own PSR4 loader and that is working, but the error is the same ... where IS the RangeAnnotation class defined? http://lsces.org.uk/externals/php-annotations/demo/ is now running with the AutoLoader and a modified index.php file so NOW I can start playing :)
Alex
@aik099
Do you have xdebug installed? It would be really easier to just debug and see line where it fails. The https://github.com/php-annotations/php-annotations/blob/master/demo/index.php#L31 line adds @range annotation by specifying FQCN of RangeAnnotation class.
Lester Caine
@lsces
There is no class in the code for RangeAnnotation. I run Eclipse/PDT and I can switch on xdebug, but I don't need that to see https://github.com/php-annotations/php-annotations/tree/master/src/annotations/standard has no RangeAnnotation and there is nothing in the AnnotationManager to register it. I've found it back at rev 85, along with some of the other annotations loaded as part of the demo, but they should all be in the main code base!
Alex
@aik099
:smile: , so the demo isn't working even, when powered by Composer's autoloader you're saying?
Lester Caine
@lsces
I would be most surprised if it was ...
Alex
@aik099
Apparently we've forgot that annotation is used in the demo, when moved them to "standard-annotations" branch: https://github.com/php-annotations/php-annotations/tree/standard-annotations/src/annotations/standard
Alex
@aik099
As I've said above it's in "standard-annotations" branch
php-annotations/php-annotations#112 - I've created an issue about it
solution is simple: copy over it's definition from that branch into demo namespace & register it within demo annotation package
a PR for that would be awesome
I guess nobody tried to run demo code recently
Lester Caine
@lsces
Would have been nice if you flagged that master branch is defunct and no longer supported!
Alex
@aik099
it's otherwise
the "master" branch is supported
the "standard-annotations" isn't
fact, that you've found a bug in "master" branch doesn't mean it's no longer supported. it's bug in demo script after all, that isn't used in production.
:smile:
Lester Caine
@lsces
https://github.com/php-annotations/php-annotations defaults to master ... select standard-annotations branch and I see the /tree/standard-annotations and the correct code!
Alex
@aik099
in old days standard annotations were part of master branch. since they doesn't help anybody we've moved them to separate branch for review and copied ones, needed by demo script to demo namespace
as I've said in above mentioned task the RangeAnnotation class was forgotten in that move
Lester Caine
@lsces
I'm getting lost here ... range and length are just the annotations I want to use as standard annotations ... but they are not supplied as standard?